]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
iommu/vt-d: Fold domain_exit() into intel_iommu_domain_free()
authorJason Gunthorpe <jgg@nvidia.com>
Mon, 14 Jul 2025 04:50:21 +0000 (12:50 +0800)
committerWill Deacon <will@kernel.org>
Mon, 14 Jul 2025 10:18:03 +0000 (11:18 +0100)
commit00939bebe51c23d325c9796ad57ace49833a5813
treef3494977b00e929dc9bbcbc8ce84b28270044449
parentcd0d0e4e48d817215695e1cc9114c6f614fb629f
iommu/vt-d: Fold domain_exit() into intel_iommu_domain_free()

It has only one caller, no need for two functions.

Correct the WARN_ON() error handling to leak the entire page table if the
HW is still referencing it so we don't UAF during WARN_ON recovery.

Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Link: https://lore.kernel.org/r/2-v3-dbbe6f7e7ae3+124ffe-vtd_prep_jgg@nvidia.com
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Link: https://lore.kernel.org/r/20250714045028.958850-5-baolu.lu@linux.intel.com
Signed-off-by: Will Deacon <will@kernel.org>
drivers/iommu/intel/iommu.c