Commit 31827e50 authored by Linus Torvalds's avatar Linus Torvalds

Merge master.kernel.org:/home/davem/BK/compat-statfs64-2.5

into home.osdl.org:/home/torvalds/v2.5/linux
parents 108ff4c2 0de5c2cc
......@@ -65,8 +65,8 @@ sys_call_table32:
.word sys32_ipc, sys32_sigreturn, sys_clone, sys_nis_syscall, sys32_adjtimex
/*220*/ .word compat_sys_sigprocmask, sys_ni_syscall, sys32_delete_module, sys_ni_syscall, sys_getpgid
.word sys32_bdflush, sys32_sysfs, sys_nis_syscall, sys32_setfsuid16, sys32_setfsgid16
/*230*/ .word sys32_select, sys_time, sys_nis_syscall, sys_stime, sys_statfs64
.word sys_fstatfs64, sys_llseek, sys_mlock, sys_munlock, sys_mlockall
/*230*/ .word sys32_select, sys_time, sys_nis_syscall, sys_stime, compat_statfs64
.word compat_fstatfs64, sys_llseek, sys_mlock, sys_munlock, sys_mlockall
/*240*/ .word sys_munlockall, sys_sched_setparam, sys_sched_getparam, sys_sched_setscheduler, sys_sched_getscheduler
.word sys_sched_yield, sys_sched_get_priority_max, sys_sched_get_priority_min, sys32_sched_rr_get_interval, compat_sys_nanosleep
/*250*/ .word sys32_mremap, sys32_sysctl, sys_getsid, sys_fdatasync, sys32_nfsservctl
......
......@@ -169,7 +169,6 @@ asmlinkage long compat_sys_fstatfs(unsigned int fd, struct compat_statfs *buf)
static int put_compat_statfs64(struct compat_statfs64 *ubuf, struct kstatfs *kbuf)
{
if (sizeof ubuf->f_blocks == 4) {
if ((kbuf->f_blocks | kbuf->f_bfree |
kbuf->f_bavail | kbuf->f_files | kbuf->f_ffree) &
......@@ -192,11 +191,14 @@ static int put_compat_statfs64(struct compat_statfs64 *ubuf, struct kstatfs *kbu
return 0;
}
asmlinkage long compat_statfs64(const char *path, struct compat_statfs64 *buf)
asmlinkage long compat_statfs64(const char *path, compat_size_t sz, struct compat_statfs64 *buf)
{
struct nameidata nd;
int error;
if (sz != sizeof(*buf))
return -EINVAL;
error = user_path_walk(path, &nd);
if (!error) {
struct kstatfs tmp;
......@@ -208,12 +210,15 @@ asmlinkage long compat_statfs64(const char *path, struct compat_statfs64 *buf)
return error;
}
asmlinkage long compat_fstatfs64(unsigned int fd, struct compat_statfs64 *buf)
asmlinkage long compat_fstatfs64(unsigned int fd, compat_size_t sz, struct compat_statfs64 *buf)
{
struct file * file;
struct kstatfs tmp;
int error;
if (sz != sizeof(*buf))
return -EINVAL;
error = -EBADF;
file = fget(fd);
if (!file)
......
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