[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH V2 4/5] smmu: switch to use memory_region_unmap_iommu_notifier_ra
From: |
Jason Wang |
Subject: |
[PATCH V2 4/5] smmu: switch to use memory_region_unmap_iommu_notifier_range() |
Date: |
Thu, 23 Feb 2023 14:59:23 +0800 |
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
hw/arm/smmu-common.c | 16 +---------------
1 file changed, 1 insertion(+), 15 deletions(-)
diff --git a/hw/arm/smmu-common.c b/hw/arm/smmu-common.c
index 733c964778..5e2847d511 100644
--- a/hw/arm/smmu-common.c
+++ b/hw/arm/smmu-common.c
@@ -467,20 +467,6 @@ IOMMUMemoryRegion *smmu_iommu_mr(SMMUState *s, uint32_t
sid)
return NULL;
}
-/* Unmap the whole notifier's range */
-static void smmu_unmap_notifier_range(IOMMUNotifier *n)
-{
- IOMMUTLBEvent event;
-
- event.type = IOMMU_NOTIFIER_UNMAP;
- event.entry.target_as = &address_space_memory;
- event.entry.iova = n->start;
- event.entry.perm = IOMMU_NONE;
- event.entry.addr_mask = n->end - n->start;
-
- memory_region_notify_iommu_one(n, &event);
-}
-
/* Unmap all notifiers attached to @mr */
static void smmu_inv_notifiers_mr(IOMMUMemoryRegion *mr)
{
@@ -488,7 +474,7 @@ static void smmu_inv_notifiers_mr(IOMMUMemoryRegion *mr)
trace_smmu_inv_notifiers_mr(mr->parent_obj.name);
IOMMU_NOTIFIER_FOREACH(n, mr) {
- smmu_unmap_notifier_range(n);
+ memory_region_unmap_iommu_notifier_range(n);
}
}
--
2.25.1
- [PATCH V2 0/5] Fix UNMAP notifier for intel-iommu, Jason Wang, 2023/02/23
- [PATCH V2 1/5] intel-iommu: fail MAP notifier without caching mode, Jason Wang, 2023/02/23
- [PATCH V2 2/5] intel-iommu: fail DEVIOTLB_UNMAP without dt mode, Jason Wang, 2023/02/23
- [PATCH V2 3/5] memory: introduce memory_region_unmap_iommu_notifier_range(), Jason Wang, 2023/02/23
- [PATCH V2 4/5] smmu: switch to use memory_region_unmap_iommu_notifier_range(),
Jason Wang <=
- [PATCH V2 5/5] intel-iommu: send UNMAP notifications for domain or global inv desc, Jason Wang, 2023/02/23
- Re: [PATCH V2 0/5] Fix UNMAP notifier for intel-iommu, Peter Xu, 2023/02/23