summaryrefslogtreecommitdiffstats
path: root/kernel/fs/btrfs/acl.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/fs/btrfs/acl.c')
-rw-r--r--kernel/fs/btrfs/acl.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/kernel/fs/btrfs/acl.c b/kernel/fs/btrfs/acl.c
index 9a0124a95..fb3e64d37 100644
--- a/kernel/fs/btrfs/acl.c
+++ b/kernel/fs/btrfs/acl.c
@@ -83,11 +83,9 @@ static int __btrfs_set_acl(struct btrfs_trans_handle *trans,
case ACL_TYPE_ACCESS:
name = POSIX_ACL_XATTR_ACCESS;
if (acl) {
- ret = posix_acl_equiv_mode(acl, &inode->i_mode);
- if (ret < 0)
+ ret = posix_acl_update_mode(inode, &inode->i_mode, &acl);
+ if (ret)
return ret;
- if (ret == 0)
- acl = NULL;
}
ret = 0;
break;