diff options
| author | Banajit Goswami <bgoswami@codeaurora.org> | 2014-08-20 18:23:46 -0700 |
|---|---|---|
| committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 20:09:56 -0700 |
| commit | 1da9ca94be25b263d7f253d8c1d8d557d8036f96 (patch) | |
| tree | 47ca5724176da88467c0b2b98f4aec3c74b4cf67 | |
| parent | f794212e7c9103b587a24129daeb13f6e81f5d0b (diff) | |
ASoC: Don't close shared back end dailink
Multiple front end dailinks can use a single backend dailink.
When front end dailink is closed, associated back end dailink shouldn't
be closed if it is connected to other front ends.
Change ensures that back end dai is closed after all connected front end
dailinks are closed.
Change-Id: Ie00abca8391011377a9566adb837b3e46d499a5a
Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
| -rw-r--r-- | sound/soc/soc-pcm.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c index e7f2305da899..7c441a06a13d 100644 --- a/sound/soc/soc-pcm.c +++ b/sound/soc/soc-pcm.c @@ -180,8 +180,11 @@ int dpcm_dapm_stream_event(struct snd_soc_pcm_runtime *fe, int dir, dev_dbg(be->dev, "ASoC: BE %s event %d dir %d\n", be->dai_link->name, event, dir); - - snd_soc_dapm_stream_event(be, dir, event); + if (event == SND_SOC_DAPM_STREAM_STOP && be->dpcm[dir].users >= 1) { + pr_debug("%s Don't close BE \n", __func__); + continue; + } + snd_soc_dapm_stream_event(be, dir, event); } snd_soc_dapm_stream_event(fe, dir, event); |
