raw_atomic6...turn_release(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– raw_atomic64_sub_return_release β€” from the Kernel API Manual, section 9 πŸŽ€

okay bestie so the header on this page got absolutely butchered by the truncation goblins and shows up as raw_atomic6...turn_release(9) 😭 but like, we know her. This is raw_atomic64_sub_return_release from section 9 of the Kernel API Manual, and she's lowkey an icon.


✨ NAME ✨

raw_atomic64_sub_return_release β€” atomic subtract with release ordering. that's it. that's the whole vibe. πŸ¦‹


🌸 SYNOPSIS 🌸

s64 raw_atomic64_sub_return_release (s64 i , atomic64_t *v );

🧚 ARGUMENTS 🧚

  • i β€” the s64 value you're subtracting. the amount coming off the top, no cap. πŸ’œ
  • v β€” pointer to atomic64_t. this is the girl. the thing actually getting updated. πŸ‘‘

πŸ”₯ DESCRIPTION πŸ”₯

So the way this works is genuinely so clean: it atomically updates v to (v - i) with release ordering. all at once, nobody sees a half-finished state, slay. ⭐

It's safe to use in noinstr code β€” that's her whole personality β€” but elsewhere, prefer atomic64_sub_return_release instead. like, raw_* is for the special occasions, iykyk. πŸ’…


πŸŽ€ RETURN πŸŽ€

Returns the updated value of v. so you get the new number back, not the old one. periodt. ✨


🌈 SEE ALSO 🌈


🫢 and that's the page!! sourced straight from ./include/linux/atomic, dated October 2026, filed under the title raw_atomic6...turn_release(9) (truncated so rudely, but we love her anyway). go forth and subtract atomically bestie πŸ’–πŸ’…βœ¨

πŸ“¦ where this page comes from