powerpc/pci: Move pci_find_bus_by_node() around
authorGavin Shan <gwshan@linux.vnet.ibm.com>
Tue, 3 May 2016 05:41:39 +0000 (15:41 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 11 May 2016 11:54:24 +0000 (21:54 +1000)
commit6384d97780c123d2e167242862ed4ea9051210e4
tree63c873c2e959aa2e63eeef7d93c752662c12ec34
parent3773dd258e91e1e14d95cdf17b9d83a1a7b27af1
powerpc/pci: Move pci_find_bus_by_node() around

This moves pci_find_bus_by_node() from arch/powerpc/platforms/
pseries/pci_dlpar.c to arch/powerpc/kernel/pci-hotplug.c so that
the function can be used by pSeries and PowerNV platform at the
same time. Also, below cleanup applied. No functional changes
introduced.

   * Remove variable "busdn" in find_bus_among_children()
   * Use PCI_DN() to convert device node to pci_dn

Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/pci-hotplug.c
arch/powerpc/platforms/pseries/pci_dlpar.c