diff options
Diffstat (limited to 'arch/x86/xen')
-rw-r--r-- | arch/x86/xen/enlighten.c | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 49dbd78ec3cb..66272a237622 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c | |||
@@ -250,23 +250,7 @@ static __init void xen_init_cpuid_mask(void) | |||
250 | ~((1 << X86_FEATURE_APIC) | /* disable local APIC */ | 250 | ~((1 << X86_FEATURE_APIC) | /* disable local APIC */ |
251 | (1 << X86_FEATURE_ACPI)); /* disable ACPI */ | 251 | (1 << X86_FEATURE_ACPI)); /* disable ACPI */ |
252 | 252 | ||
253 | ax = 1; | 253 | cpuid_leaf1_ecx_mask &= ~(1 << (X86_FEATURE_XSAVE % 32)); /* disable XSAVE */ |
254 | cx = 0; | ||
255 | xen_cpuid(&ax, &bx, &cx, &dx); | ||
256 | |||
257 | /* cpuid claims we support xsave; try enabling it to see what happens */ | ||
258 | if (cx & (1 << (X86_FEATURE_XSAVE % 32))) { | ||
259 | unsigned long cr4; | ||
260 | |||
261 | set_in_cr4(X86_CR4_OSXSAVE); | ||
262 | |||
263 | cr4 = read_cr4(); | ||
264 | |||
265 | if ((cr4 & X86_CR4_OSXSAVE) == 0) | ||
266 | cpuid_leaf1_ecx_mask &= ~(1 << (X86_FEATURE_XSAVE % 32)); | ||
267 | |||
268 | clear_in_cr4(X86_CR4_OSXSAVE); | ||
269 | } | ||
270 | } | 254 | } |
271 | 255 | ||
272 | static void xen_set_debugreg(int reg, unsigned long val) | 256 | static void xen_set_debugreg(int reg, unsigned long val) |