From: Bjorn Helgaas <bjorn.helgaas@hp.com>
To: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: Matthew Garrett <mjg59@srcf.ucam.org>,
Tony Luck <tony.luck@intel.com>,
linux-pci@vger.kernel.org, Peter Haight <peterh@sapros.com>,
Gary Hade <garyhade@us.ibm.com>,
linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org,
Yinghai Lu <yinghai@kernel.org>, Ingo Molnar <mingo@elte.hu>,
Linus Torvalds <torvalds@linux-foundation.org>,
Larry Finger <Larry.Finger@lwfinger.net>
Subject: [PATCH v1 4/7] PCI: read bridge windows before filling in subtractive decode resources
Date: Wed, 03 Feb 2010 16:39:16 -0700 [thread overview]
Message-ID: <20100203233916.10803.19478.stgit@bob.kio> (raw)
In-Reply-To: <20100203233617.10803.92102.stgit@bob.kio>
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>
---
drivers/pci/probe.c | 15 ++++++++++-----
1 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index 1d498cd..fbff005 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -391,14 +391,19 @@ void __devinit pci_read_bridge_bases(struct pci_bus *child)
child->secondary, child->subordinate,
dev->transparent ? " (subtractive decode)": "");
- if (dev->transparent) {
- for(i = 3; i < PCI_BUS_NUM_RESOURCES; i++)
- child->resource[i] = child->parent->resource[i - 3];
- }
-
pci_read_bridge_io(child);
pci_read_bridge_mmio(child);
pci_read_bridge_mmio_pref(child);
+
+ if (dev->transparent) {
+ for (i = 3; i < PCI_BUS_NUM_RESOURCES; i++) {
+ child->resource[i] = child->parent->resource[i - 3];
+ if (child->resource[i])
+ dev_printk(KERN_DEBUG, &dev->dev,
+ " bridge window %pR (subtractive decode)\n",
+ child->resource[i]);
+ }
+ }
}
static struct pci_bus * pci_alloc_bus(void)
next prev parent reply other threads:[~2010-02-03 23:39 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-03 23:38 [PATCH v1 0/7] PCI: try enabling "pci=use_crs" again Bjorn Helgaas
2010-02-03 23:39 ` [PATCH v1 1/7] x86/PCI: remove IOH range fetching Bjorn Helgaas
2010-02-03 23:39 ` [PATCH v1 2/7] PCI: break out primary/secondary/subordinate for readability Bjorn Helgaas
2010-02-03 23:39 ` [PATCH v1 3/7] PCI: split up pci_read_bridge_bases() Bjorn Helgaas
2010-02-08 19:59 ` Jesse Barnes
2010-02-03 23:39 ` Bjorn Helgaas [this message]
2010-02-03 23:39 ` [PATCH v1 5/7] PCI: replace bus resource table with a list Bjorn Helgaas
2010-02-03 23:39 ` [PATCH v1 6/7] x86/PCI: use host bridge _CRS info by default on 2010 and newer machines Bjorn Helgaas
2010-02-03 23:39 ` [PATCH v1 7/7] PCI: reference bridge window resources explicitly Bjorn Helgaas
2010-02-04 0:04 ` [PATCH v1 0/7] PCI: try enabling "pci=use_crs" again Linus Torvalds
2010-02-04 4:37 ` Larry Finger
2010-02-04 17:55 ` Bjorn Helgaas
2010-02-04 22:36 ` Larry Finger
2010-02-04 22:55 ` Bjorn Helgaas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100203233916.10803.19478.stgit@bob.kio \
--to=bjorn.helgaas@hp.com \
--cc=Larry.Finger@lwfinger.net \
--cc=garyhade@us.ibm.com \
--cc=jbarnes@virtuousgeek.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=mjg59@srcf.ucam.org \
--cc=peterh@sapros.com \
--cc=tony.luck@intel.com \
--cc=torvalds@linux-foundation.org \
--cc=yinghai@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox