Skip to content

Commit

Permalink
ASoC: sta32x: Remove unneeded gpiod NULL check
Browse files Browse the repository at this point in the history
The gpiod API checks for NULL descriptors, so there is no need to
duplicate the check in the driver.

Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Fabio Estevam authored and Mark Brown committed Jul 17, 2017
1 parent 5771a8c commit c5efe23
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions sound/soc/codecs/sta32x.c
Original file line number Diff line number Diff line change
Expand Up @@ -847,8 +847,7 @@ static int sta32x_set_bias_level(struct snd_soc_codec *codec,
msleep(300);
sta32x_watchdog_stop(sta32x);

if (sta32x->gpiod_nreset)
gpiod_set_value(sta32x->gpiod_nreset, 0);
gpiod_set_value(sta32x->gpiod_nreset, 0);

regulator_bulk_disable(ARRAY_SIZE(sta32x->supplies),
sta32x->supplies);
Expand Down

0 comments on commit c5efe23

Please sign in to comment.