add_to_queue(9)
๐ add_to_queue(9) โ the Kernel API Manual, bestie edition ๐
okay so you found add_to_queue(9) in the kernel API manual and you're like "what is this tiny little function doing in my life" โ don't worry, I got you. It's short, it's sweet, it's a whole vibe.
โจ NAME โจ
add_to_queue โ add a holder to the wait queue (but likeโฆ ๐ look for recursion, bestie)
๐ฆ SYNOPSIS ๐ฆ
void add_to_queue (struct gfs2_holder *gh );
๐ธ ARGUMENTS ๐ธ
ghโ the holder structure to add. that's it. that's the whole argument. she's the star of the show ๐
๐ DESCRIPTION ๐
okay so here's the tea ๐ต โ eventually, we should move the recursive locking trap over to a debugging option or something like that. like, it's on the to-do list, it's giving "we'll get to it."
but for right now? this is the fast path ๐ฅ and it needs to have the minimum number of distractions. no extra checks, no side quests, no main-character detours โ just get in, add the holder, and go. periodt. ๐
๐ฎ SEE ALSO ๐ฎ
Kernel file ./fs/gfs2/glock.c and the whole friend group ๐ซถ:
wake_up_glock(9)gfs2_glock_hold(9)gfs2_glock_put(9)may_grant(9)do_error(9)find_first_holder(9)do_promote(9)find_first_waiter(9)find_last_waiter(9)state_change(9)finish_xmote(9)do_xmote(9)run_queue(9)glock_set_object(9)glock_clear_object(9)gfs2_glock_get(9)__gfs2_holder_init(9)gfs2_holder_reinit(9)gfs2_holder_uninit(9)gfs2_glock_holder_ready(9)gfs2_glock_wait(9)gfs2_glock_async_wait(9)request_demote(9)gfs2_glock_nq(9)gfs2_glock_poll(9)gfs2_glock_dq(9)gfs2_glock_dq_uninit(9)gfs2_glock_nq_num(9)glock_compare(9)nq_m_sync(9)gfs2_glock_nq_m(9)gfs2_glock_dq_m(9)gfs2_should_freeze(9)gfs2_glock_complete(9)glock_hash_walk(9)thaw_glock(9)gfs2_glock_thaw(9)gfs2_wait_glocks(9)dump_holder(9)gfs2_dump_glock(9)
like, that's the whole group chat, go say hi ๐
and that's the page!! ๐ this one's from ./fs/gfs2 and it's dated October 2026 โ so yeah, she's fresh, she's iconic, she's add_to_queue(9), and now you know her. mwah ๐
โจ
๐ฆ 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