aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/dma/mpc512x_dma.c
diff options
context:
space:
mode:
authorRussell King - ARM Linux <linux@arm.linux.org.uk>2012-03-06 17:35:47 -0500
committerVinod Koul <vinod.koul@linux.intel.com>2012-03-13 02:07:22 -0400
commitd3ee98cdcd6198ea1cf75c603178acc8a805b69b (patch)
tree721f252d07d5e0596fa9b58a7c876dfd75823d0a /drivers/dma/mpc512x_dma.c
parent96a2af41c78b1fbb1f567a3486bdc63f7b31c5fd (diff)
dmaengine: consolidate initialization of cookies
Provide a common function to initialize a channels cookie values. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Tested-by: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Jassi Brar <jassisinghbrar@gmail.com> [imx-sdma.c & mxs-dma.c] Tested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
Diffstat (limited to 'drivers/dma/mpc512x_dma.c')
-rw-r--r--drivers/dma/mpc512x_dma.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/dma/mpc512x_dma.c b/drivers/dma/mpc512x_dma.c
index 138271591ae9..2ab0a3d0eed5 100644
--- a/drivers/dma/mpc512x_dma.c
+++ b/drivers/dma/mpc512x_dma.c
@@ -733,8 +733,7 @@ static int __devinit mpc_dma_probe(struct platform_device *op)
733 mchan = &mdma->channels[i]; 733 mchan = &mdma->channels[i];
734 734
735 mchan->chan.device = dma; 735 mchan->chan.device = dma;
736 mchan->chan.cookie = 1; 736 dma_cookie_init(&mchan->chan);
737 mchan->chan.completed_cookie = mchan->chan.cookie;
738 737
739 INIT_LIST_HEAD(&mchan->free); 738 INIT_LIST_HEAD(&mchan->free);
740 INIT_LIST_HEAD(&mchan->prepared); 739 INIT_LIST_HEAD(&mchan->prepared);