All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next 0/3] net: dsa: realtek: Add support for use of an optional mdio node
@ 2025-07-27 18:02 ` Jonas Karlman
  0 siblings, 0 replies; 42+ messages in thread
From: Jonas Karlman @ 2025-07-27 18:02 UTC (permalink / raw)
  To: Linus Walleij, Alvin Šipraga, Andrew Lunn, Vladimir Oltean
  Cc: David S . Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Yao Zi, Chukun Pan, Heiko Stuebner, netdev, linux-rockchip,
	linux-arm-kernel, linux-kernel, Jonas Karlman

The Radxa E24C, a Rockchip RK3528A based device, uses a MDIO-connected
RTL8367RB-VB switch to expose four Ethernet ports on the device.

Trying to describe this switch in the device tree in a way that makes
it work for the driver results in dtschema complaining that use of an
mdio child OF node is not allowed.

This series relaxes the realtek dsa drivers requirement of having a mdio
child OF node to probe and instead have it register a user_mii_bus to
make it function when a mdio child OF node is missing.

Another option could also be to adjust the dt-bindings schema to allow
use of a mdio child OF node for MDIO-connected switches.

With this series dtschema is happy and the switch can work:

  rtl8365mb-mdio stmmac-0:1d: found an RTL8367RB-VB switch
  rtl8365mb-mdio stmmac-0:1d: configuring for fixed/rgmii-id link mode
  rtl8365mb-mdio stmmac-0:1d: Link is Up - 1Gbps/Full - flow control off
  rtl8365mb-mdio stmmac-0:1d wan (uninitialized): PHY [stmmac-0:1d:user_mii:00] driver [RTL8365MB-VC Gigabit Ethernet] (irq=74)
  rtl8365mb-mdio stmmac-0:1d lan1 (uninitialized): PHY [stmmac-0:1d:user_mii:01] driver [RTL8365MB-VC Gigabit Ethernet] (irq=75)
  rtl8365mb-mdio stmmac-0:1d lan2 (uninitialized): PHY [stmmac-0:1d:user_mii:02] driver [RTL8365MB-VC Gigabit Ethernet] (irq=76)
  rtl8365mb-mdio stmmac-0:1d lan3 (uninitialized): PHY [stmmac-0:1d:user_mii:03] driver [RTL8365MB-VC Gigabit Ethernet] (irq=77)
  rtl8365mb-mdio stmmac-0:1d wan: configuring for phy/gmii link mode
  rtl8365mb-mdio stmmac-0:1d wan: Link is Up - 1Gbps/Full - flow control off

The device tree changes builds on top of the "arm64: dts: rockchip: Add
Radxa E24C" series at [1].

[1] https://lore.kernel.org/r/20250727144409.327740-1-jonas@kwiboo.se

Jonas Karlman (3):
  net: dsa: realtek: remove unused user_mii_bus from realtek_priv
  net: dsa: realtek: Add support for use of an optional mdio node
  arm64: dts: rockchip: Add RTL8367RB-VB switch to Radxa E24C

 .../boot/dts/rockchip/rk3528-radxa-e24c.dts   | 55 +++++++++++++++++++
 drivers/net/dsa/realtek/realtek.h             |  1 -
 drivers/net/dsa/realtek/rtl83xx.c             | 28 ++++++++--
 3 files changed, 77 insertions(+), 7 deletions(-)

-- 
2.50.1



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

end of thread, other threads:[~2025-08-10 16:52 UTC | newest]

Thread overview: 42+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-27 18:02 [PATCH net-next 0/3] net: dsa: realtek: Add support for use of an optional mdio node Jonas Karlman
2025-07-27 18:02 ` Jonas Karlman
2025-07-27 18:02 ` [PATCH net-next 1/3] net: dsa: realtek: remove unused user_mii_bus from realtek_priv Jonas Karlman
2025-07-27 18:02   ` Jonas Karlman
2025-07-27 18:02 ` [PATCH net-next 2/3] net: dsa: realtek: Add support for use of an optional mdio node Jonas Karlman
2025-07-27 18:02   ` Jonas Karlman
2025-07-27 19:09   ` Andrew Lunn
2025-07-27 19:09     ` Andrew Lunn
2025-07-27 21:52     ` Jonas Karlman
2025-07-27 21:52       ` Jonas Karlman
2025-07-27 22:09       ` Andrew Lunn
2025-07-27 22:09         ` Andrew Lunn
2025-07-28 15:24         ` Jonas Karlman
2025-07-28 15:24           ` Jonas Karlman
2025-07-28 15:40           ` Andrew Lunn
2025-07-28 15:40             ` Andrew Lunn
2025-07-28 16:14             ` Jonas Karlman
2025-07-28 16:14               ` Jonas Karlman
2025-07-27 18:03 ` [PATCH 3/3] arm64: dts: rockchip: Add RTL8367RB-VB switch to Radxa E24C Jonas Karlman
2025-07-27 18:03   ` Jonas Karlman
2025-07-27 19:16   ` Andrew Lunn
2025-07-27 19:16     ` Andrew Lunn
2025-07-28 14:57     ` Jonas Karlman
2025-07-28 14:57       ` Jonas Karlman
2025-07-27 19:57   ` Russell King (Oracle)
2025-07-27 19:57     ` Russell King (Oracle)
2025-07-28 14:30   ` Chukun Pan
2025-07-28 14:30     ` Chukun Pan
2025-07-28 17:47     ` Jonas Karlman
2025-07-28 17:47       ` Jonas Karlman
2025-07-29 11:50       ` Chukun Pan
2025-07-29 11:50         ` Chukun Pan
2025-07-29 20:55         ` Jonas Karlman
2025-07-29 20:55           ` Jonas Karlman
2025-07-29 21:44           ` Andrew Lunn
2025-07-29 21:44             ` Andrew Lunn
2025-08-10 14:01           ` Chukun Pan
2025-08-10 14:01             ` Chukun Pan
2025-08-10 15:15             ` Andrew Lunn
2025-08-10 15:15               ` Andrew Lunn
2025-08-10 16:49               ` Vladimir Oltean
2025-08-10 16:49                 ` Vladimir Oltean

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.