From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Jan Beulich <JBeulich@suse.com>
Cc: Kevin Tian <kevin.tian@intel.com>,
Jun Nakajima <jun.nakajima@intel.com>,
Xen-devel <xen-devel@lists.xen.org>
Subject: Re: [PATCH v2 1/2] x86/vmx: Introduce a bitfield structure for EPT_VIOLATION EXIT_QUALIFICATIONs
Date: Wed, 8 Feb 2017 15:04:58 +0000 [thread overview]
Message-ID: <c7bbe4dd-94b0-f8e2-c51d-cc902b1ecb79@citrix.com> (raw)
In-Reply-To: <589B2B000200007800137BBC@prv-mh.provo.novell.com>
On 08/02/17 13:28, Jan Beulich wrote:
>>>> On 08.02.17 at 14:03, <andrew.cooper3@citrix.com> wrote:
>> On 08/02/17 12:30, Jan Beulich wrote:
>>>>>> On 08.02.17 at 12:56, <andrew.cooper3@citrix.com> wrote:
>>>> On 08/02/17 11:53, Jan Beulich wrote:
>>>>>>>> On 08.02.17 at 11:44, <andrew.cooper3@citrix.com> wrote:
>>>>>> On 08/02/17 10:42, Andrew Cooper wrote:
>>>>>>> This results in rather more readable code. No functional change.
>>>>>>>
>>>>>>> All fields currently specified are included, but commented out as no support
>>>>>>> for their use is present.
>>>>>> Apologies - sent a slightly stale version of the patch. I have dropped
>>>>>> this paragraph from the commit message, but the code is correct for v2.
>>>>> With that and despite ...
>>>>>
>>>>>>> Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
>>>>>>> ---
>>>>>>> CC: Jan Beulich <JBeulich@suse.com>
>>>>>>> CC: Jun Nakajima <jun.nakajima@intel.com>
>>>>>>> CC: Kevin Tian <kevin.tian@intel.com>
>>>>>>>
>>>>>>> v2:
>>>>>>> * Use a transparent union rather than modifying the caller of
>>>>>>> ept_handle_violation()
>>>>>>> * Drop the extranious commented out bitfield names, but keep eff_user_exec so
>>>>>>> gla_{valid,fault} are appropriately located.
>>>>> ... this not really being what Kevin and I had asked for,
>>>>> Reviewed-by: Jan Beulich <jbeulich@suse.com>
>>>> In which case I am confused? What were you asking for if it isn't this?
>>> The request was to keep commented out just the one field use of
>>> which needs enabling work elsewhere, but present as normal
>>> (named) fields the three higher ones we currently lack.
>> All of the originally commented out bits need further work in Xen to enable.
>>
>> The higher bits are undefined if advanced EPT Violation VM-exit
>> information is unavailable in hardware, meaning that they are not safe
>> to use currently.
> Bit 6 requires a control to be turned on, but the same doesn't hold
> for bits 9..11 according to my reading of the SDM.
This matches my reading.
> So consuming the bits would, as an integral part, require an additional feature check,
> but that is entirely independent of naming these fields.
Without a new vmx_ept_vpid_cap-based predicate, it is unsafe to read
those bits, because they are not guaranteed to be zero. (It is curious
that some fields are documented as reserved, and should be zero, while
these are documented as undefined.)
I purposefully don't want to make them available, because forcing
someone to modify ept_qual_t to use them will make it less likely that
we miss the above requirement on the review of the first patch which
starts to use them.
> And for bit 12 I don't see how it would be dangerous to give a name
> in any event (it's even shared with at least one other exit qual).
This particular bit falls into the grey category of "despite having a
clear name, its not obvious what to do with it". I haven't yet found
any indication in the manuals as to whether it is purely informative, or
whether action needs to be taken.
~Andrew
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2017-02-08 15:04 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-30 16:54 [PATCH 1/2] x86/vmx: Introduce a bitfield structure for EPT_VIOLATION EXIT_QUALIFICATIONs Andrew Cooper
2017-01-30 16:54 ` [PATCH 2/2] x86/vmx: Drop ept_get_*() helpers Andrew Cooper
2017-01-30 18:01 ` George Dunlap
2017-01-31 10:22 ` Jan Beulich
2017-02-08 7:06 ` Tian, Kevin
2017-01-31 10:19 ` [PATCH 1/2] x86/vmx: Introduce a bitfield structure for EPT_VIOLATION EXIT_QUALIFICATIONs Jan Beulich
2017-01-31 10:39 ` Andrew Cooper
2017-01-31 10:56 ` Jan Beulich
2017-02-08 7:06 ` Tian, Kevin
2017-02-08 10:42 ` [PATCH v2 " Andrew Cooper
2017-02-08 10:44 ` Andrew Cooper
2017-02-08 11:53 ` Jan Beulich
2017-02-08 11:56 ` Andrew Cooper
2017-02-08 12:30 ` Jan Beulich
2017-02-08 13:03 ` Andrew Cooper
2017-02-08 13:28 ` Jan Beulich
2017-02-08 15:04 ` Andrew Cooper [this message]
2017-02-08 15:46 ` Jan Beulich
2017-02-09 0:41 ` Tian, Kevin
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=c7bbe4dd-94b0-f8e2-c51d-cc902b1ecb79@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=JBeulich@suse.com \
--cc=jun.nakajima@intel.com \
--cc=kevin.tian@intel.com \
--cc=xen-devel@lists.xen.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).