drm/amd/display: Remove the unneeded result variable
authorzhang songyi <zhang.songyi@zte.com.cn>
Fri, 2 Sep 2022 07:54:50 +0000 (07:54 +0000)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 8 Sep 2022 02:28:42 +0000 (22:28 -0400)
Return the enable_link_dp() directly instead of storing it in another
redundant variable.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Reviewed-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: zhang songyi <zhang.songyi@zte.com.cn>
Signed-off-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/core/dc_link.c

index 38fa63d..19644ed 100644 (file)
@@ -2077,11 +2077,7 @@ static enum dc_status enable_link_edp(
                struct dc_state *state,
                struct pipe_ctx *pipe_ctx)
 {
-       enum dc_status status;
-
-       status = enable_link_dp(state, pipe_ctx);
-
-       return status;
+       return enable_link_dp(state, pipe_ctx);
 }
 
 static enum dc_status enable_link_dp_mst(