Skip to content

PCI: tegra: Add Tegra234 PCIe support

Vidya Sagar linux-devicetree linux-pci linux-tegra lkml 6 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v6 Latest16 patches 2 repliesIn review
  2. v59 patches 3 repliesSuperseded
  3. v49 patches 5 repliesSuperseded
Earlier versions · 3
VersionPostedPatchesRepliesStatus
v311 patches15 repliesApplied
v28 patches5 repliesSuperseded
v110 patches12 repliesSuperseded

Changes in v6 from the cover letter

* Addressed review comments from Bjorn
* Moved out non-Tegra234 specific changes and created separate patches

Patches in v6 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/16dt-bindings: pci: tegra: Convert to json-schemaDocumentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.txt Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.yaml +1 more+478 -2470 replies
2/16dt-bindings: PCI: tegra234: Add schema for tegra234 rootport modeDocumentation/devicetree/bindings/pci/nvidia,tegra194-pcie.yaml+100 -20 replies
3/16dt-bindings: PCI: tegra234: Add schema for tegra234 endpoint modeDocumentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml+95 -20 replies
4/16arm64: tegra: Add regulators required for PCIearch/arm64/boot/dts/nvidia/tegra234-p3701-0000.dtsi+36 -00 replies
5/16arm64: tegra: Add P2U and PCIe controller nodes to Tegra234 DTarch/arm64/boot/dts/nvidia/tegra234.dtsi+927 -00 replies
6/16arm64: tegra: Enable PCIe slots in P3737-0000 boardarch/arm64/boot/dts/nvidia/tegra234-p3737-0000+p3701-0000.dts+51 -00 replies
7/16PCI: Disable MSI for Tegra234 root portsdrivers/pci/quirks.c+11 -20 replies
8/16Revert "PCI: tegra194: Rename tegra_pcie_dw to tegra194_pcie"drivers/pci/controller/dwc/pcie-tegra194.c+111 -1110 replies
9/16PCI: tegra194: Find RAS DES PCIe capability offsetdrivers/pci/controller/dwc/pcie-designware.h drivers/pci/controller/dwc/pcie-tegra194.c+35 -370 replies
10/16PCI: tegra194: Fix root port interrupt handlingdrivers/pci/controller/dwc/pcie-tegra194.c+22 -240 replies
11/16PCI: tegra194: Clear bandwidth management statusdrivers/pci/controller/dwc/pcie-tegra194.c+6 -00 replies
12/16PCI: tegra194: Enable support for 256 Byte payloaddrivers/pci/controller/dwc/pcie-tegra194.c+13 -00 replies
13/16PCI: tegra194: Cleanup the exit path for endpoint modedrivers/pci/controller/dwc/pcie-tegra194.c+31 -140 replies
14/16PCI: tegra194: Fix link up retry sequencedrivers/pci/controller/dwc/pcie-tegra194.c+1 -11 reply
15/16PCI: tegra194: Extend endpoint mode supportdrivers/pci/controller/dwc/pcie-tegra194.c+9 -00 replies
16/16PCI: tegra: Add Tegra234 PCIe supportdrivers/pci/controller/dwc/pcie-tegra194.c+225 -590 replies

Reviews trailers per patch

4 of 16 patches have a Reviewed-by or Acked-by.

PatchRob Herring
1/16R-b
2/16R-b
3/16R-b
4/16
5/16
6/16
7/16
8/16
9/16
10/16
11/16
12/16
13/16
14/16R-b
15/16
16/16

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v6 thread

Cover letter [PATCH V6 00/16] PCI: tegra: Add Tegra234 PCIe support

Tegra234 has a total of 11 PCIe controllers based on Synopsys DesignWare core. There are three Universal PHY (UPHY) blocks (viz. HSIO, NVHS and GBE) with each block supporting 8 lanes respectively. Controllers:0~4 use UPHY lanes from HSIO block, Controllers:5,6 use UPHY lanes from NVHS block and Controllers:7~10 use UPHY lanes from GBE block. Lane mapping in each block is controlled in XBAR module by BPMP-FW. Since PCIe core has PIPE interface, a glue module called PIPE-to-UPHY (P2U) is used to connect each UPHY lane (applicable to all three UPHY bricks i.e. HSIO/NVHS/GBE) to PCIe controller. All the controllers can operate in the RootPort mode where as only controllers C5, C6, C7 and C10 can operate in the EndPoint mode.

