]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - drivers/dma/mv_xor.c
dmaengine: mv_xor: Use correct device for DMA API
[mirror_ubuntu-bionic-kernel.git] / drivers / dma / mv_xor.c
index 1993889003fd11d51d80090daf32737d740a5b4b..1c57577f49fea23cd1aa73c7df850effe2b88d1b 100644 (file)
@@ -1059,6 +1059,7 @@ mv_xor_channel_add(struct mv_xor_device *xordev,
                mv_chan->op_in_desc = XOR_MODE_IN_DESC;
 
        dma_dev = &mv_chan->dmadev;
+       dma_dev->dev = &pdev->dev;
        mv_chan->xordev = xordev;
 
        /*
@@ -1091,7 +1092,6 @@ mv_xor_channel_add(struct mv_xor_device *xordev,
        dma_dev->device_free_chan_resources = mv_xor_free_chan_resources;
        dma_dev->device_tx_status = mv_xor_status;
        dma_dev->device_issue_pending = mv_xor_issue_pending;
-       dma_dev->dev = &pdev->dev;
 
        /* set prep routines based on capability */
        if (dma_has_cap(DMA_INTERRUPT, dma_dev->cap_mask))