VIORTC_MSG_INIT(9)
π VIORTC_MSG_INIT β the Kernel API Manual, bestie edition β¨
okay so welcome to the Kernel API Manual π and today's main character is VIORTC_MSG_INIT(9), which is literally the glow-up ritual for your message handle. it's giving "get ready with me" but for kernel objects π
πΈ NAME πΈ
VIORTC_MSG_INIT β initialize your message handle, periodt β¨
π¦ SYNOPSIS π¦
VIORTC_MSG_INIT (hdl , viortc );
that's it. that's the whole invocation. copy it exactly, don't get creative, the compiler is not your friend π«Ά
π ARGUMENTS π
hdlβ the message handle. this is the thing you're initializing, bestie. it's the whole point. the moment. the main character πviortcβ the device data, of typestruct viortc_dev *. yes it's a pointer. yes you need it. no you cannot skip it, i'm so serious π
β CONTEXT β
Process context. lowkey the most chill context there is β no atomic panic, no interrupt chaos, just a normal process doing normal process things π
π₯ RETURN π₯
0on success β we love a win π-ENOMEMotherwise β that's a memory issue, ngl. happens to the best of us π
π SEE ALSO π
the whole extended universe, fr fr β go read the source and then read it again π
- Kernel file
./drivers/virtio/virtio_rtc_driver.c struct viortc_vq(9)struct viortc_dev(9)struct viortc_msg(9)viortc_class_from_dev(9)viortc_alarms_supported(9)viortc_feed_vq(9)viortc_msg_init(9)viortc_msg_release(9)viortc_do_cb(9)viortc_requestq_hdlr(9)viortc_cb_requestq(9)viortc_alarmq_hdlr(9)viortc_cb_alarmq(9)viortc_get_resp_errno(9)viortc_msg_xfer(9)VIORTC_DECLARE_MSG_HDL_ONSTACK(9)VIORTC_MSG(9)VIORTC_MSG_WRITE(9)VIORTC_MSG_READ(9)viortc_read(9)viortc_read_cross(9)viortc_cfg(9)viortc_clock_cap(9)viortc_cross_cap(9)viortc_read_alarm(9)viortc_set_alarm(9)viortc_set_alarm_enabled(9)viortc_init_rtc_class_clock(9)viortc_init_ptp_clock(9)viortc_init_clock(9)viortc_clocks_deinit(9)viortc_clocks_init(9)viortc_populate_vq(9)viortc_alloc_vq_bufs(9)viortc_init_vqs(9)viortc_probe(9)viortc_remove(9)
iykyk β that's a lot of cross-references, and every single one of them is exactly where it belongs. don't @ me, just read them π
π that's the page, bestie π this little love letter lives in ./drivers/virtio and was written down in October 2026 β go forth and initialize responsibly ππ¦πΈ
π¦ 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