summaryrefslogtreecommitdiffstats
path: root/drivers/dma
diff options
context:
space:
mode:
authorCong Ding <dinggnu@gmail.com>2013-01-15 01:23:48 +0100
committerVinod Koul <vinod.koul@intel.com>2013-01-20 05:49:40 -0800
commit855372c013bbad8369223f7c75242bd3c94f9345 (patch)
tree93ae6496fe982c599e0b67a1506fe71227c54626 /drivers/dma
parented30933e6f3dbeaaab1de91e1bec25f42d5d32df (diff)
dma: sh/shdma-base.c: remove unnecessary null pointer check
the variable chan is dereferenced in line 635, so it is no reason to check null again in line 641. Signed-off-by: Cong Ding <dinggnu@gmail.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma')
-rw-r--r--drivers/dma/sh/shdma-base.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/dma/sh/shdma-base.c b/drivers/dma/sh/shdma-base.c
index f4cd946d259..4acb85a1025 100644
--- a/drivers/dma/sh/shdma-base.c
+++ b/drivers/dma/sh/shdma-base.c
@@ -638,9 +638,6 @@ static int shdma_control(struct dma_chan *chan, enum dma_ctrl_cmd cmd,
unsigned long flags;
int ret;
- if (!chan)
- return -EINVAL;
-
switch (cmd) {
case DMA_TERMINATE_ALL:
spin_lock_irqsave(&schan->chan_lock, flags);