diff options
author | Shirish S <shirish.s@amd.com> | 2021-02-25 21:07:21 +0530 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2021-02-26 17:23:49 -0500 |
commit | e0cd93b7e307cf6920fbc699df04d073c9004c22 (patch) | |
tree | c3f8c0a4adeeedc796f9e7c6aaad557319a5bbd2 /drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_hwmgr.c | |
parent | e9995d4a3026b104724700397ee9db4cd75445dc (diff) |
amdgpu/pm: read_sensor() report failure apporpriately
report -ENOTSUPP instead of -EINVAL, so that if userspace
fails to read sensor data can figure it out the failure correctly.
Signed-off-by: Shirish S <shirish.s@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/amd/pm/powerplay/hwmgr/vega20_hwmgr.c')
-rw-r--r-- | drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_hwmgr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_hwmgr.c b/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_hwmgr.c index 87811b005b85..e8eec2539c17 100644 --- a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_hwmgr.c +++ b/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_hwmgr.c @@ -2240,7 +2240,7 @@ static int vega20_read_sensor(struct pp_hwmgr *hwmgr, int idx, *size = 8; break; default: - ret = -EINVAL; + ret = -EOPNOTSUPP; break; } return ret; |