powerpc/pci: Add shutdown hook to pci_controller_ops
authorMichael Neuling <mikey@neuling.org>
Wed, 27 May 2015 06:06:59 +0000 (16:06 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 3 Jun 2015 03:27:16 +0000 (13:27 +1000)
commit7a8e6bbf8593a9395dd6c61f7c5f421570600017
tree6247d0668a48fc4bea1981fc45329b70d69fe771
parentf46580a5cf07b3d35e357bb2401ae3c49cff7e65
powerpc/pci: Add shutdown hook to pci_controller_ops

Currently pnv_pci_shutdown() calls the PHB shutdown code for all PHBs in the
system.  It dereferences the private_data assuming it's a powernv PHB, which
won't be the case when we have different PHB in the systems (like when we add
vPHBs for CXL).

This moves the shutdown hook to the pci_controller_ops and fixes the call site
to use that instead.

Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/pci-bridge.h
arch/powerpc/platforms/powernv/pci-ioda.c
arch/powerpc/platforms/powernv/pci.c
arch/powerpc/platforms/powernv/pci.h