All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 00/19] Enhance CP110 COMPHY support
@ 2019-06-27  9:50 Miquel Raynal
  2019-06-27  9:50   ` Miquel Raynal
                   ` (12 more replies)
  0 siblings, 13 replies; 49+ messages in thread
From: Miquel Raynal @ 2019-06-27  9:50 UTC (permalink / raw)
  To: Gregory Clement, Jason Cooper, Andrew Lunn,
	Sebastian Hesselbarth, Kishon Vijay Abraham I
  Cc: devicetree, Antoine Tenart, Grzegorz Jaszczyk, Russell King,
	Maxime Chevallier, Nadav Haklai, Rob Herring, Thomas Petazzoni,
	Miquel Raynal, linux-arm-kernel

Armada CP110 have a COMPHY IP which supports configuring SERDES lanes
in one mode, either:
- SATA
- USB3 host
- PCIe (several width)
- Ethernet (several modes)

As of today, only a few Ethernet modes are supported and the code is
embedded in the Linux driver. A more complete COMPHY driver that can
be used by both Linux and U-Boot is embedded in the firmware and can
be run through SMC calls.

First the current COMPHY driver is updated to use SMC calls but
fallbacks to the already existing functions if the firmware is not
up-to-date. Then, more Ethernet modes are added (through SMC calls
only). SATA, USB3H and PCIe modes are also supported one by one.

There is one subtle difference with the PCIe functions: we must tell
the firmware the number of lanes to configure (x1, x2 or x4). This
parameter depends on the number of entries in the 'phys' property
describing the PCIe PHY. We use the "submode" parameter of the generic
PHY API to carry this value. The Armada-8k PCIe driver has been
updated to follow this idea and this change has been merged already:
http://patchwork.ozlabs.org/patch/1072763/

Thanks,
Miquèl


Changes since v1:
-----------------
- All modes report their errors to the user.
- If the firmware is too old, advise the user to update it.
- Credit Grzegorz for his work.
- Fix wrong speed in Ethernet modes.
- Add COMPHY necessary clocks.
- Update bindings.
- The security flaw related to the fact that we must give the CP
  address to the firmware has been mitigated by the addition of extra
  checks in ATF recently.

Grzegorz Jaszczyk (5):
  phy: mvebu-cp110-comphy: Add SMC call support
  phy: mvebu-cp110-comphy: Add RXAUI support
  phy: mvebu-cp110-comphy: Add USB3 host/device support
  phy: mvebu-cp110-comphy: Add SATA support
  phy: mvebu-cp110-comphy: Add PCIe support

Miquel Raynal (14):
  phy: mvebu-cp110-comphy: Add clocks support
  phy: mvebu-cp110-comphy: Explicitly initialize the lane submode
  phy: mvebu-cp110-comphy: List already supported Ethernet modes
  phy: mvebu-cp110-comphy: Rename the macro handling only Ethernet modes
  phy: mvebu-cp110-comphy: Allow non-Ethernet modes to be configured
  phy: mvebu-cp110-comphy: Cosmetic change in a helper
  phy: mvebu-cp110-comphy: Update comment about powering off all lanes
    at boot
  dt-bindings: phy: Add Marvell COMPHY clocks
  dt-bindings: pci: add PHY properties to Armada 7K/8K controller
    bindings
  arm64: dts: marvell: Add CP110 COMPHY clocks
  arm64: dts: marvell: Add 7k/8k per-port PHYs in SATA nodes
  arm64: dts: marvell: Add 7k/8k PHYs in USB3 nodes
  arm64: dts: marvell: Add 7k/8k PHYs in PCIe nodes
  arm64: dts: marvell: Convert 7k/8k usb-phy properties to phy-supply

 .../devicetree/bindings/pci/pci-armada8k.txt  |   4 +
 .../bindings/phy/phy-mvebu-comphy.txt         |  10 +
 .../arm64/boot/dts/marvell/armada-7040-db.dts |  37 +-
 .../marvell/armada-8040-clearfog-gt-8k.dts    |  22 +-
 .../arm64/boot/dts/marvell/armada-8040-db.dts |  43 +-
 .../boot/dts/marvell/armada-8040-mcbin.dtsi   |  38 +-
 arch/arm64/boot/dts/marvell/armada-cp110.dtsi |  13 +
 drivers/phy/marvell/phy-mvebu-cp110-comphy.c  | 409 +++++++++++++++---
 8 files changed, 494 insertions(+), 82 deletions(-)

-- 
2.19.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 49+ messages in thread

end of thread, other threads:[~2019-07-29  8:10 UTC | newest]

Thread overview: 49+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-27  9:50 [PATCH v2 00/19] Enhance CP110 COMPHY support Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 01/19] phy: mvebu-cp110-comphy: Add clocks support Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-07-29  8:06   ` Grzegorz Jaszczyk
2019-07-29  8:10   ` Grzegorz Jaszczyk
2019-06-27  9:50 ` [PATCH v2 02/19] phy: mvebu-cp110-comphy: Explicitly initialize the lane submode Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 03/19] phy: mvebu-cp110-comphy: Add SMC call support Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-07-23  8:48   ` Maxime Chevallier
2019-07-23  8:48     ` Maxime Chevallier
2019-06-27  9:50 ` [PATCH v2 04/19] phy: mvebu-cp110-comphy: List already supported Ethernet modes Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 05/19] phy: mvebu-cp110-comphy: Add RXAUI support Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 06/19] phy: mvebu-cp110-comphy: Rename the macro handling only Ethernet modes Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 07/19] phy: mvebu-cp110-comphy: Allow non-Ethernet modes to be configured Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 08/19] phy: mvebu-cp110-comphy: Add USB3 host/device support Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 09/19] phy: mvebu-cp110-comphy: Add SATA support Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 10/19] phy: mvebu-cp110-comphy: Cosmetic change in a helper Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 11/19] phy: mvebu-cp110-comphy: Add PCIe support Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27  9:50 ` [PATCH v2 12/19] phy: mvebu-cp110-comphy: Update comment about powering off all lanes at boot Miquel Raynal
2019-06-27  9:50   ` Miquel Raynal
2019-06-27 12:24 ` [PATCH v2 13/19] dt-bindings: phy: Add Marvell COMPHY clocks Miquel Raynal
2019-06-27 12:24   ` Miquel Raynal
2019-06-27 12:25   ` [PATCH v2 14/19] dt-bindings: pci: add PHY properties to Armada 7K/8K controller bindings Miquel Raynal
2019-06-27 12:25     ` Miquel Raynal
2019-07-22 17:52     ` Rob Herring
2019-07-22 17:52       ` Rob Herring
2019-07-23  8:35       ` Miquel Raynal
2019-07-24 15:56       ` Miquel Raynal
2019-06-27 12:25   ` [PATCH v2 15/19] arm64: dts: marvell: Add CP110 COMPHY clocks Miquel Raynal
2019-06-27 12:25     ` Miquel Raynal
2019-06-27 12:25   ` [PATCH v2 16/19] arm64: dts: marvell: Add 7k/8k per-port PHYs in SATA nodes Miquel Raynal
2019-06-27 12:25     ` Miquel Raynal
2019-06-27 12:25   ` [PATCH v2 17/19] arm64: dts: marvell: Add 7k/8k PHYs in USB3 nodes Miquel Raynal
2019-06-27 12:25     ` Miquel Raynal
2019-06-27 12:25   ` [PATCH v2 18/19] arm64: dts: marvell: Add 7k/8k PHYs in PCIe nodes Miquel Raynal
2019-06-27 12:25     ` Miquel Raynal
2019-06-27 12:25   ` [PATCH v2 19/19] arm64: dts: marvell: Convert 7k/8k usb-phy properties to phy-supply Miquel Raynal
2019-06-27 12:25     ` Miquel Raynal
2019-07-22 17:51   ` [PATCH v2 13/19] dt-bindings: phy: Add Marvell COMPHY clocks Rob Herring
2019-07-22 17:51     ` Rob Herring

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.