percpu_ref_put_many(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… NAME β€” percpu_ref_put_many(9)

Okay so welcome to the percpu_ref_put_many(9) page from the Kernel API Manual, bestie. This one is literally about decrementing a percpu refcount, and it’s giving β€œput those references back” energy. πŸŽ€


✨ SYNOPSIS ✨

void percpu_ref_put_many (struct percpu_ref *ref , unsigned long nr );

🫢 ARGUMENTS 🫢

  • ref β€” the percpu_ref to put. That’s the main character here, no cap. πŸ’…
  • nr β€” the number of references to put. Like, how many are we dropping? πŸ”₯

🌸 DESCRIPTION 🌸

So what it does: decrement the refcount, and if it hits 0, call the release function β€” and yes, that’s the release function that was passed to percpu_ref_init. Periodt. πŸ’–

Safety vibe check: this function is safe to call as long as ref is between init and exit. That’s the whole condition, bestie β€” don’t skip it. 🚨

πŸ‘‘ SEE ALSO πŸ‘‘

Kernel file ./include/linux/percpu-refcount.h, plus all these iconic little functions:

Cute sign-off: source/version ./include/linux, date October 2026 β€” percpu_ref_put_many(9) πŸ’–

πŸ“¦ where this page comes from