[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250515081332.151250-6-asoponar@taladin.ro>
Date: Thu, 15 May 2025 11:13:21 +0300
From: Alexandru Soponar <asoponar@...adin.ro>
To: linux-kernel@...r.kernel.org,
linux-hwmon@...r.kernel.org,
linux-iio@...r.kernel.org,
linux-leds@...r.kernel.org,
linux-watchdog@...r.kernel.org
Cc: jdelvare@...e.com,
linux@...ck-us.net,
jic23@...nel.org,
pavel@....cz,
lee@...nel.org,
baocheng.su@...mens.com,
wim@...ux-watchdog.org,
tobias.schaffner@...mens.com,
angelogioacchino.delregno@...labora.com,
benedikt.niedermayr@...mens.com,
matthias.bgg@...il.com,
aardelean@...libre.com,
contact@...y.one,
Alexandru Soponar <asoponar@...adin.ro>
Subject: [PATCH 05/16] hwmon: max1619: Fix type incompatibility with non-macro find_closest
The update_intervals array was previously declared as u16 but used with
find_closest_descending(). With find_closest_descending() now implemented
as a function taking signed int parameters instead of a macro, passing
unsigned arrays causes type incompatibility errors. This patch changes
the array type from u16 to int to ensure compatibility with the function
signature and prevent compilation errors.
Signed-off-by: Alexandru Soponar <asoponar@...adin.ro>
---
drivers/hwmon/max1619.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hwmon/max1619.c b/drivers/hwmon/max1619.c
index 9b6d03cff4df..0bd9fbb2517c 100644
--- a/drivers/hwmon/max1619.c
+++ b/drivers/hwmon/max1619.c
@@ -103,7 +103,7 @@ static int max1619_temp_read(struct regmap *regmap, u32 attr, int channel, long
return 0;
}
-static u16 update_intervals[] = { 16000, 8000, 4000, 2000, 1000, 500, 250, 125 };
+static int update_intervals[] = { 16000, 8000, 4000, 2000, 1000, 500, 250, 125 };
static int max1619_chip_read(struct regmap *regmap, u32 attr, long *val)
{
--
2.49.0
Powered by blists - more mailing lists