linux/arch/s390/lib
Michel Lespinasse 37a9d912b2 futex: Sanitize cmpxchg_futex_value_locked API
The cmpxchg_futex_value_locked API was funny in that it returned either
the original, user-exposed futex value OR an error code such as -EFAULT.
This was confusing at best, and could be a source of livelocks in places
that retry the cmpxchg_futex_value_locked after trying to fix the issue
by running fault_in_user_writeable().
    
This change makes the cmpxchg_futex_value_locked API more similar to the
get_futex_value_locked one, returning an error code and updating the
original value through a reference argument.
    
Signed-off-by: Michel Lespinasse <walken@google.com>
Acked-by: Chris Metcalf <cmetcalf@tilera.com>  [tile]
Acked-by: Tony Luck <tony.luck@intel.com>  [ia64]
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Michal Simek <monstr@monstr.eu>  [microblaze]
Acked-by: David Howells <dhowells@redhat.com> [frv]
Cc: Darren Hart <darren@dvhart.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Matt Turner <mattst88@gmail.com>
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
LKML-Reference: <20110311024851.GC26122@google.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2011-03-11 12:23:08 +01:00
..
delay.c [S390] time: let local_tick_enable/disable() reprogram the clock comparator 2011-01-05 12:47:25 +01:00
div64.c [S390] __div64_31 broken for CONFIG_MARCH_G5 2009-03-18 13:28:12 +01:00
Makefile [S390] uaccess: make sure copy_from_user_overflow is builtin 2010-03-08 12:25:29 +01:00
qrnnd.S [S390] Calibrate delay and bogomips. 2007-02-05 21:18:31 +01:00
spinlock.c [S390] spinlock: check virtual cpu running status 2010-02-26 22:37:31 +01:00
string.c [S390] use compiler builtin versions of strlen/strcpy/strcat 2009-03-26 15:24:24 +01:00
uaccess_mvcos.c [S390] Improve address space mode selection. 2009-12-07 12:51:33 +01:00
uaccess_pt.c futex: Sanitize cmpxchg_futex_value_locked API 2011-03-11 12:23:08 +01:00
uaccess_std.c futex: Sanitize cmpxchg_futex_value_locked API 2011-03-11 12:23:08 +01:00
uaccess.h futex: Sanitize cmpxchg_futex_value_locked API 2011-03-11 12:23:08 +01:00
ucmpdi2.c [S390] add __ucmpdi2() helper function 2009-07-07 16:37:53 +02:00
usercopy.c [S390] uaccess: implement strict user copy checks 2010-02-26 22:37:29 +01:00