diff options
author | Chao Jiang <chaoj@nvidia.com> | 2011-07-12 11:39:37 +0900 |
---|---|---|
committer | Niket Sirsi <nsirsi@nvidia.com> | 2011-07-12 15:00:53 -0700 |
commit | 77bb3984fc74852eec5d1aedac0edcdc686a388d (patch) | |
tree | 2fa880832068049549d6fcd252b278db6690ad81 | |
parent | ad6bc09bbf7e81ddad3749b98713d366524c64e0 (diff) |
ASoC: tegra: wait on amplifier to be enabled
According to the datasheet of wm9001 amplifier, it needs 100ms to
enable itself for Class D with Vmid capacitor 4.7uF. Some sound data
will be missing without the msleep call.
Fixed bug#831138
Change-Id: I047355875c2ee8debffc5b4c3adaa4e236a21b26
Reviewed-on: http://git-master/r/40536
Reviewed-by: Chao Jiang <chaoj@nvidia.com>
Tested-by: Chao Jiang <chaoj@nvidia.com>
Reviewed-by: Sumit Bhattacharya <sumitb@nvidia.com>
Reviewed-by: Scott Peterson <speterson@nvidia.com>
-rw-r--r-- | sound/soc/tegra/tegra_soc_wm8903.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sound/soc/tegra/tegra_soc_wm8903.c b/sound/soc/tegra/tegra_soc_wm8903.c index 2a52788cc97a..f45a113cdeaf 100644 --- a/sound/soc/tegra/tegra_soc_wm8903.c +++ b/sound/soc/tegra/tegra_soc_wm8903.c @@ -434,6 +434,11 @@ static int tegra_dapm_event_int_spk(struct snd_soc_dapm_widget* w, gpio_set_value_cansleep(tegra_wired_jack_conf.en_spkr, SND_SOC_DAPM_EVENT_ON(event) ? 1 : 0); + + /* the amplifier needs 100ms to enable. wait 100ms after + * gpio EN triggered */ + if (SND_SOC_DAPM_EVENT_ON(event)) + msleep(100); } return 0; |