summaryrefslogtreecommitdiff
path: root/sound/soc
diff options
context:
space:
mode:
authorHuang Chao <chao7.huang@samsung.com>2014-07-05 13:25:12 +0800
committerChanho Park <chanho61.park@samsung.com>2014-11-18 12:00:01 +0900
commit9dca6387f835c3c30b74bc68ec7cbe6e550191cb (patch)
tree83f4913f0029a2bc21d01b97fb35818cc50a2672 /sound/soc
parent364851829ca3f15ebbceb0c0b533947c1de26c59 (diff)
downloadlinux-3.10-9dca6387f835c3c30b74bc68ec7cbe6e550191cb.tar.gz
linux-3.10-9dca6387f835c3c30b74bc68ec7cbe6e550191cb.tar.bz2
linux-3.10-9dca6387f835c3c30b74bc68ec7cbe6e550191cb.zip
ASoC: samsung: dma: Remove the unnecessary dma chan pointer check
After DMA request slave channel failed and return NULL in dma_open, the snd_dmaengine_pcm_open function will check and handle it. Besides, there is no need to call kfree with NULL argument when a dma_request_slave_channel call fails. Change-Id: I02629dd74b9c535bb134f5516bf3c03a239bd241 Signed-off-by: Huang Chao <chao7.huang@samsung.com>
Diffstat (limited to 'sound/soc')
-rw-r--r--sound/soc/samsung/dma.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/sound/soc/samsung/dma.c b/sound/soc/samsung/dma.c
index b39820b1461..26db25da19c 100644
--- a/sound/soc/samsung/dma.c
+++ b/sound/soc/samsung/dma.c
@@ -120,11 +120,6 @@ static int dma_open(struct snd_pcm_substream *substream)
else
chan = dma_request_slave_channel(rtd->cpu_dai->dev,
dma_chan_names[1]);
- if (!chan) {
- pr_err("%s: failed to request dma chan\n", __func__);
- kfree(chan);
- return -EFAULT;
- }
return snd_dmaengine_pcm_open(substream, chan);
}