NvBufferTransform ERROR

hi ,in my system , i use the nvbuffer api NvBufferTransform ,my sometimes it run a long time it will occure the follownig error:( my process is that caputre jpeg->dectoFd,then NvBufferTransform to other fd )

NvDdkVicExecute Failed
nvbuffer_transform Failed
Failed to convert the buffer
NvRmPrivFlush: NvRmChannelSubmit failed (err = 196623, SyncPointIdx = 7, SyncPointValue = 0)
fence_set_name ioctl failed with 22
NvDdkVicExecute Failed
nvbuffer_transform Failed
Failed to convert the buffer
NvRmPrivFlush: NvRmChannelSubmit failed (err = 196623, SyncPointIdx = 7, SyncPointValue = 0)
fence_set_name ioctl failed with 22
NvDdkVicExecute Failed
nvbuffer_transform Failed
Failed to convert the buffer
NvRmPrivFlush: NvRmChannelSubmit failed (err = 196623, SyncPointIdx = 7, SyncPointValue = 0)
fence_set_name ioctl failed with 22
NvDdkVicExecute Failed
nvbuffer_transform Failed
Failed to convert the buffer
NvRmPrivFlush: NvRmChannelSubmit failed (err = 196623, SyncPointIdx = 7, SyncPointValue = 0)
fence_set_name ioctl failed with 22
NvDdkVicExecute Failed
nvbuffer_transform Failed
Failed to convert the buffer
NvRmPrivFlush: NvRmChannelSubmit failed (err = 196623, SyncPointIdx = 7, SyncPointValue = 0)
fence_set_name ioctl failed with 22
NvDdkVicExecute Failed
nvbuffer_transform Failed
Failed to convert the buffer
NvRmPrivFlush: NvRmChannelSubmit failed (err = 196623, SyncPointIdx = 7, SyncPointValue = 0)
fence_set_name ioctl failed with 22

when the error occure i save the jpeg data,and then do a test individually like that dec it and NvBufferTransform to other fd,but it can dec and ttransform normally ,so i am confused

my app has 2 v4l2 cap jpeg ,and create 2 decoder

when the errors occure ,the NvBufferTransform function will be failed all the time ,and can not be recovery,so how can i do to fix it ?

Hi,

Which JetPack version do you use?
More, could you share a simple source for us to reproduce this?

Thanks.

hi AastaLLL,thanks for your help,my jetpack version is jetpack 4.4[L4T 32.4.3],my app system is not just for cap,dec, also have alg process ,so it is a little Complicatedly,so i have to do some other test for stability,because it sometimes run for 7~10days then will be occure,so it is reproduced difficultly,i want to know that may be what reason cause it?

Hi,
Are you able to upgrade to Jetpack4.5.1 and try? We have stability enhancement of hardware converter and may resolve this error case.

@ DaneLLL thanks for your help, i will do it ,after test i will feedback to you!!!

@DaneLLL , the jetpack4.5.1 we have to modify the device driver ,so it may be need more time ,now i found when the error occure ,i demsg found the error log :

*[85709.573769] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.598330] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.607931] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.630556] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.641296] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.677382] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.698453] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.709436] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.730336] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.766412] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.781268] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.798757] (NULL device ): nvhost_sync_fence_set_name: failed to get fence
*[85709.813333] (NULL device ): nvhost_sync_fence_set_name: failed to get fence

so what is the wrong with it ?

Hi,
Seems like certain fences are occupied and the NvBufferTransform() call cannot get one to access hardware converter. Not sure if it helps but you may try to cerate NvBufferSession and set to

  /** NvBufferSession to be used for transform. If NULL, the default session
   * is used. */
  NvBufferSession session;
}NvBufferTransformParams;

This should give better scheduling to access the hardware engine.

hi ,thanks for your help ,i have just modify that use the NvBufferSessionCreate function create session , and will test it ,if i have a result ,i will feedback to you!!!

@DaneLLL ,i do a test after NvBufferSessionCreate for about 7 hours the error occue,the dmesg info is following:
3.txt (127.8 KB)

Hi,
Are you able to try Jetpack 4.5.1?

Or may try to reboot the device when the issue occurs.

@DaneLLL thanks for your help ,update to Jetpack 4.5.1 need more time ,and i test found that may be conflict with my alg process or the qt display, also it is not friendly to reboot the device when the issue occurs,and i want to know how to get the return -1 for which error code,so i can get some reason

or what is wrong with err code 196623 NvRmPrivFlush: NvRmChannelSubmit failed (err = 196623, SyncPointIdx = 7, SyncPointValue = 0)

@DaneLLL ,hi ,i found my app have memory leak, but when the error occurs ,the memory still have more then 220M, so whether the error may be cause by the memory leak.