Commit ab0d1e85 authored by Dominik Brodowski's avatar Dominik Brodowski

fs/quota: use COMPAT_SYSCALL_DEFINE for sys32_quotactl()

While sys32_quotactl() is only needed on x86, it can use the recommended
COMPAT_SYSCALL_DEFINEx() machinery for its setup.
Acked-by: default avatarJan Kara <jack@suse.cz>
Cc: Christoph Hellwig <hch@infradead.org>
Signed-off-by: default avatarDominik Brodowski <linux@dominikbrodowski.net>
parent cb0b476a
...@@ -137,7 +137,7 @@ ...@@ -137,7 +137,7 @@
128 i386 init_module sys_init_module 128 i386 init_module sys_init_module
129 i386 delete_module sys_delete_module 129 i386 delete_module sys_delete_module
130 i386 get_kernel_syms 130 i386 get_kernel_syms
131 i386 quotactl sys_quotactl sys32_quotactl 131 i386 quotactl sys_quotactl compat_sys_quotactl32
132 i386 getpgid sys_getpgid 132 i386 getpgid sys_getpgid
133 i386 fchdir sys_fchdir 133 i386 fchdir sys_fchdir
134 i386 bdflush sys_bdflush 134 i386 bdflush sys_bdflush
......
...@@ -41,8 +41,9 @@ struct compat_fs_quota_stat { ...@@ -41,8 +41,9 @@ struct compat_fs_quota_stat {
__u16 qs_iwarnlimit; __u16 qs_iwarnlimit;
}; };
asmlinkage long sys32_quotactl(unsigned int cmd, const char __user *special, COMPAT_SYSCALL_DEFINE4(quotactl32, unsigned int, cmd,
qid_t id, void __user *addr) const char __user *, special, qid_t, id,
void __user *, addr)
{ {
unsigned int cmds; unsigned int cmds;
struct if_dqblk __user *dqblk; struct if_dqblk __user *dqblk;
......
...@@ -461,6 +461,9 @@ asmlinkage ssize_t compat_sys_pwritev2(compat_ulong_t fd, ...@@ -461,6 +461,9 @@ asmlinkage ssize_t compat_sys_pwritev2(compat_ulong_t fd,
const struct compat_iovec __user *vec, const struct compat_iovec __user *vec,
compat_ulong_t vlen, u32 pos_low, u32 pos_high, rwf_t flags); compat_ulong_t vlen, u32 pos_low, u32 pos_high, rwf_t flags);
asmlinkage long compat_sys_quotactl32(unsigned int cmd,
const char __user *special, qid_t id, void __user *addr);
#ifdef __ARCH_WANT_COMPAT_SYS_PREADV64 #ifdef __ARCH_WANT_COMPAT_SYS_PREADV64
asmlinkage long compat_sys_preadv64(unsigned long fd, asmlinkage long compat_sys_preadv64(unsigned long fd,
const struct compat_iovec __user *vec, const struct compat_iovec __user *vec,
......
...@@ -241,8 +241,6 @@ static inline void addr_limit_user_check(void) ...@@ -241,8 +241,6 @@ static inline void addr_limit_user_check(void)
#endif #endif
} }
asmlinkage long sys32_quotactl(unsigned int cmd, const char __user *special,
qid_t id, void __user *addr);
asmlinkage long sys_time(time_t __user *tloc); asmlinkage long sys_time(time_t __user *tloc);
asmlinkage long sys_stime(time_t __user *tptr); asmlinkage long sys_stime(time_t __user *tptr);
asmlinkage long sys_gettimeofday(struct timeval __user *tv, asmlinkage long sys_gettimeofday(struct timeval __user *tv,
......
...@@ -18,7 +18,7 @@ asmlinkage long sys_ni_syscall(void) ...@@ -18,7 +18,7 @@ asmlinkage long sys_ni_syscall(void)
} }
cond_syscall(sys_quotactl); cond_syscall(sys_quotactl);
cond_syscall(sys32_quotactl); cond_syscall(compat_sys_quotactl32);
cond_syscall(sys_acct); cond_syscall(sys_acct);
cond_syscall(sys_lookup_dcookie); cond_syscall(sys_lookup_dcookie);
cond_syscall(compat_sys_lookup_dcookie); cond_syscall(compat_sys_lookup_dcookie);
......
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