iommu/amd: Consolidate logic to allocate protection domain
authorSuravee Suthikulpanit <suravee.suthikulpanit@amd.com>
Thu, 21 Sep 2023 09:21:36 +0000 (09:21 +0000)
committerJoerg Roedel <jroedel@suse.de>
Mon, 25 Sep 2023 10:39:00 +0000 (12:39 +0200)
commitba7d263b7749f8e7f227d7357963632711b5c6ea
tree88d2700c5bee984463110427a0b2c81a6ac7ba4d
parent75e6d7edfdcc540fc59d7bb289bd8b68ca11aa1c
iommu/amd: Consolidate logic to allocate protection domain

Move the logic into the common caller function to simplify the code.

No functional changes intended.

Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
Signed-off-by: Vasant Hegde <vasant.hegde@amd.com>
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Reviewed-by: Jerry Snitselaar <jsnitsel@redhat.com>
Link: https://lore.kernel.org/r/20230921092147.5930-4-vasant.hegde@amd.com
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/amd/iommu.c