mirror of
https://github.com/torvalds/linux.git
synced 2026-06-04 04:23:35 +02:00
drm/amd/pm: Get metrics table version for smu_v13_0_12
Get metrics table version for smu_v13_0_12 and populate pm_metrics Signed-off-by: Asad Kamal <asad.kamal@amd.com> Reviewed-by: Lijo Lazar <lijo.lazar@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
e4e6ae41cc
commit
e6aae1db41
|
|
@ -208,6 +208,7 @@ int smu_v13_0_12_setup_driver_pptable(struct smu_context *smu)
|
|||
StaticMetricsTable_t *static_metrics = (StaticMetricsTable_t *)smu_table->metrics_table;
|
||||
struct PPTable_t *pptable =
|
||||
(struct PPTable_t *)smu_table->driver_pptable;
|
||||
uint32_t table_version;
|
||||
int ret, i;
|
||||
|
||||
if (!pptable->Init) {
|
||||
|
|
@ -215,6 +216,13 @@ int smu_v13_0_12_setup_driver_pptable(struct smu_context *smu)
|
|||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = smu_cmn_send_smc_msg(smu, SMU_MSG_GetMetricsVersion,
|
||||
&table_version);
|
||||
if (ret)
|
||||
return ret;
|
||||
smu_table->tables[SMU_TABLE_SMU_METRICS].version =
|
||||
table_version;
|
||||
|
||||
pptable->MaxSocketPowerLimit =
|
||||
SMUQ10_ROUND(static_metrics->MaxSocketPowerLimit);
|
||||
pptable->MaxGfxclkFrequency =
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user