summaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorMoise Gergaud <moise.gergaud@st.com>2015-11-19 14:54:09 +0100
committerMark Brown <broonie@kernel.org>2015-11-19 17:49:35 +0000
commit36a65e2072625556191c6c616d65ed4f67f4f0d0 (patch)
tree33ab41c48b4aa3d0db82a95319c80f295c3fd321 /sound
parentf9f51973d3a8559731a228e91ac29792b43046a5 (diff)
downloadlinux-stable-36a65e2072625556191c6c616d65ed4f67f4f0d0.tar.gz
linux-stable-36a65e2072625556191c6c616d65ed4f67f4f0d0.tar.bz2
linux-stable-36a65e2072625556191c6c616d65ed4f67f4f0d0.zip
ASoC: sti: set player private data
Set substream player private data. substream player private data is used in uni_player_irq_handler to lock, stop & unlock the stream when interrupt indicates underflow/overflow. If not set, then segmentation fault occurs. Signed-off-by: Moise Gergaud <moise.gergaud@st.com> Acked-by: Arnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/sti/uniperif_player.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/soc/sti/uniperif_player.c b/sound/soc/sti/uniperif_player.c
index 1e19a7c6b7e8..5c2bc53f0a9b 100644
--- a/sound/soc/sti/uniperif_player.c
+++ b/sound/soc/sti/uniperif_player.c
@@ -669,6 +669,7 @@ static int uni_player_startup(struct snd_pcm_substream *substream,
{
struct sti_uniperiph_data *priv = snd_soc_dai_get_drvdata(dai);
struct uniperif *player = priv->dai_data.uni;
+ player->substream = substream;
player->clk_adj = 0;
@@ -950,6 +951,8 @@ static void uni_player_shutdown(struct snd_pcm_substream *substream,
if (player->state != UNIPERIF_STATE_STOPPED)
/* Stop the player */
uni_player_stop(player);
+
+ player->substream = NULL;
}
static int uni_player_parse_dt_clk_glue(struct platform_device *pdev,