diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-10-20 21:46:25 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2012-11-28 21:53:37 -0500 |
commit | d03d26e58fde2ec99478e26aab47b55755189b08 (patch) | |
tree | 025a102a36e62b21a139bcc5ca7abf2c250cd209 | |
parent | 910cdc553a324d3df56b73c84cdef20836817d52 (diff) |
make compat_do_execve() static, lose pt_regs argument
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | fs/exec.c | 10 | ||||
-rw-r--r-- | include/linux/compat.h | 2 |
2 files changed, 4 insertions, 8 deletions
diff --git a/fs/exec.c b/fs/exec.c index 0039055b1fc..f86b6cc2d6c 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -1575,10 +1575,9 @@ int do_execve(const char *filename, } #ifdef CONFIG_COMPAT -int compat_do_execve(const char *filename, +static int compat_do_execve(const char *filename, const compat_uptr_t __user *__argv, - const compat_uptr_t __user *__envp, - struct pt_regs *regs) + const compat_uptr_t __user *__envp) { struct user_arg_ptr argv = { .is_compat = true, @@ -1588,7 +1587,7 @@ int compat_do_execve(const char *filename, .is_compat = true, .ptr.compat = __envp, }; - return do_execve_common(filename, argv, envp, regs); + return do_execve_common(filename, argv, envp, current_pt_regs()); } #endif @@ -1682,8 +1681,7 @@ asmlinkage long compat_sys_execve(const char __user * filename, struct filename *path = getname(filename); int error = PTR_ERR(path); if (!IS_ERR(path)) { - error = compat_do_execve(path->name, argv, envp, - current_pt_regs()); + error = compat_do_execve(path->name, argv, envp); putname(path); } return error; diff --git a/include/linux/compat.h b/include/linux/compat.h index d2db71077d9..784ebfe63c4 100644 --- a/include/linux/compat.h +++ b/include/linux/compat.h @@ -284,8 +284,6 @@ asmlinkage ssize_t compat_sys_pwritev(unsigned long fd, const struct compat_iovec __user *vec, unsigned long vlen, u32 pos_low, u32 pos_high); -int compat_do_execve(const char *filename, const compat_uptr_t __user *argv, - const compat_uptr_t __user *envp, struct pt_regs *regs); asmlinkage long compat_sys_execve(const char __user *filename, const compat_uptr_t __user *argv, const compat_uptr_t __user *envp); |