phy_error(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… phy_error β€” like, the emergency panic button for your PHY, bestie

okay so this is a page straight out of the Kernel API Manual, and honestly? it's short, it's iconic, it's giving "one job and she does it." let's get into it 🫢


✨ NAME ✨

phy_error β€” enter ERROR state for this PHY device

no cap, that's literally the whole vibe. something went wrong, and this is the function that says so out loud. πŸ’€


🌸 SYNOPSIS 🌸

void phy_error (struct phy_device *phydev );

she takes exactly one argument, returns nothing, and does not miss. periodt.


πŸŽ€ ARGUMENTS πŸŽ€

  • phydev β€” target phy_device struct. this is the PHY we're putting in timeout. the main character, if you will πŸ‘‘

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so hear me out: phy_error moves the PHY to the ERROR state in response to a read or write error, and then it tells the controller the link is down. like, "bestie the link is done, pack it up." 😭

the one rule that is NOT optional: this must be called with phydev->lock held. not "should", not "ideally" β€” must. so hold that lock, or don't come crying to me. πŸ”₯

⭐ SEE ALSO ⭐

the whole friend group, in the order the page says it, because I would never leave anyone out πŸ’– β€” all of these live in the Kernel file ./drivers/net/phy/phy.c:


✨ that's the whole page, nothing skipped, nothing invented, absolutely zero notes left behind ✨

okay love u, bye β€” this one shipped from ./drivers/net/phy, dated October 2026, and yes she's still serving phy_error(9) realness πŸŒˆπŸ’œπŸ“

πŸ“¦ where this page comes from