diff options
author | Yinghai Lu <yinghai@kernel.org> | 2012-09-17 22:20:29 -0700 |
---|---|---|
committer | Yinghai Lu <yinghai@kernel.org> | 2012-09-17 22:20:29 -0700 |
commit | 2ebf82f33e3518fa3901661b36aea1f32da5cc8d (patch) | |
tree | c35f8e3cbbc978b2b641f4ef303ea20dfa440ab0 | |
parent | 256789e100a1ae6b8fd877946d4d9dc247b62a39 (diff) | |
download | linux-yinghai-2ebf82f33e3518fa3901661b36aea1f32da5cc8d.tar.gz |
PCI, acpiphp: Use for_each_pci_dev_resource helper
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
-rw-r--r-- | drivers/pci/hotplug/acpiphp_glue.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c index 1f26706827cbe4..df5e4dbf6cceff 100644 --- a/drivers/pci/hotplug/acpiphp_glue.c +++ b/drivers/pci/hotplug/acpiphp_glue.c @@ -1096,10 +1096,10 @@ static void acpiphp_sanitize_bus(struct pci_bus *bus) struct pci_dev *dev; int i; unsigned long type_mask = IORESOURCE_IO | IORESOURCE_MEM; + struct resource *res; list_for_each_entry(dev, &bus->devices, bus_list) { - for (i=0; i<PCI_BRIDGE_RESOURCES; i++) { - struct resource *res = &dev->resource[i]; + for_each_pci_resource(dev, res, i, PCI_NOBRIDGE_RES) { if ((res->flags & type_mask) && !res->start && res->end) { /* Could not assign a required resources |