llist_add(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

llist_add(9) πŸ’…

okay bestie, this one’s from the Kernel API Manual, and it’s lowkey iconic: we’re adding a new entry to a lock-less list. Let’s get into it ✨


✨ NAME ✨

llist_add β€” add a new entry πŸŽ€


✨ SYNOPSIS ✨

bool llist_add (struct llist_node *new , struct llist_head *head );

✨ ARGUMENTS ✨

  • new β€” the new entry to be added, periodt πŸ’…
  • head β€” the head for your lock-less list 🫢

✨ DESCRIPTION ✨

Returns true if the list was empty prior to adding this entry. Not me checking whether the list was empty before the glow-up 😭✨


✨ SEE ALSO ✨

Kernel file ./include/linux/llist.h plus these besties:


source/version: ./include/linux, date: October 2026 β€” bye bestie, mwah πŸ’‹πŸ’–

πŸ“¦ where this page comes from