Post Go back to editing

ICPLBMissWithoutReplacement error -- while DMA memory transfer

Hi,

while i am working with my project, a strange problem occurring. I tried to trace the error. But could not find the error cause. But i narrowed down the part of the program which may be the cause of the error.

I wrote a simple program for BF609 with custom board in CCES 1.0.3. which do:

transfers memory from a L1  memory to another L1 memory through DMA21- DMA22 with autoflow mode.

while running this program with debug mode, after some minutes, a run time error occurs.

A fatal error or exception has occurred.

  Description:   An instruction CPLB miss has occurred without a corresponding CPLB entry.

  General Type:  RunTimeError

  Specific Type: ICPLBMissWithoutReplacement

  General Code:  0x8

  Specific Code: 0x321

  Error Value:   0x7fa00f32

  Error PC:      0x7fa00f32

Another strange thing is: if i disable the function  "adi_core_1_enable();", its running without any errors.

but core1 is do initialization and being in while loop doing nothing.

I have attached the c files,

Please someone help me.

attachments.zip
  • Hi  Sarathkumar,

    In order to find the exact cause of error and get further details you can do the following steps

    1) Check EXCAUSE field in  SEQSTAT register to find the Exception cause.

    2) The look over the EXCAUSE table  in Program Ref Manual in BF60x

    This will give you an exact reason of your error.

    I looked through you code, your interrupt handler does not adhere to function types defined in adi_int.h.

    and I suspect that may be causing this exception.

    You can get more details about Defining an Interrupt Handler in the Cross Core Help.

    // Interrupt Handler Prototype

    void MDMA22Handler(uint32_t iid, void* handlerArg) ;

    // Install handler

    adi_int_InstallHandler(INTR_MDMA0_DST, MDMA22Handler, NULL, true);

    //Defining Interrupt Handler

    void MDMA22Handler(uint32_t iid, void* handlerArg)

    {

    *pREG_DMA22_STAT=0x1;

    }

    Thanks,

    Akash

  • Thank you.

    I have tried it with modifying as you suggested. But same error occurring.

    If i disable core1, no such error occurs.

    and if i disable interrupt no error. so I agree interrupt part is causing the problem.

    if i pause the running program, it goes into the following,

    /*

    * These are the environment-specific interrupt wrappers.

    * I.e. these are the wrappers that are used for interrupts that

    * may call operating system APIs, and hence must support

    * rescheduling. In the no-RTOS OSAL they have essentially the

    * same implementation as the plain wrapper, since there is

    * no rescheduling in this environment. We let the compiler

    * generate the appropriate code for saving and restoring registers,

    * and for setting up the C runtime.

    */

    EX_DISPATCHED_HANDLER_NESTED(_adi_osal_stdWrapper, iid,  index, arg)

    {

        (_adi_osal_gHandlerTable[index])(iid, (void*) arg);

    }





    I could not understand these concepts.Please give me some hint about the problem and where to look.

  • Hi,

    I have tested the same code by running in BF609-EZKit lite. No such problem occurs.

    So I doubt in my custom board design. and also ,During the exception, stack pointer is corrupted. it is 0x7FA0 or 0xFBA0 instead of 0xFFA0.

    will it be there any power shortage or fluctuation causing the problem?

    Running core1 requires more current than being in Idle?

  • I found the problem causing the error.

    when i use only one core, no errors occur. and another core being in idle.

    If both cores enabled and any interrupt generated, after executing interrupt handler, reloading stack pointer is corrupted. I think this is because of current shortage to power the both cores resources.

    Thank you for the giving out the clues and support.