xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Tamas K Lengyel <tamas@tklengyel.com>
To: Razvan Cojocaru <rcojocaru@bitdefender.com>
Cc: Wei Liu <wei.liu2@citrix.com>, Keir Fraser <keir@xen.org>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	Andrew Cooper <andrew.cooper3@citrix.com>,
	Ian Jackson <ian.jackson@eu.citrix.com>,
	Julien Grall <julien.grall@arm.com>,
	Jan Beulich <jbeulich@suse.com>,
	Xen-devel <xen-devel@lists.xenproject.org>
Subject: Re: [PATCH v2 2/5] vm_event: Implement ARM SMC events
Date: Fri, 29 Apr 2016 14:12:48 -0600	[thread overview]
Message-ID: <CABfawhmHmFDH5R9QZ3XV-zykrk=Z4-i_fHWgyod5swys52Oo4w@mail.gmail.com> (raw)
In-Reply-To: <ee51bce5-e2f9-a1d6-d368-c291c1196846@bitdefender.com>


[-- Attachment #1.1: Type: text/plain, Size: 1701 bytes --]

> @@ -2491,6 +2492,21 @@ bad_data_abort:
> >      inject_dabt_exception(regs, info.gva, hsr.len);
> >  }
> >
> > +static void do_trap_smc(struct cpu_user_regs *regs, const union hsr hsr)
> > +{
> > +    int rc = 0;
> > +    if ( current->domain->arch.monitor.privileged_call_enabled )
> > +    {
> > +        rc = monitor_smc(regs);
> > +    }
>
>
> If you need to increment the patch version, maybe remove the curly
> braces here?
>

Sure.


>
> > diff --git a/xen/common/vm_event.c b/xen/common/vm_event.c
> > index 2906407..a29bda8 100644
> > --- a/xen/common/vm_event.c
> > +++ b/xen/common/vm_event.c
> > @@ -818,7 +818,6 @@ int vm_event_monitor_traps(struct vcpu *v, uint8_t
> sync,
> >          req->altp2m_idx = altp2m_vcpu_idx(v);
> >      }
> >
> > -    vm_event_fill_regs(req);
> >      vm_event_put_request(d, &d->vm_event->monitor, req);
> >
> >      return 1;
>
> So now for x86 we only vm_fill_regs() for CR writes and breakpoints (and
> EPT faults, but that's in p2m.c which hasn't been touched by this
> patch)? That's a pretty big change, and one that's not explained in the
> patch description (which makes no mention of any x86 changes).
>
> Having that call in vm_event_monitor_traps() made sure that all
> vm_events get a copy of the respective registers. In the x86 case, that
> includes the guest request and MSR write events, which now no longer
> seem to carry that information, unless I'm missing something.
>
> That behaviour should not change for x86 events, please.
>

Yeap, good catch. It needs to be moved from the common path because the
inputs to the function will differ on ARM and x86. I'll double-check that
the x86 paths will remain functionally the same.

Tamas

[-- Attachment #1.2: Type: text/html, Size: 2473 bytes --]

[-- Attachment #2: Type: text/plain, Size: 126 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

  reply	other threads:[~2016-04-29 20:12 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-29 18:07 [PATCH v2 1/5] monitor: Rename vm_event_monitor_get_capabilities Tamas K Lengyel
2016-04-29 18:07 ` [PATCH v2 2/5] vm_event: Implement ARM SMC events Tamas K Lengyel
2016-04-29 20:07   ` Razvan Cojocaru
2016-04-29 20:12     ` Tamas K Lengyel [this message]
2016-04-29 20:27       ` Tamas K Lengyel
2016-04-29 20:32         ` Razvan Cojocaru
2016-05-02 10:35   ` Wei Liu
2016-05-03 11:31   ` Julien Grall
2016-05-03 18:48     ` Tamas K Lengyel
2016-05-04 10:31       ` Julien Grall
     [not found]         ` <CABfawhmwVQyYeGYMxKTb1zMUkyOSutMwm4bkTxoeNaFTmGuyXA@mail.gmail.com>
     [not found]           ` <CABfawhmVUyqcuoxitKrXxcg93yLY4e8H7S1A_GEFbX3+Vb-hrA@mail.gmail.com>
2016-05-04 12:42             ` Tamas K Lengyel
2016-05-04 13:26               ` Julien Grall
2016-05-04 13:30                 ` Razvan Cojocaru
2016-05-04 14:03                   ` Julien Grall
2016-05-04 14:08                     ` Tamas K Lengyel
2016-04-29 18:07 ` [PATCH v2 3/5] x86/hvm: Rename hvm/event to hvm/monitor Tamas K Lengyel
2016-05-04  1:13   ` Tian, Kevin
2016-04-29 18:07 ` [PATCH v2 4/5] x86/hvm: Add debug exception vm_events Tamas K Lengyel
2016-05-02 13:12   ` Jan Beulich
2016-05-02 15:35     ` Tamas K Lengyel
2016-05-02 15:40       ` Jan Beulich
2016-05-02 15:45         ` Tamas K Lengyel
2016-04-29 18:07 ` [PATCH v2 5/5] MAINTAINERS: Update monitor/vm_event covered code Tamas K Lengyel
2016-05-02 13:00   ` Jan Beulich
2016-05-03  8:18   ` Jan Beulich
2016-05-03  8:20     ` Razvan Cojocaru
2016-05-03  8:26       ` Jan Beulich
2016-05-03  9:09     ` Wei Liu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CABfawhmHmFDH5R9QZ3XV-zykrk=Z4-i_fHWgyod5swys52Oo4w@mail.gmail.com' \
    --to=tamas@tklengyel.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=jbeulich@suse.com \
    --cc=julien.grall@arm.com \
    --cc=keir@xen.org \
    --cc=rcojocaru@bitdefender.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).