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.

Vdec_requestBitstreamBuffer error



hi, I use dvrrdk4.0..0.3 on DM8168, my usecat is vdec_vdis. DDR3 run 531Mhz.

DM8168 decode a single 1080@60 bitstream reading from file.At the begin, decodeing and displaying are good. But after about half minute, Vdec_requestBitstreamBuffer return error. Here is the Vsys_printBufferStatistics and Vsys_printDetailedStatistics print.It seems buffer runing out. Thanks.


 IPCBITSOUTLINK:Buffer Statistics
 Num Channels:10
 ChId | TotalBufCnt | FreeBufCnt | BufSize | AppAllocCount
       0|           50|          0| 2088960|            0
       1|            0|          0| 2088960|            0
       2|            0|          0| 2088960|            0
       3|            0|          0| 2088960|            0
       4|            0|          0| 2088960|            0
       5|            0|          0| 2088960|            0
       6|            0|          0| 2088960|            0
       7|            0|          0| 2088960|            0
       8|            0|          0|  414720|            0
       9|            0|          0|  414720|            0

 VDEC:Buffer Statistics
 ChId | InBufCnt | OutBufCnt
     0|        49|         5
     1|         0|         5
     2|         0|         5
     3|         0|         5
     4|         0|         5
     5|         0|         5
     6|         0|         5
     7|         0|         5
     8|         0|         5
     9|         0|         5
 [m3vpss ] 
 [m3vpss ]  *** [SWMS0] Mosaic Statistics ***
 [m3vpss ] 7506046: SWMS: Rcvd from prev = 0, Returned to prev = 2411
 [m3vpss ] SWMS Out  Buf Q Status
 [m3vpss ] Empty Q -> count 3, wrPtr 235, rdPtr 232
 [m3vpss ] Full Q -> count 1, wrPtr 232, rdPtr 231
 [m3vpss ] 
 [m3vpss ]  *** [SWMS1] Mosaic Statistics ***
 [m3vpss ] 7506047: SWMS: Rcvd from prev = 0, Returned to prev = 2408
 [m3vpss ] SWMS Out  Buf Q Status
 [m3vpss ] Empty Q -> count 3, wrPtr 232, rdPtr 229
 [m3vpss ] Full Q -> count 1, wrPtr 229, rdPtr 228
 [m3vpss ] 
 [m3vpss ]  *** Display Statistics ***
 [m3vpss ] 7506047: DISPLAY: Rcvd from prev = 2919, Returned to prev = 2916, BufsInDriver = 5
 [m3vpss ] 
 [m3vpss ]  *** Display Statistics ***
 [m3vpss ] 7506048: DISPLAY: Rcvd from prev = 2917, Returned to prev = 2914, BufsInDriver = 5
 [m3vpss ] 
 [m3vpss ]  *** [MP_SCLR0 ] Statistics ***
 [m3vpss ] 
 [m3vpss ]  Total Frames Received  : 2462
 [m3vpss ]  Total Frames Forwarded : 2462
 [m3vpss ] 
 [m3vpss ] 
 [m3vpss ]  CH  | In Recv In Reject Processed  Latency(DRV) Processed  Rejected
 [m3vpss ]  Num | FPS     FPS       FPS        Min / Max    Frames     Frames 
 [m3vpss ]  -------------------------------------------------------------------
 [m3vpss ] 
 [m3vpss ]  *** [SWMS0] Mosaic Statistics ***
 [m3vpss ] 
 [m3vpss ]  Elasped Time: 49 secs
 [m3vpss ] 
 [m3vpss ]  Output Request FPS   : 60 fps (2981 frames)
 [m3vpss ]  Output Actual  FPS   : 60 fps (2981 frames)
 [m3vpss ]  Output Drop    FPS   : 0 fps (0 frames)
 [m3vpss ]  Output Reject  FPS   : 0 fps (0 frames)
 [m3vpss ]  Scaling Internal     : 16 ms
 [m3vpss ]  Scaling Internal min : 16 ms
 [m3vpss ]  Scaling Internal max : 17 ms
 [m3vpss ] 
 [m3vpss ]  Win | Window Repeat Drop Recv Que  FID Invlid Acc Event          Invalid   Que Reject Reject Latency   OutBufCopy InBufCopy
 [m3vpss ]  Num | FPS    FPS    FPS  FPS  FPS  FPS        Count (Max/Min)    CH Frames Frames     Frames Min / Max FPS        FPS     
 [m3vpss ]  ---------------------------------------------------------------------------------------------------------------------------
 [m3vpss ]    0 |      0     60    0    0    0          0        0 (  0/255)         0          0      0 65535 /   0         60         0
 [m3vpss ] 
 [m3vpss ] 
 [m3vpss ]  *** [SWMS0] Mosaic Parameters ***
 [m3vpss ] 
 [m3vpss ]  Output FPS: 60
 [m3vpss ] 
 [m3vpss ]  Win | Ch  | Input      | Input          | Input         | Input       | Output     |  Output         | Output        | Output      | Low Cost | SWMS | Data  | Blank |
 [m3vpss ]  Num | Num | Start X, Y | Width x Height | Pitch Y / C   | Memory Type | Start X, Y |  Width x Height | Pitch Y / C   | Memory Type | ON / OFF | Inst | Format| Frame |
 [m3vpss ]  ----------------------------------------------------------------------------------------------------------------------------------------------------------------------
 [m3vpss ]    0 |   9 |    0,    0 |   720 x    576 |   896 /   896 | NON-TILED   |    0,    0 |  1920 x   1080 |  3840 /      0 | NON-TILED   |      OFF |    0 |  420SP |    ON |
 [m3vpss ] 
 [m3vpss ] 
 [m3vpss ] 
 [m3vpss ]  *** [SWMS1] Mosaic Statistics ***
 [m3vpss ] 
 [m3vpss ]  Elasped Time: 41 secs
 [m3vpss ] 
 [m3vpss ]  Output Request FPS   : 60 fps (2470 frames)
 [m3vpss ]  Output Actual  FPS   : 60 fps (2470 frames)
 [m3vpss ]  Output Drop    FPS   : 0 fps (0 frames)
 [m3vpss ]  Output Reject  FPS   : 0 fps (0 frames)
 [m3vpss ]  Scaling Internal     : 16 ms
 [m3vpss ]  Scaling Internal min : 16 ms
 [m3vpss ]  Scaling Internal max : 17 ms
 [m3vpss ] 
 [m3vpss ]  Win | Window Repeat Drop Recv Que  FID Invlid Acc Event          Invalid   Que Reject Reject Latency   OutBufCopy InBufCopy
 [m3vpss ]  Num | FPS    FPS    FPS  FPS  FPS  FPS        Count (Max/Min)    CH Frames Frames     Frames Min / Max FPS        FPS     
 [m3vpss ]  ---------------------------------------------------------------------------------------------------------------------------
 [m3vpss ]    0 |     60      0    0   60   60          0        0 (  0/255)         0          0      0 11736 / 52884          0         0
 [m3vpss ] 
 [m3vpss ] 
 [m3vpss ]  *** [SWMS1] Mosaic Parameters ***
 [m3vpss ] 
 [m3vpss ]  Output FPS: 60
 [m3vpss ] 
 [m3vpss ]  Win | Ch  | Input      | Input          | Input         | Input       | Output     |  Output         | Output        | Output      | Low Cost | SWMS | Data  | Blank |
 [m3vpss ]  Num | Num | Start X, Y | Width x Height | Pitch Y / C   | Memory Type | Start X, Y |  Width x Height | Pitch Y / C   | Memory Type | ON / OFF | Inst | Format| Frame |
 [m3vpss ]  ----------------------------------------------------------------------------------------------------------------------------------------------------------------------
 [m3vpss ]    0 |   0 |    0,    0 |  1920 x   1080 |  2176 /  2176 | NON-TILED   |    0,    0 |  1920 x   1080 |  3840 /      0 | NON-TILED   |      OFF |    0 |  420SP |   OFF |
 [m3vpss ] 
 [m3vpss ] 
 [m3vpss ]  7507056: DISPLAY: HDDAC(BP0) : 59 fps, Latency (Min / Max) = ( 66 / 69 ), Callback Interval (Min / Max) = ( 16 / 17 ) DropCount:0 DispLatency (Min / Max) = ( 46 / 63 ) !!!
 [m3vpss ]  7507056: DISPLAY DRV: HDDAC(BP0) : Q:[2982] Display:[2988], Repeat:[8], DQ:[2979]
 [m3vpss ]  7507056: DISPLAY: UNDERFLOW COUNT: HDMI(BP0) 2986, HDDAC(BP0) 2988, DVO2(BP1) 2988, SDDAC(SEC1) 2988
 [m3vpss ]  7507056: SYSTEM  : FREE SPACE : System Heap      = 67336 B, Mbx = 10239 msgs)
 [m3vpss ]  7507056: SYSTEM  : FREE SPACE : SR0 Heap         = 5188096 B (4 MB)
 [m3vpss ]  7507056: SYSTEM  : FREE SPACE : Frame Buffer     = 210080640 B (200 MB)
 [m3vpss ]  7507056: SYSTEM  : FREE SPACE : Bitstream Buffer = 142258048 B (135 MB)
 [m3vpss ]  7507057: SYSTEM  : FREE SPACE : Tiler Buffer     = 224 B (0 MB)  - TILER OFF
 [m3vpss ]  7507057: DISPLAY: DVO2(BP1)  : 59 fps, Latency (Min / Max) = ( 66 / 101 ), Callback Interval (Min / Max) = ( 16 / 17 ) DropCount:0 DispLatency (Min / Max) = ( 49 / 83 ) !!!
 [m3vpss ]  7507057: DISPLAY DRV: DVO2(BP1)  : Q:[2979] Display:[2984], Repeat:[7], DQ:[2976]
 [m3video]      7513057: HDVICP-ID:0
 [m3video] All percentage figures are based off totalElapsedTime
 [m3video]               totalAcquire2wait :0 %
 [m3video]               totalWait2Isr :52 %
 [m3video]               totalIsr2Done :0 %
 [m3video]               totalWait2Done :52 %
 [m3video]               totalDone2Release :0 %
 [m3video]               totalAcquire2Release :53 %
 [m3video]               totalAcq2acqDelay :46 %
 [m3video]               totalElapsedTime in msec :   48508
 [m3video]               numAccessCnt:    2467
 [m3video]              IVA-FPS :      51
 [m3video]              Average time spent per frame in microsec:   10224
 [m3video]      7513058: HDVICP-ID:1
 [m3video] All percentage figures are based off totalElapsedTime
 [m3video]               totalAcquire2wait :1 %
 [m3video]               totalWait2Isr :0 %
 [m3video]               totalIsr2Done :0 %
 [m3video]               totalWait2Done :0 %
 [m3video]               totalDone2Release :0 %
 [m3video]               totalAcquire2Release :1 %
 [m3video]               totalAcq2acqDelay :98 %
 [m3video]               totalElapsedTime in msec :     154
 [m3video]               numAccessCnt:       5
 [m3video]              IVA-FPS :       0
 [m3video]              Average time spent per frame in microsec:       0
 [m3video]      7513059: HDVICP-ID:2
 [m3video] All percentage figures are based off totalElapsedTime
 [m3video]               totalAcquire2wait :0 %
 [m3video]               totalWait2Isr :0 %
 [m3video]               totalIsr2Done :0 %
 [m3video]               totalWait2Done :0 %
 [m3video]               totalDone2Release :0 %
 [m3video]               totalAcquire2Release :0 %
 [m3video]               totalAcq2acqDelay :0 %
 [m3video]               totalElapsedTime in msec :       0
 [m3video]               numAccessCnt:       0
 [m3video]              IVA-FPS :       0
 [m3video]              Average time spent per frame in microsec:       0
 [m3video] 
 [m3video]  *** DECODE Statistics ***
 [m3video] 
 [m3video]  Elasped Time           : 47 secs
 [m3video] 
 [m3video] 
 [m3video]  CH  | In Recv In User  Out
 [m3video]  Num | FPS     Skip FPS FPS
 [m3video]  -----------------------------------
 [m3video]    0 |      52        0  52
 [m3video]    1 |       0        0   0
 [m3video]    2 |       0        0   0
 [m3video]    3 |       0        0   0
 [m3video]    4 |       0        0   0
 [m3video]    5 |       0        0   0
 [m3video]    6 |       0        0   0
 [m3video]    7 |       0        0   0
 [m3video]    8 |       0        0   0
 [m3video]    9 |       0        0   0
 [m3video] 
 [m3video] Multi Channel Decode Average Submit Batch Size
 [m3video] Max Submit Batch Size : 24
 [m3video] IVAHD_0 Average Batch Size : 1
 [m3video] IVAHD_0 Max achieved Batch Size : 1
 [m3video] IVAHD_1 Average Batch Size : 0
 [m3video] IVAHD_1 Max achieved Batch Size : 0
 [m3video] IVAHD_2 Average Batch Size : 0
 [m3video] IVAHD_2 Max achieved Batch Size : 0
 [m3video] 
 [m3video] Multi Channel Decode Batch break Stats
 [m3video] Total Number of Batches created: 2459
 [m3video] All numbers are based off total number of Batches created
 [m3video]       Batch breaks due to batch sizeexceeding limit: 100 %
 [m3video]       Batch breaks due to ReqObj Que being empty: 0 %
 [m3video]       Batch breaks due to changed resolution class: 0 %
 [m3video]       Batch breaks due to interlace and progressivecontent mix: 0 %
 [m3video]       Batch breaks due to channel repeat: 0 %
 [m3video]       Batch breaks due to different codec: 0 %
 [m3video] Total Number of Batches created: 0
 [m3video] All numbers are based off total number of Batches created
 [m3video]       Batch breaks due to batch sizeexceeding limit: 0 %
 [m3video]       Batch breaks due to ReqObj Que being empty: 0 %
 [m3video]       Batch breaks due to changed resolution class: 0 %
 [m3video]       Batch breaks due to interlace and progressivecontent mix: 0 %
 [m3video]       Batch breaks due to channel repeat: 0 %
 [m3video]       Batch breaks due to different codec: 0 %
 [m3video] Total Number of Batches created: 0
 [m3video] All numbers are based off total number of Batches created
 [m3video]       Batch breaks due to batch sizeexceeding limit: 0 %
 [m3video]       Batch breaks due to ReqObj Que being empty: 0 %
 [m3video]       Batch breaks due to changed resolution class: 0 %
 [m3video]       Batch breaks due to interlace and progressivecontent mix: 0 %
 [m3video]       Batch breaks due to channel repeat: 0 %
 [m3video]       Batch breaks due to different codec: 0 %
 [m3video] 
 [m3vpss ] 
 [m3vpss ]  7516064: LOAD: CPU: 8.9% HWI: 2.4%, SWI:1.2%
 [m3vpss ] 
 [m3vpss ]  7516064: LOAD: TSK: IPC_IN_M30          : 0.2%
 [m3vpss ]  7516064: LOAD: TSK: DISPLAY0            : 0.6%
 [m3vpss ]  7516064: LOAD: TSK: DISPLAY1            : 0.5%
 [m3vpss ]  7516064: LOAD: TSK: DUP0                : 0.2%
 [m3vpss ]  7516064: LOAD: TSK: SWMS0               : 1.4%
 [m3vpss ]  7516065: LOAD: TSK: SWMS1               : 1.7%
 [m3vpss ]  7516065: LOAD: TSK: MP_SCLR_FWD_Q0      : 0.2%
 [m3vpss ]  7516065: LOAD: TSK: MISC                : 0.5%
 [m3vpss ] 
 [m3video] 
 [m3video]  7516566: LOAD: CPU: 5.7% HWI: 0.7%, SWI:0.8%
 [m3video] 
 [m3video]  7516566: LOAD: TSK: IPC_OUT_M30         : 0.6%
 [m3video]  7516567: LOAD: TSK: IPC_BITS_IN0        : 0.3%
 [m3video]  7516567: LOAD: TSK: DEC0                : 2.0%
 [m3video]  7516567: LOAD: TSK: DEC_PROCESS_TSK_0   : 1.2%
 [m3video]  7516567: LOAD: TSK: MISC                : 0.1%
 [m3video] 
 [c6xdsp ] 
 [c6xdsp ]  7516086: LOAD: CPU: 0.1% HWI: 0.0%, SWI:0.0%
 [c6xdsp ] 
 [c6xdsp ]  7516086: LOAD: TSK: MISC                : 0.1%
 [c6xdsp ] 

 

  • The logs don't show any issue. The display is consuming frames at 60 fps correctly. Your application is probably feeding frames at a faster rate. Vdec_requestBitstream returning no buffers is not an error condition.It just means there are no free buffers. Your application should sleep and retry until you get free buffer. One thing you could check is disable avsync

    /dvr_rdk/mcfw/src_linux/mcfw_api/usecases/ti81xx/multich_vdec_vdis.c

    mulich_vdec_vdis_set_avsync_vidque_prm

    change

    queCfg->avsyncEnable = TRUE;

    to

    queCfg->avsyncEnable = FALSE;