• Joerg Roedel's avatar
    iommu/amd: Fix race in increase_address_space() · 754265bc
    Joerg Roedel authored
    After the conversion to lock-less dma-api call the
    increase_address_space() function can be called without any
    locking. Multiple CPUs could potentially race for increasing
    the address space, leading to invalid domain->mode settings
    and invalid page-tables. This has been happening in the wild
    under high IO load and memory pressure.
    
    Fix the race by locking this operation. The function is
    called infrequently so that this does not introduce
    a performance regression in the dma-api path again.
    Reported-by: default avatarQian Cai <cai@lca.pw>
    Fixes: 256e4621 ('iommu/amd: Make use of the generic IOVA allocator')
    Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
    754265bc
Name
Last commit
Last update
..
Kconfig Loading commit data...
Makefile Loading commit data...
amd_iommu.c Loading commit data...
amd_iommu_debugfs.c Loading commit data...
amd_iommu_init.c Loading commit data...
amd_iommu_proto.h Loading commit data...
amd_iommu_types.h Loading commit data...
amd_iommu_v2.c Loading commit data...
arm-smmu-regs.h Loading commit data...
arm-smmu-v3.c Loading commit data...
arm-smmu.c Loading commit data...
dma-iommu.c Loading commit data...
dmar.c Loading commit data...
exynos-iommu.c Loading commit data...
fsl_pamu.c Loading commit data...
fsl_pamu.h Loading commit data...
fsl_pamu_domain.c Loading commit data...
fsl_pamu_domain.h Loading commit data...
hyperv-iommu.c Loading commit data...
intel-iommu-debugfs.c Loading commit data...
intel-iommu.c Loading commit data...
intel-pasid.c Loading commit data...
intel-pasid.h Loading commit data...
intel-svm.c Loading commit data...
intel_irq_remapping.c Loading commit data...
io-pgtable-arm-v7s.c Loading commit data...
io-pgtable-arm.c Loading commit data...
io-pgtable.c Loading commit data...
iommu-debugfs.c Loading commit data...
iommu-sysfs.c Loading commit data...
iommu-traces.c Loading commit data...
iommu.c Loading commit data...
iova.c Loading commit data...
ipmmu-vmsa.c Loading commit data...
irq_remapping.c Loading commit data...
irq_remapping.h Loading commit data...
msm_iommu.c Loading commit data...
msm_iommu.h Loading commit data...
msm_iommu_hw-8xxx.h Loading commit data...
mtk_iommu.c Loading commit data...
mtk_iommu.h Loading commit data...
mtk_iommu_v1.c Loading commit data...
of_iommu.c Loading commit data...
omap-iommu-debug.c Loading commit data...
omap-iommu.c Loading commit data...
omap-iommu.h Loading commit data...
omap-iopgtable.h Loading commit data...
qcom_iommu.c Loading commit data...
rockchip-iommu.c Loading commit data...
s390-iommu.c Loading commit data...
tegra-gart.c Loading commit data...
tegra-smmu.c Loading commit data...
virtio-iommu.c Loading commit data...