public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Thanos Makatos <thanos.makatos@nutanix.com>
Cc: "kvm@vger.kernel.org" <kvm@vger.kernel.org>,
	Joao Martins <joao.m.martins@oracle.com>,
	John Levon <john.levon@nutanix.com>,
	"john.g.johnson@oracle.com" <john.g.johnson@oracle.com>,
	"alex.williamson@redhat.com" <alex.williamson@redhat.com>,
	Stefan Hajnoczi <stefanha@redhat.com>,
	"kevin.tian@intel.com" <kevin.tian@intel.com>,
	Eric Auger <eric.auger@redhat.com>,
	David Gibson <david@gibson.dropbear.id.au>,
	"yi.l.liu@intel.com" <yi.l.liu@intel.com>
Subject: Re: iommufd dirty page logging overview
Date: Wed, 16 Mar 2022 20:50:44 -0300	[thread overview]
Message-ID: <20220316235044.GA388745@nvidia.com> (raw)
In-Reply-To: <DM8PR02MB80050C48AF03C8772EB5988F8B119@DM8PR02MB8005.namprd02.prod.outlook.com>

On Wed, Mar 16, 2022 at 11:29:42PM +0000, Thanos Makatos wrote:

> We're interested in adopting the new migration v2 interface and the
> new dirty page logging for /dev/iommufd in an out-of-process device
> emulation protocol [1]. Although it's purely userspace, we do want
> to stay close to the new API(s) being proposed for many reasons,
> mainly to re-use the QEMU implementation. The migration-related
> changes are relatively straightforward, I'm more interested in the
> dirty page logging. I've started reading the relevant email threads
> and my impression so far is that the details are still being
> decided? 

Yes

Joao has made the most progress so far

> there a rough idea of how the new dirty page logging will look like?
> Is this already explained in the email threads an I missed it?

I'm hoping to get something to show in the next few weeks, but what
I've talked about previously is to have two things:

1) Control and reporting of dirty tracking via the system IOMMU
   through the iommu_domain interface exposed by iommufd

2) Control and reporting of dirty tracking via a VFIO migration
   capable device's internal tracking through a VFIO_DEVICE_FEATURE
   interface similar to the v2 migration interface

The two APIs would be semantically very similar but target different
HW blocks. Userspace would be in charge to decide which dirty tracker
to use and how to configure it.

I'm expecting that semantically everything would look like the current
dirty tracking draft, where you start/stop tracking then read&clear a
bitmap for a range of IOVA and integrate that with the dirty data
from KVM.

Jason


  reply	other threads:[~2022-03-16 23:50 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-16 23:29 iommufd dirty page logging overview Thanos Makatos
2022-03-16 23:50 ` Jason Gunthorpe [this message]
2022-03-18  9:23   ` Tian, Kevin
2022-03-18 12:41     ` Jason Gunthorpe
2022-03-18 15:06       ` Alex Williamson
2022-03-18 15:55         ` Jason Gunthorpe
2022-03-19  7:54       ` Tian, Kevin
2022-03-19  8:14       ` Tian, Kevin
2022-03-20  3:34       ` Tian, Kevin
2022-03-21 13:30         ` Jason Gunthorpe
2022-03-22  2:40           ` Tian, Kevin
2022-03-17 12:39 ` Joao Martins

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=20220316235044.GA388745@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=alex.williamson@redhat.com \
    --cc=david@gibson.dropbear.id.au \
    --cc=eric.auger@redhat.com \
    --cc=joao.m.martins@oracle.com \
    --cc=john.g.johnson@oracle.com \
    --cc=john.levon@nutanix.com \
    --cc=kevin.tian@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=stefanha@redhat.com \
    --cc=thanos.makatos@nutanix.com \
    --cc=yi.l.liu@intel.com \
    /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