Skip to content
Commit 50952026 authored by Ralf Baechle's avatar Ralf Baechle
Browse files

[MIPS] Fix bug in atomic_sub_if_positive.



The branch optimization fixes in 2.6.21 introduced a bug in
atomic_sub_if_positive that causes it to return even when the sc
instruction fails. The result is that e.g. down_trylock becomes unreliable
as the semaphore counter is not always decremented.

Original MUA-shredded patch from Morten Larsen <mlarsen@broadcom.com>.

Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
parent bf9127c3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment