debuggers.hg

changeset 22669:a71729704d4b

x86 xsave: Fix 64bit xsave_feature support for set_xcr0().

Signed-off-by: Wei Huang <wei.huang2@amd.com>
author Keir Fraser <keir@xen.org>
date Fri Dec 24 08:37:34 2010 +0000 (2010-12-24)
parents a0228a0f3fd2
children 26e7e6c6ff7f
files xen/arch/x86/i387.c
line diff
     1.1 --- a/xen/arch/x86/i387.c	Fri Dec 24 08:32:43 2010 +0000
     1.2 +++ b/xen/arch/x86/i387.c	Fri Dec 24 08:37:34 2010 +0000
     1.3 @@ -187,7 +187,7 @@ void xsave_init(void)
     1.4       * Set CR4_OSXSAVE and run "cpuid" to get xsave_cntxt_size.
     1.5       */
     1.6      set_in_cr4(X86_CR4_OSXSAVE);
     1.7 -    set_xcr0(eax & XCNTXT_MASK);
     1.8 +    set_xcr0((((u64)edx << 32) | eax) & XCNTXT_MASK);
     1.9      cpuid_count(XSTATE_CPUID, 0, &eax, &ebx, &ecx, &edx);
    1.10  
    1.11      if ( cpu == 0 )