Skip to content

Commit

Permalink
spi: sc18is602: Change gpiod_set_value to gpiod_set_value_cansleep
Browse files Browse the repository at this point in the history
To avoid warning when using i2c gpio expander change call to the
cansleep variant. There should be no issue with sleeping in the
drivers probe function.

Signed-off-by: Phil Reid <preid@electromag.com.au>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Phil Reid authored and Mark Brown committed Sep 29, 2016
1 parent f990080 commit 76cce7e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/spi/spi-sc18is602.c
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ static int sc18is602_probe(struct i2c_client *client,
hw->reset = devm_gpiod_get_optional(dev, "reset", GPIOD_OUT_HIGH);
if (IS_ERR(hw->reset))
return PTR_ERR(hw->reset);
gpiod_set_value(hw->reset, 0);
gpiod_set_value_cansleep(hw->reset, 0);

hw->master = master;
hw->client = client;
Expand Down

0 comments on commit 76cce7e

Please sign in to comment.