linux-stable/arch/powerpc
Oliver O'Halloran 965c94f309 powerpc/iov: Move VF pdev fixup into pcibios_fixup_iov()
An ioda_pe for each VF is allocated in pnv_pci_sriov_enable() before
the pci_dev for the VF is created. We need to set the pe->pdev pointer
at some point after the pci_dev is created. Currently we do that in:

pcibios_bus_add_device()
	pnv_pci_dma_dev_setup() (via phb->ops.dma_dev_setup)
		/* fixup is done here */
		pnv_pci_ioda_dma_dev_setup() (via pnv_phb->dma_dev_setup)

The fixup needs to be done before setting up DMA for for the VF's PE,
but there's no real reason to delay it until this point. Move the
fixup into pnv_pci_ioda_fixup_iov() so the ordering is:

	pcibios_add_device()
		pnv_pci_ioda_fixup_iov() (via ppc_md.pcibios_fixup_sriov)

	pcibios_bus_add_device()
		...

This isn't strictly required, but it's a slightly more logical place
to do the fixup and it simplifies pnv_pci_dma_dev_setup().

Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200110070207.439-4-oohall@gmail.com
2020-01-23 21:31:22 +11:00
..
boot powerpc/devicetrees: Change 'gpios' to 'cs-gpios' on fsl, spi nodes 2020-01-23 21:31:14 +11:00
configs Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2019-12-01 13:26:18 -08:00
crypto powerpc updates for 5.5 2019-11-30 14:35:43 -08:00
include powerpc/pcidn: Make VF pci_dn management CONFIG_PCI_IOV specific 2020-01-23 21:31:19 +11:00
kernel powerpc/pci: Fold pcibios_setup_device() into pcibios_bus_add_device() 2020-01-23 21:31:21 +11:00
kexec powerpc: Avoid clang warnings around setjmp and longjmp 2019-11-25 21:45:43 +11:00
kvm PPC: 2019-12-22 10:26:59 -08:00
lib powerpc: Fix __clear_user() with KUAP enabled 2019-12-16 23:19:44 +11:00
math-emu treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
mm powerpc/8xx: Fix permanently mapped IMMR region. 2020-01-23 21:31:14 +11:00
net treewide: Use sizeof_field() macro 2019-12-09 10:36:44 -08:00
oprofile treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 333 2019-06-05 17:37:06 +02:00
perf powerpc updates for 5.5 2019-11-30 14:35:43 -08:00
platforms powerpc/iov: Move VF pdev fixup into pcibios_fixup_iov() 2020-01-23 21:31:22 +11:00
purgatory treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 441 2019-06-05 17:37:17 +02:00
sysdev powerpc/mpic: constify copied structure 2020-01-07 21:42:16 +11:00
tools powerpc/tools: Don't quote $objdump in scripts 2019-10-30 22:55:12 +11:00
xmon powerpc/xmon: Allow passing an argument to ppc_md.restart() 2020-01-23 21:31:21 +11:00
Kbuild powerpc/kexec: Move kexec files into a dedicated subdir. 2019-11-21 15:41:34 +11:00
Kconfig powerpc: Remove STRICT_KERNEL_RWX incompatibility with RELOCATABLE 2020-01-16 14:59:36 +10:00
Kconfig.debug powerpc/ptdump: Only enable PPC_CHECK_WX with STRICT_KERNEL_RWX 2020-01-23 21:31:13 +11:00
Makefile powerpc: Don't add -mabi= flags when building with Clang 2019-11-25 21:45:43 +11:00
Makefile.postlink kbuild: add $(BASH) to run scripts with bash-extension 2019-09-04 22:54:13 +09:00