From: Keir Fraser <keir@xensource.com>
To: Jan Beulich <jbeulich@novell.com>
Cc: xen-devel@lists.xensource.com
Subject: Re: NMI deferral on i386
Date: Wed, 23 May 2007 11:03:40 +0100 [thread overview]
Message-ID: <C279D00C.F628%keir@xensource.com> (raw)
In-Reply-To: <4651CA2F.76E4.0078.0@novell.com>
Well, this sounds fine to me. If you port it I'll apply it. I would prefer
it as a separate patch from the rest of the MCA/MCE changes really, but if
that's a pain then don't worry about it.
-- Keir
On 21/5/07 15:34, "Jan Beulich" <jbeulich@novell.com> wrote:
> The idea is to always check values read from %ds and %es against
> __HYPERVISOR_DS,
> and only store into the current frame (all normal handlers) or the outer-most
> one (NMI and MCE) if the value read is different. That way, any NMI or MCE
> occurring during frame setup will store selectors not saved so far on behalf
> of
> the interrupted handler, with that interrupted handler either having managed
> to read the guest selector (in which case it can store it regardless of
> whether
> NMI/MCE kicked in between the read and the store) or finding __HYPERVISOR_DS
> already in the register, in which case it'll know not to store (as the nested
> handler would have done the store).
>
> For the restore portion this makes use of the fact that there's exactly one
> such code sequence, and by moving the selector restore part past all other
> restores (including all stack pointer adjustments) the NMI/MCE handlers can
> safely detect whether any selector would have been restored already (by
> range checking EIP) and move EIP back to the beginning of the selector
> restore sequence without having to play with the stack pointer itself or any
> other gpr.
prev parent reply other threads:[~2007-05-23 10:03 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-15 14:46 NMI deferral on i386 Jan Beulich
2007-05-15 15:00 ` Keir Fraser
2007-05-16 8:17 ` Jan Beulich
2007-05-16 8:28 ` Keir Fraser
2007-05-16 10:10 ` Jan Beulich
2007-05-16 12:32 ` Keir Fraser
2007-05-16 14:19 ` Jan Beulich
2007-05-21 14:01 ` Jan Beulich
2007-05-21 14:17 ` Keir Fraser
2007-05-21 14:34 ` Jan Beulich
2007-05-23 10:03 ` Keir Fraser [this message]
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=C279D00C.F628%keir@xensource.com \
--to=keir@xensource.com \
--cc=jbeulich@novell.com \
--cc=xen-devel@lists.xensource.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.