Part Number: J784S4XEVM
Hello,
I have a question regarding an intermittent CSI UDMA-related error.
(SDK Version : RTOS 11.01, Linux: 11.01)
(boot_app Boot Mode)
During CSI testing, I am running repeated reboot tests, and I occasionally see a UDMA-related error.
In my implementation, the RX task initializes UDMA, and the TX task only uses the UDMA handle initialized by the RX task.
// RX Task
static int32_t CsirxApp_init(Csi_commonObj* appCommonObj)
{
int32_t retVal = FVID2_SOK, dmaStatus = UDMA_SOK;
Udma_DrvHandle drvHandle;
Udma_InitPrms udmaInitPrms;
Fvid2_InitPrms initPrms;
/* Fvid2 init */
Fvid2InitPrms_init(&initPrms);
initPrms.printFxn = &App_fvidPrint;
retVal = Fvid2_init(&initPrms);
if (FVID2_SOK != retVal)
{
GT_0trace(CsirxAppTrace, GT_ERR,
APP_RX_NAME ": Fvid2 Init Failed!!!\r\n");
}
drvHandle = &appCommonObj->udmaDrvObj;
UdmaInitPrms_init(UDMA_INST_ID_BCDMA_0, &udmaInitPrms);
udmaInitPrms.printFxn = &App_dmaPrint;
dmaStatus = Udma_init(drvHandle, &udmaInitPrms);
if(UDMA_SOK != dmaStatus)
{
retVal = FVID2_EFAIL;
GT_0trace(CsirxAppTrace, GT_ERR,
APP_RX_NAME ": UDMA Init Failed!!!\r\n");
}
// TX Task
static int32_t CsitxApp_init(Csi_commonObj* appCommonObj)
{
int32_t retVal = FVID2_SOK;
Udma_DrvHandle drvHandle;
Csitx_initParamsInit(&appCommonObj->txinitPrms);
drvHandle = &appCommonObj->udmaDrvObj;
appCommonObj->txinitPrms.drvHandle = drvHandle;
retVal = Csitx_init(&appCommonObj->txinitPrms);
if (FVID2_SOK != retVal)
{
GT_0trace(AppTrace, GT_ERR,
APP_TX_NAME ": System Init Failed!!!\r\n");
}
return (retVal);
}
The TX task waits for the RX initialization using Semaphore_pend().
After the RX task completes initialization, it sends Semaphore_post() to the TX task and then calls Fvid2_start().
Once the TX task receives the semaphore from the RX task, it proceeds with its own initialization and then calls Fvid2_start().
The error message is shown below.
There is no fixed pattern, but it occurs roughly once after about 30 reboot test cycles.
CSI_RX_TASK:===================Setup Details===================
csi/csi_rx_func.c @ Line 338: CSI_RX_TASK: Three Capture Instance 0, 1, 2 instance
CSI_RX_TASK: Capture DF:0x2a
CSI_RX_TASK: Capture Resolution:1024 x 131
CSI_RX_TASK:===================================================
Clock Freq: CSITX_MOD_ESC_CLK = 20000000Hz
Clock Freq: CSITX_MOD_DPHY_TXBYTECLKHS_CLK = 0Hz
Clock Freq: CSITX_MOD_VBUS_CLK = 250000000Hz
Clock Freq: CSITX_MOD_MAIN_CLK = 500000000Hz
CSI_RX_TASK:Set D-PHY Configuration Successful for CSIRX instance 0!!!
CSI_RX_TASK:Error Events Registration Successful for CSIRX instance 0!!!
CSI_RX_TASK: CSIRX Capture created for CSIRX instance 0
CSI_RX_TASK:Set D-PHY Configuration Successful for CSIRX instance 1!!!
CSI_RX_TASK:Error Events Registration Successful for CSIRX instance 1!!!
CSI_RX_TASK: CSIRX Capture created for CSIRX instance 1
CSI_RX_TASK:Set D-PHY Configuration Successful for CSIRX instance 2!!!
CSI_RX_TASK:Error Events Registration Successful for CSIRX instance 2!!!
CSI_RX_TASK: CSIRX Capture created for CSIRX instance 2
[UDMA] [Error] Sciclient event config failed!!!
[UDMA] [Error] Event config failed!!
[UDMA] Assertion @ Line: 991 in src/udma_event.c: (UDMA_EVENT_INVALID != vintrNum) : failed !!!
[UDMA] [Error] Sciclient event config failed!!!
[UDMA] [Error] Event config failed!!
src/csitx_drvUdma.c @ Line 332: [ERROR]UDMA CQ event register FAILED!!!
src/csitx_drv.c @ Line 345: Instance create failed!!!
src/csitx_drv.c @ Line 1392: [ERROR]UDMA channel close FAILED!!!
src/csitx_drv.c @ Line 1392: [ERROR]UDMA channel close FAILED!!!
src/csitx_drv.c @ Line 1392: [ERROR]UDMA channel close FAILED!!!
src/csitx_drv.c @ Line 1392: [ERROR]UDMA channel close FAILED!!!
src/csitx_drv.c @ Line 376: Create failed for given configuration
src/fvid2_drvMgr.c @ Line 777: Driver create failed!!
Could you please advise what might be causing this issue, or if there is any recommended solution or workaround?