arch_change_bit(9)
π arch_change_bit(9) π
Okay so this page is from the Kernel API Manual, and it's here to make a bit-toggling function make sense, bestie. No cap. π
β¨ NAME β¨
arch_change_bit β toggle a bit in memory. That's the whole name, and it ate. π
π οΈ SYNOPSIS π οΈ
Here's the exact signature, keep it verbatim:
void arch_change_bit (int nr , volatile unsigned long *addr );
π§Ύ ARGUMENTS π§Ύ
Two arguments, bestie β both iconic:
nrβ bit to change. π¦addrβ address to start counting from. π
π DESCRIPTION π
Big caveat first, fr fr: change_bit may be reordered on other architectures than x86. π¨ So don't treat that reorder thing as a universal x86 vibe.
Also, note that nr may be almost arbitrarily large; this function is not restricted to acting on a single-word quantity. πΈ So yeah, it's not just a one-word situation β that's the whole point, iykyk.
π SEE ALSO π
Kernel file ./arch/riscv/include/asm/bitops.h β go look, bestie. π
The whole function squad, in order:
__ffs(9)__fls(9)ffs(9)fls(9)arch_test_and_set_bit(9)arch_test_and_clear_bit(9)arch_test_and_change_bit(9)arch_set_bit(9)arch_clear_bit(9)arch_test_and_set_bit_lock(9)arch_clear_bit_unlock(9)arch___clear_bit_unlock(9)
π And that's the tea: source/version ./arch/riscv/include/asm, dated October 2026, for arch_change_bit(9). Stay iconic, bestie! π
π¦ 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