From: DUO Labs <dvdugo333@gmail.com>
To: qemu-devel@nongnu.org
Subject: Creating a vhost-user-vsock backend
Date: Fri, 23 Aug 2024 09:19:38 -0400 [thread overview]
Message-ID: <9981c499-13ee-4e68-b15b-b4fe184b0950@gmail.com> (raw)
I've been studying the example given in `contrib/vhost-user-blk`, and trying to match the code to what is in the standard (https://docs.oasis-open.org/virtio/virtio/v1.3/csd01/virtio-v1.3-csd01.html#x1-3050002), so I can use the code to create my own vhost-user-vsock server.
I think I almost understand it, but I don't get exactly how do you correlate out_sg and in_sg to the header and ancillary data (for virtio-blk, it would either be the data to be written or a buffer to read data into, and vsock would be similar), respectively.
In virtio-blk, I see that there's an inhdr, and outhdr, but vsock doesn't have that, so I'm not sure how to map the same concept. Similarly, does `elem->out_sg[0]` always map to the header, and `elem->out_sg[1]` always map to the ancillary data? What about when you are reading into a buffer --- should it always be read into `elem->in_sg[0]`, or is that only for virtio-blk?
reply other threads:[~2024-08-23 13:20 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9981c499-13ee-4e68-b15b-b4fe184b0950@gmail.com \
--to=dvdugo333@gmail.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).