Linux IOMMU Development
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Samiullah Khawaja <skhawaja@google.com>
Cc: David Woodhouse <dwmw2@infradead.org>,
	Lu Baolu <baolu.lu@linux.intel.com>,
	Joerg Roedel <joro@8bytes.org>, Will Deacon <will@kernel.org>,
	Pasha Tatashin <pasha.tatashin@soleen.com>,
	iommu@lists.linux.dev, Robin Murphy <robin.murphy@arm.com>,
	Pratyush Yadav <pratyush@kernel.org>,
	Kevin Tian <kevin.tian@intel.com>,
	Alex Williamson <alex@shazbot.org>,
	linux-kernel@vger.kernel.org, Saeed Mahameed <saeedm@nvidia.com>,
	Adithya Jayachandran <ajayachandra@nvidia.com>,
	Parav Pandit <parav@nvidia.com>,
	Leon Romanovsky <leonro@nvidia.com>, William Tu <witu@nvidia.com>,
	Vipin Sharma <vipinsh@google.com>,
	dmatlack@google.com, YiFei Zhu <zhuyifei@google.com>,
	Chris Li <chrisl@kernel.org>,
	praan@google.com
Subject: Re: [RFC PATCH v2 00/32] Add live update state preservation
Date: Wed, 28 Jan 2026 15:59:43 -0400	[thread overview]
Message-ID: <20260128195943.GY1641016@ziepe.ca> (raw)
In-Reply-To: <20251202230303.1017519-1-skhawaja@google.com>

On Tue, Dec 02, 2025 at 11:02:30PM +0000, Samiullah Khawaja wrote:
> 
> Samiullah Khawaja (26):
>   iommu: Add liveupdate FLB for IOMMU state preservation
>   iommu: Register IOMMU FLB with iommufd file handler
>   iommu: Implement IOMMU LU FLB preserve/unpreserve callbacks
>   iommu: Add iommu_domain ops to preserve, unpreserve and restore
>   iommu/pages: Add APIs to preserve/unpreserve/restore iommu pages
>   iommupt: Implement preserve/unpreserve/restore callbacks
>   iommu: Add APIs to preserve/unpreserve iommu domains
>   iommufd: Use the iommu_domain_preserve/unpreserve APIs
>   iommu: Add API to keep track of iommu domain attachments
>   iommu: Add API to preserve/unpreserve a device
>   iommu/vt-d: Implement device and iommu preserve/unpreserve ops
>   iommufd: Add APIs to preserve/unpreserve a vfio cdev
>   vfio/pci: Preserve the iommufd state of the vfio cdev
>   iommu: Add APIs to get preserved state of a device
>   iommu/vt-d: Clean the context entries of unpreserved devices
>   iommu: Implement IOMMU FLB retrieve and finish ops
>   iommu: Add an API get the preserved state of an IOMMU
>   iommu/vt-d: restore state of the preserved IOMMU
>   iommu: Add helper APIs to fetch preserved device state
>   iommu/vt-d: reclaim domain ids of the preserved devices
>   iommu: restore preserved domain and reattach
>   iommu/vt-d: reuse the preserved domain id for preserved devices
>   iommufd: Handle the iommufd can_finish properly
>   iommu: Transfer device ownership after liveupdate
>   iommu: Allow replacing restored domain
>   iommufd/selftest: Add test to verify iommufd preservation
> 
> YiFei Zhu (6):
>   iommufd: Allow HWPTs to have a NULL IOAS
>   iommufd: split alloc and domain assign from iommufd_hwpt_paging_alloc
>   iommufd: Add basic skeleton based on liveupdate_file_handler
>   iommufd-lu: Implement basic prepare/cancel/finish/retrieve using
>     folios
>   iommufd-lu: Implement ioctl to let userspace mark an HWPT to be
>     preserved
>   iommufd-lu: Persist iommu hardware pagetables for live update

This really needs to be made smaller and more focused to be
reviewable and mergable. Try to stick to 15-ish patches.

There is a lot giong on here, I suggest focusing this only on the main
iommu core, a vt-d driver implementation of the bare minimum, and an
iommufd function to trigger preservation of a domain.

Start off by just making the successor kernel fail to accept any
drivers at all because the iommu_domain was preserved. ie restore the
domain and set it as the default_domain and then fail in
iommu_device_use_default_domain() and related functions.

All it should do is convey an iommu_domain and the pasid table entry
unchanged without hit from prior to successor kernel. That's the bare
minimum.

Then a second series which picks up from there and feeds the sucessor path
through iommufd/vfio.

