list_del_rcu(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

okay bestie, welcome to the list_del_rcu(9) page from the Kernel API Manual. short version: list_del_rcu deletes entry from list without re-initialization. that's the whole name vibe. periodt.

✨ SYNOPSIS ✨

void list_del_rcu (struct list_head *entry );

πŸŽ€ ARGUMENTS πŸŽ€

  • entry β€” the element to delete from the list. yes queen, that's the one.

πŸ¦‹ NOTE πŸ¦‹

big note time, bestie, don't skip this:

  • list_empty on entry does not return true after this. the entry is in an undefined state. it is useful for RCU based lockfree traversal.
  • In particular, it means that we can not poison the forward pointers that may still be used for walking the list.
  • The caller must take whatever precautions are necessary (such as holding appropriate locks) to avoid racing with another list-mutation primitive, such as list_del_rcu or list_add_rcu, running on this same list. However, it is perfectly legal to run concurrently with the _rcu list-traversal primitives, such as list_for_each_entry_rcu.
  • Note that the caller is not permitted to immediately free the newly deleted entry. Instead, either synchronize_rcu or call_rcu must be used to defer freeing until an RCU grace period has elapsed.

🌈 SEE ALSO 🌈

the kernel file is ./include/linux/rculist.h, and the whole link-up squad is:


signed off from the ./include/linux source/version, dated October 2026 β€” list_del_rcu(9) πŸ«ΆπŸ’…

πŸ“¦ where this page comes from