Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5c675d64 authored by Trond Myklebust's avatar Trond Myklebust
Browse files

NFS: Set NFS_INO_REVAL_PAGECACHE if the change attribute is uninitialised



We can't allow caching of data until the change attribute has been
initialised correctly.

Signed-off-by: default avatarTrond Myklebust <trond.myklebust@primarydata.com>
parent 85a23cee
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -443,7 +443,8 @@ nfs_fhget(struct super_block *sb, struct nfs_fh *fh, struct nfs_fattr *fattr, st
		if (fattr->valid & NFS_ATTR_FATTR_CHANGE)
			inode->i_version = fattr->change_attr;
		else if (nfs_server_capable(inode, NFS_CAP_CHANGE_ATTR))
			nfs_set_cache_invalid(inode, NFS_INO_INVALID_ATTR);
			nfs_set_cache_invalid(inode, NFS_INO_INVALID_ATTR
				| NFS_INO_REVAL_PAGECACHE);
		if (fattr->valid & NFS_ATTR_FATTR_SIZE)
			inode->i_size = nfs_size_to_loff_t(fattr->size);
		else