* [PATCH] media: dvb: mb86a20s: get rid of a clang-15 warning
@ 2023-06-28 13:03 Mauro Carvalho Chehab
2023-06-28 15:09 ` Chen-Yu Tsai
0 siblings, 1 reply; 2+ messages in thread
From: Mauro Carvalho Chehab @ 2023-06-28 13:03 UTC (permalink / raw)
To: linux-media; +Cc: linux-kernel, Mauro Carvalho Chehab
When building with clang-15: this warning is produced:
../drivers/media/dvb-frontends/mb86a20s.c:1572:6: error: variable 'active_layers' set but not used [-Werror,-Wunused-but-set-variable]
int active_layers = 0, pre_ber_layers = 0, post_ber_layers = 0;
^
1 error generated.
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
---
drivers/media/dvb-frontends/mb86a20s.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/media/dvb-frontends/mb86a20s.c b/drivers/media/dvb-frontends/mb86a20s.c
index b74b9afed9a2..125fed4891ba 100644
--- a/drivers/media/dvb-frontends/mb86a20s.c
+++ b/drivers/media/dvb-frontends/mb86a20s.c
@@ -1569,7 +1569,7 @@ static int mb86a20s_get_stats(struct dvb_frontend *fe, int status_nr)
u32 t_post_bit_error = 0, t_post_bit_count = 0;
u32 block_error = 0, block_count = 0;
u32 t_block_error = 0, t_block_count = 0;
- int active_layers = 0, pre_ber_layers = 0, post_ber_layers = 0;
+ int pre_ber_layers = 0, post_ber_layers = 0;
int per_layers = 0;
dev_dbg(&state->i2c->dev, "%s called.\n", __func__);
@@ -1589,9 +1589,6 @@ static int mb86a20s_get_stats(struct dvb_frontend *fe, int status_nr)
for (layer = 0; layer < NUM_LAYERS; layer++) {
if (c->isdbt_layer_enabled & (1 << layer)) {
- /* Layer is active and has rc segments */
- active_layers++;
-
/* Handle BER before vterbi */
rc = mb86a20s_get_pre_ber(fe, layer,
&bit_error, &bit_count);
--
2.41.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] media: dvb: mb86a20s: get rid of a clang-15 warning
2023-06-28 13:03 [PATCH] media: dvb: mb86a20s: get rid of a clang-15 warning Mauro Carvalho Chehab
@ 2023-06-28 15:09 ` Chen-Yu Tsai
0 siblings, 0 replies; 2+ messages in thread
From: Chen-Yu Tsai @ 2023-06-28 15:09 UTC (permalink / raw)
To: Mauro Carvalho Chehab; +Cc: linux-media, linux-kernel
On Wed, Jun 28, 2023 at 3:03 PM Mauro Carvalho Chehab
<mchehab@kernel.org> wrote:
>
> When building with clang-15: this warning is produced:
>
> ../drivers/media/dvb-frontends/mb86a20s.c:1572:6: error: variable 'active_layers' set but not used [-Werror,-Wunused-but-set-variable]
> int active_layers = 0, pre_ber_layers = 0, post_ber_layers = 0;
> ^
> 1 error generated.
>
> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Reviewed-by: Chen-Yu Tsai <wenst@chromium.org>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-06-28 15:09 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-28 13:03 [PATCH] media: dvb: mb86a20s: get rid of a clang-15 warning Mauro Carvalho Chehab
2023-06-28 15:09 ` Chen-Yu Tsai
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®