__mdiobus_register(9)
π __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 targetmii_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 usemdiobus_registerrather than__mdiobus_registerunless they need to pass a specificownermodule. 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:
mdiobus_release(9)mdio_bus_match(9)mdiobus_alloc_size(9)mdiobus_scan_c22(9)mdiobus_scan_c45(9)mdiobus_free(9)mdio_find_bus(9)of_mdio_find_bus(9)
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
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms