Commit 1085cbf2 authored by Matthias Kaehlcke's avatar Matthias Kaehlcke Committed by Mauro Carvalho Chehab

[media] vcodec: mediatek: Remove double parentheses

The extra pairs of parentheses are not needed and cause clang
warnings like this:

drivers/media/platform/mtk-vcodec/venc/venc_vp8_if.c:158:32: error: equality comparison with extraneous parentheses [-Werror,-Wparentheses-equality]
                if ((inst->work_bufs[i].size == 0))
                     ~~~~~~~~~~~~~~~~~~~~~~~~^~~~
drivers/media/platform/mtk-vcodec/venc/venc_vp8_if.c:158:32: note: remove extraneous parentheses around the comparison to silence this warning
                if ((inst->work_bufs[i].size == 0))
                    ~                        ^   ~
drivers/media/platform/mtk-vcodec/venc/venc_vp8_if.c:158:32: note: use '=' to turn this equality comparison into an assignment
                if ((inst->work_bufs[i].size == 0))
                                             ^~
                                             =
Signed-off-by: default avatarMatthias Kaehlcke <mka@chromium.org>
Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent ee8c7cdb
...@@ -155,7 +155,7 @@ static void vp8_enc_free_work_buf(struct venc_vp8_inst *inst) ...@@ -155,7 +155,7 @@ static void vp8_enc_free_work_buf(struct venc_vp8_inst *inst)
/* Buffers need to be freed by AP. */ /* Buffers need to be freed by AP. */
for (i = 0; i < VENC_VP8_VPU_WORK_BUF_MAX; i++) { for (i = 0; i < VENC_VP8_VPU_WORK_BUF_MAX; i++) {
if ((inst->work_bufs[i].size == 0)) if (inst->work_bufs[i].size == 0)
continue; continue;
mtk_vcodec_mem_free(inst->ctx, &inst->work_bufs[i]); mtk_vcodec_mem_free(inst->ctx, &inst->work_bufs[i]);
} }
...@@ -172,7 +172,7 @@ static int vp8_enc_alloc_work_buf(struct venc_vp8_inst *inst) ...@@ -172,7 +172,7 @@ static int vp8_enc_alloc_work_buf(struct venc_vp8_inst *inst)
mtk_vcodec_debug_enter(inst); mtk_vcodec_debug_enter(inst);
for (i = 0; i < VENC_VP8_VPU_WORK_BUF_MAX; i++) { for (i = 0; i < VENC_VP8_VPU_WORK_BUF_MAX; i++) {
if ((wb[i].size == 0)) if (wb[i].size == 0)
continue; continue;
/* /*
* This 'wb' structure is set by VPU side and shared to AP for * This 'wb' structure is set by VPU side and shared to AP for
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment