Re: [PATCH 3/7] iommu/amd: Introduce function to check SEV-SNP support

2022-06-13 Thread Suthikulpanit, Suravee via iommu
On 6/13/2022 8:24 AM, Suravee Suthikulpanit wrote: @@ -3543,3 +3537,30 @@ int amd_iommu_pc_set_reg(struct amd_iommu *iommu, u8 bank, u8 cntr, u8 fxn, u64 return iommu_pc_get_set_reg(iommu, bank, cntr, fxn, value, true); } + +bool iommu_sev_snp_supported(void) +{ + /* +

[PATCH 3/7] iommu/amd: Introduce function to check SEV-SNP support

2022-06-12 Thread Suravee Suthikulpanit via iommu
From: Brijesh Singh The SEV-SNP support requires that IOMMU must to enabled. It also prohibits IOMMU configurations where DTE[Mode]=0, which means the SEV-SNP feature is not supported with IOMMU passthrough domain (a.k.a IOMMU_DOMAIN_IDENTITY), or when AMD IOMMU driver is configured to not use