of_reset_control_get_shared(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… NAME πŸ’…

of_reset_control_get_shared β€” bestie, this is the one that goes and looks up a reset controller and hands you a shared reference to it. Like, you're not the only one holding it, and that's literally the whole point ✨

(oh also, hi, this is the Kernel API Manual β€” welcome to the function-specific corner of the kernel docs πŸŽ€)


✨ SYNOPSIS ✨

struct reset_control * of_reset_control_get_shared (struct device_node
*node , const char *id );

🌸 ARGUMENTS 🌸

  • node β€” the device that's getting reset by the controller πŸ‘‘ like, this is the main character here.
  • id β€” the name of the reset line πŸŽ€

πŸ’– DESCRIPTION πŸ’–

Okay so here's the tea πŸ«– β€” when a reset-control is shared, the behaviour of reset_control_assert / deassert is genuinely different, no cap. The reset-core keeps track of a deassert_count and it will only (re-)assert the reset after reset_control_assert has been called as many times as reset_control_deassert was called. It's giving ✨reference counting energy✨ ngl. Also, go peek at the remark about shared reset-controls over in the reset_control_assert docs πŸ‘€

⚠️ Real talk, bestie β€” calling reset_control_assert without first calling reset_control_deassert is not allowed on a shared reset control. Periodt. And calling reset_control_reset is also not allowed on a shared reset control. Not me warning you twice 😭

It returns a struct reset_control or an IS_ERR condition containing errno πŸ’€

Use of id names is optional πŸ¦‹ (so like, optional optional, not a vibe check you have to pass)


πŸ”₯ SEE ALSO πŸ”₯

Kernel file ./include/linux/reset.h β€” and honestly the whole reset-core friend group πŸ’œ:


okay that's the whole page, you ate that πŸ’… this lil doc lives in ./include/linux and it's dated October 2026 β€” so it's from the future, iconic behavior honestly πŸ¦‹βœ¨

πŸ“¦ where this page comes from