Fixed DMA loop condition