summaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil-cisco@xs4all.nl>2019-11-03 12:23:34 +0100
committerMauro Carvalho Chehab <mchehab@kernel.org>2019-11-08 07:26:33 +0100
commit492b53a50a1c565d067f48de96b85336f1ea601e (patch)
tree829ef3775e90ead2e8c9fa1aebae70344fc55268 /drivers/media
parentmedia: mtk-vpu: fix two smatch warnings (diff)
downloadlinux-492b53a50a1c565d067f48de96b85336f1ea601e.tar.xz
linux-492b53a50a1c565d067f48de96b85336f1ea601e.zip
media: rc/ite-cir: fix smatch warning
Use sizeof instead of ARRAY_SIZE to fix this smatch warning: drivers/media/rc/ite-cir.c:385 ite_tx_ir() warn: calling memset(x, y, ARRAY_SIZE()); Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Acked-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/rc/ite-cir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/rc/ite-cir.c b/drivers/media/rc/ite-cir.c
index 3ab6cec0dc3b..07667c04c1d2 100644
--- a/drivers/media/rc/ite-cir.c
+++ b/drivers/media/rc/ite-cir.c
@@ -382,7 +382,7 @@ static int ite_tx_ir(struct rc_dev *rcdev, unsigned *txbuf, unsigned n)
ite_dbg("%s called", __func__);
/* clear the array just in case */
- memset(last_sent, 0, ARRAY_SIZE(last_sent));
+ memset(last_sent, 0, sizeof(last_sent));
spin_lock_irqsave(&dev->lock, flags);