mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/netfilter/nf.git
synced 2026-04-03 23:38:12 -04:00
reset: gpio: check the return value of gpiod_set_value_cansleep()
gpiod_set_value_cansleep() now returns an integer and can indicate failures. Propagate the return value to the caller of the reset API. Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com> Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
This commit is contained in:
committed by
Philipp Zabel
parent
5aac7afc75
commit
ae089de7ad
@@ -22,9 +22,7 @@ static int reset_gpio_assert(struct reset_controller_dev *rc, unsigned long id)
|
||||
{
|
||||
struct reset_gpio_priv *priv = rc_to_reset_gpio(rc);
|
||||
|
||||
gpiod_set_value_cansleep(priv->reset, 1);
|
||||
|
||||
return 0;
|
||||
return gpiod_set_value_cansleep(priv->reset, 1);
|
||||
}
|
||||
|
||||
static int reset_gpio_deassert(struct reset_controller_dev *rc,
|
||||
@@ -32,9 +30,7 @@ static int reset_gpio_deassert(struct reset_controller_dev *rc,
|
||||
{
|
||||
struct reset_gpio_priv *priv = rc_to_reset_gpio(rc);
|
||||
|
||||
gpiod_set_value_cansleep(priv->reset, 0);
|
||||
|
||||
return 0;
|
||||
return gpiod_set_value_cansleep(priv->reset, 0);
|
||||
}
|
||||
|
||||
static int reset_gpio_status(struct reset_controller_dev *rc, unsigned long id)
|
||||
|
||||
Reference in New Issue
Block a user