Commit 1e7bfb21 authored by Heiko Carstens's avatar Heiko Carstens

[CVE-2009-0029] System call wrappers part 27

Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
parent c4ea37c2
...@@ -99,7 +99,7 @@ static inline void put_binfmt(struct linux_binfmt * fmt) ...@@ -99,7 +99,7 @@ static inline void put_binfmt(struct linux_binfmt * fmt)
* *
* Also note that we take the address to load from from the file itself. * Also note that we take the address to load from from the file itself.
*/ */
asmlinkage long sys_uselib(const char __user * library) SYSCALL_DEFINE1(uselib, const char __user *, library)
{ {
struct file *file; struct file *file;
struct nameidata nd; struct nameidata nd;
......
...@@ -179,7 +179,7 @@ static int fs_maxindex(void) ...@@ -179,7 +179,7 @@ static int fs_maxindex(void)
/* /*
* Whee.. Weird sysv syscall. * Whee.. Weird sysv syscall.
*/ */
asmlinkage long sys_sysfs(int option, unsigned long arg1, unsigned long arg2) SYSCALL_DEFINE3(sysfs, int, option, unsigned long, arg1, unsigned long, arg2)
{ {
int retval = -EINVAL; int retval = -EINVAL;
......
...@@ -86,8 +86,8 @@ static struct { ...@@ -86,8 +86,8 @@ static struct {
}, },
}; };
long SYSCALL_DEFINE3(nfsservctl, int, cmd, struct nfsctl_arg __user *, arg,
asmlinkage sys_nfsservctl(int cmd, struct nfsctl_arg __user *arg, void __user *res) void __user *, res)
{ {
struct file *file; struct file *file;
void __user *p = &arg->u; void __user *p = &arg->u;
......
...@@ -382,7 +382,7 @@ int do_syslog(int type, char __user *buf, int len) ...@@ -382,7 +382,7 @@ int do_syslog(int type, char __user *buf, int len)
return error; return error;
} }
asmlinkage long sys_syslog(int type, char __user *buf, int len) SYSCALL_DEFINE3(syslog, int, type, char __user *, buf, int, len)
{ {
return do_syslog(type, buf, len); return do_syslog(type, buf, len);
} }
......
...@@ -574,7 +574,7 @@ struct task_struct *ptrace_get_task_struct(pid_t pid) ...@@ -574,7 +574,7 @@ struct task_struct *ptrace_get_task_struct(pid_t pid)
#define arch_ptrace_attach(child) do { } while (0) #define arch_ptrace_attach(child) do { } while (0)
#endif #endif
asmlinkage long sys_ptrace(long request, long pid, long addr, long data) SYSCALL_DEFINE4(ptrace, long, request, long, pid, long, addr, long, data)
{ {
struct task_struct *child; struct task_struct *child;
long ret; long ret;
......
...@@ -1688,7 +1688,7 @@ int do_sysctl(int __user *name, int nlen, void __user *oldval, size_t __user *ol ...@@ -1688,7 +1688,7 @@ int do_sysctl(int __user *name, int nlen, void __user *oldval, size_t __user *ol
return error; return error;
} }
asmlinkage long sys_sysctl(struct __sysctl_args __user *args) SYSCALL_DEFINE1(sysctl, struct __sysctl_args __user *, args)
{ {
struct __sysctl_args tmp; struct __sysctl_args tmp;
int error; int error;
...@@ -2989,7 +2989,7 @@ int sysctl_ms_jiffies(struct ctl_table *table, ...@@ -2989,7 +2989,7 @@ int sysctl_ms_jiffies(struct ctl_table *table,
#else /* CONFIG_SYSCTL_SYSCALL */ #else /* CONFIG_SYSCTL_SYSCALL */
asmlinkage long sys_sysctl(struct __sysctl_args __user *args) SYSCALL_DEFINE1(sysctl, struct __sysctl_args __user *, args)
{ {
struct __sysctl_args tmp; struct __sysctl_args tmp;
int error; int error;
......
...@@ -1400,7 +1400,7 @@ int do_sysinfo(struct sysinfo *info) ...@@ -1400,7 +1400,7 @@ int do_sysinfo(struct sysinfo *info)
return 0; return 0;
} }
asmlinkage long sys_sysinfo(struct sysinfo __user *info) SYSCALL_DEFINE1(sysinfo, struct sysinfo __user *, info)
{ {
struct sysinfo val; struct sysinfo val;
......
...@@ -54,11 +54,11 @@ static int key_get_type_from_user(char *type, ...@@ -54,11 +54,11 @@ static int key_get_type_from_user(char *type,
* - returns the new key's serial number * - returns the new key's serial number
* - implements add_key() * - implements add_key()
*/ */
asmlinkage long sys_add_key(const char __user *_type, SYSCALL_DEFINE5(add_key, const char __user *, _type,
const char __user *_description, const char __user *, _description,
const void __user *_payload, const void __user *, _payload,
size_t plen, size_t, plen,
key_serial_t ringid) key_serial_t, ringid)
{ {
key_ref_t keyring_ref, key_ref; key_ref_t keyring_ref, key_ref;
char type[32], *description; char type[32], *description;
...@@ -146,10 +146,10 @@ asmlinkage long sys_add_key(const char __user *_type, ...@@ -146,10 +146,10 @@ asmlinkage long sys_add_key(const char __user *_type,
* - if the _callout_info string is empty, it will be rendered as "-" * - if the _callout_info string is empty, it will be rendered as "-"
* - implements request_key() * - implements request_key()
*/ */
asmlinkage long sys_request_key(const char __user *_type, SYSCALL_DEFINE4(request_key, const char __user *, _type,
const char __user *_description, const char __user *, _description,
const char __user *_callout_info, const char __user *, _callout_info,
key_serial_t destringid) key_serial_t, destringid)
{ {
struct key_type *ktype; struct key_type *ktype;
struct key *key; struct key *key;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment