stmmac_mdio_read_c22(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ stmmac_mdio_read_c22(9) β€” kernel API manual, but make it fashion

okay so bestie, this is a page straight out of the Kernel API Manual β€” the function is stmmac_mdio_read_c22 and yes the manual name is literally just "Kernel API Manual", no extra lore, we move πŸ’…


✨ NAME ✨

stmmac_mdio_read_c22 β€” and that's it. The original page leaves the description side blank (just a lonely little -), so we are not out here inventing lore, periodt πŸŽ€


🌸 SYNOPSIS 🌸

int stmmac_mdio_read_c22 (struct mii_bus *bus , int phyaddr , int phyreg
);

that's the whole vibe check, bestie β€” it returns an int, and it takes three things πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • bus β€” this one points to the mii_bus structure. she's the main character of the whole operation fr fr πŸ¦‹
  • phyaddr β€” the MII addr. literally what it says on the tin ✨
  • phyreg β€” the MII reg. also literally what it says on the tin πŸ’–

πŸ’œ DESCRIPTION πŸ’œ

okay so the tea: this bad boy reads data from the MII register, and it does it from within the phy device itself. iconic behavior, no notes 🌈

now the important bit β€” for the 7111 GMAC, you must set bit 0 in the MII address register while you're accessing the PHY registers. not optional, not a suggestion, it's a whole requirement πŸ‘‘

and the lucky little plot twist? it seems this has no drawback for the 7109 MAC. so the 7109 is out here unbothered, living her best life, slay 😌✨

bestie pls don't skip the bit-0 thing on the 7111, it's not decorative πŸ’€

πŸ”₯ SEE ALSO πŸ”₯

the kernel file herself, in all her glory:

./drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c

and the whole friend group 🫢:

like, the c45 siblings, the write twins, the reset, the clock, the register/unregister duo β€” the entire ensemble cast is here, ate and left no crumbs πŸ‘‘πŸ’…


🌸 and that's the page!! huge shoutout to the source, ./drivers/net/ethernet/stmicro/..., dated October 2026 β€” read responsibly bestie, mwah πŸ’–πŸ§šβ€β™€οΈπŸ“

πŸ“¦ where this page comes from