drm/amd/display: remove no need variable
authorBernard Zhao <bernard@vivo.com>
Sat, 5 Jun 2021 12:30:59 +0000 (05:30 -0700)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 7 Jun 2021 18:58:09 +0000 (14:58 -0400)
remove no need variable, just return the DC_OK

Signed-off-by: Bernard Zhao <bernard@vivo.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c

index f962b905e79e6051e65b7460d6ac9907a0123678..7daadb6a52332d4a3f5686d6d6e641e3ac97c6c7 100644 (file)
@@ -1266,8 +1266,6 @@ static enum dc_status dcn10_validate_global(struct dc *dc, struct dc_state *cont
 
 static enum dc_status dcn10_patch_unknown_plane_state(struct dc_plane_state *plane_state)
 {
-       enum dc_status result = DC_OK;
-
        enum surface_pixel_format surf_pix_format = plane_state->format;
        unsigned int bpp = resource_pixel_format_to_bpp(surf_pix_format);
 
@@ -1279,7 +1277,7 @@ static enum dc_status dcn10_patch_unknown_plane_state(struct dc_plane_state *pla
                swizzle = DC_SW_64KB_S;
 
        plane_state->tiling_info.gfx9.swizzle = swizzle;
-       return result;
+       return DC_OK;
 }
 
 struct stream_encoder *dcn10_find_first_free_match_stream_enc_for_link(