diff options
author | Fred Isaman <iisaman@netapp.com> | 2011-03-03 16:13:49 +0100 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2011-03-11 21:38:45 +0100 |
commit | 36fe432d33e078caee5c954e15e929819c2cacae (patch) | |
tree | 84bccc3434a423f8eabae42d543fad5914124ae2 /fs/nfs/write.c | |
parent | NFSv4.1: rearrange ->doio args (diff) | |
download | linux-36fe432d33e078caee5c954e15e929819c2cacae.tar.xz linux-36fe432d33e078caee5c954e15e929819c2cacae.zip |
NFSv4.1: Clear lseg pointer in ->doio function
Now that we have access to the pointer, clear it immediately after
the put, instead of in caller.
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 | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c index b74200a2f753..47a3ad63e0d5 100644 --- a/fs/nfs/write.c +++ b/fs/nfs/write.c @@ -949,6 +949,7 @@ static int nfs_flush_multi(struct nfs_pageio_descriptor *desc) } while (nbytes != 0); put_lseg(lseg); + desc->pg_lseg = NULL; return ret; out_bad: @@ -1005,6 +1006,7 @@ static int nfs_flush_one(struct nfs_pageio_descriptor *desc) ret = nfs_write_rpcsetup(req, data, &nfs_write_full_ops, desc->pg_count, 0, lseg, desc->pg_ioflags); out: put_lseg(lseg); /* Cleans any gotten in ->pg_test */ + desc->pg_lseg = NULL; return ret; } |