projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ba25cbf
)
iio: light: al3010: Use unsigned int for the indexing
author
David Heidelberg
<david@ixit.cz>
Wed, 19 Mar 2025 20:59:40 +0000
(21:59 +0100)
committer
Jonathan Cameron
<Jonathan.Cameron@huawei.com>
Tue, 22 Apr 2025 18:09:53 +0000
(19:09 +0100)
The integer is used as array index which cannot be negative.
Signed-off-by: David Heidelberg <david@ixit.cz>
Link:
https://patch.msgid.link/20250319-al3010-iio-regmap-v2-1-1310729d0543@ixit.cz
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/light/al3010.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/iio/light/al3010.c
b/drivers/iio/light/al3010.c
index 7cbb8b203300907a88f4a0ab87da89cabdd087f3..4c2fd88ab32cd73f4735b0fa3014af084037c94d 100644
(file)
--- 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: