History

Merge tag 'nfs-rdma-for-5.11-1' of git://git.linux-nfs.org/projects/anna/linux-nfs into linux-next

NFSoRDmA Client updates for Linux 5.11 Cleanups and improvements: - Remove use of raw kernel memory addresses in tracepoints - Replace dprintk() call sites in ERR_CHUNK path - Trace unmap sync calls - Optimize MR DMA-unmapping

Trond Myklebust committed 5 years ago

Commit edffb842 parents 5c3485b 7a03aeb7 files · +302 −313Browse files

Showing the changes to include/trace (1 of 7 files). Show all

Unified · Split

include/trace/events/rpcrdma.h+212−238
@@ -60,7 +60,7 @@ DECLARE_EVENT_CLASS(rpcrdma_completion_class, · 59 unmodified lines
60 ), \60 ), \
61 TP_ARGS(wc, cid))61 TP_ARGS(wc, cid))
62 62
63DECLARE_EVENT_CLASS(xprtrdma_reply_event,63DECLARE_EVENT_CLASS(xprtrdma_reply_class,
64 TP_PROTO(64 TP_PROTO(
65 const struct rpcrdma_rep *rep65 const struct rpcrdma_rep *rep
66 ),66 ),
@@ -68,29 +68,30 @@ DECLARE_EVENT_CLASS(xprtrdma_reply_event, · 1 unmodified line
68 TP_ARGS(rep),68 TP_ARGS(rep),
69 69
70 TP_STRUCT__entry(70 TP_STRUCT__entry(
71 __field(const void *, rep)
72 __field(const void *, r_xprt)
73 __field(u32, xid)71 __field(u32, xid)
74 __field(u32, version)72 __field(u32, version)
75 __field(u32, proc)73 __field(u32, proc)
74 __string(addr, rpcrdma_addrstr(rep->rr_rxprt))
75 __string(port, rpcrdma_portstr(rep->rr_rxprt))
76 ),76 ),
77 77
78 TP_fast_assign(78 TP_fast_assign(
79 __entry->rep = rep;
80 __entry->r_xprt = rep->rr_rxprt;
81 __entry->xid = be32_to_cpu(rep->rr_xid);79 __entry->xid = be32_to_cpu(rep->rr_xid);
82 __entry->version = be32_to_cpu(rep->rr_vers);80 __entry->version = be32_to_cpu(rep->rr_vers);
83 __entry->proc = be32_to_cpu(rep->rr_proc);81 __entry->proc = be32_to_cpu(rep->rr_proc);
82 __assign_str(addr, rpcrdma_addrstr(rep->rr_rxprt));
83 __assign_str(port, rpcrdma_portstr(rep->rr_rxprt));
84 ),84 ),
85 85
86 TP_printk("rxprt %p xid=0x%08x rep=%p: version %u proc %u",86 TP_printk("peer=[%s]:%s xid=0x%08x version=%u proc=%u",
87 __entry->r_xprt, __entry->xid, __entry->rep,87 __get_str(addr), __get_str(port),
88 __entry->version, __entry->proc88 __entry->xid, __entry->version, __entry->proc
89 )89 )
90);90);
91 91
92#define DEFINE_REPLY_EVENT(name) \92#define DEFINE_REPLY_EVENT(name) \
93 DEFINE_EVENT(xprtrdma_reply_event, name, \93 DEFINE_EVENT(xprtrdma_reply_class, \
94 xprtrdma_reply_##name##_err, \
94 TP_PROTO( \95 TP_PROTO( \
95 const struct rpcrdma_rep *rep \96 const struct rpcrdma_rep *rep \
96 ), \97 ), \
@@ -261,54 +262,67 @@ DECLARE_EVENT_CLASS(xprtrdma_wrch_event, · 164 unmodified lines
261 ), \262 ), \
262 TP_ARGS(task, mr, nsegs))263 TP_ARGS(task, mr, nsegs))
263 264
264DECLARE_EVENT_CLASS(xprtrdma_frwr_done,265TRACE_DEFINE_ENUM(DMA_BIDIRECTIONAL);
266TRACE_DEFINE_ENUM(DMA_TO_DEVICE);
267TRACE_DEFINE_ENUM(DMA_FROM_DEVICE);
268TRACE_DEFINE_ENUM(DMA_NONE);
269
270#define xprtrdma_show_direction(x) \
271 __print_symbolic(x, \
272 { DMA_BIDIRECTIONAL, "BIDIR" }, \
273 { DMA_TO_DEVICE, "TO_DEVICE" }, \
274 { DMA_FROM_DEVICE, "FROM_DEVICE" }, \
275 { DMA_NONE, "NONE" })
276
277DECLARE_EVENT_CLASS(xprtrdma_mr_class,
265 TP_PROTO(278 TP_PROTO(
266 const struct ib_wc *wc,279 const struct rpcrdma_mr *mr
267 const struct rpcrdma_frwr *frwr
268 ),280 ),
269 281
270 TP_ARGS(wc, frwr),282 TP_ARGS(mr),
271 283
272 TP_STRUCT__entry(284 TP_STRUCT__entry(
285 __field(unsigned int, task_id)
286 __field(unsigned int, client_id)
273 __field(u32, mr_id)287 __field(u32, mr_id)
274 __field(unsigned int, status)288 __field(int, nents)
275 __field(unsigned int, vendor_err)289 __field(u32, handle)
290 __field(u32, length)
291 __field(u64, offset)
292 __field(u32, dir)
276 ),293 ),
277 294
278 TP_fast_assign(295 TP_fast_assign(
279 __entry->mr_id = frwr->fr_mr->res.id;296 const struct rpcrdma_req *req = mr->mr_req;
280 __entry->status = wc->status;297 const struct rpc_task *task = req->rl_slot.rq_task;
281 __entry->vendor_err = __entry->status ? wc->vendor_err : 0;298
299 __entry->task_id = task->tk_pid;
300 __entry->client_id = task->tk_client->cl_clid;
301 __entry->mr_id = mr->frwr.fr_mr->res.id;
302 __entry->nents = mr->mr_nents;
303 __entry->handle = mr->mr_handle;
304 __entry->length = mr->mr_length;
305 __entry->offset = mr->mr_offset;
306 __entry->dir = mr->mr_dir;
282 ),307 ),
283 308
284 TP_printk(309 TP_printk("task:%u@%u mr.id=%u nents=%d %u@0x%016llx:0x%08x (%s)",
285 "mr.id=%u: %s (%u/0x%x)",310 __entry->task_id, __entry->client_id,
286 __entry->mr_id, rdma_show_wc_status(__entry->status),311 __entry->mr_id, __entry->nents, __entry->length,
287 __entry->status, __entry->vendor_err312 (unsigned long long)__entry->offset, __entry->handle,
313 xprtrdma_show_direction(__entry->dir)
288 )314 )
289);315);
290 316
291#define DEFINE_FRWR_DONE_EVENT(name) \317#define DEFINE_MR_EVENT(name) \
292 DEFINE_EVENT(xprtrdma_frwr_done, name, \318 DEFINE_EVENT(xprtrdma_mr_class, \
319 xprtrdma_mr_##name, \
293 TP_PROTO( \320 TP_PROTO( \
294 const struct ib_wc *wc, \321 const struct rpcrdma_mr *mr \
295 const struct rpcrdma_frwr *frwr \
296 ), \322 ), \
297 TP_ARGS(wc, frwr))323 TP_ARGS(mr))
298
299TRACE_DEFINE_ENUM(DMA_BIDIRECTIONAL);
300TRACE_DEFINE_ENUM(DMA_TO_DEVICE);
301TRACE_DEFINE_ENUM(DMA_FROM_DEVICE);
302TRACE_DEFINE_ENUM(DMA_NONE);
303
304#define xprtrdma_show_direction(x) \
305 __print_symbolic(x, \
306 { DMA_BIDIRECTIONAL, "BIDIR" }, \
307 { DMA_TO_DEVICE, "TO_DEVICE" }, \
308 { DMA_FROM_DEVICE, "FROM_DEVICE" }, \
309 { DMA_NONE, "NONE" })
310 324
311DECLARE_EVENT_CLASS(xprtrdma_mr,325DECLARE_EVENT_CLASS(xprtrdma_anonymous_mr_class,
312 TP_PROTO(326 TP_PROTO(
313 const struct rpcrdma_mr *mr327 const struct rpcrdma_mr *mr
314 ),328 ),
@@ -340,45 +354,47 @@ DECLARE_EVENT_CLASS(xprtrdma_mr, · 25 unmodified lines
340 )354 )
341);355);
342 356
343#define DEFINE_MR_EVENT(name) \357#define DEFINE_ANON_MR_EVENT(name) \
344 DEFINE_EVENT(xprtrdma_mr, xprtrdma_mr_##name, \358 DEFINE_EVENT(xprtrdma_anonymous_mr_class, \
345 TP_PROTO( \359 xprtrdma_mr_##name, \
346 const struct rpcrdma_mr *mr \360 TP_PROTO( \
347 ), \361 const struct rpcrdma_mr *mr \
362 ), \
348 TP_ARGS(mr))363 TP_ARGS(mr))
349 364
350DECLARE_EVENT_CLASS(xprtrdma_cb_event,365DECLARE_EVENT_CLASS(xprtrdma_callback_class,
351 TP_PROTO(366 TP_PROTO(
367 const struct rpcrdma_xprt *r_xprt,
352 const struct rpc_rqst *rqst368 const struct rpc_rqst *rqst
353 ),369 ),
354 370
355 TP_ARGS(rqst),371 TP_ARGS(r_xprt, rqst),
356 372
357 TP_STRUCT__entry(373 TP_STRUCT__entry(
358 __field(const void *, rqst)
359 __field(const void *, rep)
360 __field(const void *, req)
361 __field(u32, xid)374 __field(u32, xid)
375 __string(addr, rpcrdma_addrstr(r_xprt))
376 __string(port, rpcrdma_portstr(r_xprt))
362 ),377 ),
363 378
364 TP_fast_assign(379 TP_fast_assign(
365 __entry->rqst = rqst;
366 __entry->req = rpcr_to_rdmar(rqst);
367 __entry->rep = rpcr_to_rdmar(rqst)->rl_reply;
368 __entry->xid = be32_to_cpu(rqst->rq_xid);380 __entry->xid = be32_to_cpu(rqst->rq_xid);
381 __assign_str(addr, rpcrdma_addrstr(r_xprt));
382 __assign_str(port, rpcrdma_portstr(r_xprt));
369 ),383 ),
370 384
371 TP_printk("xid=0x%08x, rqst=%p req=%p rep=%p",385 TP_printk("peer=[%s]:%s xid=0x%08x",
372 __entry->xid, __entry->rqst, __entry->req, __entry->rep386 __get_str(addr), __get_str(port), __entry->xid
373 )387 )
374);388);
375 389
376#define DEFINE_CB_EVENT(name) \390#define DEFINE_CALLBACK_EVENT(name) \
377 DEFINE_EVENT(xprtrdma_cb_event, name, \391 DEFINE_EVENT(xprtrdma_callback_class, \
392 xprtrdma_cb_##name, \
378 TP_PROTO( \393 TP_PROTO( \
394 const struct rpcrdma_xprt *r_xprt, \
379 const struct rpc_rqst *rqst \395 const struct rpc_rqst *rqst \
380 ), \396 ), \
381 TP_ARGS(rqst))397 TP_ARGS(r_xprt, rqst))
382 398
383/**399/**
384 ** Connection events400 ** Connection events
@@ -549,61 +565,33 @@ TRACE_EVENT(xprtrdma_createmrs, · 164 unmodified lines
549 )565 )
550);566);
551 567
552TRACE_EVENT(xprtrdma_mr_get,568TRACE_EVENT(xprtrdma_nomrs_err,
553 TP_PROTO(
554 const struct rpcrdma_req *req
555 ),
556
557 TP_ARGS(req),
558
559 TP_STRUCT__entry(
560 __field(const void *, req)
561 __field(unsigned int, task_id)
562 __field(unsigned int, client_id)
563 __field(u32, xid)
564 ),
565
566 TP_fast_assign(
567 const struct rpc_rqst *rqst = &req->rl_slot;
568
569 __entry->req = req;
570 __entry->task_id = rqst->rq_task->tk_pid;
571 __entry->client_id = rqst->rq_task->tk_client->cl_clid;
572 __entry->xid = be32_to_cpu(rqst->rq_xid);
573 ),
574
575 TP_printk("task:%u@%u xid=0x%08x req=%p",
576 __entry->task_id, __entry->client_id, __entry->xid,
577 __entry->req
578 )
579);
580
581TRACE_EVENT(xprtrdma_nomrs,
582 TP_PROTO(569 TP_PROTO(
570 const struct rpcrdma_xprt *r_xprt,
583 const struct rpcrdma_req *req571 const struct rpcrdma_req *req
584 ),572 ),
585 573
586 TP_ARGS(req),574 TP_ARGS(r_xprt, req),
587 575
588 TP_STRUCT__entry(576 TP_STRUCT__entry(
589 __field(const void *, req)
590 __field(unsigned int, task_id)577 __field(unsigned int, task_id)
591 __field(unsigned int, client_id)578 __field(unsigned int, client_id)
592 __field(u32, xid)579 __string(addr, rpcrdma_addrstr(r_xprt))
580 __string(port, rpcrdma_portstr(r_xprt))
593 ),581 ),
594 582
595 TP_fast_assign(583 TP_fast_assign(
596 const struct rpc_rqst *rqst = &req->rl_slot;584 const struct rpc_rqst *rqst = &req->rl_slot;
597 585
598 __entry->req = req;
599 __entry->task_id = rqst->rq_task->tk_pid;586 __entry->task_id = rqst->rq_task->tk_pid;
600 __entry->client_id = rqst->rq_task->tk_client->cl_clid;587 __entry->client_id = rqst->rq_task->tk_client->cl_clid;
601 __entry->xid = be32_to_cpu(rqst->rq_xid);588 __assign_str(addr, rpcrdma_addrstr(r_xprt));
589 __assign_str(port, rpcrdma_portstr(r_xprt));
602 ),590 ),
603 591
604 TP_printk("task:%u@%u xid=0x%08x req=%p",592 TP_printk("peer=[%s]:%s task:%u@%u",
605 __entry->task_id, __entry->client_id, __entry->xid,593 __get_str(addr), __get_str(port),
606 __entry->req594 __entry->task_id, __entry->client_id
607 )595 )
608);596);
609 597
@@ -735,8 +723,8 @@ TRACE_EVENT(xprtrdma_post_send, · 125 unmodified lines
735 TP_ARGS(req),723 TP_ARGS(req),
736 724
737 TP_STRUCT__entry(725 TP_STRUCT__entry(
738 __field(const void *, req)726 __field(u32, cq_id)
739 __field(const void *, sc)727 __field(int, completion_id)
740 __field(unsigned int, task_id)728 __field(unsigned int, task_id)
741 __field(unsigned int, client_id)729 __field(unsigned int, client_id)
742 __field(int, num_sge)730 __field(int, num_sge)
@@ -745,20 +733,21 @@ TRACE_EVENT(xprtrdma_post_send, · 2 unmodified lines
745 733
746 TP_fast_assign(734 TP_fast_assign(
747 const struct rpc_rqst *rqst = &req->rl_slot;735 const struct rpc_rqst *rqst = &req->rl_slot;
736 const struct rpcrdma_sendctx *sc = req->rl_sendctx;
748 737
738 __entry->cq_id = sc->sc_cid.ci_queue_id;
739 __entry->completion_id = sc->sc_cid.ci_completion_id;
749 __entry->task_id = rqst->rq_task->tk_pid;740 __entry->task_id = rqst->rq_task->tk_pid;
750 __entry->client_id = rqst->rq_task->tk_client ?741 __entry->client_id = rqst->rq_task->tk_client ?
751 rqst->rq_task->tk_client->cl_clid : -1;742 rqst->rq_task->tk_client->cl_clid : -1;
752 __entry->req = req;
753 __entry->sc = req->rl_sendctx;
754 __entry->num_sge = req->rl_wr.num_sge;743 __entry->num_sge = req->rl_wr.num_sge;
755 __entry->signaled = req->rl_wr.send_flags & IB_SEND_SIGNALED;744 __entry->signaled = req->rl_wr.send_flags & IB_SEND_SIGNALED;
756 ),745 ),
757 746
758 TP_printk("task:%u@%u req=%p sc=%p (%d SGE%s) %s",747 TP_printk("task:%u@%u cq.id=%u cid=%d (%d SGE%s) %s",
759 __entry->task_id, __entry->client_id,748 __entry->task_id, __entry->client_id,
760 __entry->req, __entry->sc, __entry->num_sge,749 __entry->cq_id, __entry->completion_id,
761 (__entry->num_sge == 1 ? "" : "s"),750 __entry->num_sge, (__entry->num_sge == 1 ? "" : "s"),
762 (__entry->signaled ? "signaled" : "")751 (__entry->signaled ? "signaled" : "")
763 )752 )
764);753);
@@ -771,15 +760,17 @@ TRACE_EVENT(xprtrdma_post_recv, · 6 unmodified lines
771 TP_ARGS(rep),760 TP_ARGS(rep),
772 761
773 TP_STRUCT__entry(762 TP_STRUCT__entry(
774 __field(const void *, rep)763 __field(u32, cq_id)
764 __field(int, completion_id)
775 ),765 ),
776 766
777 TP_fast_assign(767 TP_fast_assign(
778 __entry->rep = rep;768 __entry->cq_id = rep->rr_cid.ci_queue_id;
769 __entry->completion_id = rep->rr_cid.ci_completion_id;
779 ),770 ),
780 771
781 TP_printk("rep=%p",772 TP_printk("cq.id=%d cid=%d",
782 __entry->rep773 __entry->cq_id, __entry->completion_id
783 )774 )
784);775);
785 776
@@ -816,7 +807,7 @@ TRACE_EVENT(xprtrdma_post_recvs, · 30 unmodified lines
816 )807 )
817);808);
818 809
819TRACE_EVENT(xprtrdma_post_linv,810TRACE_EVENT(xprtrdma_post_linv_err,
820 TP_PROTO(811 TP_PROTO(
821 const struct rpcrdma_req *req,812 const struct rpcrdma_req *req,
822 int status813 int status
@@ -825,19 +816,21 @@ TRACE_EVENT(xprtrdma_post_linv, · 2 unmodified lines
825 TP_ARGS(req, status),816 TP_ARGS(req, status),
826 817
827 TP_STRUCT__entry(818 TP_STRUCT__entry(
828 __field(const void *, req)819 __field(unsigned int, task_id)
820 __field(unsigned int, client_id)
829 __field(int, status)821 __field(int, status)
830 __field(u32, xid)
831 ),822 ),
832 823
833 TP_fast_assign(824 TP_fast_assign(
834 __entry->req = req;825 const struct rpc_task *task = req->rl_slot.rq_task;
826
827 __entry->task_id = task->tk_pid;
828 __entry->client_id = task->tk_client->cl_clid;
835 __entry->status = status;829 __entry->status = status;
836 __entry->xid = be32_to_cpu(req->rl_slot.rq_xid);
837 ),830 ),
838 831
839 TP_printk("req=%p xid=0x%08x status=%d",832 TP_printk("task:%u@%u status=%d",
840 __entry->req, __entry->xid, __entry->status833 __entry->task_id, __entry->client_id, __entry->status
841 )834 )
842);835);
843 836
@@ -845,75 +838,12 @@ TRACE_EVENT(xprtrdma_post_linv, · 1 unmodified line
845 ** Completion events838 ** Completion events
846 **/839 **/
847 840
848TRACE_EVENT(xprtrdma_wc_send,841DEFINE_COMPLETION_EVENT(xprtrdma_wc_receive);
849 TP_PROTO(842DEFINE_COMPLETION_EVENT(xprtrdma_wc_send);
850 const struct rpcrdma_sendctx *sc,843DEFINE_COMPLETION_EVENT(xprtrdma_wc_fastreg);
851 const struct ib_wc *wc844DEFINE_COMPLETION_EVENT(xprtrdma_wc_li);
852 ),845DEFINE_COMPLETION_EVENT(xprtrdma_wc_li_wake);
853 846DEFINE_COMPLETION_EVENT(xprtrdma_wc_li_done);
854 TP_ARGS(sc, wc),
855
856 TP_STRUCT__entry(
857 __field(const void *, req)
858 __field(const void *, sc)
859 __field(unsigned int, unmap_count)
860 __field(unsigned int, status)
861 __field(unsigned int, vendor_err)
862 ),
863
864 TP_fast_assign(
865 __entry->req = sc->sc_req;
866 __entry->sc = sc;
867 __entry->unmap_count = sc->sc_unmap_count;
868 __entry->status = wc->status;
869 __entry->vendor_err = __entry->status ? wc->vendor_err : 0;
870 ),
871
872 TP_printk("req=%p sc=%p unmapped=%u: %s (%u/0x%x)",
873 __entry->req, __entry->sc, __entry->unmap_count,
874 rdma_show_wc_status(__entry->status),
875 __entry->status, __entry->vendor_err
876 )
877);
878
879TRACE_EVENT(xprtrdma_wc_receive,
880 TP_PROTO(
881 const struct ib_wc *wc
882 ),
883
884 TP_ARGS(wc),
885
886 TP_STRUCT__entry(
887 __field(const void *, rep)
888 __field(u32, byte_len)
889 __field(unsigned int, status)
890 __field(u32, vendor_err)
891 ),
892
893 TP_fast_assign(
894 __entry->rep = container_of(wc->wr_cqe, struct rpcrdma_rep,
895 rr_cqe);
896 __entry->status = wc->status;
897 if (wc->status) {
898 __entry->byte_len = 0;
899 __entry->vendor_err = wc->vendor_err;
900 } else {
901 __entry->byte_len = wc->byte_len;
902 __entry->vendor_err = 0;
903 }
904 ),
905
906 TP_printk("rep=%p %u bytes: %s (%u/0x%x)",
907 __entry->rep, __entry->byte_len,
908 rdma_show_wc_status(__entry->status),
909 __entry->status, __entry->vendor_err
910 )
911);
912
913DEFINE_FRWR_DONE_EVENT(xprtrdma_wc_fastreg);
914DEFINE_FRWR_DONE_EVENT(xprtrdma_wc_li);
915DEFINE_FRWR_DONE_EVENT(xprtrdma_wc_li_wake);
916DEFINE_FRWR_DONE_EVENT(xprtrdma_wc_li_done);
917 847
918TRACE_EVENT(xprtrdma_frwr_alloc,848TRACE_EVENT(xprtrdma_frwr_alloc,
919 TP_PROTO(849 TP_PROTO(
@@ -1036,9 +966,9 @@ TRACE_EVENT(xprtrdma_frwr_maperr, · 116 unmodified lines
1036 966
1037DEFINE_MR_EVENT(localinv);967DEFINE_MR_EVENT(localinv);
1038DEFINE_MR_EVENT(map);968DEFINE_MR_EVENT(map);
1039DEFINE_MR_EVENT(unmap);969
1040DEFINE_MR_EVENT(reminv);970DEFINE_ANON_MR_EVENT(unmap);
1041DEFINE_MR_EVENT(recycle);971DEFINE_ANON_MR_EVENT(recycle);
1042 972
1043TRACE_EVENT(xprtrdma_dma_maperr,973TRACE_EVENT(xprtrdma_dma_maperr,
1044 TP_PROTO(974 TP_PROTO(
@@ -1066,17 +996,14 @@ TRACE_EVENT(xprtrdma_reply, · 21 unmodified lines
1066 TP_PROTO(996 TP_PROTO(
1067 const struct rpc_task *task,997 const struct rpc_task *task,
1068 const struct rpcrdma_rep *rep,998 const struct rpcrdma_rep *rep,
1069 const struct rpcrdma_req *req,
1070 unsigned int credits999 unsigned int credits
1071 ),1000 ),
1072 1001
1073 TP_ARGS(task, rep, req, credits),1002 TP_ARGS(task, rep, credits),
1074 1003
1075 TP_STRUCT__entry(1004 TP_STRUCT__entry(
1076 __field(unsigned int, task_id)1005 __field(unsigned int, task_id)
1077 __field(unsigned int, client_id)1006 __field(unsigned int, client_id)
1078 __field(const void *, rep)
1079 __field(const void *, req)
1080 __field(u32, xid)1007 __field(u32, xid)
1081 __field(unsigned int, credits)1008 __field(unsigned int, credits)
1082 ),1009 ),
@@ -1084,49 +1011,102 @@ TRACE_EVENT(xprtrdma_reply, · 1 unmodified line
1084 TP_fast_assign(1011 TP_fast_assign(
1085 __entry->task_id = task->tk_pid;1012 __entry->task_id = task->tk_pid;
1086 __entry->client_id = task->tk_client->cl_clid;1013 __entry->client_id = task->tk_client->cl_clid;
1087 __entry->rep = rep;
1088 __entry->req = req;
1089 __entry->xid = be32_to_cpu(rep->rr_xid);1014 __entry->xid = be32_to_cpu(rep->rr_xid);
1090 __entry->credits = credits;1015 __entry->credits = credits;
1091 ),1016 ),
1092 1017
1093 TP_printk("task:%u@%u xid=0x%08x, %u credits, rep=%p -> req=%p",1018 TP_printk("task:%u@%u xid=0x%08x credits=%u",
1094 __entry->task_id, __entry->client_id, __entry->xid,1019 __entry->task_id, __entry->client_id, __entry->xid,
1095 __entry->credits, __entry->rep, __entry->req1020 __entry->credits
1096 )1021 )
1097);1022);
1098 1023
1099TRACE_EVENT(xprtrdma_defer_cmp,1024DEFINE_REPLY_EVENT(vers);
1025DEFINE_REPLY_EVENT(rqst);
1026DEFINE_REPLY_EVENT(short);
1027DEFINE_REPLY_EVENT(hdr);
1028
1029TRACE_EVENT(xprtrdma_err_vers,
1100 TP_PROTO(1030 TP_PROTO(
1101 const struct rpcrdma_rep *rep1031 const struct rpc_rqst *rqst,
1032 __be32 *min,
1033 __be32 *max
1102 ),1034 ),
1103 1035
1104 TP_ARGS(rep),1036 TP_ARGS(rqst, min, max),
1105 1037
1106 TP_STRUCT__entry(1038 TP_STRUCT__entry(
1107 __field(unsigned int, task_id)1039 __field(unsigned int, task_id)
1108 __field(unsigned int, client_id)1040 __field(unsigned int, client_id)
1109 __field(const void *, rep)
1110 __field(u32, xid)1041 __field(u32, xid)
1042 __field(u32, min)
1043 __field(u32, max)
1111 ),1044 ),
1112 1045
1113 TP_fast_assign(1046 TP_fast_assign(
1114 __entry->task_id = rep->rr_rqst->rq_task->tk_pid;1047 __entry->task_id = rqst->rq_task->tk_pid;
1115 __entry->client_id = rep->rr_rqst->rq_task->tk_client->cl_clid;1048 __entry->client_id = rqst->rq_task->tk_client->cl_clid;
1116 __entry->rep = rep;1049 __entry->xid = be32_to_cpu(rqst->rq_xid);
1117 __entry->xid = be32_to_cpu(rep->rr_xid);1050 __entry->min = be32_to_cpup(min);
1051 __entry->max = be32_to_cpup(max);
1118 ),1052 ),
1119 1053
1120 TP_printk("task:%u@%u xid=0x%08x rep=%p",1054 TP_printk("task:%u@%u xid=0x%08x versions=[%u, %u]",
1121 __entry->task_id, __entry->client_id, __entry->xid,1055 __entry->task_id, __entry->client_id, __entry->xid,
1122 __entry->rep1056 __entry->min, __entry->max
1057 )
1058);
1059
1060TRACE_EVENT(xprtrdma_err_chunk,
1061 TP_PROTO(
1062 const struct rpc_rqst *rqst
1063 ),
1064
1065 TP_ARGS(rqst),
1066
1067 TP_STRUCT__entry(
1068 __field(unsigned int, task_id)
1069 __field(unsigned int, client_id)
1070 __field(u32, xid)
1071 ),
1072
1073 TP_fast_assign(
1074 __entry->task_id = rqst->rq_task->tk_pid;
1075 __entry->client_id = rqst->rq_task->tk_client->cl_clid;
1076 __entry->xid = be32_to_cpu(rqst->rq_xid);
1077 ),
1078
1079 TP_printk("task:%u@%u xid=0x%08x",
1080 __entry->task_id, __entry->client_id, __entry->xid
1123 )1081 )
1124);1082);
1125 1083
1126DEFINE_REPLY_EVENT(xprtrdma_reply_vers);1084TRACE_EVENT(xprtrdma_err_unrecognized,
1127DEFINE_REPLY_EVENT(xprtrdma_reply_rqst);1085 TP_PROTO(
1128DEFINE_REPLY_EVENT(xprtrdma_reply_short);1086 const struct rpc_rqst *rqst,
1129DEFINE_REPLY_EVENT(xprtrdma_reply_hdr);1087 __be32 *procedure
1088 ),
1089
1090 TP_ARGS(rqst, procedure),
1091
1092 TP_STRUCT__entry(
1093 __field(unsigned int, task_id)
1094 __field(unsigned int, client_id)
1095 __field(u32, xid)
1096 __field(u32, procedure)
1097 ),
1098
1099 TP_fast_assign(
1100 __entry->task_id = rqst->rq_task->tk_pid;
1101 __entry->client_id = rqst->rq_task->tk_client->cl_clid;
1102 __entry->procedure = be32_to_cpup(procedure);
1103 ),
1104
1105 TP_printk("task:%u@%u xid=0x%08x procedure=%u",
1106 __entry->task_id, __entry->client_id, __entry->xid,
1107 __entry->procedure
1108 )
1109);
1130 1110
1131TRACE_EVENT(xprtrdma_fixup,1111TRACE_EVENT(xprtrdma_fixup,
1132 TP_PROTO(1112 TP_PROTO(
@@ -1187,6 +1167,28 @@ TRACE_EVENT(xprtrdma_decode_seg, · 54 unmodified lines
1187 )1167 )
1188);1168);
1189 1169
1170TRACE_EVENT(xprtrdma_mrs_zap,
1171 TP_PROTO(
1172 const struct rpc_task *task
1173 ),
1174
1175 TP_ARGS(task),
1176
1177 TP_STRUCT__entry(
1178 __field(unsigned int, task_id)
1179 __field(unsigned int, client_id)
1180 ),
1181
1182 TP_fast_assign(
1183 __entry->task_id = task->tk_pid;
1184 __entry->client_id = task->tk_client->cl_clid;
1185 ),
1186
1187 TP_printk("task:%u@%u",
1188 __entry->task_id, __entry->client_id
1189 )
1190);
1191
1190/**1192/**
1191 ** Callback events1193 ** Callback events
1192 **/1194 **/
@@ -1219,36 +1221,8 @@ TRACE_EVENT(xprtrdma_cb_setup, · 26 unmodified lines
1219 )1221 )
1220);1222);
1221 1223
1222DEFINE_CB_EVENT(xprtrdma_cb_call);1224DEFINE_CALLBACK_EVENT(call);
1223DEFINE_CB_EVENT(xprtrdma_cb_reply);1225DEFINE_CALLBACK_EVENT(reply);
1224
1225TRACE_EVENT(xprtrdma_leaked_rep,
1226 TP_PROTO(
1227 const struct rpc_rqst *rqst,
1228 const struct rpcrdma_rep *rep
1229 ),
1230
1231 TP_ARGS(rqst, rep),
1232
1233 TP_STRUCT__entry(
1234 __field(unsigned int, task_id)
1235 __field(unsigned int, client_id)
1236 __field(u32, xid)
1237 __field(const void *, rep)
1238 ),
1239
1240 TP_fast_assign(
1241 __entry->task_id = rqst->rq_task->tk_pid;
1242 __entry->client_id = rqst->rq_task->tk_client->cl_clid;
1243 __entry->xid = be32_to_cpu(rqst->rq_xid);
1244 __entry->rep = rep;
1245 ),
1246
1247 TP_printk("task:%u@%u xid=0x%08x rep=%p",
1248 __entry->task_id, __entry->client_id, __entry->xid,
1249 __entry->rep
1250 )
1251);
1252 1226
1253/**1227/**
1254 ** Server-side RPC/RDMA events1228 ** Server-side RPC/RDMA events

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t