phy_put(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… phy_put(9) πŸ’…

okay bestie, welcome to the Kernel API Manual β€” yes, that's the manual name, and yes, we're reading it together, hold my hand 🫢


🌸 NAME 🌸

phy_put β€” release the PHY, that's literally it, that's the whole job ✨


πŸ¦‹ SYNOPSIS πŸ¦‹

void phy_put (struct device *dev , struct phy *phy );

no cap, that's the entire signature. two args, void return, in and out, done πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the device that wants to release this phy. it's giving "hey, I'm done with this, take it back" energy πŸ‘‘
  • phy β€” the phy returned by phy_get. important!! this is the one you got back from phy_get, not some random phy you found lying around πŸ™ˆ

πŸ’– DESCRIPTION πŸ’–

so what it actually does: it releases a refcount the caller received from phy_get.

that's it. that's the vibe check. you took a ref, now you're giving it back. balanced. symmetrical. main character energy for your reference counting ngl ⭐

bestie please actually pair this with your phy_get β€” an unmatched ref is not the slay you think it is 😭

πŸ”₯ SEE ALSO πŸ”₯

the whole friend group, fr fr β€” all of these live in the kernel file ./drivers/phy/phy-core.c:

phy_create_lookup(9), phy_remove_lookup(9), phy_init(9), phy_exit(9), phy_power_on(9), phy_power_off(9), phy_calibrate(9), phy_notify_connect(9), phy_notify_disconnect(9), phy_notify_state(9), phy_configure(9), phy_validate(9), _of_phy_get(9), of_phy_get(9), of_phy_put(9), devm_phy_put(9), of_phy_simple_xlate(9), phy_get(9), devm_phy_get(9), devm_phy_optional_get(9), devm_of_phy_get(9), devm_of_phy_optional_get(9), devm_of_phy_get_by_index(9), phy_create(9), devm_phy_create(9), phy_destroy(9), devm_phy_destroy(9), __of_phy_provider_register(9), __devm_of_phy_provider_register(9), of_phy_provider_unregister(9), devm_of_phy_provider_unregister(9), phy_release(9)

like. the entire roster. iykyk 🌈


and that's the page, bestie 🧚 this little gem lives in ./drivers/phy and it's dated October 2026 β€” go forth, release your PHYs responsibly, and remember: refcount in, refcount out, periodt πŸ’œπŸŽ€

πŸ“¦ where this page comes from