From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: Xen HVM regression on certain Intel CPUs Date: Wed, 27 Mar 2013 10:23:59 -0700 Message-ID: <51532B2F.60506@zytor.com> References: <51530F9F.10805@canonical.com> <515315EC.4030803@canonical.com> <20130327160427.GB6688@phenom.dumpdata.com> <5153222B.3030605@canonical.com> <515323D4.2030806@zytor.com> <5153299A.7070108@canonical.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <5153299A.7070108@canonical.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Stefan Bader Cc: wei.y.yang@intel.com, "xen-devel@lists.xensource.com" , haitao.shan@intel.com, xin.li@intel.com, Konrad Rzeszutek Wilk List-Id: xen-devel@lists.xenproject.org On 03/27/2013 10:17 AM, Stefan Bader wrote: >> What does x86info and /proc/cpuinfo show in HVM? > > x86info cpuid[7].ebx = 0xbbb and /proc/cpuinfo also shows smep > set. On all CPUs? >> The inbound %cr4 shouldn't matter at all, we try to not rely on >> it. >> >> If the hypervisor presents SMEP to the guest then the guest is >> pretty obviously going to try to use it. > > To me it looks like when bootstrapping the APs things are not yet > ready to use it. If I did not miss something, the only place that > the saved contents of cr4 are used is in startup_32 when the cpus > are brought up. And then just stop dead. Would need to read more > code but a bit weird why the BP is not affected. This feels like a bug in Xen, but I don't know for sure yet. Either which way, it is odd. That write to cr4 should be entirely legitimate. -hpa