Commit 48dc345a authored by Vasant Hegde's avatar Vasant Hegde Committed by Joerg Roedel

iommu/amd: Check EFR[EPHSup] bit before enabling PPR

Check for EFR[EPHSup] bit before enabling PPR. This bit must be set
to enable PPR.
Reported-by: default avatarBorislav Petkov <bp@alien8.de>
Fixes: c4cb2311 ("iommu/amd: Add support for enable/disable IOPF")
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=218900Tested-by: default avatarBorislav Petkov <bp@alien8.de>
Tested-by: default avatarJean-Christophe Guillain <jean-christophe@guillain.net>
Signed-off-by: default avatarVasant Hegde <vasant.hegde@amd.com>
Reviewed-by: default avatarSuravee Suthikulpanit <suravee.suthikulpanit@amd.com>
Link: https://lore.kernel.org/r/20240530071118.10297-1-vasant.hegde@amd.comSigned-off-by: default avatarJoerg Roedel <jroedel@suse.de>
parent 998a0a36
......@@ -129,7 +129,8 @@ static inline int check_feature_gpt_level(void)
static inline bool amd_iommu_gt_ppr_supported(void)
{
return (check_feature(FEATURE_GT) &&
check_feature(FEATURE_PPR));
check_feature(FEATURE_PPR) &&
check_feature(FEATURE_EPHSUP));
}
static inline u64 iommu_virt_to_phys(void *vaddr)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment