X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=arch%2Fum%2Fkernel%2Fsyscall.c;h=237c4eab7cfd6c429a6ca8831a6a681671a3ddd6;hb=721e2629fa2167c0e5a9f10d704b1fee1621a8cb;hp=abf14aaf905ffb2fda7789ccbfab5779122f91e8;hpb=e9ff3990f08e9a0c2839cc22808b01732ea5b3e4;p=linux-2.6-omap-h63xx.git diff --git a/arch/um/kernel/syscall.c b/arch/um/kernel/syscall.c index abf14aaf905..237c4eab7cf 100644 --- a/arch/um/kernel/syscall.c +++ b/arch/um/kernel/syscall.c @@ -18,7 +18,6 @@ #include "asm/mman.h" #include "asm/uaccess.h" #include "kern_util.h" -#include "user_util.h" #include "sysdep/syscalls.h" #include "mode_kern.h" #include "choose-mode.h" @@ -149,18 +148,15 @@ long sys_olduname(struct oldold_utsname __user * name) return error; } -DEFINE_SPINLOCK(syscall_lock); - -static int syscall_index = 0; - -int next_syscall_index(int limit) +int kernel_execve(const char *filename, char *const argv[], char *const envp[]) { + mm_segment_t fs; int ret; - spin_lock(&syscall_lock); - ret = syscall_index; - if(++syscall_index == limit) - syscall_index = 0; - spin_unlock(&syscall_lock); - return(ret); + fs = get_fs(); + set_fs(KERNEL_DS); + ret = um_execve(filename, argv, envp); + set_fs(fs); + + return ret; }