Commit 7bcacd88 authored by David S. Miller's avatar David S. Miller

[SPARC64]: Fix preempt handling in dec_and_lock.S

parent 141d73f7
......@@ -29,7 +29,7 @@
atomic_dec_and_lock: /* %o0 = counter, %o1 = lock */
loop1: lduw [%o0], %g5
subcc %g5, 1, %g7
be,pn %icc, to_zero
be,pn %icc, start_to_zero
nop
nzero: cas [%o0], %g5, %g7
cmp %g5, %g7
......@@ -40,6 +40,7 @@ out:
membar #StoreLoad | #StoreStore
retl
mov %g1, %o0
start_to_zero:
#ifdef CONFIG_PREEMPT
ldsw [%g6 + TI_PRE_COUNT], %g3
add %g3, 1, %g3
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment