NPA_SpinLock

Acquires a specified spin lock to allow multiprocessor (MP) safe operations on shared data.

Thread Context:Non-Blocking

Syntax

    void NPA_SpinLock (
       LONG  *lockStatus
       );
     
    

Parameters

lockStatus
(IN) Address of the spin lock to be acquired.

Remarks

Must be initialized using NPA_SpinLockInit before using it.Cannot be used recursively.

Thread should not attempt to acquire an already acquired lock or the system deadlocks.

A TryLock can be used to avoid deadlocks.

If a spin lock is used by both process time and interrupt time code, the process time code should use NPA_SpinLockDisable to avoid deadlocks with the interrupt time code.