summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sound/soc/ux500/ux500_msp_dai.c12
-rw-r--r--sound/soc/ux500/ux500_msp_i2s.c3
-rw-r--r--sound/soc/ux500/ux500_pcm.c4
3 files changed, 10 insertions, 9 deletions
diff --git a/sound/soc/ux500/ux500_msp_dai.c b/sound/soc/ux500/ux500_msp_dai.c
index 2af5bf14193..4a2ff3419f2 100644
--- a/sound/soc/ux500/ux500_msp_dai.c
+++ b/sound/soc/ux500/ux500_msp_dai.c
@@ -189,11 +189,6 @@ static void ux500_msp_dai_shutdown(struct snd_pcm_substream *substream,
if (drvdata == NULL)
return;
- if (mode_playback)
- drvdata->playback_active = false;
- else
- drvdata->capture_active = false;
-
if (ux500_msp_i2s_close(drvdata->msp_i2s_drvdata,
mode_playback ? DISABLE_TRANSMIT : DISABLE_RECEIVE)) {
pr_err("%s: Error: MSP %d (%s): Unable to close i2s.\n",
@@ -202,10 +197,13 @@ static void ux500_msp_dai_shutdown(struct snd_pcm_substream *substream,
stream_str(substream));
}
- if (mode_playback)
+ if (mode_playback) {
+ drvdata->playback_active = false;
drvdata->configured &= ~PLAYBACK_CONFIGURED;
- else
+ } else {
+ drvdata->capture_active = false;
drvdata->configured &= ~CAPTURE_CONFIGURED;
+ }
}
static void ux500_msp_dai_setup_multichannel(struct ux500_platform_drvdata *private,
diff --git a/sound/soc/ux500/ux500_msp_i2s.c b/sound/soc/ux500/ux500_msp_i2s.c
index 91a9a03f93d..f8138bd1aa3 100644
--- a/sound/soc/ux500/ux500_msp_i2s.c
+++ b/sound/soc/ux500/ux500_msp_i2s.c
@@ -317,7 +317,8 @@ void ux500_msp_i2s_configure_dma(struct msp *msp, struct msp_config *config)
u16 word_width;
bool rx_active, tx_active;
- if (msp->tx_pipeid != NULL) {
+ if ((msp->tx_pipeid != NULL) &&
+ (config->direction == MSP_TRANSMIT_MODE)) {
dma_release_channel(msp->tx_pipeid);
msp->tx_pipeid = NULL;
}
diff --git a/sound/soc/ux500/ux500_pcm.c b/sound/soc/ux500/ux500_pcm.c
index 29b3f5e0ffb..07e18135451 100644
--- a/sound/soc/ux500/ux500_pcm.c
+++ b/sound/soc/ux500/ux500_pcm.c
@@ -276,11 +276,13 @@ static int ux500_pcm_trigger(struct snd_pcm_substream *substream, int cmd)
return -EINVAL;
}
break;
-
+ case SNDRV_PCM_TRIGGER_RESUME:
+ break;
case SNDRV_PCM_TRIGGER_PAUSE_PUSH:
break;
case SNDRV_PCM_TRIGGER_STOP:
+ case SNDRV_PCM_TRIGGER_SUSPEND:
pr_debug("%s: SNDRV_PCM_TRIGGER_STOP\n", __func__);
pr_debug("%s: no_of_underruns = %u\n",
__func__,