diff options
| -rw-r--r-- | arch/x86/pci/mrst.c | 10 | ||||
| -rw-r--r-- | drivers/acpi/pci_root.c | 4 | ||||
| -rw-r--r-- | drivers/pci/hotplug/acpiphp_glue.c | 14 | ||||
| -rw-r--r-- | include/linux/pci-acpi.h | 2 |
4 files changed, 23 insertions, 7 deletions
diff --git a/arch/x86/pci/mrst.c b/arch/x86/pci/mrst.c index 0e0fabf17342..6eb18c42a28a 100644 --- a/arch/x86/pci/mrst.c +++ b/arch/x86/pci/mrst.c | |||
| @@ -141,11 +141,6 @@ static int pci_device_update_fixed(struct pci_bus *bus, unsigned int devfn, | |||
| 141 | */ | 141 | */ |
| 142 | static bool type1_access_ok(unsigned int bus, unsigned int devfn, int reg) | 142 | static bool type1_access_ok(unsigned int bus, unsigned int devfn, int reg) |
| 143 | { | 143 | { |
| 144 | if (bus == 0 && (devfn == PCI_DEVFN(2, 0) | ||
| 145 | || devfn == PCI_DEVFN(0, 0) | ||
| 146 | || devfn == PCI_DEVFN(3, 0))) | ||
| 147 | return 1; | ||
| 148 | |||
| 149 | /* This is a workaround for A0 LNC bug where PCI status register does | 144 | /* This is a workaround for A0 LNC bug where PCI status register does |
| 150 | * not have new CAP bit set. can not be written by SW either. | 145 | * not have new CAP bit set. can not be written by SW either. |
| 151 | * | 146 | * |
| @@ -155,7 +150,10 @@ static bool type1_access_ok(unsigned int bus, unsigned int devfn, int reg) | |||
| 155 | */ | 150 | */ |
| 156 | if (reg >= 0x100 || reg == PCI_STATUS || reg == PCI_HEADER_TYPE) | 151 | if (reg >= 0x100 || reg == PCI_STATUS || reg == PCI_HEADER_TYPE) |
| 157 | return 0; | 152 | return 0; |
| 158 | 153 | if (bus == 0 && (devfn == PCI_DEVFN(2, 0) | |
| 154 | || devfn == PCI_DEVFN(0, 0) | ||
| 155 | || devfn == PCI_DEVFN(3, 0))) | ||
| 156 | return 1; | ||
| 159 | return 0; /* langwell on others */ | 157 | return 0; /* langwell on others */ |
| 160 | } | 158 | } |
| 161 | 159 | ||
diff --git a/drivers/acpi/pci_root.c b/drivers/acpi/pci_root.c index 1dd6f6c85874..e427dc516c76 100644 --- a/drivers/acpi/pci_root.c +++ b/drivers/acpi/pci_root.c | |||
| @@ -641,7 +641,9 @@ static void _handle_hotplug_event_root(struct work_struct *work) | |||
| 641 | /* bus enumerate */ | 641 | /* bus enumerate */ |
| 642 | printk(KERN_DEBUG "%s: Bus check notify on %s\n", __func__, | 642 | printk(KERN_DEBUG "%s: Bus check notify on %s\n", __func__, |
| 643 | (char *)buffer.pointer); | 643 | (char *)buffer.pointer); |
| 644 | if (!root) | 644 | if (root) |
| 645 | acpiphp_check_host_bridge(handle); | ||
| 646 | else | ||
| 645 | handle_root_bridge_insertion(handle); | 647 | handle_root_bridge_insertion(handle); |
| 646 | 648 | ||
| 647 | break; | 649 | break; |
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c index 96fed19c6d90..716aa93fff76 100644 --- a/drivers/pci/hotplug/acpiphp_glue.c +++ b/drivers/pci/hotplug/acpiphp_glue.c | |||
| @@ -950,6 +950,20 @@ check_sub_bridges(acpi_handle handle, u32 lvl, void *context, void **rv) | |||
| 950 | return AE_OK ; | 950 | return AE_OK ; |
| 951 | } | 951 | } |
| 952 | 952 | ||
| 953 | void acpiphp_check_host_bridge(acpi_handle handle) | ||
| 954 | { | ||
| 955 | struct acpiphp_bridge *bridge; | ||
| 956 | |||
| 957 | bridge = acpiphp_handle_to_bridge(handle); | ||
| 958 | if (bridge) { | ||
| 959 | acpiphp_check_bridge(bridge); | ||
| 960 | put_bridge(bridge); | ||
| 961 | } | ||
| 962 | |||
| 963 | acpi_walk_namespace(ACPI_TYPE_DEVICE, handle, | ||
| 964 | ACPI_UINT32_MAX, check_sub_bridges, NULL, NULL, NULL); | ||
| 965 | } | ||
| 966 | |||
| 953 | static void _handle_hotplug_event_bridge(struct work_struct *work) | 967 | static void _handle_hotplug_event_bridge(struct work_struct *work) |
| 954 | { | 968 | { |
| 955 | struct acpiphp_bridge *bridge; | 969 | struct acpiphp_bridge *bridge; |
diff --git a/include/linux/pci-acpi.h b/include/linux/pci-acpi.h index 81b31613eb25..170447977278 100644 --- a/include/linux/pci-acpi.h +++ b/include/linux/pci-acpi.h | |||
| @@ -60,11 +60,13 @@ static inline void acpi_pci_slot_remove(struct pci_bus *bus) { } | |||
| 60 | void acpiphp_init(void); | 60 | void acpiphp_init(void); |
| 61 | void acpiphp_enumerate_slots(struct pci_bus *bus, acpi_handle handle); | 61 | void acpiphp_enumerate_slots(struct pci_bus *bus, acpi_handle handle); |
| 62 | void acpiphp_remove_slots(struct pci_bus *bus); | 62 | void acpiphp_remove_slots(struct pci_bus *bus); |
| 63 | void acpiphp_check_host_bridge(acpi_handle handle); | ||
| 63 | #else | 64 | #else |
| 64 | static inline void acpiphp_init(void) { } | 65 | static inline void acpiphp_init(void) { } |
| 65 | static inline void acpiphp_enumerate_slots(struct pci_bus *bus, | 66 | static inline void acpiphp_enumerate_slots(struct pci_bus *bus, |
| 66 | acpi_handle handle) { } | 67 | acpi_handle handle) { } |
| 67 | static inline void acpiphp_remove_slots(struct pci_bus *bus) { } | 68 | static inline void acpiphp_remove_slots(struct pci_bus *bus) { } |
| 69 | static inline void acpiphp_check_host_bridge(acpi_handle handle) { } | ||
| 68 | #endif | 70 | #endif |
| 69 | 71 | ||
| 70 | #else /* CONFIG_ACPI */ | 72 | #else /* CONFIG_ACPI */ |
