Lines Matching refs:xdr
89 static void encode_fallocate(struct xdr_stream *xdr, in encode_fallocate() argument
92 encode_nfs4_stateid(xdr, &args->falloc_stateid); in encode_fallocate()
93 encode_uint64(xdr, args->falloc_offset); in encode_fallocate()
94 encode_uint64(xdr, args->falloc_length); in encode_fallocate()
97 static void encode_allocate(struct xdr_stream *xdr, in encode_allocate() argument
101 encode_op_hdr(xdr, OP_ALLOCATE, decode_allocate_maxsz, hdr); in encode_allocate()
102 encode_fallocate(xdr, args); in encode_allocate()
105 static void encode_deallocate(struct xdr_stream *xdr, in encode_deallocate() argument
109 encode_op_hdr(xdr, OP_DEALLOCATE, decode_deallocate_maxsz, hdr); in encode_deallocate()
110 encode_fallocate(xdr, args); in encode_deallocate()
113 static void encode_seek(struct xdr_stream *xdr, in encode_seek() argument
117 encode_op_hdr(xdr, OP_SEEK, decode_seek_maxsz, hdr); in encode_seek()
118 encode_nfs4_stateid(xdr, &args->sa_stateid); in encode_seek()
119 encode_uint64(xdr, args->sa_offset); in encode_seek()
120 encode_uint32(xdr, args->sa_what); in encode_seek()
123 static void encode_layoutstats(struct xdr_stream *xdr, in encode_layoutstats() argument
130 encode_op_hdr(xdr, OP_LAYOUTSTATS, decode_layoutstats_maxsz, hdr); in encode_layoutstats()
131 p = reserve_space(xdr, 8 + 8); in encode_layoutstats()
134 encode_nfs4_stateid(xdr, &args->stateid); in encode_layoutstats()
135 p = reserve_space(xdr, 4*8 + NFS4_DEVICEID4_SIZE + 4); in encode_layoutstats()
145 devinfo->layoutstats_encode(xdr, args, devinfo); in encode_layoutstats()
147 encode_uint32(xdr, 0); in encode_layoutstats()
150 static void encode_clone(struct xdr_stream *xdr, in encode_clone() argument
156 encode_op_hdr(xdr, OP_CLONE, decode_clone_maxsz, hdr); in encode_clone()
157 encode_nfs4_stateid(xdr, &args->src_stateid); in encode_clone()
158 encode_nfs4_stateid(xdr, &args->dst_stateid); in encode_clone()
159 p = reserve_space(xdr, 3*8); in encode_clone()
169 struct xdr_stream *xdr, in nfs4_xdr_enc_allocate() argument
176 encode_compound_hdr(xdr, req, &hdr); in nfs4_xdr_enc_allocate()
177 encode_sequence(xdr, &args->seq_args, &hdr); in nfs4_xdr_enc_allocate()
178 encode_putfh(xdr, args->falloc_fh, &hdr); in nfs4_xdr_enc_allocate()
179 encode_allocate(xdr, args, &hdr); in nfs4_xdr_enc_allocate()
180 encode_getfattr(xdr, args->falloc_bitmask, &hdr); in nfs4_xdr_enc_allocate()
188 struct xdr_stream *xdr, in nfs4_xdr_enc_deallocate() argument
195 encode_compound_hdr(xdr, req, &hdr); in nfs4_xdr_enc_deallocate()
196 encode_sequence(xdr, &args->seq_args, &hdr); in nfs4_xdr_enc_deallocate()
197 encode_putfh(xdr, args->falloc_fh, &hdr); in nfs4_xdr_enc_deallocate()
198 encode_deallocate(xdr, args, &hdr); in nfs4_xdr_enc_deallocate()
199 encode_getfattr(xdr, args->falloc_bitmask, &hdr); in nfs4_xdr_enc_deallocate()
207 struct xdr_stream *xdr, in nfs4_xdr_enc_seek() argument
214 encode_compound_hdr(xdr, req, &hdr); in nfs4_xdr_enc_seek()
215 encode_sequence(xdr, &args->seq_args, &hdr); in nfs4_xdr_enc_seek()
216 encode_putfh(xdr, args->sa_fh, &hdr); in nfs4_xdr_enc_seek()
217 encode_seek(xdr, args, &hdr); in nfs4_xdr_enc_seek()
225 struct xdr_stream *xdr, in nfs4_xdr_enc_layoutstats() argument
234 encode_compound_hdr(xdr, req, &hdr); in nfs4_xdr_enc_layoutstats()
235 encode_sequence(xdr, &args->seq_args, &hdr); in nfs4_xdr_enc_layoutstats()
236 encode_putfh(xdr, args->fh, &hdr); in nfs4_xdr_enc_layoutstats()
239 encode_layoutstats(xdr, args, &args->devinfo[i], &hdr); in nfs4_xdr_enc_layoutstats()
247 struct xdr_stream *xdr, in nfs4_xdr_enc_clone() argument
254 encode_compound_hdr(xdr, req, &hdr); in nfs4_xdr_enc_clone()
255 encode_sequence(xdr, &args->seq_args, &hdr); in nfs4_xdr_enc_clone()
256 encode_putfh(xdr, args->src_fh, &hdr); in nfs4_xdr_enc_clone()
257 encode_savefh(xdr, &hdr); in nfs4_xdr_enc_clone()
258 encode_putfh(xdr, args->dst_fh, &hdr); in nfs4_xdr_enc_clone()
259 encode_clone(xdr, args, &hdr); in nfs4_xdr_enc_clone()
260 encode_getfattr(xdr, args->dst_bitmask, &hdr); in nfs4_xdr_enc_clone()
264 static int decode_allocate(struct xdr_stream *xdr, struct nfs42_falloc_res *res) in decode_allocate() argument
266 return decode_op_hdr(xdr, OP_ALLOCATE); in decode_allocate()
269 static int decode_deallocate(struct xdr_stream *xdr, struct nfs42_falloc_res *res) in decode_deallocate() argument
271 return decode_op_hdr(xdr, OP_DEALLOCATE); in decode_deallocate()
274 static int decode_seek(struct xdr_stream *xdr, struct nfs42_seek_res *res) in decode_seek() argument
279 status = decode_op_hdr(xdr, OP_SEEK); in decode_seek()
283 p = xdr_inline_decode(xdr, 4 + 8); in decode_seek()
292 print_overflow_msg(__func__, xdr); in decode_seek()
296 static int decode_layoutstats(struct xdr_stream *xdr) in decode_layoutstats() argument
298 return decode_op_hdr(xdr, OP_LAYOUTSTATS); in decode_layoutstats()
301 static int decode_clone(struct xdr_stream *xdr) in decode_clone() argument
303 return decode_op_hdr(xdr, OP_CLONE); in decode_clone()
310 struct xdr_stream *xdr, in nfs4_xdr_dec_allocate() argument
316 status = decode_compound_hdr(xdr, &hdr); in nfs4_xdr_dec_allocate()
319 status = decode_sequence(xdr, &res->seq_res, rqstp); in nfs4_xdr_dec_allocate()
322 status = decode_putfh(xdr); in nfs4_xdr_dec_allocate()
325 status = decode_allocate(xdr, res); in nfs4_xdr_dec_allocate()
328 decode_getfattr(xdr, res->falloc_fattr, res->falloc_server); in nfs4_xdr_dec_allocate()
337 struct xdr_stream *xdr, in nfs4_xdr_dec_deallocate() argument
343 status = decode_compound_hdr(xdr, &hdr); in nfs4_xdr_dec_deallocate()
346 status = decode_sequence(xdr, &res->seq_res, rqstp); in nfs4_xdr_dec_deallocate()
349 status = decode_putfh(xdr); in nfs4_xdr_dec_deallocate()
352 status = decode_deallocate(xdr, res); in nfs4_xdr_dec_deallocate()
355 decode_getfattr(xdr, res->falloc_fattr, res->falloc_server); in nfs4_xdr_dec_deallocate()
364 struct xdr_stream *xdr, in nfs4_xdr_dec_seek() argument
370 status = decode_compound_hdr(xdr, &hdr); in nfs4_xdr_dec_seek()
373 status = decode_sequence(xdr, &res->seq_res, rqstp); in nfs4_xdr_dec_seek()
376 status = decode_putfh(xdr); in nfs4_xdr_dec_seek()
379 status = decode_seek(xdr, res); in nfs4_xdr_dec_seek()
388 struct xdr_stream *xdr, in nfs4_xdr_dec_layoutstats() argument
394 status = decode_compound_hdr(xdr, &hdr); in nfs4_xdr_dec_layoutstats()
397 status = decode_sequence(xdr, &res->seq_res, rqstp); in nfs4_xdr_dec_layoutstats()
400 status = decode_putfh(xdr); in nfs4_xdr_dec_layoutstats()
405 status = decode_layoutstats(xdr); in nfs4_xdr_dec_layoutstats()
418 struct xdr_stream *xdr, in nfs4_xdr_dec_clone() argument
424 status = decode_compound_hdr(xdr, &hdr); in nfs4_xdr_dec_clone()
427 status = decode_sequence(xdr, &res->seq_res, rqstp); in nfs4_xdr_dec_clone()
430 status = decode_putfh(xdr); in nfs4_xdr_dec_clone()
433 status = decode_savefh(xdr); in nfs4_xdr_dec_clone()
436 status = decode_putfh(xdr); in nfs4_xdr_dec_clone()
439 status = decode_clone(xdr); in nfs4_xdr_dec_clone()
442 status = decode_getfattr(xdr, res->dst_fattr, res->server); in nfs4_xdr_dec_clone()