Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

media: tc358743: initialize variable

clang static analysis flags this error

tc358743.c:1468:9: warning: Branch condition evaluates
to a garbage value
return handled ? IRQ_HANDLED : IRQ_NONE;
^~~~~~~
handled should be initialized to false.

Fixes: d747b806abf4 ("[media] tc358743: add direct interrupt handling")
Signed-off-by: Tom Rix <trix@redhat.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>

authored by

Tom Rix and committed by
Mauro Carvalho Chehab
274cf92d 0ca94547

+1 -1
+1 -1
drivers/media/i2c/tc358743.c
··· 1461 1461 static irqreturn_t tc358743_irq_handler(int irq, void *dev_id) 1462 1462 { 1463 1463 struct tc358743_state *state = dev_id; 1464 - bool handled; 1464 + bool handled = false; 1465 1465 1466 1466 tc358743_isr(&state->sd, 0, &handled); 1467 1467