Thread (2 messages) 2 messages, 2 authors, 9h ago

Re: [PATCH net-next] net: stmmac: dwmac-rk: enable the reference clock for output mode

From: Maxime Chevallier <maxime.chevallier@bootlin.com>
Date: 2026-07-16 07:30:59
Also in: linux-rockchip, lkml, netdev

Hi,

On 7/16/26 08:56, Jiaxing Hu wrote:
rk_gmac_clk_init() only requests the refout clock group for RMII. The
ArmSoM CM5 has an on-module YT8531 RGMII PHY with no crystal that needs
the SoC 25 MHz reference (clk_mac_refout), so in RGMII the clock was
never enabled and the PHY did not respond on MDIO.

Request the group whenever the SoC drives the clock (clock_in_out =
"output"), not just for RMII. The clocks are optional, so other boards
are unaffected.
DT binding for rockchip-dwmac says :

clock_in_out:
    description:
      For RGMII, it must be "input", means main clock(125MHz)
      is not sourced from SoC's PLL, but input from PHY.
      For RMII, "input" means PHY provides the reference clock(50MHz),
      "output" means GMAC provides the reference clock.

So the statement "For RGMII, it must be input [...]" is now incorrect :
 - it can be output for RGMII
 - it will be 25Hz if set to output, from what I get from the commit log.

Can you update it ?

Maxime

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help