drm/amd/display: fix if == else warning
authorGuo Zhengkui <guozhengkui@vivo.com>
Sun, 24 Apr 2022 09:06:23 +0000 (17:06 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 26 Apr 2022 15:51:20 +0000 (11:51 -0400)
Fix the following coccicheck warning:

drivers/gpu/drm/amd/display/dc/dcn201/dcn201_hwseq.c:98:8-10:
WARNING: possible condition with no effect (if == else)

Reviewed-by: Zhan Liu <zhan.liu@amd.com>
Signed-off-by: Guo Zhengkui <guozhengkui@vivo.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/dcn201/dcn201_hwseq.c

index fe22530..05b3fba 100644 (file)
@@ -95,8 +95,6 @@ static void gpu_addr_to_uma(struct dce_hwseq *hwseq,
        } else if (hwseq->fb_offset.quad_part <= addr->quad_part &&
                        addr->quad_part <= hwseq->uma_top.quad_part) {
                is_in_uma = true;
-       } else if (addr->quad_part == 0) {
-               is_in_uma = false;
        } else {
                is_in_uma = false;
        }