Skip to content

Commit 40e210a

Browse files
Zhu Jungregkh
authored andcommitted
misc: isl29020: Fix the wrong format specifier
The format specifier of "unsigned long int" in sprintf() should be "%lu", not "%ld". Signed-off-by: Zhu Jun <zhujun2@cmss.chinamobile.com> Link: https://lore.kernel.org/r/20241111091950.4299-1-zhujun2@cmss.chinamobile.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 03e6a10 commit 40e210a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/misc/isl29020.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ static ssize_t als_lux_input_data_show(struct device *dev,
6868
if (val < 0)
6969
return val;
7070
lux = ((((1 << (2 * (val & 3))))*1000) * ret_val) / 65536;
71-
return sprintf(buf, "%ld\n", lux);
71+
return sprintf(buf, "%lu\n", lux);
7272
}
7373

7474
static ssize_t als_sensing_range_store(struct device *dev,

0 commit comments

Comments
 (0)