[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20220713225151.1476041-1-robert.marko@sartura.hr>
Date: Thu, 14 Jul 2022 00:51:50 +0200
From: Robert Marko <robert.marko@...tura.hr>
To: linus.walleij@...aro.org, colin.foster@...advantage.com,
linux-gpio@...r.kernel.org, linux-kernel@...r.kernel.org
Cc: Robert Marko <robert.marko@...tura.hr>
Subject: [PATCH 1/2] pinctrl: ocelot: correct pincfg regmap max_register
Commit "pinctrl: ocelot: convert pinctrl to regmap" set the pincfg regmap
max_register to 32 which is incorrect as there are 64 pins in total.
Actual register space length is 0x100, which matches the DTS and can
actually fit one register per pin with stride of 4.
So, correct the max_register to 0xfc.
Fixes: 076d9e71bcf8 ("pinctrl: ocelot: convert pinctrl to regmap")
Signed-off-by: Robert Marko <robert.marko@...tura.hr>
---
drivers/pinctrl/pinctrl-ocelot.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-ocelot.c
index 349e063a04fa..84bfbe649b67 100644
--- a/drivers/pinctrl/pinctrl-ocelot.c
+++ b/drivers/pinctrl/pinctrl-ocelot.c
@@ -1899,7 +1899,7 @@ static struct regmap *ocelot_pinctrl_create_pincfg(struct platform_device *pdev)
.reg_bits = 32,
.val_bits = 32,
.reg_stride = 4,
- .max_register = 32,
+ .max_register = 0xfc,
.name = "pincfg",
};
--
2.36.1
Powered by blists - more mailing lists