From: David Heidelberg Date: Wed, 19 Mar 2025 20:59:40 +0000 (+0100) Subject: iio: light: al3010: Use unsigned int for the indexing X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=a29542e614014a081c507539ff1bb7d21cb046fc;p=users%2Fjedix%2Flinux-maple.git iio: light: al3010: Use unsigned int for the indexing The integer is used as array index which cannot be negative. Signed-off-by: David Heidelberg Link: https://patch.msgid.link/20250319-al3010-iio-regmap-v2-1-1310729d0543@ixit.cz Signed-off-by: Jonathan Cameron --- diff --git a/drivers/iio/light/al3010.c b/drivers/iio/light/al3010.c index 7cbb8b2033009..4c2fd88ab32cd 100644 --- a/drivers/iio/light/al3010.c +++ b/drivers/iio/light/al3010.c @@ -145,7 +145,7 @@ static int al3010_write_raw(struct iio_dev *indio_dev, int val2, long mask) { struct al3010_data *data = iio_priv(indio_dev); - int i; + unsigned int i; switch (mask) { case IIO_CHAN_INFO_SCALE: