summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/pci_of_scan.c
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2012-03-28 13:53:10 +0900
committerPaul Mundt <lethal@linux-sh.org>2012-03-28 13:53:10 +0900
commit18af30e259c25a64ad69bb749c661564bc886275 (patch)
tree996c89594fd20f25fcc15b5843625d99473f6982 /arch/powerpc/kernel/pci_of_scan.c
parent691c01c3f0b3252308162de90edcd02f7ca1733c (diff)
parent6658a6991cef75719a21441aa0b7f8d6821534ee (diff)
downloadtalos-op-linux-18af30e259c25a64ad69bb749c661564bc886275.tar.gz
talos-op-linux-18af30e259c25a64ad69bb749c661564bc886275.zip
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux into sh-latest
Diffstat (limited to 'arch/powerpc/kernel/pci_of_scan.c')
-rw-r--r--arch/powerpc/kernel/pci_of_scan.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/arch/powerpc/kernel/pci_of_scan.c b/arch/powerpc/kernel/pci_of_scan.c
index b37d0b5a796e..89dde171a6fa 100644
--- a/arch/powerpc/kernel/pci_of_scan.c
+++ b/arch/powerpc/kernel/pci_of_scan.c
@@ -75,6 +75,7 @@ static void of_pci_parse_addrs(struct device_node *node, struct pci_dev *dev)
{
u64 base, size;
unsigned int flags;
+ struct pci_bus_region region;
struct resource *res;
const u32 *addrs;
u32 i;
@@ -106,10 +107,11 @@ static void of_pci_parse_addrs(struct device_node *node, struct pci_dev *dev)
printk(KERN_ERR "PCI: bad cfg reg num 0x%x\n", i);
continue;
}
- res->start = base;
- res->end = base + size - 1;
res->flags = flags;
res->name = pci_name(dev);
+ region.start = base;
+ region.end = base + size - 1;
+ pcibios_bus_to_resource(dev, res, &region);
}
}
@@ -209,6 +211,7 @@ void __devinit of_scan_pci_bridge(struct pci_dev *dev)
struct pci_bus *bus;
const u32 *busrange, *ranges;
int len, i, mode;
+ struct pci_bus_region region;
struct resource *res;
unsigned int flags;
u64 size;
@@ -270,9 +273,10 @@ void __devinit of_scan_pci_bridge(struct pci_dev *dev)
res = bus->resource[i];
++i;
}
- res->start = of_read_number(&ranges[1], 2);
- res->end = res->start + size - 1;
res->flags = flags;
+ region.start = of_read_number(&ranges[1], 2);
+ region.end = region.start + size - 1;
+ pcibios_bus_to_resource(dev, res, &region);
}
sprintf(bus->name, "PCI Bus %04x:%02x", pci_domain_nr(bus),
bus->number);
OpenPOWER on IntegriCloud