raw_atomic_..._add_release(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 NAME 🌸

okay so bestie, this is the page for raw_atomic_..._add_release(9) in the Kernel API Manual β€” and the actual star of the show is raw_atomic_long_fetch_add_release: it's an atomic add with release ordering. Atomic girl summer, no cap πŸ’…βœ¨


πŸ¦‹ SYNOPSIS πŸ¦‹

long raw_atomic_long_fetch_add_release (long i , atomic_long_t *v );

πŸŽ€ ARGUMENTS πŸŽ€

  • i β€” a long value to add. That's literally the amount going in, bestie πŸ’–
  • v β€” a pointer to atomic_long_t. This is the atomic long getting updated ✨

πŸ’œ DESCRIPTION πŸ’œ

Atomically updates v to (v + i) with release ordering. Like, the whole update happens atomically, and release ordering is doing its thing. That's the whole deal, periodt.

It's safe to use in noinstr code β€” yes, that's a real constraint, not a vibe. Everywhere else, prefer atomic_long_fetch_add_release β€” that's the instruction, bestie 🫢


⭐ RETURN ⭐

It hands back the original value of v β€” like, the value before the add happened. Not the new one. The original. πŸ’…


🌈 SEE ALSO 🌈

Kernel file: ./include/linux/atomic/atomic-long.h β€” the whole friend group lives here πŸ‘€πŸ«Ά


source/version says ./include/linux/atomic πŸ’– date says October 2026 πŸŽ€ page title says raw_atomic_..._add_release(9) β€” that's the cute little footer moment, bestie, now go slay those atomics βœ¨πŸ’…

πŸ“¦ where this page comes from