From patchwork Thu Feb 26 01:29:22 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yijing Wang X-Patchwork-Id: 5886681 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D6DDEBF440 for ; Thu, 26 Feb 2015 01:41:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id F109420373 for ; Thu, 26 Feb 2015 01:41:15 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0EE5420374 for ; Thu, 26 Feb 2015 01:41:15 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1YQnO0-0003Gk-7j; Thu, 26 Feb 2015 01:37:08 +0000 Received: from szxga01-in.huawei.com ([119.145.14.64]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YQnLJ-0000dz-AJ for linux-arm-kernel@lists.infradead.org; Thu, 26 Feb 2015 01:34:24 +0000 Received: from 172.24.2.119 (EHLO szxeml430-hub.china.huawei.com) ([172.24.2.119]) by szxrg01-dlp.huawei.com (MOS 4.3.7-GA FastPath queued) with ESMTP id CJX56579; Thu, 26 Feb 2015 09:32:00 +0800 (CST) Received: from localhost.localdomain (10.175.100.166) by szxeml430-hub.china.huawei.com (10.82.67.185) with Microsoft SMTP Server id 14.3.158.1; Thu, 26 Feb 2015 09:31:44 +0800 From: Yijing Wang To: Bjorn Helgaas Subject: [PATCH v3 05/30] PCI: Rename pci_scan_bus() to pci_scan_bus_legacy() Date: Thu, 26 Feb 2015 09:29:22 +0800 Message-ID: <1424914187-21027-6-git-send-email-wangyijing@huawei.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1424914187-21027-1-git-send-email-wangyijing@huawei.com> References: <1424914187-21027-1-git-send-email-wangyijing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.100.166] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150225_173421_971090_5F99CD0D X-CRM114-Status: GOOD ( 12.35 ) X-Spam-Score: -2.3 (--) Cc: Liviu Dudau , Rusty Russell , Russell King , Arnd Bergmann , Marc Zyngier , linux-pci@vger.kernel.org, x86@kernel.org, linux-m68k@lists.linux-m68k.org, linux-kernel@vger.kernel.org, "David S. Miller" , linux-alpha@vger.kernel.org, Tony Luck , Geert Uytterhoeven , Benjamin Herrenschmidt , Yijing Wang , linux-ia64@vger.kernel.org, Thomas Gleixner , Guan Xuetao , Yinghai Lu , Jiang Liu , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Pci_scan_bus() is called by legacy pci host drivers, the legacy host drivers mean they use NULL as parent device, use all IO/MEM as default resources. Rename pci_scan_bus() to pci_scan_bus_legacy() for better readability. Signed-off-by: Yijing Wang --- arch/alpha/kernel/sys_nautilus.c | 2 +- arch/m68k/coldfire/pci.c | 2 +- arch/sparc/kernel/pcic.c | 2 +- arch/unicore32/kernel/pci.c | 2 +- drivers/pci/hotplug/ibmphp_core.c | 2 +- drivers/pci/probe.c | 4 ++-- include/linux/pci.h | 2 +- 7 files changed, 8 insertions(+), 8 deletions(-) diff --git a/arch/alpha/kernel/sys_nautilus.c b/arch/alpha/kernel/sys_nautilus.c index 4ae4a40..2c864bb 100644 --- a/arch/alpha/kernel/sys_nautilus.c +++ b/arch/alpha/kernel/sys_nautilus.c @@ -206,7 +206,7 @@ nautilus_init_pci(void) unsigned long memtop = max_low_pfn << PAGE_SHIFT; /* Scan our single hose. */ - bus = pci_scan_bus(0, alpha_mv.pci_ops, hose); + bus = pci_scan_bus_legacy(0, alpha_mv.pci_ops, hose); hose->bus = bus; pcibios_claim_one_bus(bus); diff --git a/arch/m68k/coldfire/pci.c b/arch/m68k/coldfire/pci.c index d45f087..0ef4dd4 100644 --- a/arch/m68k/coldfire/pci.c +++ b/arch/m68k/coldfire/pci.c @@ -312,7 +312,7 @@ static int __init mcf_pci_init(void) set_current_state(TASK_UNINTERRUPTIBLE); schedule_timeout(msecs_to_jiffies(200)); - rootbus = pci_scan_bus(0, &mcf_pci_ops, NULL); + rootbus = pci_scan_bus_legacy(0, &mcf_pci_ops, NULL); rootbus->resource[0] = &mcf_pci_io; rootbus->resource[1] = &mcf_pci_mem; diff --git a/arch/sparc/kernel/pcic.c b/arch/sparc/kernel/pcic.c index 7a82fe2..f7edc97 100644 --- a/arch/sparc/kernel/pcic.c +++ b/arch/sparc/kernel/pcic.c @@ -390,7 +390,7 @@ static void __init pcic_pbm_scan_bus(struct linux_pcic *pcic) { struct linux_pbm_info *pbm = &pcic->pbm; - pbm->pci_bus = pci_scan_bus(pbm->pci_first_busno, &pcic_ops, pbm); + pbm->pci_bus = pci_scan_bus_legacy(pbm->pci_first_busno, &pcic_ops, pbm); if (pbm->pci_bus) pci_bus_add_devices(pbm->pci_bus); #if 0 /* deadwood transplanted from sparc64 */ diff --git a/arch/unicore32/kernel/pci.c b/arch/unicore32/kernel/pci.c index 3d82024..2e238b4 100644 --- a/arch/unicore32/kernel/pci.c +++ b/arch/unicore32/kernel/pci.c @@ -258,7 +258,7 @@ static int __init pci_common_init(void) pci_puv3_preinit(); - puv3_bus = pci_scan_bus(0, &pci_puv3_ops, NULL); + puv3_bus = pci_scan_bus_legacy(0, &pci_puv3_ops, NULL); if (!puv3_bus) panic("PCI: unable to scan bus!"); diff --git a/drivers/pci/hotplug/ibmphp_core.c b/drivers/pci/hotplug/ibmphp_core.c index 86e3bfd..4ade1b4 100644 --- a/drivers/pci/hotplug/ibmphp_core.c +++ b/drivers/pci/hotplug/ibmphp_core.c @@ -765,7 +765,7 @@ static u8 bus_structure_fixup(u8 busno) (l != 0x0000) && (l != 0xffff)) { debug("%s - Inside bus_structure_fixup()\n", __func__); - b = pci_scan_bus(busno, ibmphp_pci_bus->ops, NULL); + b = pci_scan_bus_legacy(busno, ibmphp_pci_bus->ops, NULL); if (b) pci_bus_add_devices(b); break; diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index 699a238..ccab9b1 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c @@ -2091,7 +2091,7 @@ struct pci_bus *pci_scan_root_bus(struct device *parent, int bus, } EXPORT_SYMBOL(pci_scan_root_bus); -struct pci_bus *pci_scan_bus(int bus, struct pci_ops *ops, +struct pci_bus *pci_scan_bus_legacy(int bus, struct pci_ops *ops, void *sysdata) { LIST_HEAD(resources); @@ -2108,7 +2108,7 @@ struct pci_bus *pci_scan_bus(int bus, struct pci_ops *ops, } return b; } -EXPORT_SYMBOL(pci_scan_bus); +EXPORT_SYMBOL(pci_scan_bus_legacy); /** * pci_rescan_bus_bridge_resize - scan a PCI bus for devices. diff --git a/include/linux/pci.h b/include/linux/pci.h index 36effb8..6dffc57 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -769,7 +769,7 @@ void pcibios_bus_to_resource(struct pci_bus *bus, struct resource *res, void pcibios_scan_specific_bus(int busn); struct pci_bus *pci_find_bus(int domain, int busnr); void pci_bus_add_devices(const struct pci_bus *bus); -struct pci_bus *pci_scan_bus(int bus, struct pci_ops *ops, void *sysdata); +struct pci_bus *pci_scan_bus_legacy(int bus, struct pci_ops *ops, void *sysdata); struct pci_bus *pci_create_root_bus(struct device *parent, int bus, struct pci_ops *ops, void *sysdata, struct list_head *resources);