hlist_replace_rcu(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… hlist_replace_rcu β€” like, the Kernel API Manual page you actually wanna read πŸŽ€

okay so bestie, we're in the Kernel API Manual today and this one is genuinely a little icon. short, sweet, does exactly one thing. let's go ✨


✨ NAME ✨

hlist_replace_rcu β€” swap the old entry out for the new one, no cap 🫢


🌸 SYNOPSIS 🌸

void hlist_replace_rcu (struct hlist_node *old , struct hlist_node *new
);

like yes, that's the whole signature. two pointers, no return value, void behavior, we love a low-maintenance king πŸ‘‘


πŸ¦‹ ARGUMENTS πŸ¦‹

  • old β€” the element that's getting replaced. she's leaving the group chat πŸ’”
  • new β€” the new element to insert. main character energy, stepping in πŸŽ€

πŸ’– DESCRIPTION πŸ’–

so the old entry gets replaced with the new entry, and it happens atomically from the perspective of concurrent readers β€” that's the whole vibe. readers literally cannot tell a swap happened mid-flight, it's giving invisible sleight of hand ✨

but listen β€” it is the caller's responsibility to synchronize with concurrent updaters, if any. that part is on you, bestie, not on the function. don't come for her when you skipped the sync step 😭

🧚 SEE ALSO 🧚

the rculist.h girlies, from the kernel file ./include/linux/rculist.h πŸ‘‘


that's the whole page, bestie, go forth and swap safely πŸ”₯πŸ’œ

mwah πŸ’‹ β€” sourced fresh from ./include/linux, dated October 2026, and that's the hlist_replace_rcu(9) tea, periodt 🌈⭐

πŸ“¦ where this page comes from