diff options
author | Serge E. Hallyn <serge@hallyn.com> | 2011-03-23 19:43:26 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-03-23 22:47:13 -0400 |
commit | 2e1496707560ecf98e9b0604622c0990f94861d3 (patch) | |
tree | d1473b70fad31a903fedc87221680678a6c6c5f6 /fs/ext2 | |
parent | e795b71799ff0b27365020c9ddaa25d0d83f99c8 (diff) |
userns: rename is_owner_or_cap to inode_owner_or_capable
And give it a kernel-doc comment.
[akpm@linux-foundation.org: btrfs changed in linux-next]
Signed-off-by: Serge E. Hallyn <serge.hallyn@canonical.com>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Daniel Lezcano <daniel.lezcano@free.fr>
Acked-by: David Howells <dhowells@redhat.com>
Cc: James Morris <jmorris@namei.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ext2')
-rw-r--r-- | fs/ext2/acl.c | 2 | ||||
-rw-r--r-- | fs/ext2/ioctl.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/fs/ext2/acl.c b/fs/ext2/acl.c index 7b4180554a62..abea5a17c764 100644 --- a/fs/ext2/acl.c +++ b/fs/ext2/acl.c | |||
@@ -406,7 +406,7 @@ ext2_xattr_set_acl(struct dentry *dentry, const char *name, const void *value, | |||
406 | return -EINVAL; | 406 | return -EINVAL; |
407 | if (!test_opt(dentry->d_sb, POSIX_ACL)) | 407 | if (!test_opt(dentry->d_sb, POSIX_ACL)) |
408 | return -EOPNOTSUPP; | 408 | return -EOPNOTSUPP; |
409 | if (!is_owner_or_cap(dentry->d_inode)) | 409 | if (!inode_owner_or_capable(dentry->d_inode)) |
410 | return -EPERM; | 410 | return -EPERM; |
411 | 411 | ||
412 | if (value) { | 412 | if (value) { |
diff --git a/fs/ext2/ioctl.c b/fs/ext2/ioctl.c index e7431309bdca..f81e250ac5c4 100644 --- a/fs/ext2/ioctl.c +++ b/fs/ext2/ioctl.c | |||
@@ -39,7 +39,7 @@ long ext2_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) | |||
39 | if (ret) | 39 | if (ret) |
40 | return ret; | 40 | return ret; |
41 | 41 | ||
42 | if (!is_owner_or_cap(inode)) { | 42 | if (!inode_owner_or_capable(inode)) { |
43 | ret = -EACCES; | 43 | ret = -EACCES; |
44 | goto setflags_out; | 44 | goto setflags_out; |
45 | } | 45 | } |
@@ -89,7 +89,7 @@ setflags_out: | |||
89 | case EXT2_IOC_GETVERSION: | 89 | case EXT2_IOC_GETVERSION: |
90 | return put_user(inode->i_generation, (int __user *) arg); | 90 | return put_user(inode->i_generation, (int __user *) arg); |
91 | case EXT2_IOC_SETVERSION: | 91 | case EXT2_IOC_SETVERSION: |
92 | if (!is_owner_or_cap(inode)) | 92 | if (!inode_owner_or_capable(inode)) |
93 | return -EPERM; | 93 | return -EPERM; |
94 | ret = mnt_want_write(filp->f_path.mnt); | 94 | ret = mnt_want_write(filp->f_path.mnt); |
95 | if (ret) | 95 | if (ret) |
@@ -115,7 +115,7 @@ setflags_out: | |||
115 | if (!test_opt(inode->i_sb, RESERVATION) ||!S_ISREG(inode->i_mode)) | 115 | if (!test_opt(inode->i_sb, RESERVATION) ||!S_ISREG(inode->i_mode)) |
116 | return -ENOTTY; | 116 | return -ENOTTY; |
117 | 117 | ||
118 | if (!is_owner_or_cap(inode)) | 118 | if (!inode_owner_or_capable(inode)) |
119 | return -EACCES; | 119 | return -EACCES; |
120 | 120 | ||
121 | if (get_user(rsv_window_size, (int __user *)arg)) | 121 | if (get_user(rsv_window_size, (int __user *)arg)) |