]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/dma/edma.c
dma: edma: fix incorrect SG list handling
[karo-tx-linux.git] / drivers / dma / edma.c
index cd8da451d1995fef8b6d076005b17ad1a17b44d1..bf5ad0f5a77ac46ab7d22794c12b6bc181256c85 100644 (file)
@@ -182,11 +182,13 @@ static void edma_execute(struct edma_chan *echan)
                                  echan->ecc->dummy_slot);
        }
 
-       edma_resume(echan->ch_num);
-
        if (edesc->processed <= MAX_NR_SG) {
                dev_dbg(dev, "first transfer starting %d\n", echan->ch_num);
                edma_start(echan->ch_num);
+       } else {
+               dev_dbg(dev, "chan: %d: completed %d elements, resuming\n",
+                       echan->ch_num, edesc->processed);
+               edma_resume(echan->ch_num);
        }
 
        /*