This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Issue with V4L2 Layer Multiple Buffers while camera is streaming

Hi,

I'm using the PSP 2.6.32 kernel (03.00.01.06), and I'm having trouble with using multiple buffers in the v4l2 layer streaming.

 

I am using a camera sensor connected to omap isp via parallel interface. Right now using a single buffer, the streaming is happening fine from my camera. To make room for parallel processing I need to make use of the multiple  buffering support.

I know that v4l2 supports upto 32 buffers which can be queued up for  enqueue and dequeue operation so that the streaming operation is faster. If I request for four buffers (using VIDIOC_REQBUFS) what I see is that only first buffer has valid data while the remaing three are empty. Please note that I am using V4L2_MEMORY_MMAP memory

 

Please  see the following kernel debug prints got while running the camera streaming application:

------------------------------------------------------------------------------------------------

vbuf: reqbufs: bufs=4, size=0x96000 [600 pages total]
vbuf: mmap setup: 4 buffers, 614400 bytes each

vbuf: qbuf: requesting next field
vbuf: qbuf: succeded
vbuf: qbuf: requesting next field
vbuf: qbuf: succeded
vbuf: qbuf: requesting next field
vbuf: qbuf: succeded
vbuf: qbuf: requesting next field
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_queue: queue 0 vb 0, mmu 1000
ISPCTRL: <1>isp_buf_queue: queue 1 vb 1, mmu 97000
ISPCTRL: <1>isp_buf_queue: queue 2 vb 2, mmu 12d000
ISPCTRL: <1>isp_buf_queue: queue 3 vb 3, mmu 1c3000

ISPCTRL: <1>isp_buf_process: finish 0 mmu 00001000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 4 vb 0, mmu 1000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 1 mmu 00097000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 5 vb 1, mmu 97000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 2 mmu 0012d000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 6 vb 2, mmu 12d000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 3 mmu 001c3000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 7 vb 3, mmu 1c3000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 4 mmu 00001000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 8 vb 0, mmu 1000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 5 mmu 00097000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 9 vb 1, mmu 97000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 6 mmu 0012d000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 10 vb 2, mmu 12d000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 7 mmu 001c3000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 11 vb 3, mmu 1c3000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 8 mmu 00001000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 12 vb 0, mmu 1000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 9 mmu 00097000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 13 vb 1, mmu 97000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 10 mmu 0012d000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 14 vb 2, mmu 12d000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 11 mmu 001c3000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 15 vb 3, mmu 1c3000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 12 mmu 00001000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 16 vb 0, mmu 1000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 13 mmu 00097000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 17 vb 1, mmu 97000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 14 mmu 0012d000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 18 vb 2, mmu 12d000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 15 mmu 001c3000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 19 vb 3, mmu 1c3000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 16 mmu 00001000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 20 vb 0, mmu 1000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 17 mmu 00097000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 21 vb 1, mmu 97000
vbuf: qbuf: succeded

ISPCTRL: <1>isp_buf_process: finish 18 mmu 0012d000
vbuf: dqbuf: state is done
vbuf: qbuf: requesting next field
ISPCTRL: <1>isp_buf_queue: queue 22 vb 2, mmu 12d000
vbuf: qbuf: succeded

----------------------------------------------------------------------------------------------------

 

I guess something is going wrong in the isp side.Can somebody please help me with this issue?

Thanks & Regards,

       Aparna