Commit dd7fd3a8 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki Committed by Linus Torvalds

ACPI / hotplug / PCI: Runtime resume bridges before bus rescans

If a PCI bridge (or PCIe port) that is runtime-suspended gets an ACPI
hotplug notification, such as a bus check, it has to be resumed before
re-scanning the devices below it, or those devices will not be
accessible and will be treated as hot-removed.

Make that happen and let the bridge suspend again after the bus below it
has been re-scanned.

This is a replacement for commit 16468c78 ("ACPI / hotplug / PCI:
Runtime resume bridge before rescan") that has been reverted, because it
introduced a system resume regression (due to missing bridge->pci_dev
checks that are necessary in case the notification is targeted at the
host bridge) and it is necessary for the code added by commit
006d44e4 ("PCI: Add runtime PM support for PCIe ports") to work as
Tested-by: default avatarLinus Torvalds <>
Signed-off-by: default avatarRafael J. Wysocki <>
Signed-off-by: default avatarLinus Torvalds <>
parent f8fbd8c4
......@@ -675,6 +675,9 @@ static void acpiphp_check_bridge(struct acpiphp_bridge *bridge)
if (bridge->is_going_away)
if (bridge->pci_dev)
list_for_each_entry(slot, &bridge->slots, node) {
struct pci_bus *bus = slot->bus;
struct pci_dev *dev, *tmp;
......@@ -694,6 +697,9 @@ static void acpiphp_check_bridge(struct acpiphp_bridge *bridge)
if (bridge->pci_dev)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment