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.

TDA4VM: Processors forum

Part Number: TDA4VM

[background]
The Question is related with TIOVX and shared memory allocator.
We have got an issue which is hard to reproduce (<5%): the pipeline of surround camera view has encountered a memory failure, which resulted in a black screen issue from vehicle market. details:
From app log, we can see the return value was(-8)VX_ERROR_NO_MEMORY) when TIOVX API vxVerifyGraph was called but no any other available log(vx_print of TIOVX has been disabled)
The internal process of vxVerifyGraph mainly apply necessary shared memory for pipelining.
But no any error slog, just some initiated log like:
"Jan 01 08:00:00.212 shmemallocator.73741 SharedMemoryAllocator: BaseAddress: 0xb8000000 Size: 0x2a000000 (704643072)"

[question]
If no error log from SharedMemoryAllocator, does it mean the issue is not related with shared memory? details:
We have checked the source code of SharedMemoryAllocator,
int SHM_alloc(int size, shm_buf *buf)
{
....
ioctl (shmHandler, CMD_SHMALLOCATOR_ALLOC, &cmdArgs); ---->①
status = cmdArgs.apiStatus;
if (status < 0) {
slogf (42, _SLOG_DEBUG1, "\nSHM_alloc: IOCTL Failed \n"); ---->②
deinitSHMHandler(shmHandler);
return status;
}
else {
buf->phy_addr = cmdArgs.result.phy_addr;
buf->vir_addr = cmdArgs.result.vir_addr; ---->③
buf->blockID = cmdArgs.result.blockID;
buf->size = cmdArgs.result.size;
buf->pid = getpid();
}
}
please referece mark①②: the return value of ioctl has not been checked but using apiStatus.
Q1. if ioctl returns abnormal value, how about the value of cmdArgs? Dose it means phy_addr/ vir_addr are NULL but no logging.
Is the case possible or would never happen?

please referece mark③
Q2. if ① is ok(apiStatus=0), there might be another case: phy_addr is valid but vir_addr is NULL.
If it happens, whether other abnormal log of virtual mapping MUST be output or not?

 

  • Hi,

    Could you please provide which TI SDK is being used.

    Regarding theory that issue may be memory related, first area recommended to be checked is the memory layout for the system.   Please review the output from

    1.  ./platform/j721e/rtos/system_memory_map.html, to get remote cores view of the memory
    2.  The output from "pidin syspage=asinfo", to get QNX HLOS view of available memory.

    and ensure they are in alignment/agreement.

    Regarding (2), some links which contribute to the QNX view of memory layout:

    The below screen shot, from above links, would be where to focus for the shared memory.

    One other item to check would be that buffers being freed correctly and in a timely fashion, and/or is there enough space which has been allocated to handle the worst case of buffers which are in use.

    Stepping back and looking at other possibilities outside of memory, is issue able to be recreated with the tiovx logging enabled? 

    Regards,

    kb