ia64/xen-unstable

changeset 19040:3fb43f23f64c

x86: propagate disabled APIC state to Dom0

This in particular eliminates the need to specify "noapic" to Dom0
when "noapic" is passed to Xen, provided the kernel side gets slightly
modified to make use of this information (Linux side patch cannot
easily be provided for the 2.6.18 tree, but this is being used by our
2.6.27-based one).

Signed-off-by: Jan Beulich <jbeulich@novell.com>
author Keir Fraser <keir.fraser@citrix.com>
date Wed Jan 14 10:56:18 2009 +0000 (2009-01-14)
parents 59274c49a029
children 2737293c761e
files xen/arch/x86/traps.c
line diff
     1.1 --- a/xen/arch/x86/traps.c	Wed Jan 14 10:55:40 2009 +0000
     1.2 +++ b/xen/arch/x86/traps.c	Wed Jan 14 10:56:18 2009 +0000
     1.3 @@ -723,6 +723,8 @@ static void pv_cpuid(struct cpu_user_reg
     1.4      {
     1.5          /* Modify Feature Information. */
     1.6          __clear_bit(X86_FEATURE_VME, &d);
     1.7 +        if ( !cpu_has_apic )
     1.8 +            __clear_bit(X86_FEATURE_APIC, &d);
     1.9          if ( !opt_allow_hugepage )
    1.10              __clear_bit(X86_FEATURE_PSE, &d);
    1.11          __clear_bit(X86_FEATURE_PGE, &d);
    1.12 @@ -755,6 +757,8 @@ static void pv_cpuid(struct cpu_user_reg
    1.13          __clear_bit(X86_FEATURE_XTPR % 32, &c);
    1.14          __clear_bit(X86_FEATURE_PDCM % 32, &c);
    1.15          __clear_bit(X86_FEATURE_DCA % 32, &c);
    1.16 +        if ( !cpu_has_apic )
    1.17 +           __clear_bit(X86_FEATURE_X2APIC % 32, &c);
    1.18          __set_bit(X86_FEATURE_HYPERVISOR % 32, &c);
    1.19          break;
    1.20      case 0x80000001:
    1.21 @@ -773,6 +777,8 @@ static void pv_cpuid(struct cpu_user_reg
    1.22          __clear_bit(X86_FEATURE_RDTSCP % 32, &d);
    1.23  
    1.24          __clear_bit(X86_FEATURE_SVME % 32, &c);
    1.25 +        if ( !cpu_has_apic )
    1.26 +           __clear_bit(X86_FEATURE_EXTAPICSPACE % 32, &c);
    1.27          __clear_bit(X86_FEATURE_OSVW % 32, &c);
    1.28          __clear_bit(X86_FEATURE_IBS % 32, &c);
    1.29          __clear_bit(X86_FEATURE_SKINIT % 32, &c);