Page 1 of 1
using the dma
Posted: Tue Jul 14, 2009 8:19 am
by yemista
I understand that dma expects contiguous memory from the first 16mb, but does it matter where those are? For example, If I have my kernel control 0-2mb, can I set aside the next 4mb for dma, and just setup all dma transfers to take place in that region or does dma need the whole 16mb to be free?
Re: using the dma
Posted: Tue Jul 14, 2009 8:51 am
by XanClic
No, you just need a part of it. But the begin of the DMA buffer has to be aligned on 64kB boundaries, as far as I know.
Re: using the dma
Posted: Wed Jul 15, 2009 12:19 am
by xenos
IIRC, the begin of the DMA buffer does not have to be on a 64 kB boundary. But, nevertheless, the DMA transfer must not cross a 64 kB boundary. I.e. a transfer of, say, 0x4000 bytes to adress 0x68000 is perfectly fine, while a transfer of 0x4000 bytes to 0x6d000 will fail since it crosses tha boundary at 0x70000.
Re: using the dma
Posted: Wed Jul 15, 2009 10:11 am
by XanClic
OK, then that's right.