Skip to content
Commit 01d69a82 authored by Tony Luck's avatar Tony Luck
Browse files

[IA64] Fix 64-bit atomic routines to return "long"



These have been broken (returning "int") since the dawn of
time. But there were no users that needed the whole value
until commit
 424acaae
 rwsem: wake queued readers when writer blocks on active read lock

made this change:

-           (rwsem_atomic_update(0, sem) & RWSEM_ACTIVE_MASK))
-               /* Someone grabbed the sem already */
+           rwsem_atomic_update(0, sem) < RWSEM_WAITING_BIAS)
+               /* Someone grabbed the sem for write already */

RWSEM_ACTIVE_MASK is 0xffffffffL, so the old code only looked
at the low order 32-bits. The new code needs to see all 64 bits.

Signed-off-by: default avatarTony Luck <tony.luck@intel.com>
parent ad41a1e0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment