rtc_timer_do_work(9)
β¨ rtc_timer_do_work β the Kernel API Manual glow-up β¨
okay bestie, welcome to the Kernel API Manual corner of the universe π this one's a function page, it's short, it's sweet, and it is literally the reason your RTC alarms fire on time instead of just vibing forever. let's get into it π«Ά
πΈ NAME πΈ
rtc_timer_do_work β Expires rtc timers. that's the whole job description. it expires them. iconic behavior honestly π
π SYNOPSIS π
void rtc_timer_do_work (struct work_struct *work );
returns void, takes exactly one pointer, no notes. lowkey minimalist queen π¦
π ARGUMENTS π
workβ the work item π§ that's it, that's the parameter. it's the work item. it showed up to work. give it a little respect.
π₯ DESCRIPTION π₯
so what does it do. Expires rtc timers. periodt π and if that's not enough drama for you β it also reprograms the next alarm event if needed, so the next one's already queued up before you even notice π
it gets called via worktask. no cap, that's the entry point, that's how it slides into the main character slot β¨
and the safety girlie moment: it serializes access to the timerqueue via the ops_lock mutex π meaning nobody's touching that timerqueue while this one's in it. no chaos, no collisions, just clean locked-down access, we love to see it π
π SEE ALSO π
the kernel file lives at ./drivers/rtc/interface.c π and here's the whole friend group, all of them, no gatekeeping:
rtc_read_next_alarm(9)rtc_handle_legacy_irq(9)rtc_aie_update_irq(9)rtc_uie_update_irq(9)rtc_pie_update_irq(9)rtc_update_irq(9)rtc_irq_set_state(9)rtc_irq_set_freq(9)rtc_timer_enqueue(9)rtc_timer_remove(9)rtc_read_offset(9)rtc_set_offset(9)
iykyk π go read them, they're all slay in their own way π
ngl this page is short but it's doing a LOT of heavy lifting behind the scenes. respect the timer expiry grind π₯
and that's the tea, bestie π this page comes straight from ./drivers/rtc, dated October 2026 β mwah, catch you in 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