Skip to content

Commit

Permalink
drm/amd/display: Fix wrong return value in dm_update_plane_state()
Browse files Browse the repository at this point in the history
[ Upstream commit c353761 ]

On an error exit path, a negative error code should be returned
instead of a positive return value.

Fixes: 9e86906 ("drm/amd/display: Move iteration out of dm_update_planes")
Cc: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Tianjia Zhang <tianjia.zhang@linux.alibaba.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
uudiin authored and gregkh committed Oct 29, 2020
1 parent 0d234d1 commit 0a5630d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
Original file line number Diff line number Diff line change
Expand Up @@ -6984,8 +6984,7 @@ static int dm_update_plane_state(struct dc *dc,
dm_old_plane_state->dc_state,
dm_state->context)) {

ret = EINVAL;
return ret;
return -EINVAL;
}


Expand Down

0 comments on commit 0a5630d

Please sign in to comment.