diff --git a/fs/nfs/write.c b/fs/nfs/write.c index 55a8c36712331f031446bb56cb82819d92b5d8b6..92b4a6614fd333c82a28cf60ebf5a0922a3c57af 100644 --- a/fs/nfs/write.c +++ b/fs/nfs/write.c @@ -474,7 +474,10 @@ nfs_clear_request_commit(struct nfs_page *req) static inline int nfs_write_need_commit(struct nfs_write_data *data) { - return data->verf.committed != NFS_FILE_SYNC; + if (data->verf.committed == NFS_DATA_SYNC) + return data->lseg == NULL; + else + return data->verf.committed != NFS_FILE_SYNC; } static inline