]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/dma/txx9dmac.c
Merge branches 'upstream-fixes', 'wacom' and 'waltop' into for-linus
[karo-tx-linux.git] / drivers / dma / txx9dmac.c
index bb7b3d96ac6f659d5dc16e464d9275f5fab052d8..913f55c76c9915bfb08bde041afdc2d9a7d7590f 100644 (file)
@@ -833,7 +833,7 @@ txx9dmac_prep_dma_memcpy(struct dma_chan *chan, dma_addr_t dest, dma_addr_t src,
 static struct dma_async_tx_descriptor *
 txx9dmac_prep_slave_sg(struct dma_chan *chan, struct scatterlist *sgl,
                unsigned int sg_len, enum dma_transfer_direction direction,
-               unsigned long flags)
+               unsigned long flags, void *context)
 {
        struct txx9dmac_chan *dc = to_txx9dmac_chan(chan);
        struct txx9dmac_dev *ddev = dc->ddev;
@@ -1034,7 +1034,7 @@ static int txx9dmac_alloc_chan_resources(struct dma_chan *chan)
                return -EIO;
        }
 
-       chan->completed_cookie = chan->cookie = 1;
+       dma_cookie_init(chan);
 
        dc->ccr = TXX9_DMA_CCR_IMMCHN | TXX9_DMA_CCR_INTENE | CCR_LE;
        txx9dmac_chan_set_SMPCHN(dc);
@@ -1163,7 +1163,7 @@ static int __init txx9dmac_chan_probe(struct platform_device *pdev)
        dc->ddev->chan[ch] = dc;
        dc->chan.device = &dc->dma;
        list_add_tail(&dc->chan.device_node, &dc->chan.device->channels);
-       dc->chan.cookie = dc->chan.completed_cookie = 1;
+       dma_cookie_init(&dc->chan);
 
        if (is_dmac64(dc))
                dc->ch_regs = &__txx9dmac_regs(dc->ddev)->CHAN[ch];