From: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
To: Gavin Shan <gwshan@linux.vnet.ibm.com>, linuxppc-dev@lists.ozlabs.org
Cc: aik@ozlabs.ru, alistair@popple.id.au
Subject: Re: [PATCH v9 18/26] powerpc/pci: Rename pcibios_{add, remove}_pci_devices()
Date: Wed, 4 May 2016 14:43:07 +1000 [thread overview]
Message-ID: <57297DDB.3030301@au1.ibm.com> (raw)
In-Reply-To: <1462254105-24128-19-git-send-email-gwshan@linux.vnet.ibm.com>
On 03/05/16 15:41, Gavin Shan wrote:
> This renames pcibios_{add,remove}_pci_devices() to avoid conflicts
> with names of the weak functions in PCI subsystem, which have the
> prefix "pcibios". No logical changes introduced.
>
> Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
Looks fine to me.
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
> ---
> arch/powerpc/include/asm/pci-bridge.h | 4 ++--
> arch/powerpc/kernel/eeh_driver.c | 12 ++++++------
> arch/powerpc/kernel/pci-hotplug.c | 15 +++++++--------
> drivers/pci/hotplug/rpadlpar_core.c | 2 +-
> drivers/pci/hotplug/rpaphp_core.c | 4 ++--
> drivers/pci/hotplug/rpaphp_pci.c | 2 +-
> 6 files changed, 19 insertions(+), 20 deletions(-)
>
> diff --git a/arch/powerpc/include/asm/pci-bridge.h b/arch/powerpc/include/asm/pci-bridge.h
> index 220129f..99027b8 100644
> --- a/arch/powerpc/include/asm/pci-bridge.h
> +++ b/arch/powerpc/include/asm/pci-bridge.h
> @@ -260,10 +260,10 @@ static inline struct eeh_dev *pdn_to_eeh_dev(struct pci_dn *pdn)
> extern struct pci_bus *pcibios_find_pci_bus(struct device_node *dn);
>
> /** Remove all of the PCI devices under this bus */
> -extern void pcibios_remove_pci_devices(struct pci_bus *bus);
> +extern void pci_hp_remove_devices(struct pci_bus *bus);
>
> /** Discover new pci devices under this bus, and add them */
> -extern void pcibios_add_pci_devices(struct pci_bus *bus);
> +extern void pci_hp_add_devices(struct pci_bus *bus);
>
>
> extern void isa_bridge_find_early(struct pci_controller *hose);
> diff --git a/arch/powerpc/kernel/eeh_driver.c b/arch/powerpc/kernel/eeh_driver.c
> index fb6207d..618d13c 100644
> --- a/arch/powerpc/kernel/eeh_driver.c
> +++ b/arch/powerpc/kernel/eeh_driver.c
> @@ -621,7 +621,7 @@ static int eeh_reset_device(struct eeh_pe *pe, struct pci_bus *bus,
> * We don't remove the corresponding PE instances because
> * we need the information afterwords. The attached EEH
> * devices are expected to be attached soon when calling
> - * into pcibios_add_pci_devices().
> + * into pci_hp_add_devices().
> */
> eeh_pe_state_mark(pe, EEH_PE_KEEP);
> if (bus) {
> @@ -630,7 +630,7 @@ static int eeh_reset_device(struct eeh_pe *pe, struct pci_bus *bus,
> } else {
> eeh_pe_state_clear(pe, EEH_PE_PRI_BUS);
> pci_lock_rescan_remove();
> - pcibios_remove_pci_devices(bus);
> + pci_hp_remove_devices(bus);
> pci_unlock_rescan_remove();
> }
> } else if (frozen_bus) {
> @@ -681,7 +681,7 @@ static int eeh_reset_device(struct eeh_pe *pe, struct pci_bus *bus,
> if (pe->type & EEH_PE_VF)
> eeh_add_virt_device(edev, NULL);
> else
> - pcibios_add_pci_devices(bus);
> + pci_hp_add_devices(bus);
> } else if (frozen_bus && rmv_data->removed) {
> pr_info("EEH: Sleep 5s ahead of partial hotplug\n");
> ssleep(5);
> @@ -691,7 +691,7 @@ static int eeh_reset_device(struct eeh_pe *pe, struct pci_bus *bus,
> if (pe->type & EEH_PE_VF)
> eeh_add_virt_device(edev, NULL);
> else
> - pcibios_add_pci_devices(frozen_bus);
> + pci_hp_add_devices(frozen_bus);
> }
> eeh_pe_state_clear(pe, EEH_PE_KEEP);
>
> @@ -896,7 +896,7 @@ perm_error:
> eeh_pe_dev_mode_mark(pe, EEH_DEV_REMOVED);
>
> pci_lock_rescan_remove();
> - pcibios_remove_pci_devices(frozen_bus);
> + pci_hp_remove_devices(frozen_bus);
> pci_unlock_rescan_remove();
> }
> }
> @@ -981,7 +981,7 @@ static void eeh_handle_special_event(void)
> bus = eeh_pe_bus_get(phb_pe);
> eeh_pe_dev_traverse(pe,
> eeh_report_failure, NULL);
> - pcibios_remove_pci_devices(bus);
> + pci_hp_remove_devices(bus);
> }
> pci_unlock_rescan_remove();
> }
> diff --git a/arch/powerpc/kernel/pci-hotplug.c b/arch/powerpc/kernel/pci-hotplug.c
> index 59c4361..2d108e5 100644
> --- a/arch/powerpc/kernel/pci-hotplug.c
> +++ b/arch/powerpc/kernel/pci-hotplug.c
> @@ -38,20 +38,20 @@ void pcibios_release_device(struct pci_dev *dev)
> }
>
> /**
> - * pcibios_remove_pci_devices - remove all devices under this bus
> + * pci_hp_remove_devices - remove all devices under this bus
> * @bus: the indicated PCI bus
> *
> * Remove all of the PCI devices under this bus both from the
> * linux pci device tree, and from the powerpc EEH address cache.
> */
> -void pcibios_remove_pci_devices(struct pci_bus *bus)
> +void pci_hp_remove_devices(struct pci_bus *bus)
> {
> struct pci_dev *dev, *tmp;
> struct pci_bus *child_bus;
>
> /* First go down child busses */
> list_for_each_entry(child_bus, &bus->children, node)
> - pcibios_remove_pci_devices(child_bus);
> + pci_hp_remove_devices(child_bus);
>
> pr_debug("PCI: Removing devices on bus %04x:%02x\n",
> pci_domain_nr(bus), bus->number);
> @@ -60,11 +60,10 @@ void pcibios_remove_pci_devices(struct pci_bus *bus)
> pci_stop_and_remove_bus_device(dev);
> }
> }
> -
> -EXPORT_SYMBOL_GPL(pcibios_remove_pci_devices);
> +EXPORT_SYMBOL_GPL(pci_hp_remove_devices);
>
> /**
> - * pcibios_add_pci_devices - adds new pci devices to bus
> + * pci_hp_add_devices - adds new pci devices to bus
> * @bus: the indicated PCI bus
> *
> * This routine will find and fixup new pci devices under
> @@ -74,7 +73,7 @@ EXPORT_SYMBOL_GPL(pcibios_remove_pci_devices);
> * is how this routine differs from other, similar pcibios
> * routines.)
> */
> -void pcibios_add_pci_devices(struct pci_bus * bus)
> +void pci_hp_add_devices(struct pci_bus *bus)
> {
> int slotno, mode, pass, max;
> struct pci_dev *dev;
> @@ -114,4 +113,4 @@ void pcibios_add_pci_devices(struct pci_bus * bus)
> }
> pcibios_finish_adding_to_bus(bus);
> }
> -EXPORT_SYMBOL_GPL(pcibios_add_pci_devices);
> +EXPORT_SYMBOL_GPL(pci_hp_add_devices);
> diff --git a/drivers/pci/hotplug/rpadlpar_core.c b/drivers/pci/hotplug/rpadlpar_core.c
> index b46b57d..b770d6d 100644
> --- a/drivers/pci/hotplug/rpadlpar_core.c
> +++ b/drivers/pci/hotplug/rpadlpar_core.c
> @@ -380,7 +380,7 @@ int dlpar_remove_pci_slot(char *drc_name, struct device_node *dn)
> }
>
> /* Remove all devices below slot */
> - pcibios_remove_pci_devices(bus);
> + pci_hp_remove_devices(bus);
>
> /* Unmap PCI IO space */
> if (pcibios_unmap_io_space(bus)) {
> diff --git a/drivers/pci/hotplug/rpaphp_core.c b/drivers/pci/hotplug/rpaphp_core.c
> index 611f605..8d13202 100644
> --- a/drivers/pci/hotplug/rpaphp_core.c
> +++ b/drivers/pci/hotplug/rpaphp_core.c
> @@ -404,7 +404,7 @@ static int enable_slot(struct hotplug_slot *hotplug_slot)
>
> if (state == PRESENT) {
> pci_lock_rescan_remove();
> - pcibios_add_pci_devices(slot->bus);
> + pci_hp_add_devices(slot->bus);
> pci_unlock_rescan_remove();
> slot->state = CONFIGURED;
> } else if (state == EMPTY) {
> @@ -426,7 +426,7 @@ static int disable_slot(struct hotplug_slot *hotplug_slot)
> return -EINVAL;
>
> pci_lock_rescan_remove();
> - pcibios_remove_pci_devices(slot->bus);
> + pci_hp_remove_devices(slot->bus);
> pci_unlock_rescan_remove();
> vm_unmap_aliases();
>
> diff --git a/drivers/pci/hotplug/rpaphp_pci.c b/drivers/pci/hotplug/rpaphp_pci.c
> index 7836d69..137a892 100644
> --- a/drivers/pci/hotplug/rpaphp_pci.c
> +++ b/drivers/pci/hotplug/rpaphp_pci.c
> @@ -116,7 +116,7 @@ int rpaphp_enable_slot(struct slot *slot)
> }
>
> if (list_empty(&bus->devices))
> - pcibios_add_pci_devices(bus);
> + pci_hp_add_devices(bus);
>
> if (!list_empty(&bus->devices)) {
> info->adapter_status = CONFIGURED;
>
--
Andrew Donnellan OzLabs, ADL Canberra
andrew.donnellan@au1.ibm.com IBM Australia Limited
next prev parent reply other threads:[~2016-05-04 4:44 UTC|newest]
Thread overview: 59+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-03 5:41 [PATCH v9 00/26] powerpc/powernv: PCI hotplug preparation Gavin Shan
2016-05-03 5:41 ` [PATCH v9 01/26] powerpc/pci: Cleanup on struct pci_controller_ops Gavin Shan
2016-05-10 21:48 ` [v9,01/26] " Michael Ellerman
2016-05-03 5:41 ` [PATCH v9 02/26] powerpc/powernv: Cleanup on pci_controller_ops instances Gavin Shan
2016-05-05 4:07 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 03/26] powerpc/powernv: Drop phb->bdfn_to_pe() Gavin Shan
2016-05-03 5:41 ` [PATCH v9 04/26] powerpc/powernv: Reorder fields in struct pnv_phb Gavin Shan
2016-05-03 5:41 ` [PATCH v9 05/26] powerpc/powernv: Rename PE# " Gavin Shan
2016-05-03 5:41 ` [PATCH v9 06/26] powerpc/powernv: Data type unsigned int for PE number Gavin Shan
2016-05-04 3:31 ` Alistair Popple
2016-05-04 8:39 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 07/26] powerpc/powernv: Fix initial IO and M32 segmap Gavin Shan
2016-05-04 3:31 ` Alistair Popple
2016-05-04 4:38 ` Gavin Shan
2016-05-05 2:06 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 08/26] powerpc/powernv: Simplify pnv_ioda_setup_pe_seg() Gavin Shan
2016-05-04 3:45 ` Alistair Popple
2016-05-05 2:11 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 09/26] powerpc/powernv: IO and M32 mapping based on PCI device resources Gavin Shan
2016-05-05 2:57 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 10/26] powerpc/powernv: Track M64 segment consumption Gavin Shan
2016-05-03 5:41 ` [PATCH v9 11/26] powerpc/powernv: Rename M64 related functions Gavin Shan
2016-05-03 5:41 ` [PATCH v9 12/26] powerpc/powernv/ioda1: M64 support on P7IOC Gavin Shan
2016-05-04 5:17 ` Alistair Popple
2016-05-04 6:48 ` Gavin Shan
2016-05-04 23:53 ` Alistair Popple
2016-05-05 0:40 ` Gavin Shan
2016-05-05 1:03 ` Alistair Popple
2016-05-05 2:28 ` Gavin Shan
2016-05-05 2:02 ` [PATCH v10 " Gavin Shan
2016-05-05 2:41 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 13/26] powerpc/powernv/ioda1: Rename pnv_pci_ioda_setup_dma_pe() Gavin Shan
2016-05-03 5:41 ` [PATCH v9 14/26] powerpc/powernv/ioda1: Introduce PNV_IODA1_DMA32_SEGSIZE Gavin Shan
2016-05-04 4:02 ` Alistair Popple
2016-05-05 2:48 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 15/26] powerpc/powernv: Remove DMA32 PE list Gavin Shan
2016-05-03 5:41 ` [PATCH v9 16/26] powerpc/powernv/ioda1: Improve DMA32 segment track Gavin Shan
2016-05-04 13:20 ` Gavin Shan
2016-05-05 1:55 ` Gavin Shan
2016-05-05 2:04 ` [PATCH v10 " Gavin Shan
2016-05-05 4:03 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 17/26] powerpc/powernv: Use PE instead of number during setup and release Gavin Shan
2016-05-03 5:41 ` [PATCH v9 18/26] powerpc/pci: Rename pcibios_{add, remove}_pci_devices() Gavin Shan
2016-05-04 4:10 ` Alistair Popple
2016-05-04 4:53 ` [PATCH v9 18/26] powerpc/pci: Rename pcibios_{add,remove}_pci_devices() Gavin Shan
2016-05-04 4:43 ` Andrew Donnellan [this message]
2016-05-05 3:06 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 19/26] powerpc/pci: Rename pcibios_find_pci_bus() Gavin Shan
2016-05-03 5:41 ` [PATCH v9 20/26] powerpc/pci: Move pci_find_bus_by_node() around Gavin Shan
2016-05-04 4:46 ` Andrew Donnellan
2016-05-05 3:07 ` Alexey Kardashevskiy
2016-05-03 5:41 ` [PATCH v9 21/26] powerpc/pci: Export pci_add_device_node_info() Gavin Shan
2016-05-03 5:41 ` [PATCH v9 22/26] powerpc/pci: Introduce pci_remove_device_node_info() Gavin Shan
2016-05-03 5:41 ` [PATCH v9 23/26] powerpc/pci: Export pci_traverse_device_nodes() Gavin Shan
2016-05-03 5:41 ` [PATCH v9 24/26] powerpc/pci: Don't scan empty slot Gavin Shan
2016-05-03 5:41 ` [PATCH v9 25/26] powerpc/powernv: Simplify pnv_eeh_reset() Gavin Shan
2016-05-03 5:41 ` [PATCH v9 26/26] powerpc/powernv: Exclude root bus in pnv_pci_reset_secondary_bus() Gavin Shan
2016-05-12 3:48 ` Gavin Shan
2016-05-12 11:35 ` Michael Ellerman
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=57297DDB.3030301@au1.ibm.com \
--to=andrew.donnellan@au1.ibm.com \
--cc=aik@ozlabs.ru \
--cc=alistair@popple.id.au \
--cc=gwshan@linux.vnet.ibm.com \
--cc=linuxppc-dev@lists.ozlabs.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;
as well as URLs for NNTP newsgroup(s).