The regmap_write for TEMPOFFSETL should use low_temp but incorrectly
uses high_temp, causing the low temperature threshold to be misconfigured.
This prevents the low temperature trip point from working properly.
Fixes: 7d55e75edc87 ("thermal: airoha: convert to regmap API")
Signed-off-by: Wayen Yan <win847@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/23780
Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
- writel(TEMP_TO_RAW(priv, low) >> 4,
- priv->base + EN7581_TEMPOFFSETL);
+ regmap_write(priv->map, EN7581_TEMPOFFSETL,
-+ TEMP_TO_RAW(priv, high) >> 4);
++ TEMP_TO_RAW(priv, low) >> 4);
enable_monitor = true;
}