Lines Matching refs:xdr

89 static void encode_bool(struct xdr_stream *xdr, const int value)  in encode_bool()  argument
93 p = xdr_reserve_space(xdr, 4); in encode_bool()
97 static void encode_int32(struct xdr_stream *xdr, const s32 value) in encode_int32() argument
101 p = xdr_reserve_space(xdr, 4); in encode_int32()
108 static void encode_netobj(struct xdr_stream *xdr, in encode_netobj() argument
113 p = xdr_reserve_space(xdr, 4 + length); in encode_netobj()
117 static int decode_netobj(struct xdr_stream *xdr, in decode_netobj() argument
122 ret = xdr_stream_decode_opaque_inline(xdr, (void *)&obj->data, in decode_netobj()
133 static void encode_cookie(struct xdr_stream *xdr, in encode_cookie() argument
136 encode_netobj(xdr, (u8 *)&cookie->data, cookie->len); in encode_cookie()
139 static int decode_cookie(struct xdr_stream *xdr, in decode_cookie() argument
145 p = xdr_inline_decode(xdr, 4); in decode_cookie()
154 p = xdr_inline_decode(xdr, length); in decode_cookie()
174 static void encode_fh(struct xdr_stream *xdr, const struct nfs_fh *fh) in encode_fh() argument
176 encode_netobj(xdr, (u8 *)&fh->data, fh->size); in encode_fh()
201 static void encode_nlm4_stat(struct xdr_stream *xdr, in encode_nlm4_stat() argument
207 p = xdr_reserve_space(xdr, 4); in encode_nlm4_stat()
211 static int decode_nlm4_stat(struct xdr_stream *xdr, __be32 *stat) in decode_nlm4_stat() argument
215 p = xdr_inline_decode(xdr, 4); in decode_nlm4_stat()
239 static void encode_nlm4_holder(struct xdr_stream *xdr, in encode_nlm4_holder() argument
246 encode_bool(xdr, lock->fl.fl_type == F_RDLCK); in encode_nlm4_holder()
247 encode_int32(xdr, lock->svid); in encode_nlm4_holder()
248 encode_netobj(xdr, lock->oh.data, lock->oh.len); in encode_nlm4_holder()
250 p = xdr_reserve_space(xdr, 4 + 4); in encode_nlm4_holder()
256 static int decode_nlm4_holder(struct xdr_stream *xdr, struct nlm_res *result) in decode_nlm4_holder() argument
268 p = xdr_inline_decode(xdr, 4 + 4); in decode_nlm4_holder()
275 error = decode_netobj(xdr, &lock->oh); in decode_nlm4_holder()
279 p = xdr_inline_decode(xdr, 8 + 8); in decode_nlm4_holder()
298 static void encode_caller_name(struct xdr_stream *xdr, const char *name) in encode_caller_name() argument
304 p = xdr_reserve_space(xdr, 4 + length); in encode_caller_name()
318 static void encode_nlm4_lock(struct xdr_stream *xdr, in encode_nlm4_lock() argument
324 encode_caller_name(xdr, lock->caller); in encode_nlm4_lock()
325 encode_fh(xdr, &lock->fh); in encode_nlm4_lock()
326 encode_netobj(xdr, lock->oh.data, lock->oh.len); in encode_nlm4_lock()
328 p = xdr_reserve_space(xdr, 4 + 8 + 8); in encode_nlm4_lock()
353 struct xdr_stream *xdr, in nlm4_xdr_enc_testargs() argument
359 encode_cookie(xdr, &args->cookie); in nlm4_xdr_enc_testargs()
360 encode_bool(xdr, lock->fl.fl_type == F_WRLCK); in nlm4_xdr_enc_testargs()
361 encode_nlm4_lock(xdr, lock); in nlm4_xdr_enc_testargs()
375 struct xdr_stream *xdr, in nlm4_xdr_enc_lockargs() argument
381 encode_cookie(xdr, &args->cookie); in nlm4_xdr_enc_lockargs()
382 encode_bool(xdr, args->block); in nlm4_xdr_enc_lockargs()
383 encode_bool(xdr, lock->fl.fl_type == F_WRLCK); in nlm4_xdr_enc_lockargs()
384 encode_nlm4_lock(xdr, lock); in nlm4_xdr_enc_lockargs()
385 encode_bool(xdr, args->reclaim); in nlm4_xdr_enc_lockargs()
386 encode_int32(xdr, args->state); in nlm4_xdr_enc_lockargs()
398 struct xdr_stream *xdr, in nlm4_xdr_enc_cancargs() argument
404 encode_cookie(xdr, &args->cookie); in nlm4_xdr_enc_cancargs()
405 encode_bool(xdr, args->block); in nlm4_xdr_enc_cancargs()
406 encode_bool(xdr, lock->fl.fl_type == F_WRLCK); in nlm4_xdr_enc_cancargs()
407 encode_nlm4_lock(xdr, lock); in nlm4_xdr_enc_cancargs()
417 struct xdr_stream *xdr, in nlm4_xdr_enc_unlockargs() argument
423 encode_cookie(xdr, &args->cookie); in nlm4_xdr_enc_unlockargs()
424 encode_nlm4_lock(xdr, lock); in nlm4_xdr_enc_unlockargs()
434 struct xdr_stream *xdr, in nlm4_xdr_enc_res() argument
439 encode_cookie(xdr, &result->cookie); in nlm4_xdr_enc_res()
440 encode_nlm4_stat(xdr, result->status); in nlm4_xdr_enc_res()
457 struct xdr_stream *xdr, in nlm4_xdr_enc_testres() argument
462 encode_cookie(xdr, &result->cookie); in nlm4_xdr_enc_testres()
463 encode_nlm4_stat(xdr, result->status); in nlm4_xdr_enc_testres()
465 encode_nlm4_holder(xdr, result); in nlm4_xdr_enc_testres()
490 static int decode_nlm4_testrply(struct xdr_stream *xdr, in decode_nlm4_testrply() argument
495 error = decode_nlm4_stat(xdr, &result->status); in decode_nlm4_testrply()
499 error = decode_nlm4_holder(xdr, result); in decode_nlm4_testrply()
505 struct xdr_stream *xdr, in nlm4_xdr_dec_testres() argument
511 error = decode_cookie(xdr, &result->cookie); in nlm4_xdr_dec_testres()
514 error = decode_nlm4_testrply(xdr, result); in nlm4_xdr_dec_testres()
526 struct xdr_stream *xdr, in nlm4_xdr_dec_res() argument
532 error = decode_cookie(xdr, &result->cookie); in nlm4_xdr_dec_res()
535 error = decode_nlm4_stat(xdr, &result->status); in nlm4_xdr_dec_res()