__mdiobus_register(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– __mdiobus_register(9) πŸ’–

okay so this is the __mdiobus_register(9) page from the Kernel API Manual, and honestly? it's giving β€œbus driver glow-up” energy. let's get into it bestie 🫢


🌸 NAME 🌸

__mdiobus_register β€” bring up all the PHYs on a given bus and attach them to bus


✨ SYNOPSIS ✨

int __mdiobus_register (struct mii_bus *bus , struct module *owner );

πŸŽ€ ARGUMENTS πŸŽ€

  • bus β€” the target mii_bus πŸ‘‘
  • owner β€” the module containing bus accessor functions 🧚

πŸ¦‹ DESCRIPTION πŸ¦‹

So this function gets called by a bus driver to bring up all the PHYs on a given bus, and attach them to the bus. main character behavior, honestly πŸ’…

🚨 lowkey important: drivers should use mdiobus_register rather than __mdiobus_register unless they need to pass a specific owner module. like, don't reach for the double-underscore one for no reason, bestie 😭

MDIO devices which are not PHYs will not be brought up by this function. they are expected to be explicitly listed in DT and instantiated by of_mdiobus_register. periodt ✨

Returns 0 on success or < 0 on error. that's it, that's the vibe check 🌈


πŸ”₯ SEE ALSO πŸ”₯

Kernel file ./drivers/net/phy/mdio_bus_provider.c and these besties:


and that's the page, bestie πŸ’– signing off with the footer deets: source/version ./drivers/net/phy, dated October 2026. mwah πŸ’‹πŸŽ€

πŸ“¦ where this page comes from