summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
authorXiaojian Du <Xiaojian.Du@amd.com>2020-12-14 17:05:55 +0800
committerAlex Deucher <alexander.deucher@amd.com>2021-01-06 16:02:45 -0500
commit0e61f09af48beb41be0954e7be7d3ba2d18c9946 (patch)
treea52e6f62ae3756551e2db2054c414a9ee88de9b4 /drivers/gpu/drm
parent5b2fc08c455bbf749489254a81baeffdf4c0a693 (diff)
downloadlinux-0e61f09af48beb41be0954e7be7d3ba2d18c9946.tar.bz2
drm/amd/pm: correct the sensor value of power for vangogh
This patch is to correct the sensor value of power for vangogh. Signed-off-by: Xiaojian Du <Xiaojian.Du@amd.com> Reviewed-by: Evan Quan <evan.quan@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/amd/pm/swsmu/smu11/vangogh_ppt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu11/vangogh_ppt.c b/drivers/gpu/drm/amd/pm/swsmu/smu11/vangogh_ppt.c
index 8cb4fcee9a2c..5c1482d4ca43 100644
--- a/drivers/gpu/drm/amd/pm/swsmu/smu11/vangogh_ppt.c
+++ b/drivers/gpu/drm/amd/pm/swsmu/smu11/vangogh_ppt.c
@@ -252,7 +252,8 @@ static int vangogh_get_smu_metrics_data(struct smu_context *smu,
*value = metrics->UvdActivity;
break;
case METRICS_AVERAGE_SOCKETPOWER:
- *value = metrics->CurrentSocketPower;
+ *value = (metrics->CurrentSocketPower << 8) /
+ 1000 ;
break;
case METRICS_TEMPERATURE_EDGE:
*value = metrics->GfxTemperature / 100 *