+ s390-fix-in-user-atomic-futex-operation.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     s390: fix in-user atomic futex operation.

has been added to the -mm tree.  Its filename is

     s390-fix-in-user-atomic-futex-operation.patch

See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this

------------------------------------------------------
Subject: s390: fix in-user atomic futex operation.
From: Martin Schwidefsky <schwidefsky@xxxxxxxxxx>


__futex_atomic_op needs to do an atomic operation in the user address space,
not the kernel address space.  Add the missing sacf 256/sacf 0 to switch to
the secondary mode before doing the compare-and-swap.  In addition add
another fixup for catch specification exceptions if the compare-and-swap
address is not aligned.

Signed-off-by: Martin Schwidefsky <schwidefsky@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 include/asm-s390/futex.h |   15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff -puN include/asm-s390/futex.h~s390-fix-in-user-atomic-futex-operation include/asm-s390/futex.h
--- devel/include/asm-s390/futex.h~s390-fix-in-user-atomic-futex-operation	2006-06-08 01:33:53.000000000 -0700
+++ devel-akpm/include/asm-s390/futex.h	2006-06-08 01:33:53.000000000 -0700
@@ -11,23 +11,24 @@
 #define __futex_atomic_fixup \
 		     ".section __ex_table,\"a\"\n"			\
 		     "   .align 4\n"					\
-		     "   .long  0b,2b,1b,2b\n"				\
+		     "   .long  0b,4b,2b,4b,3b,4b\n"			\
 		     ".previous"
 #else /* __s390x__ */
 #define __futex_atomic_fixup \
 		     ".section __ex_table,\"a\"\n"			\
 		     "   .align 8\n"					\
-		     "   .quad  0b,2b,1b,2b\n"				\
+		     "   .quad  0b,4b,2b,4b,3b,4b\n"			\
 		     ".previous"
 #endif /* __s390x__ */
 
 #define __futex_atomic_op(insn, ret, oldval, newval, uaddr, oparg)	\
-	asm volatile("   l   %1,0(%6)\n"				\
-		     "0: " insn						\
-		     "   cs  %1,%2,0(%6)\n"				\
-		     "1: jl  0b\n"					\
+	asm volatile("   sacf 256\n"					\
+		     "0: l   %1,0(%6)\n"				\
+		     "1: " insn						\
+		     "2: cs  %1,%2,0(%6)\n"				\
+		     "3: jl  1b\n"					\
 		     "   lhi %0,0\n"					\
-		     "2:\n"						\
+		     "4: sacf 0\n"					\
 		     __futex_atomic_fixup				\
 		     : "=d" (ret), "=&d" (oldval), "=&d" (newval),	\
 		       "=m" (*uaddr)					\
_

Patches currently in -mm which might be from schwidefsky@xxxxxxxxxx are

s390-fix-in-user-atomic-futex-operation.patch
s390-cleanup-bitopsh.patch
create-sys-hypervisor-when-needed.patch
s390_hypfs-filesystem.patch
swapless-pm-add-r-w-migration-entries-fix.patch
adjust-handle_irr_event-return-type.patch
define-__raw_get_cpu_var-and-use-it.patch
lock-validator-add-per_cpu_offset-fix.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux