aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/iommu/intel/nested.c
diff options
context:
space:
mode:
authorLu Baolu <[email protected]>2024-09-02 02:27:23 +0000
committerJoerg Roedel <[email protected]>2024-09-02 16:15:02 +0000
commit777cdd853434849cc98ef94787538b1eb9f492d9 (patch)
tree0a844316be219a061d68e68607abbde7df192cf6 /drivers/iommu/intel/nested.c
parentiommu/vt-d: Refactor IOTLB and Dev-IOTLB flush for batching (diff)
downloadkernel-777cdd853434849cc98ef94787538b1eb9f492d9.tar.gz
kernel-777cdd853434849cc98ef94787538b1eb9f492d9.zip
iommu/vt-d: Add qi_batch for dmar_domain
Introduces a qi_batch structure to hold batched cache invalidation descriptors on a per-dmar_domain basis. A fixed-size descriptor array is used for simplicity. The qi_batch is allocated when the first cache tag is added to the domain and freed during iommu_free_domain(). Signed-off-by: Lu Baolu <[email protected]> Signed-off-by: Tina Zhang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Joerg Roedel <[email protected]>
Diffstat (limited to 'drivers/iommu/intel/nested.c')
-rw-r--r--drivers/iommu/intel/nested.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/iommu/intel/nested.c b/drivers/iommu/intel/nested.c
index 36a91b1b52be..433c58944401 100644
--- a/drivers/iommu/intel/nested.c
+++ b/drivers/iommu/intel/nested.c
@@ -83,6 +83,7 @@ static void intel_nested_domain_free(struct iommu_domain *domain)
spin_lock(&s2_domain->s1_lock);
list_del(&dmar_domain->s2_link);
spin_unlock(&s2_domain->s1_lock);
+ kfree(dmar_domain->qi_batch);
kfree(dmar_domain);
}