summaryrefslogtreecommitdiff
path: root/fs/nfs/internal.h
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@primarydata.com>2016-06-01 21:42:32 -0400
committerTrond Myklebust <trond.myklebust@primarydata.com>2016-07-05 19:11:02 -0400
commita5314a74928fa6dbc4503a8c64f43bb5c1c12ac1 (patch)
tree0aa0e3f0b6b5a33a74a144b5714683d0d7e9eb41 /fs/nfs/internal.h
parent8fc3c3862728373e0d0f5abccc6afc56c69e0c63 (diff)
downloadlinux-exynos-a5314a74928fa6dbc4503a8c64f43bb5c1c12ac1.tar.gz
linux-exynos-a5314a74928fa6dbc4503a8c64f43bb5c1c12ac1.tar.bz2
linux-exynos-a5314a74928fa6dbc4503a8c64f43bb5c1c12ac1.zip
NFS: Ensure we reset the write verifier 'committed' value on resend.
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/internal.h')
-rw-r--r--fs/nfs/internal.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/fs/nfs/internal.h b/fs/nfs/internal.h
index 150a8eb0f323..0eb5c924886d 100644
--- a/fs/nfs/internal.h
+++ b/fs/nfs/internal.h
@@ -499,6 +499,23 @@ int nfs_key_timeout_notify(struct file *filp, struct inode *inode);
bool nfs_ctx_key_to_expire(struct nfs_open_context *ctx);
void nfs_pageio_stop_mirroring(struct nfs_pageio_descriptor *pgio);
+#ifdef CONFIG_NFS_V4_1
+static inline
+void nfs_clear_pnfs_ds_commit_verifiers(struct pnfs_ds_commit_info *cinfo)
+{
+ int i;
+
+ for (i = 0; i < cinfo->nbuckets; i++)
+ cinfo->buckets[i].direct_verf.committed = NFS_INVALID_STABLE_HOW;
+}
+#else
+static inline
+void nfs_clear_pnfs_ds_commit_verifiers(struct pnfs_ds_commit_info *cinfo)
+{
+}
+#endif
+
+
#ifdef CONFIG_MIGRATION
extern int nfs_migrate_page(struct address_space *,
struct page *, struct page *, enum migrate_mode);