diff options
author | Fred Isaman <iisaman@netapp.com> | 2011-03-23 09:27:44 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2011-03-23 15:29:02 -0400 |
commit | 465d52437d5ce8d4eb9da0d3e3818b51cff163a1 (patch) | |
tree | eb78b7c5e1e07a6a726e6b7d5dbc683eaad26902 /fs/nfs/write.c | |
parent | 8ef2ce3e16d9bec6cf015207c1c82a5b864046ac (diff) |
NFSv4.1: don't send COMMIT to ds for data sync writes
Based on consensus reached in Feb 2011 interim IETF meeting regarding
use of LAYOUTCOMMIT, it has been decided that a NFS_DATA_SYNC return
from a WRITE to data server should not initiate a COMMIT.
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/write.c')
-rw-r--r-- | fs/nfs/write.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c index 55a8c3671233..92b4a6614fd3 100644 --- a/fs/nfs/write.c +++ b/fs/nfs/write.c | |||
@@ -474,7 +474,10 @@ nfs_clear_request_commit(struct nfs_page *req) | |||
474 | static inline | 474 | static inline |
475 | int nfs_write_need_commit(struct nfs_write_data *data) | 475 | int nfs_write_need_commit(struct nfs_write_data *data) |
476 | { | 476 | { |
477 | return data->verf.committed != NFS_FILE_SYNC; | 477 | if (data->verf.committed == NFS_DATA_SYNC) |
478 | return data->lseg == NULL; | ||
479 | else | ||
480 | return data->verf.committed != NFS_FILE_SYNC; | ||
478 | } | 481 | } |
479 | 482 | ||
480 | static inline | 483 | static inline |