linux/drivers/pci/controller/dwc
Stephen Warren 6d6b05e3d5 PCI: dwc: Don't hard-code DBI/ATU offset
The DWC PCIe core contains various separate register spaces: DBI, DBI2,
ATU, DMA, etc. The relationship between the addresses of these register
spaces is entirely determined by the implementation of the IP block, not
by the IP block design itself. Hence, the DWC driver must not make
assumptions that one register space can be accessed at a fixed offset from
any other register space. To avoid such assumptions, introduce an
explicit/separate register pointer for the ATU register space. In
particular, the current assumption is not valid for NVIDIA's T194 SoC.

The ATU register space is only used on systems that require unrolled ATU
access. This property is detected at run-time for host controllers, and
when this is detected, this patch provides a default value for atu_base
that matches the previous assumption re: register layout. An alternative
would be to update all drivers for HW that requires unrolled access to
explicitly set atu_base. However, it's hard to tell which drivers would
require atu_base to be set. The unrolled property is not detected for
endpoint systems, and so any endpoint driver that requires unrolled access
must explicitly set the iatu_unroll_enabled flag (none do at present), and
so a check is added to require the driver to also set atu_base while at
it.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Acked-by: Gustavo Pimentel <gustavo.pimentel@synopsys.com>
Acked-by: Vidya Sagar <vidyas@nvidia.com>
2018-12-18 12:01:17 +00:00
..
Kconfig PCI: dwc: Adjust Kconfig to allow IMX6 PCIe host on IMX7 2018-12-18 12:01:16 +00:00
Makefile PCI: keystone: Merge pci-keystone-dw.c and pci-keystone.c 2018-10-17 09:43:44 +01:00
pci-dra7xx.c PCI: dwc: pci-dra7xx: Enable errata i870 for both EP and RC mode 2018-09-25 10:53:10 +01:00
pci-exynos.c PCI: exynos: Drop unnecessary root_bus_nr setting 2018-07-13 14:07:47 +01:00
pci-imx6.c PCI: imx: Add imx6sx suspend/resume support 2018-12-18 12:01:16 +00:00
pci-keystone.c PCI: keystone: Cleanup macros defined in pci-keystone.c 2018-10-17 09:59:02 +01:00
pci-layerscape.c PCI: dwc: layerscape: Constify driver data 2018-12-18 12:01:15 +00:00
pcie-armada8k.c PCI: armada8k: Add support for gpio controlled reset signal 2018-12-18 12:01:16 +00:00
pcie-artpec6.c PCI: Update xxx_pcie_ep_raise_irq() and pci_epc_raise_irq() signatures 2018-07-19 11:34:42 +01:00
pcie-designware-ep.c PCI: dwc: Don't hard-code DBI/ATU offset 2018-12-18 12:01:17 +00:00
pcie-designware-host.c PCI: dwc: Don't hard-code DBI/ATU offset 2018-12-18 12:01:17 +00:00
pcie-designware-plat.c pci-epf-test/pci_endpoint_test: Add MSI-X support 2018-07-19 11:46:45 +01:00
pcie-designware.c PCI: dwc: Don't hard-code DBI/ATU offset 2018-12-18 12:01:17 +00:00
pcie-designware.h PCI: dwc: Don't hard-code DBI/ATU offset 2018-12-18 12:01:17 +00:00
pcie-hisi.c
pcie-histb.c PCI: histb: Constify dw_pcie_host_ops structure 2018-11-08 13:54:44 +00:00
pcie-kirin.c PCI: kirin: Fix section mismatch warning 2018-10-01 17:16:23 +01:00
pcie-qcom.c PCI: qcom: Fix error handling in runtime PM support 2018-09-18 10:13:14 +01:00
pcie-spear13xx.c PCI: spear13xx: Drop unnecessary root_bus_nr setting 2018-07-13 14:10:55 +01:00