unrcu_pointer(9)
π unrcu_pointer β the "bestie, you're not RCU anymore" moment β¨
ok so picture this: it's unrcu_pointer(9) from the Kernel API Manual, and it's literally the teeny tiny function that removes the __rcu sparkle from a pointer. iconic behaviour, no cap π
πΈ NAME πΈ
unrcu_pointer β mark a pointer as not being RCU protected π
β¨ SYNOPSIS β¨
unrcu_pointer (p );
π¦ ARGUMENTS π¦
pβ the pointer that needs to lose its__rcuproperty. it's giving "graduation day" πβ¨
π DESCRIPTION π
so what it actually does: it converts p from an __rcu pointer into a __kernel pointer. that's it. that's the whole vibe π
why do we care? because this is what lets an __rcu pointer be used with xchg and friends π«Ά β the compiler stops side-eyeing you, and you get to hang out with the rest of the atomic crew. slay.
π₯ SEE ALSO π₯
like, all of RCU's extended universe is here, bestie. the kernel file lives at ./include/linux/rcupdate.h, and these are the β¨iconicβ¨ neighbours:
same_state_synchronize_rcu(9)cond_resched_tasks_rcu_qs(9)rcu_softirq_qs_periodic(9)RCU_LOCKDEP_WARN(9)lockdep_assert_in_rcu_read_lock(9)lockdep_assert_in_rcu_read_lock_bh(9)lockdep_assert_in_rcu_read_lock_sched(9)lockdep_assert_in_rcu_reader(9)RCU_INITIALIZER(9)rcu_assign_pointer(9)rcu_replace_pointer(9)rcu_access_pointer(9)rcu_dereference_check(9)rcu_dereference_bh_check(9)rcu_dereference_sched_check(9)rcu_dereference_all_check(9)rcu_dereference_protected(9)rcu_dereference(9)rcu_dereference_bh(9)rcu_dereference_sched(9)rcu_dereference_all(9)rcu_pointer_handoff(9)rcu_read_lock(9)rcu_read_unlock(9)rcu_read_lock_bh(9)rcu_read_unlock_bh(9)rcu_read_lock_sched(9)rcu_read_unlock_sched(9)RCU_INIT_POINTER(9)RCU_POINTER_INITIALIZER(9)kfree_rcu(9)kfree_rcu_mightsleep(9)kfree_rcu_nolock(9)rcu_head_init(9)rcu_head_after_call_rcu(9)
ok that's the whole page, go forth and un-rcu your pointers ππ
sign-off time: this lil beauty comes from ./include/linux, dated October 2026, and it's page unrcu_pointer(9) of the Kernel API Manual β mwah, bye 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