diff options
author | Arun Bharadwaj <arun@linux.vnet.ibm.com> | 2010-11-18 10:36:43 +0000 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2010-11-22 13:24:42 -0500 |
commit | b47d19de2c714020ba8f5545a6e7d4968f37eb45 (patch) | |
tree | 546161934b37b1dd4901f2752387fee6542a224a /fs/nfs | |
parent | 5fc43978a79e8021c189660ab63249fd29c5fb32 (diff) | |
download | op-kernel-dev-b47d19de2c714020ba8f5545a6e7d4968f37eb45.zip op-kernel-dev-b47d19de2c714020ba8f5545a6e7d4968f37eb45.tar.gz |
Pure nfs client performance using odirect.
When an application opens a file with O_DIRECT flag, if the size of
the data that is written is equal to wsize, the client sends a
WRITE RPC with stable flag set to UNSTABLE followed by a single
COMMIT RPC rather than sending a single WRITE RPC with the stable
flag set to FILE_SYNC. This a bug.
Patch to fix this.
Signed-off-by: Arun R Bharadwaj <arun@linux.vnet.ibm.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs')
-rw-r--r-- | fs/nfs/direct.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/nfs/direct.c b/fs/nfs/direct.c index 84d3c8b..e6ace0d 100644 --- a/fs/nfs/direct.c +++ b/fs/nfs/direct.c @@ -867,7 +867,7 @@ static ssize_t nfs_direct_write(struct kiocb *iocb, const struct iovec *iov, goto out; nfs_alloc_commit_data(dreq); - if (dreq->commit_data == NULL || count < wsize) + if (dreq->commit_data == NULL || count <= wsize) sync = NFS_FILE_SYNC; dreq->inode = inode; |