This patch series
- Adds support for Tegra234 in the existing P2U PHY driver
- Adds support for Tegra234 in the existing PCIe platform controller driver
- Adds device tree nodes for all PCIe controllers
- Enables nodes applicable to P3737-0000 platform

Testing done on P3737-0000 platform
- PCIe link is up with on-board Broadcom WiFi controller

- PCIe link is up with an NVMe drive connected to M.2 Key-M slot and its functionality is verified

- PCIe link is up with a variety of cards (NICs and USB3.0 add-on cards) connected to CEM slot and their functionality is verified

- PCIe link is up with C5 controller configured for the endpoint mode with a host

V6:
* Addressed review comments from Bjorn
* Moved out non-Tegra234 specific changes and created separate patches

V5:
* Addressed review comments from Rob

V4:
* Addressed review comments from Krzysztof and Rob
* Changes are only in schema files and regulator patch
* Dropped PHY related patches as they are already accepted

V3:
* Add DT nodes for the controllers that can work in the EndPoint mode
* Converted the existing device-tree binding documentation from .txt to .yaml
* Add T234 specific information to the RP and EP .yaml documentation files
* Added regulators required to power up required power rails

V2:
* Dropped 3 patches that add clocks & resets IDs, power-domain IDs and memory IDs for PCIe controllers as the patches are already available in linux-next
* Based on Bjorn's review comment, reverted the commit b57256918399 ("PCI:
tegra194: Rename tegra_pcie_dw to tegra194_pcie") and pushed it as a separate patch before adding support for T234 in the existing driver
* Addressed review comments from Rob for the other changes

Vidya Sagar (16):
dt-bindings: pci: tegra: Convert to json-schema
dt-bindings: PCI: tegra234: Add schema for tegra234 rootport mode
dt-bindings: PCI: tegra234: Add schema for tegra234 endpoint mode
arm64: tegra: Add regulators required for PCIe
arm64: tegra: Add P2U and PCIe controller nodes to Tegra234 DT
arm64: tegra: Enable PCIe slots in P3737-0000 board
PCI: Disable MSI for Tegra234 root ports
Revert "PCI: tegra194: Rename tegra_pcie_dw to tegra194_pcie"
PCI: tegra194: Find RAS DES PCIe capability offset
PCI: tegra194: Fix root port interrupt handling
PCI: tegra194: Clear bandwidth management status
PCI: tegra194: Enable support for 256 Byte payload
PCI: tegra194: Cleanup the exit path for endpoint mode
PCI: tegra194: Fix link up retry sequence
PCI: tegra194: Extend endpoint mode support
PCI: tegra: Add Tegra234 PCIe support

 .../bindings/pci/nvidia,tegra194-pcie-ep.yaml | 318 ++++++
 .../bindings/pci/nvidia,tegra194-pcie.txt     | 245 -----
 .../bindings/pci/nvidia,tegra194-pcie.yaml    | 349 +++++++
 .../devicetree/bindings/pci/snps,dw-pcie.yaml |   4 +-
 .../boot/dts/nvidia/tegra234-p3701-0000.dtsi  |  36 +
 .../nvidia/tegra234-p3737-0000+p3701-0000.dts |  51 +
 arch/arm64/boot/dts/nvidia/tegra234.dtsi      | 927 ++++++++++++++++++
 drivers/pci/controller/dwc/pcie-designware.h  |  19 +
 drivers/pci/controller/dwc/pcie-tegra194.c    | 658 ++++++++-----
 drivers/pci/quirks.c                          |  13 +-
 10 files changed, 2136 insertions(+), 484 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
 delete mode 100644 Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.txt
 create mode 100644 Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.yaml
Signature · 1 line
2.17.1