From: Nick Piggin Date: Thu, 23 Mar 2006 11:01:02 +0000 (-0800) Subject: [PATCH] atomic: add_unless cmpxchg optimise X-Git-Tag: v2.6.17-rc1~1006 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0b2fcfdb8b4e7e379192f24ea2203163ddf5df1d;p=pandora-kernel.git [PATCH] atomic: add_unless cmpxchg optimise Without branch hints, the very unlikely chance of the loop repeating due to cmpxchg failure is unrolled with gcc-4 that I have tested. Improve this for architectures with a native cas/cmpxchg. llsc archs should try to implement this natively. Signed-off-by: Nick Piggin Cc: Andi Kleen Cc: Martin Schwidefsky Cc: Heiko Carstens Cc: "David S. Miller" Cc: Roman Zippel Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed