linux-stable/drivers/iommu/iommufd
Koichiro Den 836db2e7e4 iommufd: Fix missing update of domains_itree after splitting iopt_area
commit e7250ab7ca upstream.

In iopt_area_split(), if the original iopt_area has filled a domain and is
linked to domains_itree, pages_nodes have to be properly
reinserted. Otherwise the domains_itree becomes corrupted and we will UAF.

Fixes: 51fe6141f0 ("iommufd: Data structure to provide IOVA to PFN mapping")
Link: https://lore.kernel.org/r/20231027162941.2864615-2-den@valinux.co.jp
Cc: stable@vger.kernel.org
Signed-off-by: Koichiro Den <den@valinux.co.jp>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-11-28 17:15:01 +00:00
..
device.c iommufd: Fix locking around hwpt allocation 2023-09-13 09:53:28 +02:00
double_span.h
hw_pagetable.c iommufd: Make iommufd_hw_pagetable_alloc() do iopt_table_add_domain() 2023-03-06 10:51:57 -04:00
io_pagetable.c iommufd: Fix missing update of domains_itree after splitting iopt_area 2023-11-28 17:15:01 +00:00
io_pagetable.h
ioas.c iommu/iommufd: Pass iommufd_ctx pointer in iommufd_get_ioas() 2023-03-29 16:52:41 -03:00
iommufd_private.h iommufd: IOMMUFD_DESTROY should not increase the refcount 2023-07-27 11:27:19 -03:00
iommufd_test.h iommufd/selftest: Rename the sefltest 'device_id' to 'stdev_id' 2023-03-06 10:51:58 -04:00
Kconfig vfio: Support VFIO_NOIOMMU with iommufd 2023-02-03 15:45:23 -04:00
main.c iommufd: IOMMUFD_DESTROY should not increase the refcount 2023-07-27 11:27:19 -03:00
Makefile
pages.c iommufd: Add iopt_area_alloc() 2023-11-20 11:57:06 +01:00
selftest.c iommufd/selftest: Set varaiable mock_iommu_device storage-class-specifier to static 2023-04-04 11:02:39 -03:00
vfio_compat.c iommu/iommufd: Pass iommufd_ctx pointer in iommufd_get_ioas() 2023-03-29 16:52:41 -03:00