diff mbox series

[02/16] hwmon: emc1403: Fix type incompatibility with non-macro find_closest

Message ID 20250515081332.151250-3-asoponar@taladin.ro
State New
Headers show
Series [01/16] hwmon: w83795: Fix type incompatibility with non-macro find_closest | expand

Commit Message

Alexandru Soponar May 15, 2025, 8:13 a.m. UTC
The ina3221_conv_time array was previously declared as u16 but used with
find_closest_descending(). With find_closest_descending() now implemented
as a function taking 'int' parameters instead of a macro, passing unsigned
arrays causes type incompatibility errors. Change the array type from u16
to int to ensure compatibility with the new function signature.

Signed-off-by: Alexandru Soponar <asoponar@taladin.ro>
---
 drivers/hwmon/emc1403.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/hwmon/emc1403.c b/drivers/hwmon/emc1403.c
index eca33220d34a..41590b44b162 100644
--- a/drivers/hwmon/emc1403.c
+++ b/drivers/hwmon/emc1403.c
@@ -517,7 +517,7 @@  static int emc1403_temp_write(struct thermal_data *data, u32 attr, int channel,
 }
 
 /* Lookup table for temperature conversion times in msec */
-static const u16 ina3221_conv_time[] = {
+static const int ina3221_conv_time[] = {
 	16000, 8000, 4000, 2000, 1000, 500, 250, 125, 62, 31, 16
 };