raw_atomic64_set(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… raw_atomic64_set(9) β€” Kernel API Manual, but make it make sense πŸ¦‹

okay bestie, welcome to the raw_atomic64_set page from the Kernel API Manual ✨ this one's a short one, but it's lowkey important, so let's get into it 🫢


✨ NAME ✨

raw_atomic64_set β€” atomic set with relaxed ordering πŸ’«


🌸 SYNOPSIS 🌸

void raw_atomic64_set (atomic64_t *v , s64 i );

that's it. that's the whole signature. iconic behavior honestly πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • v β€” pointer to atomic64_t πŸ’– (the thing you're setting, she's the main character here)
  • i β€” s64 value to assign πŸ“ (the value you're sliding into her, no cap)

🌈 DESCRIPTION 🌈

Atomically sets v to i with relaxed ordering. ⭐

so like, the swap happens in one atomic lil moment β€” nobody's catching her mid-update β€” but the memory ordering is relaxed, meaning she is not out here ordering other memory ops around her. she's chill. she's minding her business. 🧚

Safe to use in noinstr code; prefer atomic64_set elsewhere. πŸ”₯

okay that last bit is the real tea fr fr β€” noinstr code is the special case, and everywhere else you should be reaching for plain atomic64_set, not this one. read the room bestie πŸ’…

πŸ’œ RETURN πŸ’œ

Nothing. πŸ’€ she gives you zero back. no return value, no notes, just vibes.


πŸ¦‹ SEE ALSO πŸ¦‹

the source file, for when you wanna go look at her home:

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

and then. okay. the guest list. it's long. it's giving family reunion at the atomic ops house 😭 but every single one is invited, so:

the 32-bit raw_atomic_* girlies:

and the 64-bit raw_atomic64_* side of the family (aka her actual sisters, note there's no raw_atomic64_set in here β€” that's this page, you're already reading her πŸ’…):

like I said. huge family. but every single name's on the list, so nobody's left out 🫢


and that's the whole page bestie πŸ’œ short, sweet, atomically correct ✨ this came from ./include/linux/atomic, dated October 2026 β€” so go forth, set your atomic64_t with relaxed ordering, and remember: noinstr only, atomic64_set everywhere else. periodt. πŸ’…πŸŽ€

πŸ“¦ where this page comes from