Jason

  parent reply	other threads:[~2026-01-28 19:59 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-02 23:02 [RFC PATCH v2 00/32] Add live update state preservation Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 01/32] iommufd: Allow HWPTs to have a NULL IOAS Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 02/32] iommufd: split alloc and domain assign from iommufd_hwpt_paging_alloc Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 03/32] iommufd: Add basic skeleton based on liveupdate_file_handler Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 04/32] iommufd-lu: Implement basic prepare/cancel/finish/retrieve using folios Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 05/32] iommufd-lu: Implement ioctl to let userspace mark an HWPT to be preserved Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 06/32] iommufd-lu: Persist iommu hardware pagetables for live update Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 07/32] iommu: Add liveupdate FLB for IOMMU state preservation Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 08/32] iommu: Register IOMMU FLB with iommufd file handler Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 09/32] iommu: Implement IOMMU LU FLB preserve/unpreserve callbacks Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 10/32] iommu: Add iommu_domain ops to preserve, unpreserve and restore Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 11/32] iommu/pages: Add APIs to preserve/unpreserve/restore iommu pages Samiullah Khawaja
2025-12-04  2:25   ` Baolu Lu
2025-12-04 17:39     ` Samiullah Khawaja
2025-12-05  4:58       ` Baolu Lu
2025-12-02 23:02 ` [RFC PATCH v2 12/32] iommupt: Implement preserve/unpreserve/restore callbacks Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 13/32] iommu: Add APIs to preserve/unpreserve iommu domains Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 14/32] iommufd: Use the iommu_domain_preserve/unpreserve APIs Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 15/32] iommu: Add API to keep track of iommu domain attachments Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 16/32] iommu: Add API to preserve/unpreserve a device Samiullah Khawaja
2025-12-04  5:46   ` Baolu Lu
2025-12-04 17:47     ` Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 17/32] iommu/vt-d: Implement device and iommu preserve/unpreserve ops Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 18/32] iommufd: Add APIs to preserve/unpreserve a vfio cdev Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 19/32] vfio/pci: Preserve the iommufd state of the " Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 20/32] iommu: Add APIs to get preserved state of a device Samiullah Khawaja
2025-12-04  6:19   ` Baolu Lu
2025-12-04 17:48     ` Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 21/32] iommu/vt-d: Clean the context entries of unpreserved devices Samiullah Khawaja
2025-12-04  6:28   ` Baolu Lu
2025-12-02 23:02 ` [RFC PATCH v2 22/32] iommu: Implement IOMMU FLB retrieve and finish ops Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 23/32] iommu: Add an API get the preserved state of an IOMMU Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 24/32] iommu/vt-d: restore state of the preserved IOMMU Samiullah Khawaja
2025-12-04  6:43   ` Baolu Lu
2025-12-04 17:55     ` Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 25/32] iommu: Add helper APIs to fetch preserved device state Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 26/32] iommu/vt-d: reclaim domain ids of the preserved devices Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 27/32] iommu: restore preserved domain and reattach Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 28/32] iommu/vt-d: reuse the preserved domain id for preserved devices Samiullah Khawaja
2025-12-02 23:02 ` [RFC PATCH v2 29/32] iommufd: Handle the iommufd can_finish properly Samiullah Khawaja
2025-12-02 23:03 ` [RFC PATCH v2 30/32] iommu: Transfer device ownership after liveupdate Samiullah Khawaja
2025-12-02 23:03 ` [RFC PATCH v2 31/32] iommu: Allow replacing restored domain Samiullah Khawaja
2025-12-02 23:03 ` [RFC PATCH v2 32/32] iommufd/selftest: Add test to verify iommufd preservation Samiullah Khawaja
2026-01-28 19:59 ` Jason Gunthorpe [this message]
2026-01-29  1:11   ` [RFC PATCH v2 00/32] Add live update state preservation Samiullah Khawaja
2026-02-02 22:45     ` David Matlack
2026-02-02 23:00       ` Samiullah Khawaja
2026-02-02 23:46         ` Jason Gunthorpe
2026-02-02 23:45       ` Jason Gunthorpe

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=20260128195943.GY1641016@ziepe.ca \
    --to=jgg@ziepe.ca \
    --cc=ajayachandra@nvidia.com \
    --cc=alex@shazbot.org \
    --cc=baolu.lu@linux.intel.com \
    --cc=chrisl@kernel.org \
    --cc=dmatlack@google.com \
    --cc=dwmw2@infradead.org \
    --cc=iommu@lists.linux.dev \
    --cc=joro@8bytes.org \
    --cc=kevin.tian@intel.com \
    --cc=leonro@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=parav@nvidia.com \
    --cc=pasha.tatashin@soleen.com \
    --cc=praan@google.com \
    --cc=pratyush@kernel.org \
    --cc=robin.murphy@arm.com \
    --cc=saeedm@nvidia.com \
    --cc=skhawaja@google.com \
    --cc=vipinsh@google.com \
    --cc=will@kernel.org \
    --cc=witu@nvidia.com \
    --cc=zhuyifei@google.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