瀏覽代碼

NFS: Fix nfs_post_op_update_inode() to set an attribute barrier

nfs_post_op_update_inode() is called after a self-induced attribute
update. Ensure that it also sets the barrier.

Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Tested-by: Chuck Lever <chuck.lever@oracle.com>
Trond Myklebust 10 年之前
父節點
當前提交
92d64e47b6
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      fs/nfs/inode.c

+ 1 - 0
fs/nfs/inode.c

@@ -1475,6 +1475,7 @@ int nfs_post_op_update_inode(struct inode *inode, struct nfs_fattr *fattr)
 	int status;
 	int status;
 
 
 	spin_lock(&inode->i_lock);
 	spin_lock(&inode->i_lock);
+	nfs_fattr_set_barrier(fattr);
 	status = nfs_post_op_update_inode_locked(inode, fattr);
 	status = nfs_post_op_update_inode_locked(inode, fattr);
 	spin_unlock(&inode->i_lock);
 	spin_unlock(&inode->i_lock);