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.

TDA2EXEVM: Spinlock issue in Multi-EVE processors platform

Part Number: TDA2EXEVM

Hi,

I'm working on application development for multi EVE scenario using data partitioning of a task approach.(Using SYS/BIOS task )

 we have used spinlock for synchronizing  the processes running on multiple EVE processors. Problem here is up to certain implementation spinlock for synchronization is working between EVE1, EVE1 and EVE3 after it either EVE2 or EVE1 only will acquire the lock and releases till the end of algorithm execution and EVE3 will be waiting to get the lock hence EVE3 core execution is getting stuck..

we are unable to find the route cause since it works till certain implementation and suddenly we observing this behavior. Please let us know what are all the factors we need to consider while using spinlock in multi-EVE scenario.

Below are the function which we using to acquire and release  the lock on processors.

#define SPINLOCK_ID (40U)
#define SOC_SPINLOCK_BASE (0x4a0f6000U)

void multicoreLockAcquire() // To acquire the lock
{
      uint32_t status = 1U;
      uint32_t baseAddr = SOC_SPINLOCK_BASE;
      uint32_t spinLockId = SPINLOCK_ID;

      while (0U != status)
    {
         status = SPINLOCKLockStatusSet(baseAddr, spinLockId);
         //printf("Spinning in a while loop of Lock fun status = %d \n", status);
    }

}

void multicoreLockRelease() // To release the lock
{
   uint32_t baseAddr = SOC_SPINLOCK_BASE;
   uint32_t spinLockId = SPINLOCK_ID;
   SPINLOCKLockStatusFree(baseAddr, spinLockId);

}

Regards,
Manavi H V