Skip to content

Commit

Permalink
ASoC: samsung: Check to see if we managed to allocate a channel
Browse files Browse the repository at this point in the history
Signed-off-by: Mark Brown <broonie@linaro.org>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
  • Loading branch information
Mark Brown committed Aug 20, 2013
1 parent 6418365 commit 37e6071
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sound/soc/samsung/dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,10 @@ static int dma_hw_params(struct snd_pcm_substream *substream,
prtd->params->ch = prtd->params->ops->request(
prtd->params->channel, &req, rtd->cpu_dai->dev,
prtd->params->ch_name);
if (!prtd->params->ch) {
pr_err("Failed to allocate DMA channel\n");
return -ENXIO;
}
prtd->params->ops->config(prtd->params->ch, &config);
}

Expand Down

0 comments on commit 37e6071

Please sign in to comment.