iommu: Move lock from iommu_change_dev_def_domain() to its caller
authorLu Baolu <baolu.lu@linux.intel.com>
Wed, 22 Mar 2023 06:49:54 +0000 (14:49 +0800)
committerJoerg Roedel <jroedel@suse.de>
Wed, 22 Mar 2023 14:45:17 +0000 (15:45 +0100)
commit33793748de8fde338c11277d3d16dadc79ba65bf
tree1affdcc3371b33aaa2238fbfcb9c4eee88d93904
parentdba9ca9d41f5266194a5e8007db50985d271d0a4
iommu: Move lock from iommu_change_dev_def_domain() to its caller

The intention is to make it possible to put group ownership check and
default domain change in a same critical region protected by the group's
mutex lock. No intentional functional change.

Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Link: https://lore.kernel.org/r/20230322064956.263419-5-baolu.lu@linux.intel.com
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/iommu.c