[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200802111536.5246-1-tianjia.zhang@linux.alibaba.com>
Date: Sun, 2 Aug 2020 19:15:36 +0800
From: Tianjia Zhang <tianjia.zhang@...ux.alibaba.com>
To: harry.wentland@....com, sunpeng.li@....com,
alexander.deucher@....com, christian.koenig@....com,
airlied@...ux.ie, daniel@...ll.ch, nicholas.kazlauskas@....com,
Rodrigo.Siqueira@....com, Bhawanpreet.Lakha@....com,
stylon.wang@....com, roman.li@....com, mikita.lipski@....com
Cc: amd-gfx@...ts.freedesktop.org, dri-devel@...ts.freedesktop.org,
linux-kernel@...r.kernel.org, tianjia.zhang@...baba.com
Subject: [PATCH] drm/amd/display: Fix wrong return value in dm_update_plane_state()
On an error exit path, a negative error code should be returned
instead of a positive return value.
Fixes: 9e869063b0021 ("drm/amd/display: Move iteration out of dm_update_planes")
Cc: Leo Li <sunpeng.li@....com>
Signed-off-by: Tianjia Zhang <tianjia.zhang@...ux.alibaba.com>
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
index 710edc70e37e..5810416e2ddc 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -8182,8 +8182,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;
}
--
2.26.2
Powered by blists - more mailing lists