Skip to content

Commit 1e0dff7

Browse files
TE-N-ShengjiuWangbroonie
authored andcommitted
ASoC: ak4458: remove "reset-gpios" property handler
commit c721f18 ("reset: Instantiate reset GPIO controller for shared reset-gpios") check if there is no "resets" property will fallback to "reset-gpios". So don't need to handle "reset-gpios" separately in the driver, the "reset-gpios" handler is duplicated with "resets" control handler, remove it. Signed-off-by: Shengjiu Wang <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent 6558e87 commit 1e0dff7

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

sound/soc/codecs/ak4458.c

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ struct ak4458_priv {
4545
const struct ak4458_drvdata *drvdata;
4646
struct device *dev;
4747
struct regmap *regmap;
48-
struct gpio_desc *reset_gpiod;
4948
struct reset_control *reset;
5049
struct gpio_desc *mute_gpiod;
5150
int digfil; /* SSLOW, SD, SLOW bits */
@@ -631,10 +630,7 @@ static struct snd_soc_dai_driver ak4497_dai = {
631630

632631
static void ak4458_reset(struct ak4458_priv *ak4458, bool active)
633632
{
634-
if (ak4458->reset_gpiod) {
635-
gpiod_set_value_cansleep(ak4458->reset_gpiod, active);
636-
usleep_range(1000, 2000);
637-
} else if (!IS_ERR_OR_NULL(ak4458->reset)) {
633+
if (!IS_ERR_OR_NULL(ak4458->reset)) {
638634
if (active)
639635
reset_control_assert(ak4458->reset);
640636
else
@@ -758,11 +754,6 @@ static int ak4458_i2c_probe(struct i2c_client *i2c)
758754
if (IS_ERR(ak4458->reset))
759755
return PTR_ERR(ak4458->reset);
760756

761-
ak4458->reset_gpiod = devm_gpiod_get_optional(ak4458->dev, "reset",
762-
GPIOD_OUT_LOW);
763-
if (IS_ERR(ak4458->reset_gpiod))
764-
return PTR_ERR(ak4458->reset_gpiod);
765-
766757
ak4458->mute_gpiod = devm_gpiod_get_optional(ak4458->dev, "mute",
767758
GPIOD_OUT_LOW);
768759
if (IS_ERR(ak4458->mute_gpiod))

0 commit comments

Comments
 (0)