NPA_Xchg

Atomic exchange function for multiprocessor (MP) safe operation.

Thread Context:Non-Blocking

Syntax

    LONG NPA_Xchg (
       LONG  *value1,
       LONG   value2
    );
    
    

Parameters

value1
(IN) Points to the value to be updated.
value2
(IN) The 32-bit value intended for value1.

Return Values

The original 32-bit value from value1.

Remarks

Stores value2 at the address specified by value1, and returns the original quantity pointed to by value1.