Skip to content

mvebu: Move PCIe code from serdes to PCIe driver

Pali Rohár u-boot 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest9 patches 2 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9arm: mvebu: Convert board_pex_config() to CONFIG_SPL_BOARD_INITarch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h board/gdsys/a38x/controlcenterdc.c +1 more+2 -90 replies
2/9board: gdsys: a38x: Enable PCIe link 2 in spl_board_init()board/gdsys/a38x/controlcenterdc.c+4 -00 replies
3/9pci: pci_mvebu: Fix PCIe MEM and IO resources assignment and mbus mappingarch/arm/mach-mvebu/include/mach/cpu.h drivers/pci/pci_mvebu.c+62 -270 replies
4/9pci: pci_mvebu: Inline mvebu_pcie_port_parse_dt() functiondrivers/pci/pci_mvebu.c+9 -180 replies
5/9pci: pci_mvebu: Remove dependency on SOC_REGS_PHY_BASE macrodrivers/pci/pci_mvebu.c+4 -20 replies
6/9pci: pci_mvebu: Split initialization of PCIe ports into 3 phasesdrivers/pci/pci_mvebu.c+84 -220 replies
7/9pci: pci_mvebu: Wait 100ms for Link Up in mvebu_pcie_probe()drivers/pci/pci_mvebu.c+23 -00 replies
8/9arm: mvebu: Implement simple mvebu-reset driver for enabling/disabling PCIe portsarch/arm/dts/armada-375.dtsi arch/arm/dts/armada-38x.dtsi arch/arm/dts/armada-xp-98dx3236.dtsi +3 more+111 -10 replies
9/9arm: mvebu: a38x: serdes: Move non-serdes PCIe code to pci_mvebu.carch/arm/dts/armada-375.dtsi arch/arm/dts/armada-380.dtsi arch/arm/dts/armada-385.dtsi +12 more+79 -1050 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH u-boot-marvell 0/9] mvebu: Move PCIe code from serdes to PCIe driver

This patch series removes gdsys's board_pex_config() function by converting it to spl_board_init(), adds a new mvebu-reset driver for enabling / disabling PCIe ports and finally moves PCIe code from serdes driver to pci_mvebu.c driver.

After all these changes, PCIe link is not initialized in serdes code anymore, but in pci_mvebu.c driver with help of mvebu-reset driver.

I'm not sure if change for gdsys board is correct, so if somebody has this board, please test it.

I tested this change on A385 board Turris Omnia and I verified that PCIe links are really enabled by pci_mvebu.c driver and not before.

This patch series is based on u-boot-marvell/next branch.

Pali Rohár (9):
arm: mvebu: Convert board_pex_config() to CONFIG_SPL_BOARD_INIT
board: gdsys: a38x: Enable PCIe link 2 in spl_board_init()
pci: pci_mvebu: Fix PCIe MEM and IO resources assignment and mbus
mapping
pci: pci_mvebu: Inline mvebu_pcie_port_parse_dt() function
pci: pci_mvebu: Remove dependency on SOC_REGS_PHY_BASE macro
pci: pci_mvebu: Split initialization of PCIe ports into 3 phases
pci: pci_mvebu: Wait 100ms for Link Up in mvebu_pcie_probe()
arm: mvebu: Implement simple mvebu-reset driver for enabling/disabling
PCIe ports
arm: mvebu: a38x: serdes: Move non-serdes PCIe code to pci_mvebu.c

 arch/arm/dts/armada-375.dtsi                  |   5 +-
 arch/arm/dts/armada-380.dtsi                  |   3 +
 arch/arm/dts/armada-385.dtsi                  |   4 +
 arch/arm/dts/armada-38x.dtsi                  |   1 +
 arch/arm/dts/armada-xp-98dx3236.dtsi          |   2 +
 arch/arm/dts/armada-xp-mv78230.dtsi           |   5 +
 arch/arm/dts/armada-xp-mv78260.dtsi           |   9 +
 arch/arm/dts/armada-xp-mv78460.dtsi           |  10 +
 arch/arm/dts/armada-xp-synology-ds414.dts     |   1 +
 arch/arm/dts/armada-xp-theadorable.dts        |   1 +
 arch/arm/dts/armada-xp.dtsi                   |   1 +
 arch/arm/mach-mvebu/Makefile                  |   1 +
 arch/arm/mach-mvebu/include/mach/cpu.h        |   5 +-
 arch/arm/mach-mvebu/serdes/a38x/Makefile      |   1 -
 arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c    |  64 ----
 arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h    |  28 --
 .../serdes/a38x/high_speed_env_spec.c         |  19 --
 arch/arm/mach-mvebu/system-controller.c       | 105 +++++++
 board/gdsys/a38x/controlcenterdc.c            |   6 +-
 configs/controlcenterdc_defconfig             |   1 +
 drivers/pci/Kconfig                           |   1 +
 drivers/pci/pci_mvebu.c                       | 275 ++++++++++++++----
 22 files changed, 371 insertions(+), 177 deletions(-)
 delete mode 100644 arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c
 delete mode 100644 arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h
 create mode 100644 arch/arm/mach-mvebu/system-controller.c
Signature · 1 line
2.20.1