]> xenbits.xensource.com Git - xen.git/commit
xen/iommu: protect iommu_add_dt_device() with dtdevs_lock
authorVikram Garhwal <vikram.garhwal@amd.com>
Wed, 6 Sep 2023 01:16:20 +0000 (18:16 -0700)
committerStefano Stabellini <stefano.stabellini@amd.com>
Wed, 6 Sep 2023 01:26:07 +0000 (18:26 -0700)
commit6b0e3b74cb4cc245c3b7fa2019fc40c5212e1ce4
tree8647e50ef6e0d4705c732f30f56de0c828a3a60a
parentbd4ce8f7e054d537e128bd02f57cbf7347bca91a
xen/iommu: protect iommu_add_dt_device() with dtdevs_lock

Protect iommu_add_dt_device() with dtdevs_lock to prevent concurrent access
to add/remove/assign/deassign.
With addition of dynamic programming feature(follow-up patches in this series),
this function can be concurrently accessed by dynamic node add/remove using
device tree overlays.

Signed-off-by: Vikram Garhwal <vikram.garhwal@amd.com>
Reviewed-by: Luca Fancellu <luca.fancellu@arm.com>
Reviewed-by: Michal Orzel <michal.orzel@amd.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
xen/drivers/passthrough/device_tree.c