summaryrefslogtreecommitdiffstats
path: root/module/zfs
diff options
context:
space:
mode:
authorBrian Behlendorf <[email protected]>2016-10-18 23:49:23 +0000
committerBrian Behlendorf <[email protected]>2016-10-20 09:39:09 -0700
commit3b0ba3ba99b8a3af0fb532bf264629436b1abd84 (patch)
tree962afba9779cd11c14a3b89b1586af74af9b6cbc /module/zfs
parent0fedeedd309eca62d15fffd8bd811e2b12660e21 (diff)
Linux 4.9 compat: inode_change_ok() renamed setattr_prepare()
In torvalds/linux@31051c8 the inode_change_ok() function was renamed setattr_prepare() and updated to take a dentry ratheri than an inode. Update the code to call the setattr_prepare() and add a wrapper function which call inode_change_ok() for older kernels. Signed-off-by: Brian Behlendorf <[email protected]> Signed-off-by: Chunwei Chen <[email protected]> Requires-spl: refs/pull/581/head
Diffstat (limited to 'module/zfs')
-rw-r--r--module/zfs/zpl_inode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/module/zfs/zpl_inode.c b/module/zfs/zpl_inode.c
index f59f2df97..b8adda7a1 100644
--- a/module/zfs/zpl_inode.c
+++ b/module/zfs/zpl_inode.c
@@ -323,7 +323,7 @@ zpl_setattr(struct dentry *dentry, struct iattr *ia)
int error;
fstrans_cookie_t cookie;
- error = inode_change_ok(ip, ia);
+ error = setattr_prepare(dentry, ia);
if (error)
return (error);