ia64/xen-unstable

changeset 15277:0feaf2fc75d3

xen: Boot on PAE systems with no EFER MSR.
Bug tracked down by Stefan Berger.
Signed-off-by: Keir Fraser <keir@xensource.com>
author kfraser@localhost.localdomain
date Tue Jun 05 10:28:59 2007 +0100 (2007-06-05)
parents 4f05a587cb6b
children c5cf3942b5da
files xen/arch/x86/boot/trampoline.S
line diff
     1.1 --- a/xen/arch/x86/boot/trampoline.S	Tue Jun 05 10:08:09 2007 +0100
     1.2 +++ b/xen/arch/x86/boot/trampoline.S	Tue Jun 05 10:28:59 2007 +0100
     1.3 @@ -60,17 +60,20 @@ trampoline_protmode_entry:
     1.4  
     1.5  #if CONFIG_PAGING_LEVELS != 2
     1.6          /* Set up EFER (Extended Feature Enable Register). */
     1.7 +        mov     SYM_TRAMP_PHYS(cpuid_ext_features),%edi
     1.8 +        test    $0x20100800,%edi /* SYSCALL/SYSRET, No Execute, Long Mode? */
     1.9 +        jz      .Lskip_efer
    1.10          movl    $MSR_EFER,%ecx
    1.11          rdmsr
    1.12  #if CONFIG_PAGING_LEVELS == 4
    1.13          btsl    $_EFER_LME,%eax /* Long Mode      */
    1.14          btsl    $_EFER_SCE,%eax /* SYSCALL/SYSRET */
    1.15  #endif
    1.16 -        mov     SYM_TRAMP_PHYS(cpuid_ext_features),%edi
    1.17 -        btl     $20,%edi        /* CPUID 0x80000001, EDX[20] */
    1.18 +        btl     $20,%edi        /* No Execute?    */
    1.19          jnc     1f
    1.20 -        btsl    $_EFER_NX,%eax  /* No-Execute     */
    1.21 +        btsl    $_EFER_NX,%eax  /* No Execute     */
    1.22  1:      wrmsr
    1.23 +.Lskip_efer:
    1.24  #endif
    1.25  
    1.26          mov     $0x80050033,%eax /* hi-to-lo: PG,AM,WP,NE,ET,MP,PE */