aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
diff options
context:
space:
mode:
authorRex Zhu <[email protected]>2018-07-25 03:51:46 +0000
committerAlex Deucher <[email protected]>2018-07-31 21:58:12 +0000
commitccf9ef0b0d10434dec5046bcfc4e834a7b1830fd (patch)
tree04ce161d443c4681d807f9bd53d4fe1c96fb1dbc /drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
parentdrm/amd/pp: Convert voltage unit in mV*4 to mV on CZ/ST (diff)
downloadkernel-ccf9ef0b0d10434dec5046bcfc4e834a7b1830fd.tar.gz
kernel-ccf9ef0b0d10434dec5046bcfc4e834a7b1830fd.zip
drm/amdgpu: fix a reversed condition
This test was reversed so it would end up leading to vddnb value can't be read via hwmon on APU. Reviewed-by: Evan Quan <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
index 15a1192c1ec5..23fc1d32b937 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
@@ -1185,7 +1185,7 @@ static ssize_t amdgpu_hwmon_show_vddnb(struct device *dev,
int r, size = sizeof(vddnb);
/* only APUs have vddnb */
- if (adev->flags & AMD_IS_APU)
+ if (!(adev->flags & AMD_IS_APU))
return -EINVAL;
/* Can't get voltage when the card is off */