wait_event_hrtimeout(9)
π wait_event_hrtimeout(9) π
okay bestie, this page is straight out of the Kernel API Manual, and it's giving βgo to sleep until the vibe changes or the clock says times upβ π΄β¨
πΈ NAME πΈ
wait_event_hrtimeout β sleep until a condition gets true or a timeout elapses. no cap, that's the whole name vibe π
β¨ SYNOPSIS β¨
okay so the call is literally:
wait_event_hrtimeout (wq_head , condition , timeout );
π ARGUMENTS π
wq_headβ the waitqueue to wait on, bestie π«Άconditionβ a C expression for the event to wait for. yes, a whole C expression, she's flexible β¨timeoutβ timeout, as aktime_tβ°
π¦ DESCRIPTION π¦
The process is put to sleep (TASK_UNINTERRUPTIBLE) until the condition evaluates to true or a signal is received. The condition is checked each time the waitqueue wq_head is woken up. π
β οΈ important: wake_up has to be called after changing any variable that could change the result of the wait condition. fr fr, don't skip that part, bestie π
The function returns 0 if condition became true, or -ETIME if the timeout elapsed. so if you get -ETIME, that's the timer girl saying βtime's upβ β°π
π SEE ALSO π
okay the whole girl gang is here β Kernel file ./include/linux/wait.h plus all these cuties:
waitqueue_active(9)wq_has_single_sleeper(9)wq_has_sleeper(9)wake_up_pollfree(9)wait_event(9)wait_event_freezable(9)wait_event_timeout(9)wait_event_cmd(9)wait_event_interruptible(9)wait_event_interruptible_timeout(9)wait_event_interruptible_hrtimeout(9)wait_event_idle(9)wait_event_idle_exclusive(9)wait_event_idle_timeout(9)wait_event_idle_exclusive_timeout(9)wait_event_interruptible_locked(9)wait_event_interruptible_locked_irq(9)wait_event_interruptible_exclusive_locked(9)wait_event_interruptible_exclusive_locked_irq(9)wait_event_killable(9)wait_event_state(9)wait_event_killable_timeout(9)wait_event_lock_irq_cmd(9)wait_event_lock_irq(9)wait_event_interruptible_lock_irq_cmd(9)wait_event_interruptible_lock_irq(9)wait_event_interruptible_lock_irq_timeout(9)
alright bestie, that's the whole page! source/version: ./include/linux Β· date: October 2026 Β· page: wait_event_hrtimeout(9) β mwah, bye! ππβ¨
π¦ 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