Commit 3773dd25 authored by Gavin Shan's avatar Gavin Shan Committed by Michael Ellerman

powerpc/pci: Rename pcibios_find_pci_bus()

This renames pcibios_find_pci_bus() to pci_find_bus_by_node() to
avoid conflicts with those PCI subsystem weak function names, which
have prefix "pcibios". No logical changes introduced.
Signed-off-by: default avatarGavin Shan <gwshan@linux.vnet.ibm.com>
Reviewed-by: default avatarAlexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
parent bd251b89
...@@ -257,7 +257,7 @@ static inline struct eeh_dev *pdn_to_eeh_dev(struct pci_dn *pdn) ...@@ -257,7 +257,7 @@ static inline struct eeh_dev *pdn_to_eeh_dev(struct pci_dn *pdn)
#endif #endif
/** Find the bus corresponding to the indicated device node */ /** Find the bus corresponding to the indicated device node */
extern struct pci_bus *pcibios_find_pci_bus(struct device_node *dn); extern struct pci_bus *pci_find_bus_by_node(struct device_node *dn);
/** Remove all of the PCI devices under this bus */ /** Remove all of the PCI devices under this bus */
extern void pci_hp_remove_devices(struct pci_bus *bus); extern void pci_hp_remove_devices(struct pci_bus *bus);
......
...@@ -54,8 +54,7 @@ find_bus_among_children(struct pci_bus *bus, ...@@ -54,8 +54,7 @@ find_bus_among_children(struct pci_bus *bus,
return child; return child;
} }
struct pci_bus * struct pci_bus *pci_find_bus_by_node(struct device_node *dn)
pcibios_find_pci_bus(struct device_node *dn)
{ {
struct pci_dn *pdn = dn->data; struct pci_dn *pdn = dn->data;
...@@ -64,7 +63,7 @@ pcibios_find_pci_bus(struct device_node *dn) ...@@ -64,7 +63,7 @@ pcibios_find_pci_bus(struct device_node *dn)
return find_bus_among_children(pdn->phb->bus, dn); return find_bus_among_children(pdn->phb->bus, dn);
} }
EXPORT_SYMBOL_GPL(pcibios_find_pci_bus); EXPORT_SYMBOL_GPL(pci_find_bus_by_node);
struct pci_controller *init_phb_dynamic(struct device_node *dn) struct pci_controller *init_phb_dynamic(struct device_node *dn)
{ {
......
...@@ -175,7 +175,7 @@ static int dlpar_add_pci_slot(char *drc_name, struct device_node *dn) ...@@ -175,7 +175,7 @@ static int dlpar_add_pci_slot(char *drc_name, struct device_node *dn)
struct pci_dev *dev; struct pci_dev *dev;
struct pci_controller *phb; struct pci_controller *phb;
if (pcibios_find_pci_bus(dn)) if (pci_find_bus_by_node(dn))
return -EINVAL; return -EINVAL;
/* Add pci bus */ /* Add pci bus */
...@@ -212,7 +212,7 @@ static int dlpar_remove_phb(char *drc_name, struct device_node *dn) ...@@ -212,7 +212,7 @@ static int dlpar_remove_phb(char *drc_name, struct device_node *dn)
struct pci_dn *pdn; struct pci_dn *pdn;
int rc = 0; int rc = 0;
if (!pcibios_find_pci_bus(dn)) if (!pci_find_bus_by_node(dn))
return -EINVAL; return -EINVAL;
/* If pci slot is hotpluggable, use hotplug to remove it */ /* If pci slot is hotpluggable, use hotplug to remove it */
...@@ -356,7 +356,7 @@ int dlpar_remove_pci_slot(char *drc_name, struct device_node *dn) ...@@ -356,7 +356,7 @@ int dlpar_remove_pci_slot(char *drc_name, struct device_node *dn)
pci_lock_rescan_remove(); pci_lock_rescan_remove();
bus = pcibios_find_pci_bus(dn); bus = pci_find_bus_by_node(dn);
if (!bus) { if (!bus) {
ret = -EINVAL; ret = -EINVAL;
goto out; goto out;
......
...@@ -93,7 +93,7 @@ int rpaphp_enable_slot(struct slot *slot) ...@@ -93,7 +93,7 @@ int rpaphp_enable_slot(struct slot *slot)
if (rc) if (rc)
return rc; return rc;
bus = pcibios_find_pci_bus(slot->dn); bus = pci_find_bus_by_node(slot->dn);
if (!bus) { if (!bus) {
err("%s: no pci_bus for dn %s\n", __func__, slot->dn->full_name); err("%s: no pci_bus for dn %s\n", __func__, slot->dn->full_name);
return -EINVAL; return -EINVAL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment