Commit a3fa9838 authored by Patrick Rudolph's avatar Patrick Rudolph Committed by Mark Brown

regulator (max5970): Fix IRQ handler

The max5970 datasheet gives the impression that IRQ status bits must
be cleared by writing a one to set bits, as those are marked with 'R/C',
however tests showed that a zero must be written.

Fixes an IRQ storm as the interrupt handler actually clears the IRQ
status bits.
Signed-off-by: default avatarPatrick Rudolph <patrick.rudolph@9elements.com>
Signed-off-by: default avatarNaresh Solanki <naresh.solanki@9elements.com>
Link: https://msgid.link/r/20240130150257.3643657-1-naresh.solanki@9elements.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent a67e1f0b
......@@ -392,7 +392,7 @@ static int max597x_regmap_read_clear(struct regmap *map, unsigned int reg,
return ret;
if (*val)
return regmap_write(map, reg, *val);
return regmap_write(map, reg, 0);
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment