]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
hwmon: (lm90) Re-enable interrupts after alert clears
authorGuenter Roeck <linux@roeck-us.net>
Sat, 8 Jan 2022 19:37:19 +0000 (11:37 -0800)
committerPaolo Pisati <paolo.pisati@canonical.com>
Thu, 3 Feb 2022 09:28:53 +0000 (10:28 +0100)
commit39e3c0b30032a510aae0625c6e02d29db50ea8f9
treecdd84803b019fbd23c0ea4bf7b0c7e9fbfce8cad
parentc9566107d8aa377801b62a3de8021143e19873a8
hwmon: (lm90) Re-enable interrupts after alert clears

BugLink: https://bugs.launchpad.net/bugs/1959879
[ Upstream commit bc341a1a98827925082e95db174734fc8bd68af6 ]

If alert handling is broken, interrupts are disabled after an alert and
re-enabled after the alert clears. However, if there is an interrupt
handler, this does not apply if alerts were originally disabled and enabled
when the driver was loaded. In that case, interrupts will stay disabled
after an alert was handled though the alert handler even after the alert
condition clears. Address the situation by always re-enabling interrupts
after the alert condition clears if there is an interrupt handler.

Fixes: 2abdc357c55d9 ("hwmon: (lm90) Unmask hardware interrupt")
Cc: Dmitry Osipenko <digetx@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
drivers/hwmon/lm90.c