All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next 0/2] dt-bindings: define property describing supported ethernet PHY modes
@ 2021-03-24 10:35 Marek Behún
  2021-03-24 10:35 ` [PATCH net-next 1/2] dt-bindings: ethernet-controller: create a type for PHY interface modes Marek Behún
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Marek Behún @ 2021-03-24 10:35 UTC (permalink / raw)
  To: netdev, Andrew Lunn, David S . Miller, Florian Fainelli,
	Heiner Kallweit, Russell King, Rob Herring, devicetree
  Cc: pali, Marek Behún

Hello,

the Marvell Alaska PHYs (88X3310, 88E2110) can, depending on their
configuration, change the PHY mode to the MAC, depending on the
copper/fiber speed.

The 88X3310, for example, can be configured (via MACTYPE register)
so that it communicates with the MAC in sgmii for 10/100/1000mbps,
2500base-x for 2500mbps, 5gbase-r for 5gbps and either 10gbase-r,
xaui or rxaui for 10gbps. Or the PHY may communicate with the MAC
in usxgmii, or one of the 10gbase-r, rxaui or xaui modes with rate
matching.

So for the 10gbps mode we have options 10gbase-r, xaui, rxaui and
usxgmii. The MAC can support some of these modes, and if it does more
than one, we need to know which one to use. Not all of these modes
must necessarily be supported by the board (xaui required wiring for
4 SerDes lanes, for example, and 10gbase-r requires wiring capable
of transmitting at 10.3125 GBd).

The MACTYPE is upon HW reset configured by strapping pins - so the
board should have a correct mode configured after HW reset.

One problem with this is that some boards configure the MACTYPE to
a rate matching mode, which, according to the errata, is broken in
some situations (it does not work for 10/100/1000, for example).

Another problem is that if lower modes are supported, we should
maybe use them in order to save power.

But for this we need to know which phy-modes are supported on the
board.

This series adds documentation for a new ethernet PHY property,
called `supported-mac-connection-types`.

When this property is present for a PHY node, only the phy-modes
listed in this property should be considered to be functional on
the board.

The second patch adds binding for this property.

The first patch does some YAML magic in ethernet-controller.yaml
in order to be able to reuse the PHY modes enum, so that the same
list does not have to be defined twice.

Marek

Marek Behún (2):
  dt-bindings: ethernet-controller: create a type for PHY interface
    modes
  dt-bindings: ethernet-phy: define `supported-mac-connection-types`
    property

 .../bindings/net/ethernet-controller.yaml     | 89 ++++++++++---------
 .../devicetree/bindings/net/ethernet-phy.yaml | 18 ++++
 2 files changed, 66 insertions(+), 41 deletions(-)

-- 
2.26.2


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

end of thread, other threads:[~2021-03-25  0:44 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-24 10:35 [PATCH net-next 0/2] dt-bindings: define property describing supported ethernet PHY modes Marek Behún
2021-03-24 10:35 ` [PATCH net-next 1/2] dt-bindings: ethernet-controller: create a type for PHY interface modes Marek Behún
2021-03-24 20:07   ` Rob Herring
2021-03-24 20:59     ` Marek Behún
2021-03-24 10:35 ` [PATCH net-next 2/2] dt-bindings: ethernet-phy: define `supported-mac-connection-types` property Marek Behún
2021-03-24 21:19 ` [PATCH net-next 0/2] dt-bindings: define property describing supported ethernet PHY modes Florian Fainelli
2021-03-24 23:00   ` Marek Behún
2021-03-24 23:16     ` Florian Fainelli
2021-03-24 23:45       ` Marek Behún
2021-03-25  0:11         ` Florian Fainelli
2021-03-25  0:30           ` Russell King - ARM Linux admin
2021-03-25  0:43           ` Marek Behún
2021-03-25  0:28         ` Russell King - ARM Linux admin

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.