hns_mdio_read_c22(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– hns_mdio_read_c22(9) πŸ’–

okay bestie, welcome to the Kernel API Manual β€” yes that's the manual name, we're literally in it β€” and today's main character is hns_mdio_read_c22, a function that 🫢 reads a phy register. that's it, that's the vibe. a little one-job icon and honestly? respect.


🌸 NAME 🌸

hns_mdio_read_c22 β€” access phy register ✨

like, it goes and gets you the goods from a phy register. no cap.


πŸ¦‹ SYNOPSIS πŸ¦‹

int hns_mdio_read_c22 (struct mii_bus *bus , int phy_id , int regnum );

the way this signature just sits there being all tidy 😭 three params, returns an int, we love a low-drama prototype.


πŸŽ€ ARGUMENTS πŸŽ€

  • bus β€” the mdio bus, bestie. it's the bus. that's the whole description and we're honoring it fr fr.
  • phy_id β€” the phy id πŸ‘‘ which phy are we talking to? this one.
  • regnum β€” the register num πŸ“ which register are we reading? this one.

three args, zero mystery, we stan.


πŸ’… DESCRIPTION πŸ’…

Return phy register value. that's the entire description and honestly it ate πŸ’€ no notes.

so like, you call it, it gives you back the value sitting in that phy register. the return type is int (see the synopsis, it's right there, i'm not making stuff up). that's the whole story, periodt.

ngl it's giving "tiny function, big responsibility" β€” you're reaching into hardware registers, so please know what phy_id and regnum you actually mean before you go poking πŸ™ˆ

🌈 SEE ALSO 🌈


and that's the page, bestie! this lil gem lives under the source dir ./drivers/net/ethernet/hisilicon, and it's dated October 2026 in the manual β€” so when you see that date in the wild, you'll know exactly which icon wrote it πŸ’–πŸ¦‹πŸŽ€

πŸ“¦ where this page comes from