Fix: update sched instrumentation for kernel 4.12
[lttng-modules.git] / instrumentation / events / lttng-module / rpc.h
CommitLineData
b87700e3 1#undef TRACE_SYSTEM
9bbf98da 2#define TRACE_SYSTEM rpc
b87700e3 3
9bbf98da
MD
4#if !defined(LTTNG_TRACE_RPC_H) || defined(TRACE_HEADER_MULTI_READ)
5#define LTTNG_TRACE_RPC_H
b87700e3 6
6ec43db8 7#include <probes/lttng-tracepoint-event.h>
b87700e3
AG
8#include <linux/sunrpc/sched.h>
9#include <linux/sunrpc/clnt.h>
b87700e3 10
3bc29f0a 11LTTNG_TRACEPOINT_EVENT_CLASS(rpc_task_status,
b87700e3
AG
12
13 TP_PROTO(struct rpc_task *task),
14
15 TP_ARGS(task),
16
f127e61e 17 TP_FIELDS(
fa91fcac
MD
18 ctf_integer_hex(const struct rpc_task *, task, task)
19 ctf_integer_hex(const struct rpc_clnt *, clnt, task->tk_client)
f127e61e
MD
20 ctf_integer(int, status, task->tk_status)
21 )
b87700e3
AG
22)
23
3bc29f0a 24LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_status, rpc_call_status,
b87700e3
AG
25 TP_PROTO(struct rpc_task *task),
26
27 TP_ARGS(task)
28)
29
3bc29f0a 30LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_status, rpc_bind_status,
b87700e3
AG
31 TP_PROTO(struct rpc_task *task),
32
33 TP_ARGS(task)
34)
35
3bc29f0a 36LTTNG_TRACEPOINT_EVENT(rpc_connect_status,
b87700e3
AG
37 TP_PROTO(struct rpc_task *task, int status),
38
39 TP_ARGS(task, status),
40
f127e61e 41 TP_FIELDS(
fa91fcac
MD
42 ctf_integer_hex(const struct rpc_task *, task, task)
43 ctf_integer_hex(const struct rpc_clnt *, clnt, task->tk_client)
f127e61e
MD
44 ctf_integer(int, status, status)
45 )
b87700e3
AG
46)
47
3bc29f0a 48LTTNG_TRACEPOINT_EVENT_CLASS(rpc_task_running,
b87700e3
AG
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
f127e61e 54 TP_FIELDS(
fa91fcac
MD
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)
f127e61e
MD
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 )
b87700e3
AG
62)
63
3bc29f0a 64LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_running, rpc_task_begin,
b87700e3
AG
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
3bc29f0a 72LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_running, rpc_task_run_action,
b87700e3
AG
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
3bc29f0a 80LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_running, rpc_task_complete,
b87700e3
AG
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
3bc29f0a 88LTTNG_TRACEPOINT_EVENT_CLASS(rpc_task_queued,
b87700e3
AG
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
f127e61e 94 TP_FIELDS(
fa91fcac
MD
95 ctf_integer_hex(const struct rpc_clnt *, clnt, clnt)
96 ctf_integer_hex(const struct rpc_task *, task, task)
f127e61e
MD
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 )
b87700e3
AG
103)
104
3bc29f0a 105LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_queued, rpc_task_sleep,
b87700e3
AG
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
3bc29f0a 113LTTNG_TRACEPOINT_EVENT_INSTANCE(rpc_task_queued, rpc_task_wakeup,
b87700e3
AG
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
9bbf98da 121#endif /* LTTNG_TRACE_RPC_H */
b87700e3 122
6ec43db8 123#include <probes/define_trace.h>
This page took 0.035491 seconds and 4 git commands to generate.