]> git.baikalelectronics.ru Git - kernel.git/commit
media: em28xx: fix two smatch warnings
authorHans Verkuil <hverkuil-cisco@xs4all.nl>
Sun, 3 Nov 2019 11:23:35 +0000 (12:23 +0100)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Fri, 8 Nov 2019 06:27:14 +0000 (07:27 +0100)
commit7675561e380a11cfef00c4b681d34b1ff0b21786
treec878c0e312e926e856678c28f0e1f31ca9311b54
parent030a15d54d07f5689c9cae3adcf9e0d365f23df6
media: em28xx: fix two smatch warnings

Use sizeof instead of ARRAY_SIZE to fix this smatch warning:

drivers/media/usb/em28xx/em28xx-i2c.c:952 em28xx_do_i2c_scan() warn: calling memset(x, y, ARRAY_SIZE());

Do the same for the em28xx_hash_mem() call in the same function.
smatch didn't pick that up, but there too it should use sizeof instead
of ARRAY_SIZE.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/media/usb/em28xx/em28xx-i2c.c