SPRUJ55D September 2023 ā July 2025 AM263P2 , AM263P2-Q1 , AM263P4 , AM263P4-Q1
This procedure configures the take and release (free) operations for the Spinlock module. A spinlock should only be held with interrupts disabled. So, before attempting to obtain the spinlock, software must disable interrupts. Then it must read the SPINLOCK_LOCK_REG_y[0] TAKEN bit to attempt to obtain the lock. If it succeeds, it must proceed directly through the critical section then unlock and re-enable interrupts. If the acquisition attempt fails, the acquisition must be reattempted. To prevent unknown interrupt disabled time, interrupts must be re-enabled and then disabled before reattempting to acquire the lock. Figure 8-5 shows the described above procedure.
Figure 8-5 Take and Release Spinlock| Register Name |
|---|
| SPINLOCK_LOCK_REG_y[0] TAKEN |
| Subprocess Name | Description |
|---|---|
| Disable (Mask) All Interrupts | For information about disabling/enabling all interrupts in an
ArmĀ® processor, refer to Arm Technical Reference Manual, available at infocenter.arm.com/help/index.jsp. For information about disabling/enabling all interrupts in other processors, refer to the corresponding processor chapter. |
| Enable (Unmask) All Interrupts |