refcount_read(9)
π refcount_read(9) π
okay so welcome to the Kernel API Manual, bestie β yes you're literally reading kernel docs rn and that's iconic of you π this one's a tiny lil page about peeking at a refcount's value, no cap.
β¨ NAME β¨
refcount_read β get a refcount's value π«Ά
πΈ SYNOPSIS πΈ
unsigned int refcount_read (const refcount_t *r );
π¦ ARGUMENTS π¦
rβ the refcount π like, the actual refcount you wanna look at, that's it, that's the whole argument
β RETURN β
the refcount's value β¨ (yes that's the entire return description, she's short and she's slaying)
ngl this one is the low-key chillest function in the whole refcount friend group β no incrementing, no testing, no acquiring, just looking π main character energy of minding your own business fr fr
π SEE ALSO π
Kernel file ./include/linux/refcount.h β and here's the whole squad, all of them, in order, because we do not skip anyone in this house π«Ά
refcount_set(9)refcount_set_release(9)refcount_add_not_zero(9)refcount_add_not_zero_acquire(9)refcount_add(9)refcount_inc_not_zero(9)refcount_inc_not_zero_acquire(9)refcount_inc(9)refcount_sub_and_test(9)refcount_dec_and_test(9)refcount_dec(9)
π and that's the whole page, bestie, you ate that π mwah π
source path./include/linux, dated October 2026, pagerefcount_read(9)β official sign-off from the kernel girlies, catch you on the next manpage ππ§ββοΈ
π¦ 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