summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFred Isaman <iisaman@netapp.com>2012-03-20 12:51:24 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2012-03-20 13:05:08 -0400
commitc4f1b62a4b50a01e8d820717906b674807ef9ca3 (patch)
tree00235f72dd714761d9536408d3c7342d0da10c6d
parent540a0f7584169651f485e8ab67461fcb06934e38 (diff)
downloadlinux-c4f1b62a4b50a01e8d820717906b674807ef9ca3.tar.gz
linux-c4f1b62a4b50a01e8d820717906b674807ef9ca3.tar.bz2
linux-c4f1b62a4b50a01e8d820717906b674807ef9ca3.zip
NFS: ncommit count is being double decremented
The decrement is handled by each call to nfs_request_remove_commit_list, no need to do it again in nfs_scan_commit. Signed-off-by: Fred Isaman <iisaman@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
-rw-r--r--fs/nfs/write.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index 0de19f413f92..628d9a69d0a2 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -595,12 +595,9 @@ nfs_scan_commit(struct inode *inode, struct list_head *dst)
spin_lock(&inode->i_lock);
if (nfsi->ncommit > 0) {
const int max = INT_MAX;
- int pnfs_ret;
ret = nfs_scan_commit_list(&nfsi->commit_list, dst, max);
- pnfs_ret = pnfs_scan_commit_lists(inode, max - ret);
- ret += pnfs_ret;
- nfsi->ncommit -= ret;
+ ret += pnfs_scan_commit_lists(inode, max - ret);
}
spin_unlock(&inode->i_lock);
return ret;