iommu/io-pgtable-arm: Add quirk to quiet WARN_ON()
authorRob Clark <robdclark@chromium.org>
Mon, 19 May 2025 17:51:28 +0000 (10:51 -0700)
committerWill Deacon <will@kernel.org>
Tue, 20 May 2025 14:04:13 +0000 (15:04 +0100)
commit3318f7b5cefbff96b1bb49584ac38d2c9997a830
treebde09f15513a7281d4a7bf76992f4015b2c35992
parentbe5a2d3f8f9738ea1426e7d2243707164ed5bac2
iommu/io-pgtable-arm: Add quirk to quiet WARN_ON()

In situations where mapping/unmapping sequence can be controlled by
userspace, attempting to map over a region that has not yet been
unmapped is an error.  But not something that should spam dmesg.

Now that there is a quirk, we can also drop the selftest_running
flag, and use the quirk instead for selftests.

Acked-by: Robin Murphy <robin.murphy@arm.com>
Signed-off-by: Rob Clark <robdclark@chromium.org>
Link: https://lore.kernel.org/r/20250519175348.11924-6-robdclark@gmail.com
[will: Rename quirk to IO_PGTABLE_QUIRK_NO_WARN per Robin's suggestion]
Signed-off-by: Will Deacon <will@kernel.org>
drivers/iommu/io-pgtable-arm.c
include/linux/io-pgtable.h