]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
power: supply: rt9471: Fix wrong WDT function regfield declaration
authorChiYuan Huang <cy_huang@richtek.com>
Wed, 25 Sep 2024 08:32:58 +0000 (16:32 +0800)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Wed, 16 Oct 2024 21:30:19 +0000 (23:30 +0200)
Fix F_WDT and F_WDT_RST wrong regfield declaration.

Fixes: 4a1a5f6781d8 ("power: supply: rt9471: Add Richtek RT9471 charger driver")
Reported-by: Lucas Tsai <lucas_tsai@richtek.com>
Signed-off-by: ChiYuan Huang <cy_huang@richtek.com>
Link: https://lore.kernel.org/r/f862e23f220612f01fabb6d8e76cfaf63756c22b.1727252762.git.cy_huang@richtek.com
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/rt9471.c

index c04af1ee89c675c3a3745d476d22c8ecf0fbf44d..730b252b49006908f01b66ab41db99d6524182bf 100644 (file)
@@ -153,8 +153,8 @@ struct rt9471_chip {
 };
 
 static const struct reg_field rt9471_reg_fields[F_MAX_FIELDS] = {
-       [F_WDT]         = REG_FIELD(RT9471_REG_TOP, 0, 0),
-       [F_WDT_RST]     = REG_FIELD(RT9471_REG_TOP, 1, 1),
+       [F_WDT]         = REG_FIELD(RT9471_REG_TOP, 0, 1),
+       [F_WDT_RST]     = REG_FIELD(RT9471_REG_TOP, 2, 2),
        [F_CHG_EN]      = REG_FIELD(RT9471_REG_FUNC, 0, 0),
        [F_HZ]          = REG_FIELD(RT9471_REG_FUNC, 5, 5),
        [F_BATFET_DIS]  = REG_FIELD(RT9471_REG_FUNC, 7, 7),