* [PATCH 21/29] PCI, ia64: kill pci_find_next_bus
[not found] <1348561590-28067-1-git-send-email-yinghai@kernel.org>
@ 2012-09-25 8:26 ` Yinghai Lu
0 siblings, 0 replies; only message in thread
From: Yinghai Lu @ 2012-09-25 8:26 UTC (permalink / raw)
To: Bjorn Helgaas, Len Brown
Cc: linux-pci, Yinghai Lu, Tony Luck, Fenghua Yu, linux-ia64,
linux-altix
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
Cc: Tony Luck <tony.luck@intel.com>
Cc: Fenghua Yu <fenghua.yu@intel.com>
Cc: linux-ia64@vger.kernel.org
Cc: linux-altix@sgi.com
---
arch/ia64/hp/common/sba_iommu.c | 7 ++++---
arch/ia64/sn/kernel/io_common.c | 5 +++--
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/arch/ia64/hp/common/sba_iommu.c b/arch/ia64/hp/common/sba_iommu.c
index bcda5b2..0f27a37 100644
--- a/arch/ia64/hp/common/sba_iommu.c
+++ b/arch/ia64/hp/common/sba_iommu.c
@@ -2155,9 +2155,10 @@ sba_init(void)
#ifdef CONFIG_PCI
{
- struct pci_bus *b = NULL;
- while ((b = pci_find_next_bus(b)) != NULL)
- sba_connect_bus(b);
+ struct pci_host_bridge *host_bridge = NULL;
+
+ for_each_pci_host_bridge(host_bridge)
+ sba_connect_bus(host_bridge->bus);
}
#endif
diff --git a/arch/ia64/sn/kernel/io_common.c b/arch/ia64/sn/kernel/io_common.c
index 8630875..131938b 100644
--- a/arch/ia64/sn/kernel/io_common.c
+++ b/arch/ia64/sn/kernel/io_common.c
@@ -516,6 +516,7 @@ arch_initcall(sn_io_early_init);
int __init
sn_io_late_init(void)
{
+ struct pci_host_bridge *host_bridge = NULL;
struct pci_bus *bus;
struct pcibus_bussoft *bussoft;
cnodeid_t cnode;
@@ -530,8 +531,8 @@ sn_io_late_init(void)
* PIC, TIOCP, TIOCE (TIOCA does it during bus fixup using
* info from the PROM).
*/
- bus = NULL;
- while ((bus = pci_find_next_bus(bus)) != NULL) {
+ for_each_pci_host_bridge(host_bridge) {
+ bus = host_bridge->bus;
bussoft = SN_PCIBUS_BUSSOFT(bus);
nasid = NASID_GET(bussoft->bs_base);
cnode = nasid_to_cnodeid(nasid);
--
1.7.7
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2012-09-25 8:26 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1348561590-28067-1-git-send-email-yinghai@kernel.org>
2012-09-25 8:26 ` [PATCH 21/29] PCI, ia64: kill pci_find_next_bus Yinghai Lu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).