Commit 68feed90 authored by Fabio Estevam's avatar Fabio Estevam Committed by Mark Brown

ASoC: adau1977: Remove unneeded gpiod NULL check

The gpiod API checks for NULL descriptors, so there is no need to
duplicate the check in the driver.
Signed-off-by: default avatarFabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 5771a8c0
...@@ -388,7 +388,6 @@ static int adau1977_power_disable(struct adau1977 *adau1977) ...@@ -388,7 +388,6 @@ static int adau1977_power_disable(struct adau1977 *adau1977)
regcache_mark_dirty(adau1977->regmap); regcache_mark_dirty(adau1977->regmap);
if (adau1977->reset_gpio)
gpiod_set_value_cansleep(adau1977->reset_gpio, 0); gpiod_set_value_cansleep(adau1977->reset_gpio, 0);
regcache_cache_only(adau1977->regmap, true); regcache_cache_only(adau1977->regmap, true);
...@@ -420,7 +419,6 @@ static int adau1977_power_enable(struct adau1977 *adau1977) ...@@ -420,7 +419,6 @@ static int adau1977_power_enable(struct adau1977 *adau1977)
goto err_disable_avdd; goto err_disable_avdd;
} }
if (adau1977->reset_gpio)
gpiod_set_value_cansleep(adau1977->reset_gpio, 1); gpiod_set_value_cansleep(adau1977->reset_gpio, 1);
regcache_cache_only(adau1977->regmap, false); regcache_cache_only(adau1977->regmap, false);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment