From: Daniel Rosenberg Date: Tue, 14 Mar 2017 22:39:05 +0000 (-0700) Subject: ANDROID: vfs: user permission2 in notify_change2 X-Git-Tag: release-20171130_firefly~4^2~100^2~196 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=dabcf1d17a04db801ac0d9068b3b20520369b8be;p=firefly-linux-kernel-4.4.55.git ANDROID: vfs: user permission2 in notify_change2 This allows filesystems to use their mount private data to influence the permissions they use when attempting to touch. Signed-off-by: Daniel Rosenberg Bug: 36228261 Change-Id: I1052319ba1c3ce5d5e586aa7f8a80c08851a5c7f --- diff --git a/fs/attr.c b/fs/attr.c index 11be2265a2d5..c86b37c38fb7 100644 --- a/fs/attr.c +++ b/fs/attr.c @@ -211,7 +211,7 @@ int notify_change2(struct vfsmount *mnt, struct dentry * dentry, struct iattr * return -EPERM; if (!inode_owner_or_capable(inode)) { - error = inode_permission(inode, MAY_WRITE); + error = inode_permission2(mnt, inode, MAY_WRITE); if (error) return error; }