completion_done(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… completion_done(9) β€” the kernel API manual, but make it make sense

okay so bestie, welcome to completion_done from the Kernel API Manual β€” yes that's the manual name, yes it's giving "ancient scrolls," but stay with me because this one is actually so useful 🫢


✨ NAME ✨

completion_done β€” a lil vibe check to see if a completion has any waiters πŸ‘€


🌸 SYNOPSIS 🌸

bool completion_done (struct completion *x );

that's it. that's the whole thing. one arg, one bool back. iconic behavior honestly ✨


πŸŽ€ ARGUMENTS πŸŽ€

  • x β€” the completion structure bestie, that's it, that's the arg πŸ’–

πŸ¦‹ RETURN πŸ¦‹

  • 0 β€” there ARE waiters (like, wait_for_completion is in progress rn) 😭
  • 1 β€” there are NO waiters, nobody's waiting, the group chat is quiet πŸŒ™
ok so heads up, the 0-means-waiters thing is lowkey the reverse of what your brain wants. 0 = people waiting. 1 = nobody waiting. not me almost getting this backwards πŸ™ˆ

🌈 DESCRIPTION 🌈

so here's the tea πŸ“: this will always return true if complete_all was called on X.

that's literally the whole note. read it again. complete_all on X? always true. no cap. πŸ’€


πŸ‘‘ SEE ALSO πŸ‘‘

Kernel file ./kernel/sched/completion.c β€” go read it, it's right there:

like a whole friend group of completion functions honestly, they all ate πŸ”₯



and that's the page!! brought to you by ./kernel/sched, dated October 2026 β€” mwah, go touch some completions bestie πŸ’œπŸ§š

πŸ“¦ where this page comes from