Hi,
we are investigating an issue where the CPU A15 is read accessing a framebuffer allocated via V4L2 and VIP. The properties with which the buffer was allocated seems to cause an extreme slowness when reading, but when writing things are fast. We are suspecting that the buffer was allocated as non-cacheable on the read side.
Here is the example
1. allocate 2 buffers with malloc for a full frame size
2. time to do memcpy from the framebuffer to the first malloc buffer
3. time to do memcpy from second malloc buffer to the framebuffer
(./yavta --capture=100 /dev/video1)
Captured 99 frames in 2.697520 seconds (36.700377 fps, 48589815.830837 B/s).
MEMCPY TIME: 1.982 for 100 copies FROM, 19.819 ms/copy (63.070 MB/s)
MEMCPY TIME: 0.096 for 100 copies TO, 0.959 ms/copy (1303.211 MB/s)
Questions:
[] Which memory allocator is the V4L2 or VIP driver using exactly?
[] What options are there to get full speed entitlement when reading with the A15 accessing framebuffer data?
[] Are there examples to setup a DMA transfer from framebuffer to malloc buffer?
[] Can the caching be enabled for V4L2 allocated framebuffers, and what APIs would need to be used to manage the cache coherency?
Thanks,
--Gunter