mirror of
https://github.com/torvalds/linux.git
synced 2026-03-08 01:04:41 +01: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:
parent
5aac7afc75
commit
ae089de7ad
1 changed files with 2 additions and 6 deletions
|
|
@ -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)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue