From: Petr Kulhavy <brain@jikos.cz>
To: broonie@kernel.org, lgirdwood@gmail.com
Cc: alsa-devel@alsa-project.org, Petr Kulhavy <brain@jikos.cz>
Subject: [PATCH 3/5] ASoC: tas571x: remove improper PDN signal usage in set_bias_level
Date: Mon, 3 Oct 2016 16:40:48 +0200 [thread overview]
Message-ID: <1475505650-8572-4-git-send-email-brain@jikos.cz> (raw)
In-Reply-To: <1475505650-8572-1-git-send-email-brain@jikos.cz>
The set_bias_level toggles the PDN signal when entering
SND_SOC_BIAS_STANDBY and SND_SOC_BIAS_OFF. However this has no effect and
actually breaks things down (tested with TAS5717) due to the following
reasons:
1) holding down PDN does not save power but holding down RST does
2) now hard mute via register 0x5 is implemented and therefore it is no
longer needed to toggle PDN to enter all channel shut down
3) in order to leave PDN it is required to toggle the RST signal (see
TAS5721 datasheet), which was not implemented
4) toggling PDN as implemented actually mutes PWMs and there is no audio
output (tested on TAS5717)
For these reasons remove the PDN signal toggling and just initialize it to
inactive in probe().
Signed-off-by: Petr Kulhavy <brain@jikos.cz>
---
sound/soc/codecs/tas571x.c | 14 --------------
1 file changed, 14 deletions(-)
diff --git a/sound/soc/codecs/tas571x.c b/sound/soc/codecs/tas571x.c
index 4d61357..a8a3279 100644
--- a/sound/soc/codecs/tas571x.c
+++ b/sound/soc/codecs/tas571x.c
@@ -341,20 +341,9 @@ static int tas571x_set_bias_level(struct snd_soc_codec *codec,
return ret;
}
}
-
- gpiod_set_value(priv->pdn_gpio, 0);
- usleep_range(5000, 6000);
-
- regcache_cache_only(priv->regmap, false);
- ret = regcache_sync(priv->regmap);
- if (ret)
- return ret;
}
break;
case SND_SOC_BIAS_OFF:
- regcache_cache_only(priv->regmap, true);
- gpiod_set_value(priv->pdn_gpio, 1);
-
if (!IS_ERR(priv->mclk))
clk_disable_unprepare(priv->mclk);
break;
@@ -771,9 +760,6 @@ static int tas571x_i2c_probe(struct i2c_client *client,
return ret;
}
- regcache_cache_only(priv->regmap, true);
- gpiod_set_value(priv->pdn_gpio, 1);
-
return snd_soc_register_codec(&client->dev, &priv->codec_driver,
&tas571x_dai, 1);
}
--
2.7.4
next prev parent reply other threads:[~2016-10-03 14:41 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-03 14:40 [PATCH 0/5] ASoC: tas571x: fix of several issues for TAS5717 Petr Kulhavy
2016-10-03 14:40 ` [PATCH 1/5] ASoC: tas571x: fix missing bias save level Petr Kulhavy
2016-10-03 17:09 ` Lars-Peter Clausen
2016-10-03 19:00 ` Petr Kulhavy
2016-10-03 19:11 ` Lars-Peter Clausen
2016-10-03 19:13 ` Lars-Peter Clausen
2016-10-03 20:24 ` Petr Kulhavy
2016-10-03 14:40 ` [PATCH 2/5] ASoC: tas571x: extend the t_i2c time to comply with TAS5721 Petr Kulhavy
2016-10-05 15:21 ` Applied "ASoC: tas571x: extend the t_i2c time to comply with TAS5721" to the asoc tree Mark Brown
2016-10-03 14:40 ` Petr Kulhavy [this message]
2016-10-05 15:21 ` Applied "ASoC: tas571x: remove improper PDN signal usage in set_bias_level" " Mark Brown
2016-10-03 14:40 ` [PATCH 4/5] ASoC: tas571x: wait 50ms after oscillator trim Petr Kulhavy
2016-10-05 15:22 ` Applied "ASoC: tas571x: wait 50ms after oscillator trim" to the asoc tree Mark Brown
2016-10-03 14:40 ` [PATCH 5/5] ASoC: tas571x: move mixer volume controls from TAS5711 to TAS5717 Petr Kulhavy
2016-10-05 15:21 ` Applied "ASoC: tas571x: move mixer volume controls from TAS5711 to TAS5717" to the asoc tree Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1475505650-8572-4-git-send-email-brain@jikos.cz \
--to=brain@jikos.cz \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=lgirdwood@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).