aboutsummaryrefslogtreecommitdiffstats
path: root/xen/include/xen/acpi.h
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2010-07-16 13:52:18 +0100
committerKeir Fraser <keir.fraser@citrix.com>2010-07-16 13:52:18 +0100
commitb3625d1e2c5815e6d65a47197bebeae2061153ce (patch)
tree0b81045610df333d54d1e17b5d081ca08560b362 /xen/include/xen/acpi.h
parent1652d36bbe2108109159bf62ec11be2736351c02 (diff)
downloadxen-b3625d1e2c5815e6d65a47197bebeae2061153ce.tar.gz
xen-b3625d1e2c5815e6d65a47197bebeae2061153ce.tar.bz2
xen-b3625d1e2c5815e6d65a47197bebeae2061153ce.zip
ACPI: add support for x2APIC ACPI extensions
All logical processors with APIC ID values of 255 and greater will have their APIC reported through Processor X2APIC structure (type-9 entry type) and all logical processors with APIC ID less than 255 will have their APIC reported through legacy Processor Local APIC (type-0 entry type) only. This is the same case even for NMI structure reporting. The Processor X2APIC Affinity structure provides the association between the X2APIC ID of a logical processor and the proximity domain to which the logical processor belongs. This patch adds 2 new subtables to MADT and one new subtable to SRAT. This patch also changes x86_acpiid_to_apicid from u8 to u32 for x2APIC ID, and changes mp_register_lapic to accept 32-bit id. But there are still some 8-bit apic id hardcode and assumptions in Xen code, it needs to be fixed in future. Signed-off-by: Weidong Han <weidong.han@intel.com>
Diffstat (limited to 'xen/include/xen/acpi.h')
-rw-r--r--xen/include/xen/acpi.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/xen/include/xen/acpi.h b/xen/include/xen/acpi.h
index 43b81536bf..0df17ea0f2 100644
--- a/xen/include/xen/acpi.h
+++ b/xen/include/xen/acpi.h
@@ -57,6 +57,8 @@ enum acpi_madt_entry_id {
ACPI_MADT_IOSAPIC,
ACPI_MADT_LSAPIC,
ACPI_MADT_PLAT_INT_SRC,
+ ACPI_MADT_X2APIC,
+ ACPI_MADT_X2APIC_NMI,
ACPI_MADT_ENTRY_COUNT
};
@@ -76,6 +78,17 @@ struct acpi_table_lapic {
} flags;
} __attribute__ ((packed));
+struct acpi_table_x2apic {
+ struct acpi_subtable_header header;
+ u16 reserved;
+ u32 id;
+ struct {
+ u32 enabled:1;
+ u32 reserved:31;
+ } flags;
+ u32 acpi_uid;
+} __attribute__ ((packed));
+
struct acpi_table_ioapic {
struct acpi_subtable_header header;
u8 id;
@@ -105,6 +118,14 @@ struct acpi_table_lapic_nmi {
u8 lint;
} __attribute__ ((packed));
+struct acpi_table_x2apic_nmi {
+ struct acpi_subtable_header header;
+ acpi_interrupt_flags flags;
+ u32 acpi_uid;
+ u8 lint;
+ u8 reserved[3];
+} __attribute__ ((packed));
+
struct acpi_table_lapic_addr_ovr {
struct acpi_subtable_header header;
u8 reserved[2];
@@ -280,6 +301,7 @@ void acpi_table_print_srat_entry (struct acpi_subtable_header *srat);
/* the following four functions are architecture-dependent */
void acpi_numa_slit_init (struct acpi_table_slit *slit);
void acpi_numa_processor_affinity_init (struct acpi_srat_cpu_affinity *pa);
+void acpi_numa_x2apic_affinity_init(struct acpi_srat_x2apic_cpu_affinity *pa);
void acpi_numa_memory_affinity_init (struct acpi_srat_mem_affinity *ma);
void acpi_numa_arch_fixup(void);