futex_set(9)
π futex_set(9) β your new fave kernel API page
okay so before we even start: this is from the Kernel API Manual, bestie. That's the vibe. Buckle up π
β¨ NAME β¨
futex_set β atomic decrement of the futex value
not me noticing the NAME says "decrement" while the function is literally called set π that's the page, that's what it says, we report, we don't editorialise. iykyk.
πΈ SYNOPSIS πΈ
u_int32_t futex_set (futex_t *uaddr , u_int32_t newval );
likeβ¦ look at her. she's taking a futex_t * and a u_int32_t and handing you back a u_int32_t. main character energy honestly π₯
π¦ ARGUMENTS π¦
uaddrβ the address of the futex to be modified. literally where the futex lives. point her in the right direction, bestie π«Άnewvalβ New value for theatomic_t. this is the glow-up value you're assigning, no cap β¨
π DESCRIPTION π
Return the new futex value.
that's it. that's the whole description. short king behaviour π she said "my job here is done" and left the group chat. we respect it. π
π SEE ALSO π
the whole futex friend group, assembled π§ββοΈβ¨ first the kernel file:
- Kernel file
./tools/testing/selftests/futex/include/futextest.h
and then the ensemble cast, periodt:
futex(9)futex_wait(9)futex_wake(9)futex_wait_bitset(9)futex_wake_bitset(9)futex_lock_pi(9)futex_unlock_pi(9)futex_wake_op(9)futex_requeue(9)futex_cmp_requeue(9)futex_wait_requeue_pi(9)futex_cmp_requeue_pi(9)futex_cmpxchg(9)futex_dec(9)futex_inc(9)
π sign-off π
this iconic little page is sourced from ./tools/testing/selftests/fute... and it's dated October 2026, and the whole thing is filed under futex_set(9). slay, go read your futexes, ily ππ
ok one last thing because i have to be that friend: everything above is exactly what the page says β i'm not adding behaviour, i'm not subtracting behaviour. copy the flags, keep the facts, and take care of your futexes fr fr π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms