]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu: Fix bug in reporting voltage for CIK
authorSandeep Raghuraman <sandy.8925@gmail.com>
Thu, 27 Aug 2020 13:13:37 +0000 (18:43 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 3 Sep 2020 04:37:14 +0000 (00:37 -0400)
commitedebbda1d1794c5fd00bcf330694f55f990ffe97
tree401a7e068fa1861a38922470feaa4ef3c9ee598c
parent65d2ce52b9b9fb37fc9dd088980d1e9706919ecf
drm/amdgpu: Fix bug in reporting voltage for CIK

On my R9 390, the voltage was reported as a constant 1000 mV.
This was due to a bug in smu7_hwmgr.c, in the smu7_read_sensor()
function, where some magic constants were used in a condition,
to determine whether the voltage should be read from PLANE2_VID
or PLANE1_VID. The VDDC mask was incorrectly used, instead of
the VDDGFX mask.

This patch changes the code to use the correct defined constants
(and apply the correct bitshift), thus resulting in correct voltage reporting.

Signed-off-by: Sandeep Raghuraman <sandy.8925@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c