Skip to content

Commit a33e9e1

Browse files
Shyam Sundar S Kij-intel
authored andcommitted
platform/x86/amd/pmf: Differentiate PMF ACPI versions
For family 1AH, certain PMF features have been enhanced - leading to a newer APMF (AMD PMF) spec (BIOS and PMF driver interface) called v2. This information would be fed into the if_version field of the verify_interface method of the APMF call from the BIOS. Use this information to store the version number to differentiate between v1 or v2 and also store the information into the PMF private data structure, as this information would be required for further code branching to support the latest silicon. Reviewed-by: Kuppuswamy Sathyanarayanan <[email protected]> Co-developed-by: Patil Rajesh Reddy <[email protected]> Signed-off-by: Patil Rajesh Reddy <[email protected]> Signed-off-by: Shyam Sundar S K <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ilpo Järvinen <[email protected]> Signed-off-by: Ilpo Järvinen <[email protected]>
1 parent f62f012 commit a33e9e1

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

drivers/platform/x86/amd/pmf/acpi.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -218,8 +218,10 @@ static int apmf_if_verify_interface(struct amd_pmf_dev *pdev)
218218
return err;
219219

220220
pdev->supported_func = output.supported_functions;
221-
dev_dbg(pdev->dev, "supported functions:0x%x notifications:0x%x\n",
222-
output.supported_functions, output.notification_mask);
221+
dev_dbg(pdev->dev, "supported functions:0x%x notifications:0x%x version:%u\n",
222+
output.supported_functions, output.notification_mask, output.version);
223+
224+
pdev->pmf_if_version = output.version;
223225

224226
return 0;
225227
}

drivers/platform/x86/amd/pmf/pmf.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,7 @@ struct amd_pmf_dev {
235235
u64 policy_addr;
236236
void __iomem *policy_base;
237237
bool smart_pc_enabled;
238+
u16 pmf_if_version;
238239
};
239240

240241
struct apmf_sps_prop_granular {

0 commit comments

Comments
 (0)