summaryrefslogtreecommitdiffstats
path: root/fs/gfs2/acl.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2016-10-08 11:06:08 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2016-10-08 11:06:08 -0400
commite55f1d1d13e7f1c364672d667d78fd1f640ab9f9 (patch)
tree406a3c127abb008f2f736c8d2ee03fc3c2926d6b /fs/gfs2/acl.c
parentf334bcd94b7d3c0fbc34d518a86548f451ab5faf (diff)
parent030b533c4fd4d2ec3402363323de4bb2983c9cee (diff)
downloadlinux-e55f1d1d13e7f1c364672d667d78fd1f640ab9f9.tar.bz2
Merge remote-tracking branch 'jk/vfs' into work.misc
Diffstat (limited to 'fs/gfs2/acl.c')
-rw-r--r--fs/gfs2/acl.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/fs/gfs2/acl.c b/fs/gfs2/acl.c
index 363ba9e9d8d0..2524807ee070 100644
--- a/fs/gfs2/acl.c
+++ b/fs/gfs2/acl.c
@@ -92,17 +92,11 @@ int __gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type)
if (type == ACL_TYPE_ACCESS) {
umode_t mode = inode->i_mode;
- error = posix_acl_equiv_mode(acl, &mode);
- if (error < 0)
+ error = posix_acl_update_mode(inode, &inode->i_mode, &acl);
+ if (error)
return error;
-
- if (error == 0)
- acl = NULL;
-
- if (mode != inode->i_mode) {
- inode->i_mode = mode;
+ if (mode != inode->i_mode)
mark_inode_dirty(inode);
- }
}
if (acl) {