aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/probe.c
diff options
context:
space:
mode:
authorBjorn Helgaas <bjorn.helgaas@hp.com>2010-02-23 12:24:26 -0500
committerJesse Barnes <jbarnes@virtuousgeek.org>2010-02-23 12:43:25 -0500
commit2adf75160b10bf3f09ed7d3d04e937f923fc557e (patch)
treedb2998c5403f6c12bb207fd80a1e1fca2ec4a1b4 /drivers/pci/probe.c
parentfa27b2d108fa49685129867a8c5b968344d6e197 (diff)
PCI: read bridge windows before filling in subtractive decode resources
No functional change; this fills in the bus subtractive decode resources after reading the bridge window information rather than before. Also, print out the subtractive decode resources as we already do for the positive decode windows. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Diffstat (limited to 'drivers/pci/probe.c')
-rw-r--r--drivers/pci/probe.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index 4b47b4bfb066..70c4ed2e67cc 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -403,14 +403,19 @@ void __devinit pci_read_bridge_bases(struct pci_bus *child)
403 child->secondary, child->subordinate, 403 child->secondary, child->subordinate,
404 dev->transparent ? " (subtractive decode)" : ""); 404 dev->transparent ? " (subtractive decode)" : "");
405 405
406 if (dev->transparent) {
407 for (i = 3; i < PCI_BUS_NUM_RESOURCES; i++)
408 child->resource[i] = child->parent->resource[i - 3];
409 }
410
411 pci_read_bridge_io(child); 406 pci_read_bridge_io(child);
412 pci_read_bridge_mmio(child); 407 pci_read_bridge_mmio(child);
413 pci_read_bridge_mmio_pref(child); 408 pci_read_bridge_mmio_pref(child);
409
410 if (dev->transparent) {
411 for (i = 3; i < PCI_BUS_NUM_RESOURCES; i++) {
412 child->resource[i] = child->parent->resource[i - 3];
413 if (child->resource[i])
414 dev_printk(KERN_DEBUG, &dev->dev,
415 " bridge window %pR (subtractive decode)\n",
416 child->resource[i]);
417 }
418 }
414} 419}
415 420
416static struct pci_bus * pci_alloc_bus(void) 421static struct pci_bus * pci_alloc_bus(void)