Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 370066e2 authored by Roel Kluin's avatar Roel Kluin Committed by Mark Brown
Browse files

ASoC: Wrong variable returned on error



The wrong variable was returned in the case of an error

Signed-off-by: default avatarRoel Kluin <roel.kluin@gmail.com>
Acked-by: default avatarLiam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent 43f0de8d
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -322,12 +322,12 @@ static int mx1_mx2_pcm_open(struct snd_pcm_substream *substream)

	pr_debug("%s: Requesting dma channel (%s)\n", __func__,
						prtd->dma_params->name);
	prtd->dma_ch = imx_dma_request_by_prio(prtd->dma_params->name,
						DMA_PRIO_HIGH);
	if (prtd->dma_ch < 0) {
	ret = imx_dma_request_by_prio(prtd->dma_params->name, DMA_PRIO_HIGH);
	if (ret < 0) {
		printk(KERN_ERR "Error %d requesting dma channel\n", ret);
		return ret;
	}
	prtd->dma_ch = ret;
	imx_dma_config_burstlen(prtd->dma_ch,
				prtd->dma_params->watermark_level);