]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
iio: light: stk3310: Use sizeof() for regmap_bulk_read/write count parameter
authorMiao Li <limiao@kylinos.cn>
Mon, 4 May 2026 03:04:08 +0000 (11:04 +0800)
committerJonathan Cameron <jic23@kernel.org>
Sun, 31 May 2026 09:59:34 +0000 (10:59 +0100)
commita4c18ea894e5587bcc6be787fcd77c0c19beaa1d
treec803206c8ef555ec7f5564b51254c283525229b3
parentac4129478a2416eecdb09e78f7d7b5d7286b9ac6
iio: light: stk3310: Use sizeof() for regmap_bulk_read/write count parameter

Convert the hardcoded count parameter to sizeof(buf) for all
regmap_bulk_write() and regmap_bulk_read() calls in this driver
to improve code maintainability. For details, see [1].

Link: https://lore.kernel.org/all/20260428192213.7c5c80e5@jic23-huawei/
Signed-off-by: Miao Li <limiao@kylinos.cn>
Reviewed-by: Joshua Crofts <joshua.crofts1@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/light/stk3310.c