Hi,
Customer has some questions regarding to spinlock HW. In the TRM, we suggest when use the spinlock, the maximum hold time should be less than 200 CPU cycles. So we suggest using for share memory access protect only.
What happens if this time is larger than 200cycles? Will spinlock be unlocked?
Basically, they want to use spinlock to protect contention if multi cores want to use the peripheral. For example: several cores want to use the same FSI/UART to exchange information to external device.
1. Core1 takes spinlock. ( the take time should be less than 200cycles).
2. Core1 start transmission by using FSI/UART, this take more than 200 cycles.
3. Core2 to try to take spinlock during Core1 using FSI/UART. When happens? Since spinlock is locked more than 200 cycles, can core2 take spinlock?
If HW spinlock is not good for this purpose, what is our recommendation?
Regards
Andre