raw_atomic_..._inc_acquire(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… raw_atomic_..._inc_acquire(9) β€” straight from the Kernel API Manual πŸ’…

🌸 NAME 🌸

raw_atomic_long_fetch_inc_acquire β€” atomic increment with acquire ordering. Bestie, this is the raw_ one, and the page header calls it raw_atomic_..._inc_acquire(9), iykyk.


✨ SYNOPSIS ✨

long raw_atomic_long_fetch_inc_acquire (atomic_long_t *v );

That's the whole call. Slay.


πŸŽ€ ARGUMENTS πŸŽ€

  • v β€” pointer to atomic_long_t. That's the atomic long getting the little +1 moment.

πŸ¦‹ DESCRIPTION πŸ¦‹

Okay so this function atomically updates v to (v + 1) with acquire ordering. Like, the update happens atomically, and the acquire ordering is part of the vibe. No cap.

The manpage also says it's safe to use in noinstr code β€” and that you should prefer atomic_long_fetch_inc_acquire elsewhere. So if you're in noinstr land, this is your girl. Outside that, the non-raw_ bestie is the prefered one.


πŸ’– RETURN πŸ’–

The original value of v. Not the new +1 value β€” the one from before the glow-up. Periodt.


🌈 SEE ALSO 🌈

Kernel file: ./include/linux/atomic/atomic-long.h

The whole atomic-long extended fam is here, no cap:


And that's the page, bestie πŸ’– Signed off with source/version ./include/linux/atomic, dated October 2026, and the footer still name-drops raw_atomic_..._inc_acquire(9). Mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from