linux-stable/drivers/vfio
Alex Williamson b620ecbd17 vfio: Introduce interface to flush virqfd inject workqueue
In order to synchronize changes that can affect the thread callback,
introduce an interface to force a flush of the inject workqueue.  The
irqfd pointer is only valid under spinlock, but the workqueue cannot
be flushed under spinlock.  Therefore the flush work for the irqfd is
queued under spinlock.  The vfio_irqfd_cleanup_wq workqueue is re-used
for queuing this work such that flushing the workqueue is also ordered
relative to shutdown.

Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Reviewed-by: Reinette Chatre <reinette.chatre@intel.com>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Link: https://lore.kernel.org/r/20240308230557.805580-4-alex.williamson@redhat.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
2024-03-11 13:08:52 -06:00
..
cdx Char/Misc and other driver changes for 6.7-rc1 2023-11-03 14:51:08 -10:00
fsl-mc eventfd: simplify eventfd_signal() 2023-11-28 14:08:38 +01:00
mdev vfio: mdev: make mdev_bus_type const 2024-02-22 12:19:33 -07:00
pci vfio/pci: Lock external INTx masking ops 2024-03-11 13:08:52 -06:00
platform vfio/platform: Convert to platform remove callback returning void 2024-03-11 12:09:22 -06:00
container.c VFIO updates for v6.3-rc1 2023-02-25 11:52:57 -08:00
debugfs.c vfio/migration: Add debugfs to live migration driver 2023-12-04 14:29:08 -07:00
device_cdev.c vfio: Add VFIO_DEVICE_[AT|DE]TACH_IOMMUFD_PT 2023-07-25 10:20:37 -06:00
group.c vfio: Move the IOMMU_CAP_CACHE_COHERENCY check in __vfio_register_dev() 2023-07-25 10:20:41 -06:00
iommufd.c vfio: Support IO page table replacement 2023-07-28 13:31:24 -03:00
Kconfig vfio/migration: Add debugfs to live migration driver 2023-12-04 14:29:08 -07:00
Makefile vfio/migration: Add debugfs to live migration driver 2023-12-04 14:29:08 -07:00
vfio.h vfio/migration: Add debugfs to live migration driver 2023-12-04 14:29:08 -07:00
vfio_iommu_spapr_tce.c powerpc/iommu: Add iommu_ops to report capabilities and allow blocking domains 2023-03-15 00:51:46 +11:00
vfio_iommu_type1.c Revert "vfio/type1: Unpin zero pages" 2024-03-04 16:11:07 -07:00
vfio_main.c vfio/migration: Add debugfs to live migration driver 2023-12-04 14:29:08 -07:00
virqfd.c vfio: Introduce interface to flush virqfd inject workqueue 2024-03-11 13:08:52 -06:00