]> git.baikalelectronics.ru Git - kernel.git/commit
xen: Allow PV-OPS kernel to detect whether XSAVE is supported
authorShan Haitao <haitao.shan@intel.com>
Tue, 9 Nov 2010 19:43:36 +0000 (11:43 -0800)
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Wed, 6 Apr 2011 12:31:13 +0000 (08:31 -0400)
commitc46e8c258827dd2fbc560f1f21078d01e808dee7
treeade0284004bf6cb7a16a6afd85c3e79b2538fc4d
parent9f863954b961fba5b6abcd4cdc68e0a2d89e342d
xen: Allow PV-OPS kernel to detect whether XSAVE is supported

Xen fails to mask XSAVE from the cpuid feature, despite not historically
supporting guest use of XSAVE.  However, now that XSAVE support has been
added to Xen, we need to reliably detect its presence.

The most reliable way to do this is to look at the OSXSAVE feature in
cpuid which is set iff the OS (Xen, in this case), has set
CR4.OSXSAVE.

[ Cleaned up conditional a bit. - Jeremy ]

Signed-off-by: Shan Haitao <haitao.shan@intel.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
arch/x86/xen/enlighten.c