viortc_class_get_locked(9)
π viortc_class_get_locked(9)
okay so bestie, welcome to the Kernel API Manual β¨ you're literally reading viortc_class_get_locked(9) and honestly? she's a little baddie with one job. let's get into it π
β¨ NAME β¨
viortc_class_get_locked β grab the RTC class wrapper, but only if the ops are allowed π no cap, that's the whole vibe.
πΈ SYNOPSIS πΈ
struct viortc_class * viortc_class_get_locked (struct device *dev );
that's it. that's the whole function signature. short king energy π
π¦ ARGUMENTS π¦
devβ the virtio device. yeah. that one. the device. give her the device π
π§ DESCRIPTION π§
so like, this function gets the RTC class wrapper from the virtio device β but only if it's actually available and the ops are allowed β . both conditions, bestie, it's giving "you need to meet the requirements" energy. if either one's not happening, no wrapper for you π
π₯ CONTEXT π₯
β οΈ caller must hold rtc_lock. this is not a suggestion, this is the law π lock it up before you call, fr fr.
β RETURN β
- the RTC class wrapper β when it's available and ops are allowed π«Ά slay
ERR_PTRβ otherwise π that's the whole deal, no in-between
π SEE ALSO π
- kernel file
./drivers/virtio/virtio_rtc_class.c struct viortc_class(9)viortc_class_read_time(9)viortc_class_read_alarm(9)viortc_class_set_alarm(9)viortc_class_alarm_irq_enable(9)viortc_class_alarm(9)viortc_class_stop(9)viortc_class_register(9)viortc_class_init(9)
the whole friend group honestly π go read them all, iykyk
and that's the page!! π this iconic lil entry lives in ./drivers/virtio and the version vibes are dated October 2026 β mwah, periodt π
β¨
π¦ 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