• Home
  • Raw
  • Download

Lines Matching refs:rctxt

416 static bool xdr_count_read_segments(struct svc_rdma_recv_ctxt *rctxt, __be32 *p)  in xdr_count_read_segments()  argument
418 rctxt->rc_call_pcl.cl_count = 0; in xdr_count_read_segments()
419 rctxt->rc_read_pcl.cl_count = 0; in xdr_count_read_segments()
424 p = xdr_inline_decode(&rctxt->rc_stream, in xdr_count_read_segments()
434 ++rctxt->rc_read_pcl.cl_count; in xdr_count_read_segments()
436 ++rctxt->rc_call_pcl.cl_count; in xdr_count_read_segments()
439 p = xdr_inline_decode(&rctxt->rc_stream, sizeof(*p)); in xdr_count_read_segments()
458 static bool xdr_check_read_list(struct svc_rdma_recv_ctxt *rctxt) in xdr_check_read_list() argument
462 p = xdr_inline_decode(&rctxt->rc_stream, sizeof(*p)); in xdr_check_read_list()
465 if (!xdr_count_read_segments(rctxt, p)) in xdr_check_read_list()
467 if (!pcl_alloc_call(rctxt, p)) in xdr_check_read_list()
469 return pcl_alloc_read(rctxt, p); in xdr_check_read_list()
472 static bool xdr_check_write_chunk(struct svc_rdma_recv_ctxt *rctxt) in xdr_check_write_chunk() argument
477 if (xdr_stream_decode_u32(&rctxt->rc_stream, &segcount)) in xdr_check_write_chunk()
481 p = xdr_inline_decode(&rctxt->rc_stream, in xdr_check_write_chunk()
501 static bool xdr_count_write_chunks(struct svc_rdma_recv_ctxt *rctxt, __be32 *p) in xdr_count_write_chunks() argument
503 rctxt->rc_write_pcl.cl_count = 0; in xdr_count_write_chunks()
505 if (!xdr_check_write_chunk(rctxt)) in xdr_count_write_chunks()
507 ++rctxt->rc_write_pcl.cl_count; in xdr_count_write_chunks()
508 p = xdr_inline_decode(&rctxt->rc_stream, sizeof(*p)); in xdr_count_write_chunks()
530 static bool xdr_check_write_list(struct svc_rdma_recv_ctxt *rctxt) in xdr_check_write_list() argument
534 p = xdr_inline_decode(&rctxt->rc_stream, sizeof(*p)); in xdr_check_write_list()
537 if (!xdr_count_write_chunks(rctxt, p)) in xdr_check_write_list()
539 if (!pcl_alloc_write(rctxt, &rctxt->rc_write_pcl, p)) in xdr_check_write_list()
542 rctxt->rc_cur_result_payload = pcl_first_chunk(&rctxt->rc_write_pcl); in xdr_check_write_list()
558 static bool xdr_check_reply_chunk(struct svc_rdma_recv_ctxt *rctxt) in xdr_check_reply_chunk() argument
562 p = xdr_inline_decode(&rctxt->rc_stream, sizeof(*p)); in xdr_check_reply_chunk()
568 if (!xdr_check_write_chunk(rctxt)) in xdr_check_reply_chunk()
571 rctxt->rc_reply_pcl.cl_count = 1; in xdr_check_reply_chunk()
572 return pcl_alloc_write(rctxt, &rctxt->rc_reply_pcl, p); in xdr_check_reply_chunk()
647 struct svc_rdma_recv_ctxt *rctxt) in svc_rdma_xdr_decode_req() argument
653 xdr_init_decode(&rctxt->rc_stream, rq_arg, rdma_argp, NULL); in svc_rdma_xdr_decode_req()
655 p = xdr_inline_decode(&rctxt->rc_stream, in svc_rdma_xdr_decode_req()
663 rctxt->rc_msgtype = *p; in svc_rdma_xdr_decode_req()
664 switch (rctxt->rc_msgtype) { in svc_rdma_xdr_decode_req()
677 if (!xdr_check_read_list(rctxt)) in svc_rdma_xdr_decode_req()
679 if (!xdr_check_write_list(rctxt)) in svc_rdma_xdr_decode_req()
681 if (!xdr_check_reply_chunk(rctxt)) in svc_rdma_xdr_decode_req()
684 rq_arg->head[0].iov_base = rctxt->rc_stream.p; in svc_rdma_xdr_decode_req()
685 hdr_len = xdr_stream_pos(&rctxt->rc_stream); in svc_rdma_xdr_decode_req()
688 trace_svcrdma_decode_rqst(rctxt, rdma_argp, hdr_len); in svc_rdma_xdr_decode_req()
692 trace_svcrdma_decode_short_err(rctxt, rq_arg->len); in svc_rdma_xdr_decode_req()
696 trace_svcrdma_decode_badvers_err(rctxt, rdma_argp); in svc_rdma_xdr_decode_req()
700 trace_svcrdma_decode_drop_err(rctxt, rdma_argp); in svc_rdma_xdr_decode_req()
704 trace_svcrdma_decode_badproc_err(rctxt, rdma_argp); in svc_rdma_xdr_decode_req()
708 trace_svcrdma_decode_parse_err(rctxt, rdma_argp); in svc_rdma_xdr_decode_req()
713 struct svc_rdma_recv_ctxt *rctxt, in svc_rdma_send_error() argument
721 svc_rdma_send_error_msg(rdma, sctxt, rctxt, status); in svc_rdma_send_error()
730 struct svc_rdma_recv_ctxt *rctxt) in svc_rdma_is_reverse_direction_reply() argument
732 __be32 *p = rctxt->rc_recv_buf; in svc_rdma_is_reverse_direction_reply()
737 if (rctxt->rc_msgtype != rdma_msg) in svc_rdma_is_reverse_direction_reply()
740 if (!pcl_is_empty(&rctxt->rc_call_pcl)) in svc_rdma_is_reverse_direction_reply()
742 if (!pcl_is_empty(&rctxt->rc_read_pcl)) in svc_rdma_is_reverse_direction_reply()
744 if (!pcl_is_empty(&rctxt->rc_write_pcl)) in svc_rdma_is_reverse_direction_reply()
746 if (!pcl_is_empty(&rctxt->rc_reply_pcl)) in svc_rdma_is_reverse_direction_reply()