29e0cd7b4e1faa035ad9109c1f236f90845143e5
[lttng-modules.git] / instrumentation / events / lttng-module / rpc.h
1 #undef TRACE_SYSTEM
2 #define TRACE_SYSTEM rpc
3
4 #if !defined(LTTNG_TRACE_RPC_H) || defined(TRACE_HEADER_MULTI_READ)
5 #define LTTNG_TRACE_RPC_H
6
7 #include <probes/lttng-tracepoint-event.h>
8 #include <linux/sunrpc/sched.h>
9 #include <linux/sunrpc/clnt.h>
10
11 LTTNG_TRACEPOINT_EVENT_CLASS(rpc_task_status,
12
13 TP_PROTO(struct rpc_task *task),
14
15 TP_ARGS(task),
16
17 TP_FIELDS(
18 ctf_integer_hex(const struct rpc_task *, task, task)
19 ctf_integer_hex(const struct rpc_clnt *, clnt, task->tk_client)
20 ctf_integer(int, status, task->tk_status)
21 )
22 )
23
24 LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_status, rpc_call_status,
25 TP_PROTO(struct rpc_task *task),
26
27 TP_ARGS(task)
28 )
29
30 LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_status, rpc_bind_status,
31 TP_PROTO(struct rpc_task *task),
32
33 TP_ARGS(task)
34 )
35
36 LTTNG_TRACEPOINT_EVENT(rpc_connect_status,
37 TP_PROTO(struct rpc_task *task, int status),
38
39 TP_ARGS(task, status),
40
41 TP_FIELDS(
42 ctf_integer_hex(const struct rpc_task *, task, task)
43 ctf_integer_hex(const struct rpc_clnt *, clnt, task->tk_client)
44 ctf_integer(int, status, status)
45 )
46 )
47
48 LTTNG_TRACEPOINT_EVENT_CLASS(rpc_task_running,
49
50 TP_PROTO(const struct rpc_clnt *clnt, const struct rpc_task *task, const void *action),
51
52 TP_ARGS(clnt, task, action),
53
54 TP_FIELDS(
55 ctf_integer_hex(const struct rpc_clnt *, clnt, clnt)
56 ctf_integer_hex(const struct rpc_task *, task, task)
57 ctf_integer_hex(const void *, action, action)
58 ctf_integer(unsigned long, runstate, task->tk_runstate)
59 ctf_integer(int, status, task->tk_status)
60 ctf_integer(unsigned short, flags, task->tk_flags)
61 )
62 )
63
64 LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_running, rpc_task_begin,
65
66 TP_PROTO(const struct rpc_clnt *clnt, const struct rpc_task *task, const void *action),
67
68 TP_ARGS(clnt, task, action)
69
70 )
71
72 LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_running, rpc_task_run_action,
73
74 TP_PROTO(const struct rpc_clnt *clnt, const struct rpc_task *task, const void *action),
75
76 TP_ARGS(clnt, task, action)
77
78 )
79
80 LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_running, rpc_task_complete,
81
82 TP_PROTO(const struct rpc_clnt *clnt, const struct rpc_task *task, const void *action),
83
84 TP_ARGS(clnt, task, action)
85
86 )
87
88 LTTNG_TRACEPOINT_EVENT_CLASS(rpc_task_queued,
89
90 TP_PROTO(const struct rpc_clnt *clnt, const struct rpc_task *task, const struct rpc_wait_queue *q),
91
92 TP_ARGS(clnt, task, q),
93
94 TP_FIELDS(
95 ctf_integer_hex(const struct rpc_clnt *, clnt, clnt)
96 ctf_integer_hex(const struct rpc_task *, task, task)
97 ctf_integer(unsigned long, timeout, task->tk_timeout)
98 ctf_integer(unsigned long, runstate, task->tk_runstate)
99 ctf_integer(int, status, task->tk_status)
100 ctf_integer(unsigned short, flags, task->tk_flags)
101 ctf_string(q_name, rpc_qname(q))
102 )
103 )
104
105 LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_queued, rpc_task_sleep,
106
107 TP_PROTO(const struct rpc_clnt *clnt, const struct rpc_task *task, const struct rpc_wait_queue *q),
108
109 TP_ARGS(clnt, task, q)
110
111 )
112
113 LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_queued, rpc_task_wakeup,
114
115 TP_PROTO(const struct rpc_clnt *clnt, const struct rpc_task *task, const struct rpc_wait_queue *q),
116
117 TP_ARGS(clnt, task, q)
118
119 )
120
121 #endif /* LTTNG_TRACE_RPC_H */
122
123 #include <probes/define_trace.h>
This page took 0.030475 seconds and 3 git commands to generate.