raw_atomic64_sub(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– raw_atomic64_sub(9) πŸ’–

okay bestie, welcome to the raw_atomic64_sub(9) page from the Kernel API Manual β€” we're doing atomic subtraction today and it's lowkey iconic ✨


🌸 NAME 🌸

raw_atomic64_sub β€” atomic subtract with relaxed ordering

✨ SYNOPSIS ✨

void raw_atomic64_sub (s64 i , atomic64_t *v );

πŸŽ€ ARGUMENTS πŸŽ€

  • i β€” s64 value to subtract
  • v β€” pointer to atomic64_t

πŸ¦‹ DESCRIPTION πŸ¦‹

So here's the tea β˜•: this atomically updates v to (v - i) with relaxed ordering. That's the whole move, and it does it atomically β€” no messy race-condition drama.

It's safe to use in noinstr code; prefer atomic64_sub elsewhere. That part matters, okay? Don't be out here using it in the wrong context and then acting surprised πŸ’€

🌈 RETURN 🌈

Nothing. Literally nothing. It's void, bestie 🫢

πŸ‘‘ SEE ALSO πŸ‘‘

Kernel file: ./include/linux/atomic/atomic-arch-fallback.h

The whole sibling squad, exactly as linked:

xoxo, sourced from ./include/linux/atomic, dated October 2026, page raw_atomic64_sub(9) β€” stay atomic, bestie πŸ’…πŸ’–

πŸ“¦ where this page comes from