Loading fs/nfs/nfs42xdr.c +19 −17 Original line number Diff line number Diff line Loading @@ -1032,7 +1032,7 @@ static int decode_read_plus_data(struct xdr_stream *xdr, struct nfs_pgio_res *re p = xdr_decode_hyper(p, &offset); count = be32_to_cpup(p); recvd = xdr_read_pages(xdr, count); recvd = xdr_align_data(xdr, res->count, count); res->count += recvd; if (count > recvd) { Loading @@ -1057,7 +1057,7 @@ static int decode_read_plus_hole(struct xdr_stream *xdr, struct nfs_pgio_res *re p = xdr_decode_hyper(p, &offset); p = xdr_decode_hyper(p, &length); recvd = xdr_expand_hole(xdr, 0, length); recvd = xdr_expand_hole(xdr, res->count, length); res->count += recvd; if (recvd < length) { Loading @@ -1070,7 +1070,7 @@ static int decode_read_plus_hole(struct xdr_stream *xdr, struct nfs_pgio_res *re static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res) { uint32_t eof, segments, type; int status; int status, i; __be32 *p; status = decode_op_hdr(xdr, OP_READ_PLUS); Loading @@ -1086,6 +1086,7 @@ static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res) if (segments == 0) goto out; for (i = 0; i < segments; i++) { p = xdr_inline_decode(xdr, 4); if (unlikely(!p)) return -EIO; Loading @@ -1098,10 +1099,11 @@ static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res) else return -EINVAL; if (status) if (status < 0) return status; if (segments > 1) eof = 0; if (status > 0) break; } out: res->eof = eof; Loading Loading
fs/nfs/nfs42xdr.c +19 −17 Original line number Diff line number Diff line Loading @@ -1032,7 +1032,7 @@ static int decode_read_plus_data(struct xdr_stream *xdr, struct nfs_pgio_res *re p = xdr_decode_hyper(p, &offset); count = be32_to_cpup(p); recvd = xdr_read_pages(xdr, count); recvd = xdr_align_data(xdr, res->count, count); res->count += recvd; if (count > recvd) { Loading @@ -1057,7 +1057,7 @@ static int decode_read_plus_hole(struct xdr_stream *xdr, struct nfs_pgio_res *re p = xdr_decode_hyper(p, &offset); p = xdr_decode_hyper(p, &length); recvd = xdr_expand_hole(xdr, 0, length); recvd = xdr_expand_hole(xdr, res->count, length); res->count += recvd; if (recvd < length) { Loading @@ -1070,7 +1070,7 @@ static int decode_read_plus_hole(struct xdr_stream *xdr, struct nfs_pgio_res *re static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res) { uint32_t eof, segments, type; int status; int status, i; __be32 *p; status = decode_op_hdr(xdr, OP_READ_PLUS); Loading @@ -1086,6 +1086,7 @@ static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res) if (segments == 0) goto out; for (i = 0; i < segments; i++) { p = xdr_inline_decode(xdr, 4); if (unlikely(!p)) return -EIO; Loading @@ -1098,10 +1099,11 @@ static int decode_read_plus(struct xdr_stream *xdr, struct nfs_pgio_res *res) else return -EINVAL; if (status) if (status < 0) return status; if (segments > 1) eof = 0; if (status > 0) break; } out: res->eof = eof; Loading