aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ia64/sn/kernel/io_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/ia64/sn/kernel/io_common.c')
-rw-r--r--arch/ia64/sn/kernel/io_common.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/arch/ia64/sn/kernel/io_common.c b/arch/ia64/sn/kernel/io_common.c
index d4dd8f4b6b8d..65979f1fb353 100644
--- a/arch/ia64/sn/kernel/io_common.c
+++ b/arch/ia64/sn/kernel/io_common.c
@@ -25,7 +25,6 @@
25#include "xtalk/xwidgetdev.h" 25#include "xtalk/xwidgetdev.h"
26#include <linux/acpi.h> 26#include <linux/acpi.h>
27#include <asm/sn/sn2/sn_hwperf.h> 27#include <asm/sn/sn2/sn_hwperf.h>
28#include <asm/sn/acpi.h>
29 28
30extern void sn_init_cpei_timer(void); 29extern void sn_init_cpei_timer(void);
31extern void register_sn_procfs(void); 30extern void register_sn_procfs(void);
@@ -37,7 +36,6 @@ extern void sn_legacy_pci_window_fixup(struct pci_controller *, u64, u64);
37extern void sn_io_acpi_init(void); 36extern void sn_io_acpi_init(void);
38extern void sn_io_init(void); 37extern void sn_io_init(void);
39 38
40
41static struct list_head sn_sysdata_list; 39static struct list_head sn_sysdata_list;
42 40
43/* sysdata list struct */ 41/* sysdata list struct */
@@ -50,6 +48,15 @@ int sn_ioif_inited; /* SN I/O infrastructure initialized? */
50 48
51struct sn_pcibus_provider *sn_pci_provider[PCIIO_ASIC_MAX_TYPES]; /* indexed by asic type */ 49struct sn_pcibus_provider *sn_pci_provider[PCIIO_ASIC_MAX_TYPES]; /* indexed by asic type */
52 50
51int sn_acpi_base_support()
52{
53 struct acpi_table_header *header;
54 (void)acpi_get_table_by_index(ACPI_TABLE_INDEX_DSDT, &header);
55 if (header && header->oem_revision >= 0x20101)
56 return 1;
57 return 0;
58}
59
53/* 60/*
54 * Hooks and struct for unsupported pci providers 61 * Hooks and struct for unsupported pci providers
55 */ 62 */
@@ -286,7 +293,7 @@ void sn_pci_fixup_slot(struct pci_dev *dev)
286 list_add_tail(&pcidev_info->pdi_list, 293 list_add_tail(&pcidev_info->pdi_list,
287 &(SN_PLATFORM_DATA(dev->bus)->pcidev_info)); 294 &(SN_PLATFORM_DATA(dev->bus)->pcidev_info));
288 295
289 if (SN_ACPI_BASE_SUPPORT()) 296 if (sn_acpi_base_support())
290 sn_acpi_slot_fixup(dev, pcidev_info); 297 sn_acpi_slot_fixup(dev, pcidev_info);
291 else 298 else
292 sn_more_slot_fixup(dev, pcidev_info); 299 sn_more_slot_fixup(dev, pcidev_info);
@@ -498,7 +505,7 @@ void __devinit
498sn_pci_fixup_bus(struct pci_bus *bus) 505sn_pci_fixup_bus(struct pci_bus *bus)
499{ 506{
500 507
501 if (SN_ACPI_BASE_SUPPORT()) 508 if (sn_acpi_base_support())
502 sn_acpi_bus_fixup(bus); 509 sn_acpi_bus_fixup(bus);
503 else 510 else
504 sn_bus_fixup(bus); 511 sn_bus_fixup(bus);
@@ -546,7 +553,7 @@ sn_io_early_init(void)
546 553
547 printk(KERN_INFO "ACPI DSDT OEM Rev 0x%x\n", 554 printk(KERN_INFO "ACPI DSDT OEM Rev 0x%x\n",
548 acpi_gbl_DSDT->oem_revision); 555 acpi_gbl_DSDT->oem_revision);
549 if (SN_ACPI_BASE_SUPPORT()) 556 if (sn_acpi_base_support())
550 sn_io_acpi_init(); 557 sn_io_acpi_init();
551 else 558 else
552 sn_io_init(); 559 sn_io_init();