stmmac_clk_csr_set(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… stmmac_clk_csr_set(9) πŸ’…

okay so this page is from the Kernel API Manual, bestie, and we're talking about stmmac_clk_csr_set β€” the function that dynamically sets the MDC clock πŸ’–. iconic behavior. ✨


🌸 NAME 🌸

stmmac_clk_csr_set β€” dynamically set the MDC clock. periodt. πŸ’…


✨ SYNOPSIS ✨

u32 stmmac_clk_csr_set (struct stmmac_priv *priv );

πŸŽ€ ARGUMENTS πŸŽ€

  • priv β€” the driver private structure. that's the one argument, and she's carrying the whole vibe 🫢

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so the whole point is that this dynamically sets the MDC clock according to the csr clock input. literally that's the function's main-character job πŸ’«


⭐ RETURN ⭐

the return value is the MII register CR field value. slay πŸ’…


πŸ’€ NOTE πŸ’€

bestie, important caveat time: if a specific clk_csr value is passed from the platform, this means that the CSR Clock Range selection cannot be changed at run-time and it is fixed (as reported in the driver documentation). Vice versa, the driver will try to set the MDC clock dynamically according to the actual clock input. so like… platform says fixed = fixed, no cap; otherwise the driver tries the dynamic route πŸ”₯

🌈 SEE ALSO 🌈

Kernel file: ./drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c β€” go read the source, iykyk πŸ“š


bye bestie 🫢 β€” this cutie comes from source/version ./drivers/net/ethernet/stmicro..., dated October 2026, and the page is still serving stmmac_clk_csr_set(9) energy πŸ‘‘πŸ’œ

πŸ“¦ where this page comes from