gint/dma: use the asynchronous DMA API

This commit is contained in:
Lephenixnoir 2021-04-28 17:54:49 +02:00
parent 8fc19004c0
commit 67999f260e
Signed by: Lephenixnoir
GPG Key ID: 1BBA026E13FC0495
1 changed files with 4 additions and 8 deletions

View File

@ -107,14 +107,10 @@ void gintctl_gint_dma(void)
void *dst = vram_address;
int blocks = 256;
if(interrupts)
{
dma_transfer(channel, DMA_4B, blocks,
src, DMA_INC, dst, DMA_INC);
dma_transfer_wait(channel);
}
else dma_transfer_noint(channel, DMA_4B, blocks,
src, DMA_INC, dst, DMA_INC);
if(interrupts) dma_transfer_sync(channel, DMA_4B,
blocks, src, DMA_INC, dst, DMA_INC);
else dma_transfer_atomic(channel, DMA_4B, blocks, src,
DMA_INC, dst, DMA_INC);
successes++;
}