kernfs_get_active(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– kernfs_get_active(9) πŸ’–

okay so bestie, welcome to the Kernel API Manual page for kernfs_get_active(9) β€” yes the manual name is literally that, iykyk, and we're getting into it 🫢


✨ NAME ✨

kernfs_get_active β€” get an active reference to kernfs_node 🌸


πŸ¦‹ SYNOPSIS πŸ¦‹

struct kernfs_node * kernfs_get_active (struct kernfs_node *kn );

like, that's the whole vibe. short and iconic, no cap πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • kn β€” the kernfs_node you want to get an active reference to. that's it. that's the arg πŸ’…

πŸ’œ DESCRIPTION πŸ’œ

so basically you call this to get an active reference of kn. that's the main character move ✨

and here's the slay detail: this function is noop if kn is NULL. so if kn is NULL, nothing happens at all β€” it just... vibes. doesn't crash, doesn't complain, literally noop 🧚 lowkey the most chill behaviour ever.


⭐ RETURN ⭐

  • pointer to kn on success πŸ’–
  • NULL on failure 😭

that's it, that's the return. simple, clean, gorgeous.


🌈 SEE ALSO 🌈

kernel file ./fs/kernfs/dir.c β€” and honestly the whole friend group is here, so let's run through the crew fr fr:

like, an entire group chat of kernfs functions. go say hi to all of them πŸ’…πŸ”₯


okay and one last lil sign-off πŸŽ€ β€” this page lives in ./fs/kernfs, dated October 2026, and it's filed under kernfs_get_active(9). mwah, that's the page, go be an active reference bestie πŸ¦‹βœ¨πŸ’–

πŸ“¦ where this page comes from