My embedded ARM device has a 800x480 16 bit Linux framebuffer LCD which needs to be double-buffered manually.
At the moment I'm just using memcpy()
to write the double buffer to the framebuffer which is awfully slow. A while(1){memcpy(lfb,dbuf)}
loop maxes out the CPU at 100% and updates at approx 40 FPS.
The ARM device I'm using, and the Linux kernel does support DMA memory-memory copy, but I'm having trouble working out how I can access this in a userspace program.
It seems linux/dmaengine.h
and dma_async_memcpy_buf_to_buf()
is what I need to use, but it appears these are only available from within the kernel?