NFSv4: Remove BKL from the nfsv4 state recovery
[pandora-kernel.git] / arch / s390 / kernel / binfmt_elf32.c
index 9565a2d..3e1c315 100644 (file)
@@ -134,6 +134,7 @@ static inline int dump_task_fpu(struct task_struct *tsk, elf_fpregset_t *fpregs)
 }
 
 #include <asm/processor.h>
+#include <asm/pgalloc.h>
 #include <linux/module.h>
 #include <linux/elfcore.h>
 #include <linux/binfmts.h>
@@ -176,7 +177,6 @@ struct elf_prpsinfo32
 
 #include <linux/highuid.h>
 
-#define elf_addr_t     u32
 /*
 #define init_elf_binfmt init_elf32_binfmt
 */
@@ -184,6 +184,16 @@ struct elf_prpsinfo32
 #undef start_thread
 #define start_thread                    start_thread31 
 
+static inline void start_thread31(struct pt_regs *regs, unsigned long new_psw,
+                                 unsigned long new_stackp)
+{
+       set_fs(USER_DS);
+       regs->psw.mask  = psw_user32_bits;
+       regs->psw.addr  = new_psw;
+       regs->gprs[15]  = new_stackp;
+       crst_table_downgrade(current->mm, 1UL << 31);
+}
+
 MODULE_DESCRIPTION("Binary format loader for compatibility with 32bit Linux for S390 binaries,"
                    " Copyright 2000 IBM Corporation"); 
 MODULE_AUTHOR("Gerhard Tonn <ton@de.ibm.com>");
@@ -193,7 +203,7 @@ MODULE_AUTHOR("Gerhard Tonn <ton@de.ibm.com>");
 
 #undef cputime_to_timeval
 #define cputime_to_timeval cputime_to_compat_timeval
-static __inline__ void
+static inline void
 cputime_to_compat_timeval(const cputime_t cputime, struct compat_timeval *value)
 {
        value->tv_usec = cputime % 1000000;