Re: [PATCH 6/9] iommu/amd: Implement map_atomic

2019-04-16 Thread Robin Murphy
On 11/04/2019 19:47, Tom Murphy wrote: Instead of using a spin lock I removed the mutex lock from both the amd_iommu_map and amd_iommu_unmap path as well. iommu_map doesn’t lock while mapping and so if iommu_map is called by two different threads on the same iova region it results in a race

[PATCH 6/9] iommu/amd: Implement map_atomic

2019-04-11 Thread Tom Murphy via iommu
Instead of using a spin lock I removed the mutex lock from both the amd_iommu_map and amd_iommu_unmap path as well. iommu_map doesn’t lock while mapping and so if iommu_map is called by two different threads on the same iova region it results in a race condition even with the locks. So the locking