projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
892cd4a
)
pnfs: use lwb as layoutcommit length
author
Peng Tao
<bergwolf@gmail.com>
Sun, 31 Jul 2011 00:52:34 +0000
(20:52 -0400)
committer
Greg Kroah-Hartman
<gregkh@suse.de>
Fri, 5 Aug 2011 04:58:37 +0000
(21:58 -0700)
commit
3557c6c3be5b2ca0b11365db7f8a813253eb520b
upstream.
Using NFS4_MAX_UINT64 will break current protocol.
[Needed in v3.0]
Signed-off-by: Peng Tao <peng_tao@emc.com>
Signed-off-by: Jim Rees <rees@umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
fs/nfs/nfs4xdr.c
patch
|
blob
|
history
diff --git
a/fs/nfs/nfs4xdr.c
b/fs/nfs/nfs4xdr.c
index e6e8f3b9a1dea29908a5179a38293dfbefce0ad8..fc97fd5399aaca1e12640f8a93e5423a0fa16379 100644
(file)
--- a/
fs/nfs/nfs4xdr.c
+++ b/
fs/nfs/nfs4xdr.c
@@
-1888,7
+1888,7
@@
encode_layoutcommit(struct xdr_stream *xdr,
*p++ = cpu_to_be32(OP_LAYOUTCOMMIT);
/* Only whole file layouts */
p = xdr_encode_hyper(p, 0); /* offset */
- p = xdr_encode_hyper(p,
NFS4_MAX_UINT64);
/* length */
+ p = xdr_encode_hyper(p,
args->lastbytewritten + 1);
/* length */
*p++ = cpu_to_be32(0); /* reclaim */
p = xdr_encode_opaque_fixed(p, args->stateid.data, NFS4_STATEID_SIZE);
*p++ = cpu_to_be32(1); /* newoffset = TRUE */