Re: [Xen-devel] [PATCH 7/9] x86: skip check for spurious faults for non-present faults

From: H. Peter Anvin
Date: Thu May 15 2014 - 15:52:31 EST


On 05/15/2014 12:22 PM, Keir Fraser wrote:
>>
>> Are we chasing hardware errata here? Or did someone go off and *assume*
>> that the x86 hardware architecture work a certain way? Or is there
>> something way more subtle going on?
>
> See Intel Developer's Manual Vol 3 Section 4.10.4.3, 3rd bullet... This
> is expected behaviour, probably to make copy-on-write faults faster.
>

Hm, yes. My memory of this comes from before these formal rules were
written down... I guess there is some wiggle room in there, presumably
as you say, for performance reasons (or implementation leeway, which is
another way to say performance.)

This does make a P bit switch architecturally different from W or NX, so
I'm okay with that, but I would like the patch adjusted in the following
ways:

1. Put in an explicit comment about the architectural difference
between the P bit on one hand and an W and NX on the other; an SDM
reference is good, and *why* this makes the specific filtering
correct.

2. Please use the standard format for multiline comments;

/*
* blah
* blah
*/

With that this should be okay.

-hpa

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/