[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU
From: |
Juan Quintela |
Subject: |
Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support |
Date: |
Wed, 15 Feb 2023 13:43:08 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) |
Avihai Horon <avihaih@nvidia.com> wrote:
> Currently, if IOMMU of a VFIO container doesn't support dirty page
> tracking, migration is blocked. This is because a DMA-able VFIO device
> can dirty RAM pages without updating QEMU about it, thus breaking the
> migration.
>
> However, this doesn't mean that migration can't be done at all.
> In such case, allow migration and let QEMU VFIO code mark all pages
> dirty.
>
> This guarantees that all pages that might have gotten dirty are reported
> back, and thus guarantees a valid migration even without VFIO IOMMU
> dirty tracking support.
>
> The motivation for this patch is the introduction of iommufd [1].
> iommufd can directly implement the /dev/vfio/vfio container IOCTLs by
> mapping them into its internal ops, allowing the usage of these IOCTLs
> over iommufd. However, VFIO IOMMU dirty tracking is not supported by
> this VFIO compatibility API.
>
> This patch will allow migration by hosts that use the VFIO compatibility
> API and prevent migration regressions caused by the lack of VFIO IOMMU
> dirty tracking support.
>
> [1]
> https://lore.kernel.org/kvm/0-v6-a196d26f289e+11787-iommufd_jgg@nvidia.com/
>
> Signed-off-by: Avihai Horon <avihaih@nvidia.com>
> Reviewed-by: Cédric Le Goater <clg@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
I know why you are doing this.
But I think this should print a warning, error, somewhere.
You are just dirtying all pages each time we arrive here.
Even calling the featura "experimental" is an understatement.
Later, Juan.
- [PATCH v10 00/12] vfio/migration: Implement VFIO migration protocol v2, Avihai Horon, 2023/02/09
- [PATCH v10 02/12] vfio/migration: Fix NULL pointer dereference bug, Avihai Horon, 2023/02/09
- [PATCH v10 01/12] linux-headers: Update to v6.2-rc1, Avihai Horon, 2023/02/09
- [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support, Avihai Horon, 2023/02/09
- Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support,
Juan Quintela <=
- Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support, Avihai Horon, 2023/02/15
- Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support, Juan Quintela, 2023/02/15
- Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support, Alex Williamson, 2023/02/15
- Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support, Jason Gunthorpe, 2023/02/15
- Re: [PATCH v10 03/12] vfio/migration: Allow migration without VFIO IOMMU dirty tracking support, Alex Williamson, 2023/02/15
[PATCH v10 04/12] migration/qemu-file: Add qemu_file_get_to_fd(), Avihai Horon, 2023/02/09
[PATCH v10 05/12] vfio/common: Change vfio_devices_all_running_and_saving() logic to equivalent one, Avihai Horon, 2023/02/09
[PATCH v10 06/12] vfio/migration: Block multiple devices migration, Avihai Horon, 2023/02/09