Skip to content

Commit 37bfdbc

Browse files
committed
Merge tag 'pci-v6.18-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/pci/pci
Pull pci fix from Bjorn Helgaas: - Fix a resource lookup regression that broke enumeration of hotplugged Thunderbolt devices on several platforms (Yangyu Chen) * tag 'pci-v6.18-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/pci/pci: PCI: Fix regression in pci_bus_distribute_available_resources()
2 parents cd5a0af + a154f14 commit 37bfdbc

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

drivers/pci/setup-bus.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2085,7 +2085,8 @@ static void pci_bus_distribute_available_resources(struct pci_bus *bus,
20852085
int i;
20862086

20872087
for (i = 0; i < PCI_P2P_BRIDGE_RESOURCE_NUM; i++) {
2088-
struct resource *res = pci_bus_resource_n(bus, i);
2088+
struct resource *res =
2089+
pci_resource_n(bridge, PCI_BRIDGE_RESOURCES + i);
20892090

20902091
available[i] = available_in[i];
20912092

@@ -2158,7 +2159,7 @@ static void pci_bus_distribute_available_resources(struct pci_bus *bus,
21582159
continue;
21592160

21602161
for (i = 0; i < PCI_P2P_BRIDGE_RESOURCE_NUM; i++) {
2161-
res = pci_bus_resource_n(bus, i);
2162+
res = pci_resource_n(dev, PCI_BRIDGE_RESOURCES + i);
21622163

21632164
/*
21642165
* Make sure the split resource space is properly

0 commit comments

Comments
 (0)