From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeremy Fitzhardinge Subject: Re: Re: [PATCH] x86: unconditionally mark TSC unstable under Xen Date: Thu, 15 Jul 2010 09:45:03 -0700 Message-ID: <4C3F3B0F.1040107@goop.org> References: <51C8308F-F413-47AF-8845-C92BD36CA35C@linode.com> <4C3E2DCC.1010201@goop.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Dan Magenheimer Cc: xen-devel@lists.xensource.com, Jed Smith , Jan Beulich , Stefano Stabellini List-Id: xen-devel@lists.xenproject.org On 07/15/2010 09:40 AM, Dan Magenheimer wrote: > Isn't the real problem that, in a PV guest, the cpuid instructions > that are testing the TSC-related CPUID bits are obtaining the actual > hardware value, rather than what Xen would like the guest to believe? > No, because there shouldn't be any "naked" rdtscs in the kernel. > IOW, isn't the correct fix to use pvcpuid instead of cpuid when > xen_pvdomain() is true? > Every use of cpuid in the kernel goes via the cpuid pvop, which ends up doing the Xen cpuid rather than the native one. Usermode cpuid is still the "real" one, unless they explicitly use the Xen version. J