From: David Gibson <david@gibson.dropbear.id.au>
To: Laurent Vivier <lvivier@redhat.com>
Cc: passt-dev@passt.top
Subject: Re: [PATCH v2 2/4] vhost-user: introduce virtio API
Date: Thu, 15 Aug 2024 14:52:52 +1000 [thread overview]
Message-ID: <Zr2JpMARQuiw-DEj@zatzit.fritz.box> (raw)
In-Reply-To: <7024df34-8a58-4eae-ab57-2af0e03aa2b0@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 1888 bytes --]
On Wed, Aug 14, 2024 at 02:47:36PM +0200, Laurent Vivier wrote:
> On 17/07/2024 07:21, David Gibson wrote:
> > On Fri, Jul 12, 2024 at 05:32:42PM +0200, Laurent Vivier wrote:
> > > Add virtio.c and virtio.h that define the functions needed
> > > to manage virtqueues.
> > >
> > > Signed-off-by: Laurent Vivier <lvivier@redhat.com>
> > > ---
> > > Makefile | 4 +-
> > > util.h | 11 +
> > > virtio.c | 611 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
> > > virtio.h | 190 +++++++++++++++++
> > > 4 files changed, 814 insertions(+), 2 deletions(-)
> > > create mode 100644 virtio.c
> > > create mode 100644 virtio.h
> > >
> ...
> > > +
> > > +/**
> > > + * struct vu_dev_region - guest shared memory region
> > > + * @gpa: Guest physical address of the region
> > > + * @size: Memory size in bytes
> > > + * @qva: QEMU virtual address
> >
> > Is this actually the qemu virtual address? Or is it our virtual
> > address?
> >
>
> It is actually QEMU virtual address, it's a virtual address provided by the
> front-end (in our case QEMU).
Ok.
> https://qemu-project.gitlab.io/qemu/interop/vhost-user.html#memory-region-description
>
> It's used in qva_to_va() to convert vring addresses that are in QEMU
> userspace (vhost-user) to our process userspace mapped address, while
> vu_gpa_to_va() is used to convert guest physical address (virtio) of buffers
> address stored vring descritors that are in guest physical address space to
> our process address space.
>
> vhost-user addresses are in QEMU virtual adress space, virtio addresses are
> in guest physical address space.
>
>
> Thansk,
> Laurent
>
--
David Gibson (he or they) | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you, not the other way
| around.
http://www.ozlabs.org/~dgibson
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2024-08-15 4:59 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-12 15:32 [PATCH v2 0/4] Add vhost-user support to passt. (part 3) Laurent Vivier
2024-07-12 15:32 ` [PATCH v2 1/4] packet: replace struct desc by struct iovec Laurent Vivier
2024-07-15 4:59 ` David Gibson
2024-07-19 21:28 ` Stefano Brivio
2024-07-12 15:32 ` [PATCH v2 2/4] vhost-user: introduce virtio API Laurent Vivier
2024-07-17 5:21 ` David Gibson
2024-08-14 12:47 ` Laurent Vivier
2024-08-15 4:52 ` David Gibson [this message]
2024-07-19 21:29 ` Stefano Brivio
2024-07-12 15:32 ` [PATCH v2 3/4] vhost-user: introduce vhost-user API Laurent Vivier
2024-07-19 21:29 ` Stefano Brivio
2024-08-14 14:44 ` Laurent Vivier
2024-07-12 15:32 ` [PATCH v2 4/4] vhost-user: add vhost-user Laurent Vivier
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=Zr2JpMARQuiw-DEj@zatzit.fritz.box \
--to=david@gibson.dropbear.id.au \
--cc=lvivier@redhat.com \
--cc=passt-dev@passt.top \
/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.
Code repositories for project(s) associated with this public inbox
https://passt.top/passt
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 IMAP folder(s).