virtsnd_pcm_msg_send(9)
π NAME
virtsnd_pcm_msg_send β bestie, this is the one that sends your asynchronous I/O messages β¨
So this page lives in the Kernel API Manual, section 9, and it's literally all about yeeting async I/O messages into the virtqueue π
πΈ SYNOPSIS
int virtsnd_pcm_msg_send (struct virtio_pcm_substream *vss , unsigned
long offset , unsigned long bytes );
That's the whole signature, no cap π«Ά
π ARGUMENTS
vssβ the VirtIO PCM substream π΅ like, the whole reason we're here.offsetβ the starting position that has been updated πbytesβ how many bytes got updated, fr fr.
π₯ DESCRIPTION
okay so here's the vibe β¨ all the messages are organized in an ordered circular list β that part matters, don't forget it π
Every single time you call this function, all the currently non-enqueued messages get added to the virtqueue π« and to figure out which messages actually need to be added, the function uses offset and bytes. That's the whole trick, iykyk π€«
π«Ά CONTEXT
Any context π but listen: it expects the tx/rx queue and the VirtIO substream spinlocks to be held by the caller β so like, hold those locks before you call it, bestie, or it's giving chaos ππ
β RETURN
0 on success, -errno on failure π iconic behavior honestly.
π SEE ALSO
- Kernel file
./sound/virtio/virtio_pcm_msg.c struct virtio_pcm_msg(9)enum pcm_msg_sg_index(9)virtsnd_pcm_sg_num(9)virtsnd_pcm_sg_from(9)virtsnd_pcm_msg_alloc(9)virtsnd_pcm_msg_free(9)virtsnd_pcm_msg_pending_num(9)virtsnd_pcm_msg_complete(9)virtsnd_pcm_notify_cb(9)virtsnd_pcm_tx_notify_cb(9)virtsnd_pcm_rx_notify_cb(9)virtsnd_pcm_ctl_msg_alloc(9)
and that's the page!! π this little gem ships out of ./sound/virtio, dated October 2026, and it's filed under virtsnd_pcm_msg_send(9) β go forth and enqueue your messages, main character ππ¦π
π¦ 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