From: Sasha Levin <sashal@kernel.org>
To: stable@vger.kernel.org
Cc: Anton Lundin <glance@ac2.se>, Guenter Roeck <linux@roeck-us.net>,
Sasha Levin <sashal@kernel.org>
Subject: [PATCH 5.15.y 2/2] hwmon: (nct6775) Handle dual use registers
Date: Wed, 25 Nov 2026 12:55:47 -0500 [thread overview]
Message-ID: <20261125175529.1065808-2-sashal@kernel.org> (raw)
In-Reply-To: <20261125175529.1065808-1-sashal@kernel.org>
From: Anton Lundin <glance@ac2.se>
[ Upstream commit ca1abdd1a9b9ce51713a18c8905bf10579533c3b ]
The REG_TARGET register has different meaning, depending on if pwm is in
thermal_cruise or speed_cruise.
This means we can't assume it's always word sized, so we need to handle
it differently depending on which mode we're in.
The code already does this, but the register was configured as word
sized for the speed_cruise mode, which would do the wrong thing in
thermal_cruise mode.
Fixes: 6c009501ff20 ("hwmon: (nct6775) Add support for NCT6102D/6106D")
Fixes: 29c7cb485b32 ("hwmon: (nct6775) Integrate new model nct6116")
Fixes: 437b3c2a4bdc ("hwmon: (nct6775) Add support for NCT6126D")
Cc: stable@vger.kernel.org
Signed-off-by: Anton Lundin <glance@ac2.se>
Link: https://patch.msgid.link/20261109082511.851377-2-glance@ac2.se
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
[ sashal: Kept this tree's existing context (no 0x59 entries, no nct6126 case) and removed only the REG_TARGET addresses from the nct6106 and nct6116 word-sized lists. ]
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
drivers/hwmon/nct6775.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/hwmon/nct6775.c b/drivers/hwmon/nct6775.c
index 35a296768fde3..8ccf4fd15b091 100644
--- a/drivers/hwmon/nct6775.c
+++ b/drivers/hwmon/nct6775.c
@@ -1362,13 +1362,11 @@ static bool is_word_sized(struct nct6775_data *data, u16 reg)
switch (data->kind) {
case nct6106:
return reg == 0x20 || reg == 0x22 || reg == 0x24 ||
- reg == 0xe0 || reg == 0xe2 || reg == 0xe4 ||
- reg == 0x111 || reg == 0x121 || reg == 0x131;
+ reg == 0xe0 || reg == 0xe2 || reg == 0xe4;
case nct6116:
return reg == 0x20 || reg == 0x22 || reg == 0x24 ||
reg == 0x26 || reg == 0x28 || reg == 0xe0 || reg == 0xe2 ||
- reg == 0xe4 || reg == 0xe6 || reg == 0xe8 || reg == 0x111 ||
- reg == 0x121 || reg == 0x131 || reg == 0x191 || reg == 0x1a1;
+ reg == 0xe4 || reg == 0xe6 || reg == 0xe8;
case nct6775:
return (((reg & 0xff00) == 0x100 ||
(reg & 0xff00) == 0x200) &&
--
2.53.0
prev parent reply other threads:[~2026-11-25 17:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-25 10:18 FAILED: patch "[PATCH] hwmon: (nct6775) Handle dual use registers" failed to apply to 5.15-stable tree gregkh
2026-11-25 17:55 ` [PATCH 5.15.y 1/2] hwmon: (nct6775) Use nct6775_*() function pointers in nct6775_data Sasha Levin
2026-11-25 17:55 ` Sasha Levin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261125175529.1065808-2-sashal@kernel.org \
--to=sashal@kernel.org \
--cc=glance@ac2.se \
--cc=linux@roeck-us.net \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox