Messages in this thread | | | From | "Tian, Kevin" <> | Subject | RE: [PATCH v2 4/6] iommu/vt-d: Remove unnecessary check in intel_iommu_add() | Date | Thu, 7 Jul 2022 01:01:49 +0000 |
| |
> From: Lu Baolu <baolu.lu@linux.intel.com> > Sent: Saturday, July 2, 2022 9:56 AM > > The Intel IOMMU hot-add process starts from dmar_device_hotplug(). It > uses the global dmar_global_lock to synchronize all the hot-add and > hot-remove paths. In the hot-add path, the new IOMMU data structures > are allocated firstly by dmar_parse_one_drhd() and then initialized by > dmar_hp_add_drhd(). All the IOMMU units are allocated and initialized > in the same synchronized path. There is no case where any IOMMU unit > is created and then initialized for multiple times. > > This removes the unnecessary check in intel_iommu_add() which is the > last reference place of the global IOMMU array. > > Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
| |