2 * Copyright (C) 2000, 2001 Jeff Dike (jdike@karaya.com)
3 * Licensed under the GPL
6 #include "linux/slab.h"
7 #include "linux/smp_lock.h"
8 #include "linux/ptrace.h"
9 #include "asm/ptrace.h"
10 #include "asm/pgtable.h"
11 #include "asm/tlbflush.h"
12 #include "asm/uaccess.h"
13 #include "user_util.h"
14 #include "kern_util.h"
19 #include "2_5compat.h"
21 #include "time_user.h"
22 #include "choose-mode.h"
23 #include "mode_kern.h"
25 void flush_thread(void)
27 CHOOSE_MODE(flush_thread_tt(), flush_thread_skas());
30 void start_thread(struct pt_regs
*regs
, unsigned long eip
, unsigned long esp
)
32 CHOOSE_MODE_PROC(start_thread_tt
, start_thread_skas
, regs
, eip
, esp
);
35 extern void log_exec(char **argv
, void *tty
);
37 static int execve1(char *file
, char **argv
, char **env
)
42 log_exec(argv
, current
->tty
);
44 error
= do_execve(file
, argv
, env
, ¤t
->thread
.regs
);
46 current
->ptrace
&= ~PT_DTRACE
;
47 set_cmdline(current_cmd());
52 int um_execve(char *file
, char **argv
, char **env
)
56 err
= execve1(file
, argv
, env
);
58 do_longjmp(current
->thread
.exec_buf
, 1);
62 int sys_execve(char *file
, char **argv
, char **env
)
68 filename
= getname((char *) file
);
69 error
= PTR_ERR(filename
);
70 if (IS_ERR(filename
)) goto out
;
71 error
= execve1(filename
, argv
, env
);
79 * Overrides for Emacs so that we follow Linus's tabbing style.
80 * Emacs will notice this stuff at the end of the file and automatically
81 * adjust the settings for this buffer only. This must remain at the end
83 * ---------------------------------------------------------------------------
85 * c-file-style: "linux"