projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6b9019a
)
dma: imx-dma: Remove redundant NULL check
author
Sachin Kamat
<sachin.kamat@linaro.org>
Mon, 2 Sep 2013 07:51:18 +0000
(13:21 +0530)
committer
Vinod Koul
<vinod.koul@intel.com>
Mon, 2 Sep 2013 12:05:58 +0000
(17:35 +0530)
kfree on a NULL pointer is a no-op. Null pointer check is
not necessary.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
drivers/dma/imx-dma.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/dma/imx-dma.c
b/drivers/dma/imx-dma.c
index ff2aab973b45dd1594fc5445380627589a1791c8..78f8ca5fccee91e7a422c419df4ee0ab427d4ad4 100644
(file)
--- a/
drivers/dma/imx-dma.c
+++ b/
drivers/dma/imx-dma.c
@@
-805,10
+805,8
@@
static void imxdma_free_chan_resources(struct dma_chan *chan)
}
INIT_LIST_HEAD(&imxdmac->ld_free);
- if (imxdmac->sg_list) {
- kfree(imxdmac->sg_list);
- imxdmac->sg_list = NULL;
- }
+ kfree(imxdmac->sg_list);
+ imxdmac->sg_list = NULL;
}
static struct dma_async_tx_descriptor *imxdma_prep_slave_sg(