aboutsummaryrefslogtreecommitdiffstats
path: root/sound/arm/pxa2xx-pcm-lib.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2011-04-10 12:56:10 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-04-10 12:56:10 -0400
commit4263a2f1dad8c8e7ce2352a0cbc882c2b0c044a9 (patch)
treee5892af7a7fd7784c5a3dba682b3cc2728ecadcf /sound/arm/pxa2xx-pcm-lib.c
parent510ec7bc3bf6bc6d87662d16a6136135d747e535 (diff)
parent84f3b6dab973c1a9e941fdd1a55caa44da6d9882 (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: ALSA: hda - Don't query connections for widgets have no connections ALSA: HDA: Fix single internal mic on ALC275 (Sony Vaio VPCSB1C5E) ALSA: hda - HDMI: Fix MCP7x audio infoframe checksums ALSA: usb-audio: define another USB ID for a buggy USB MIDI cable ALSA: HDA: Fix dock mic for Lenovo X220-tablet ASoC: format_register_str: Don't clip register values ASoC: PXA: Fix oops in __pxa2xx_pcm_prepare ASoC: zylonite: set .codec_dai_name in initializer
Diffstat (limited to 'sound/arm/pxa2xx-pcm-lib.c')
-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)
140 if (!prtd || !prtd->params) 140 if (!prtd || !prtd->params)
141 return 0; 141 return 0;
142 142
143 if (prtd->dma_ch == -1)
144 return -EINVAL;
145
143 DCSR(prtd->dma_ch) &= ~DCSR_RUN; 146 DCSR(prtd->dma_ch) &= ~DCSR_RUN;
144 DCSR(prtd->dma_ch) = 0; 147 DCSR(prtd->dma_ch) = 0;
145 DCMD(prtd->dma_ch) = 0; 148 DCMD(prtd->dma_ch) = 0;