[PATCH v2 3/7] pinctrl: armada-37xx: propagate error from armada_37xx_gpio_direction_output()
Gabor Juhos
j4g8y7 at gmail.com
Wed May 14 12:18:34 PDT 2025
The regmap_update_bits() function can fail, so propagate its error
up to the stack instead of silently ignoring that.
Signed-off-by: Imre Kaloz <kaloz at openwrt.org>
Reviewed-by: Andrew Lunn <andrew at lunn.ch>
Signed-off-by: Gabor Juhos <j4g8y7 at gmail.com>
---
Changes in v2:
- swap with patch 2 from v1
- remove 'stable' and 'Fixes' tags
- add 'Reviewed-by' tag from Andrew
- reorder 'Signed-off-by' tags (result of 'b4 trailers -u')
---
drivers/pinctrl/mvebu/pinctrl-armada-37xx.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c b/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c
index 79f9c08e5039c31acb170d4f38b516b1454fd9ea..8d93d36af63ab9496376219454214c05db30971f 100644
--- a/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c
+++ b/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c
@@ -432,9 +432,7 @@ static int armada_37xx_gpio_direction_output(struct gpio_chip *chip,
reg = OUTPUT_EN;
armada_37xx_update_reg(®, &en_offset);
- regmap_update_bits(info->regmap, reg, mask, mask);
-
- return 0;
+ return regmap_update_bits(info->regmap, reg, mask, mask);
}
static int armada_37xx_gpio_get(struct gpio_chip *chip, unsigned int offset)
--
2.49.0
More information about the linux-arm-kernel
mailing list