Ali Ahmet Memis
c88a6338ae
hwmon: (nct6694) do not expose enable on DTIN temperature channels
...
The driver registers 26 temperature channels, all advertising
HWMON_T_ENABLE, and indexes the enable bitmap with the raw channel:
data->hwmon_en.tin_en[channel / 8] |= BIT(channel % 8);
tin_en is two bytes and only covers the 5 THR and 5 TDP channels
(index 0-9). The 16 DTIN channels (index 10-25) are enabled by the
firmware and were never meant to carry an enable bit. Because the
control structure is packed, writing temp17_enable and above indexes
past tin_en into the fin_en bytes that follow it, so it toggles fan
enable state instead; nct6694_hwmon_init() then sends the whole
structure back to the device, and reads report fan state as temperature
state. It stays within the structure, so this is not a memory safety
problem, but on a board that uses the fan channels it is not harmless.
Give the DTIN channels a temperature config without HWMON_T_ENABLE so
the core never creates their enable attribute. The enable path is then
reachable only for the first 10 channels, which stay within tin_en, and
fin_en is left alone. The DTIN input and limit attributes are unchanged.
Fixes: 197e779d29 ("hwmon: Add Nuvoton NCT6694 HWMON support")
Suggested-by: Ming Yu <tmyu0@nuvoton.com >
Link: https://lore.kernel.org/all/20260802124730.20387-1-ali@iusegentoo.com/
Signed-off-by: Ali Ahmet Memis <ali@iusegentoo.com >
Link: https://patch.msgid.link/20260803102148.14196-1-ali@iusegentoo.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net >
2026-09-09 18:16:35 -07:00
..
2026-07-20 07:29:44 -07:00
2026-08-10 08:59:41 -07:00
2026-09-09 18:16:34 -07:00
2026-08-10 08:59:40 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-08-06 22:37:44 -07:00
2026-06-09 08:22:57 -07:00
2025-10-17 07:18:06 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:23:00 -07:00
2026-07-03 07:38:17 +02:00
2026-08-10 08:59:43 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-06-16 08:10:21 +05:30
2026-09-07 07:22:19 -07:00
2025-10-17 07:18:15 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-29 16:37:43 -07:00
2026-09-09 18:16:35 -07:00
2026-06-29 08:51:59 -07:00
2026-09-09 18:16:35 -07:00
2026-08-10 08:59:43 -07:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:41 -07:00
2025-10-19 18:56:14 -07:00
2026-09-09 18:16:28 -07:00
2026-08-16 14:40:33 -07:00
2026-09-09 18:16:35 -07:00
2026-08-10 08:59:43 -07:00
2026-08-10 08:59:43 -07:00
2026-08-10 08:59:41 -07:00
2026-06-23 08:31:33 -07:00
2026-06-09 08:22:59 -07:00
2026-05-22 21:49:05 -04:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:40 -07:00
2026-08-10 08:59:40 -07:00
2026-06-09 08:22:59 -07:00
2026-08-16 14:40:33 -07:00
2026-06-10 12:49:57 -07:00
2026-06-09 08:22:59 -07:00
2026-06-16 08:10:21 +05:30
2026-01-31 07:38:32 -08:00
2026-06-09 08:22:59 -07:00
2026-05-06 14:29:59 +02:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-07-07 20:03:00 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-10 22:07:17 -07:00
2026-09-09 18:16:35 -07:00
2025-07-20 16:37:09 -07:00
2026-08-10 08:59:42 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 11:33:59 +02:00
2026-09-07 07:22:19 -07:00
2026-02-21 17:09:51 -08:00
2025-10-17 07:18:15 -07:00
2026-02-21 17:09:51 -08:00
2026-02-21 20:03:00 -08:00
2026-07-06 16:59:47 +01:00
2026-09-07 07:22:19 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 13:48:19 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:23:09 -07:00
2026-07-03 07:38:17 +02:00
2026-05-06 14:29:59 +02:00
2026-08-13 20:36:36 -07:00
2026-08-10 08:59:42 -07:00
2025-04-23 07:18:27 -07:00
2026-08-25 09:38:50 -07:00
2025-05-12 18:05:54 -07:00
2026-07-03 07:38:17 +02:00
2026-03-30 19:45:05 -07:00
2026-05-21 06:48:19 -07:00
2026-06-09 08:22:59 -07:00
2026-07-27 14:33:23 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:43 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2025-10-17 07:18:10 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-09-07 07:22:18 -07:00
2026-08-10 08:59:42 -07:00
2026-07-03 07:38:17 +02:00
2026-02-22 15:48:30 -08:00
2026-08-25 09:38:50 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-08-16 14:40:33 -07:00
2026-06-09 08:22:59 -07:00
2026-06-16 08:10:21 +05:30
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-03-30 19:45:05 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2025-04-23 07:21:15 -07:00
2025-07-24 09:20:39 +02:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-09-07 07:22:18 -07:00
2026-06-03 09:12:45 +02:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:23:09 -07:00
2026-09-09 18:16:35 -07:00
2026-08-11 09:00:32 -07:00
2026-06-09 08:22:59 -07:00
2026-08-11 09:00:32 -07:00
2026-01-31 07:38:32 -08:00
2026-06-09 08:23:00 -07:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:42 -07:00
2026-06-09 08:22:57 -07:00
2026-07-06 16:59:47 +01:00
2026-08-10 08:59:42 -07:00
2026-08-04 14:07:58 -07:00
2026-06-09 08:22:59 -07:00
2026-04-10 08:33:08 -07:00
2026-06-09 08:22:59 -07:00
2026-05-21 16:48:41 +02:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:42 -07:00
2026-06-03 09:12:53 +02:00
2026-06-09 08:23:05 -07:00
2026-07-17 15:50:48 +02:00
2026-02-21 17:09:51 -08:00
2026-07-03 07:38:17 +02:00
2026-07-03 07:38:17 +02:00
2025-10-15 11:04:40 -07:00
2025-10-17 07:18:10 -07:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:41 -07:00
2026-09-07 07:22:19 -07:00
2026-08-10 08:59:42 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-07-03 07:38:17 +02:00
2026-06-09 08:22:59 -07:00
2026-07-28 22:00:15 -05:00
2026-07-03 07:38:17 +02:00
2026-07-31 09:28:15 +02:00
2026-06-09 08:22:59 -07:00
2025-11-26 09:03:15 -08:00
2026-06-09 08:22:59 -07:00
2026-06-16 08:10:21 +05:30
2026-06-09 08:22:59 -07:00
2026-08-13 04:51:39 -07:00
2026-06-09 08:22:59 -07:00
2026-07-03 07:38:17 +02:00
2026-08-10 08:59:41 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:40 -07:00
2026-06-08 10:01:49 +02:00
2025-11-21 07:50:18 -08:00
2025-11-24 11:47:45 -08:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2025-07-20 16:38:34 -07:00
2026-06-29 13:36:48 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-09 08:22:59 -07:00
2026-06-29 13:36:43 -07:00
2026-06-09 08:22:59 -07:00
2026-08-10 08:59:40 -07:00
2026-09-07 07:22:19 -07:00