aboutsummaryrefslogtreecommitdiff
path: root/sound/arm
diff options
context:
space:
mode:
authorMark Brown2011-04-03 19:28:29 +0900
committerMark Brown2011-04-03 19:28:29 +0900
commit1b4610ebf37a05a65e9f29cdf4d87c207573104d (patch)
treef2c035b44a47e4ea663449e7e2138524805d3eba /sound/arm
parent0ce790e7d736cedc563e1fb4e998babf5a4dbc3d (diff)
parent97c96c076b8ef86533f2427ea145a9cd0ec5564f (diff)
Merge branch 'for-2.6.39' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound-2.6 into for-2.6.39
Diffstat (limited to 'sound/arm')
-rw-r--r--sound/arm/pxa2xx-pcm-lib.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/arm/pxa2xx-pcm-lib.c b/sound/arm/pxa2xx-pcm-lib.c
index 8808b82311b1..76e0d5695075 100644
--- a/sound/arm/pxa2xx-pcm-lib.c
+++ b/sound/arm/pxa2xx-pcm-lib.c
@@ -140,6 +140,9 @@ int __pxa2xx_pcm_prepare(struct snd_pcm_substream *substream)
if (!prtd || !prtd->params)
return 0;
+ if (prtd->dma_ch == -1)
+ return -EINVAL;
+
DCSR(prtd->dma_ch) &= ~DCSR_RUN;
DCSR(prtd->dma_ch) = 0;
DCMD(prtd->dma_ch) = 0;