linux-stable/arch/powerpc/platforms
Oliver O'Halloran 9d72dcef89 powerpc/powernv: Disable native PCIe port management
On PowerNV the PCIe topology is (currently) managed by the powernv platform
code in Linux in cooperation with the platform firmware. Linux's native
PCIe port service drivers operate independently of both and this can cause
problems.

The main issue is that the portbus driver will conflict with the platform
specific hotplug driver (pnv_php) over ownership of the MSI used to notify
the host when a hotplug event occurs. The portbus driver claims this MSI on
behalf of the individual port services because the same interrupt is used
for hotplug events, PMEs (on root ports), and link bandwidth change
notifications. The portbus driver will always claim the interrupt even if
the individual port service drivers, such as pciehp, are compiled out.

The second, bigger, problem is that the hotplug port service driver
fundamentally does not work on PowerNV. The platform assumes that all
PCI devices have a corresponding arch-specific handle derived from the DT
node for the device (pci_dn) and without one the platform will not allow
a PCI device to be enabled. This problem is largely due to historical
baggage, but it can't be resolved without significant re-factoring of the
platform PCI support.

We can fix these problems in the interim by setting the
"pcie_ports_disabled" flag during platform initialisation. The flag
indicates the platform owns the PCIe ports which stops the portbus driver
from being registered.

This does have the side effect of disabling all port services drivers
that is: AER, PME, BW notifications, hotplug, and DPC. However, this is
not a huge disadvantage on PowerNV since these services are either unused
or handled through other means.

Fixes: 66725152fb ("PCI/hotplug: PowerPC PowerNV PCI hotplug driver")
Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20191118065553.30362-1-oohall@gmail.com
2019-11-21 15:41:38 +11:00
..
4xx powerpc: remove the ppc44x ocm.c file 2019-08-27 13:03:33 +10:00
8xx powerpc/8xx: use the fixmapped IMMR in cpm_reset() 2019-11-19 19:38:35 +11:00
40x powerpc updates for 5.3 2019-07-13 16:08:36 -07:00
44x powerpc: remove the ppc44x ocm.c file 2019-08-27 13:03:33 +10:00
52xx treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 428 2019-06-05 17:37:16 +02:00
82xx treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
83xx powerpc/sysdev: drop simple gpio 2019-11-21 15:41:34 +11:00
85xx powerpc/sysdev: drop simple gpio 2019-11-21 15:41:34 +11:00
86xx powerpc/sysdev: drop simple gpio 2019-11-21 15:41:34 +11:00
512x treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 428 2019-06-05 17:37:16 +02:00
amigaone treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
cell powerpc/spufs: remove set but not used variable 'ctx' 2019-11-13 16:58:07 +11:00
chrp treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
embedded6xx treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
maple powerpc updates for 5.3 2019-07-13 16:08:36 -07:00
pasemi powerpc/powernv/ioda2: Create bigger default window with 64k IOMMU pages 2019-08-19 13:20:23 +10:00
powermac powerpc updates for 5.3 2019-07-13 16:08:36 -07:00
powernv powerpc/powernv: Disable native PCIe port management 2019-11-21 15:41:38 +11:00
ps3 powerpc updates for 5.4 2019-09-20 11:48:06 -07:00
pseries powerpc/pseries/hotplug-memory: Change rc variable to bool 2019-11-13 16:58:10 +11:00
fsl_uli1575.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
Kconfig powerpc/sysdev: drop simple gpio 2019-11-21 15:41:34 +11:00
Kconfig.cputype powerpc: use the generic dma coherent remap allocator 2019-08-28 23:19:34 +10:00
Makefile powerpc: Add -Werror at arch/powerpc level 2018-10-19 00:56:17 +11:00