]> git.baikalelectronics.ru Git - kernel.git/commit
iommu: Handle freelists when using deferred flushing in iommu drivers
authorTom Murphy <murphyt7@tcd.ie>
Tue, 24 Nov 2020 08:20:51 +0000 (16:20 +0800)
committerWill Deacon <will@kernel.org>
Wed, 25 Nov 2020 12:03:48 +0000 (12:03 +0000)
commite0ab34887b5282304045e85e426d144a286041e9
tree93b3b75f1def62809f901b1a852834fe4cc1ef71
parentefdffe53e0aa59437206684845d9dff1b4889d9c
iommu: Handle freelists when using deferred flushing in iommu drivers

Allow the iommu_unmap_fast to return newly freed page table pages and
pass the freelist to queue_iova in the dma-iommu ops path.

This is useful for iommu drivers (in this case the intel iommu driver)
which need to wait for the ioTLB to be flushed before newly
free/unmapped page table pages can be freed. This way we can still batch
ioTLB free operations and handle the freelists.

Signed-off-by: Tom Murphy <murphyt7@tcd.ie>
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Tested-by: Logan Gunthorpe <logang@deltatee.com>
Link: https://lore.kernel.org/r/20201124082057.2614359-2-baolu.lu@linux.intel.com
Signed-off-by: Will Deacon <will@kernel.org>
drivers/iommu/dma-iommu.c
drivers/iommu/intel/iommu.c
include/linux/iommu.h