Skip to content

Commit

Permalink
iommu/vt-d: Always reserve a domain ID for identity setup
Browse files Browse the repository at this point in the history
[ Upstream commit 2c13012 ]

We will use a global static identity domain. Reserve a static domain ID
for it.

Signed-off-by: Lu Baolu <[email protected]>
Reviewed-by: Jason Gunthorpe <[email protected]>
Reviewed-by: Kevin Tian <[email protected]>
Reviewed-by: Jerry Snitselaar <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Joerg Roedel <[email protected]>
Signed-off-by: Sasha Levin <[email protected]>
  • Loading branch information
LuBaolu authored and gregkh committed Oct 10, 2024
1 parent e58cd57 commit d97b7dd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/iommu/intel/iommu.c
Original file line number Diff line number Diff line change
Expand Up @@ -1447,10 +1447,10 @@ static int iommu_init_domains(struct intel_iommu *iommu)
* entry for first-level or pass-through translation modes should
* be programmed with a domain id different from those used for
* second-level or nested translation. We reserve a domain id for
* this purpose.
* this purpose. This domain id is also used for identity domain
* in legacy mode.
*/
if (sm_supported(iommu))
set_bit(FLPT_DEFAULT_DID, iommu->domain_ids);
set_bit(FLPT_DEFAULT_DID, iommu->domain_ids);

return 0;
}
Expand Down

0 comments on commit d97b7dd

Please sign in to comment.