power: reset: at91-sama5d2_shdwc: fix wkupdbc mask
authorClaudiu Beznea <claudiu.beznea@microchip.com>
Wed, 16 Dec 2020 12:57:31 +0000 (14:57 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 4 Mar 2021 09:26:28 +0000 (10:26 +0100)
[ Upstream commit 95aa21a3f1183260db1b0395e03df5bebc5ed641 ]

According to datasheet WKUPDBC mask is b/w bits 26..24.

Fixes: f80cb48843987 ("power: reset: at91-shdwc: add new shutdown controller driver")
Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Reviewed-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/power/reset/at91-sama5d2_shdwc.c

index e341cc5c0ea6f1253772d5a48772aa183e395b31..c84df27cd548230e641f553a165edc58cd163a33 100644 (file)
@@ -37,7 +37,7 @@
 
 #define AT91_SHDW_MR   0x04            /* Shut Down Mode Register */
 #define AT91_SHDW_WKUPDBC_SHIFT        24
-#define AT91_SHDW_WKUPDBC_MASK GENMASK(31, 16)
+#define AT91_SHDW_WKUPDBC_MASK GENMASK(26, 24)
 #define AT91_SHDW_WKUPDBC(x)   (((x) << AT91_SHDW_WKUPDBC_SHIFT) \
                                                & AT91_SHDW_WKUPDBC_MASK)