]>
git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/blob - include/trace/events/preemptirq.h
1 #ifdef CONFIG_PREEMPTIRQ_EVENTS
4 #define TRACE_SYSTEM preemptirq
6 #if !defined(_TRACE_PREEMPTIRQ_H) || defined(TRACE_HEADER_MULTI_READ)
7 #define _TRACE_PREEMPTIRQ_H
9 #include <linux/ktime.h>
10 #include <linux/tracepoint.h>
11 #include <linux/string.h>
12 #include <asm/sections.h>
14 DECLARE_EVENT_CLASS(preemptirq_template
,
16 TP_PROTO(unsigned long ip
, unsigned long parent_ip
),
18 TP_ARGS(ip
, parent_ip
),
21 __field(u32
, caller_offs
)
22 __field(u32
, parent_offs
)
26 __entry
->caller_offs
= (u32
)(ip
- (unsigned long)_stext
);
27 __entry
->parent_offs
= (u32
)(parent_ip
- (unsigned long)_stext
);
30 TP_printk("caller=%pF parent=%pF",
31 (void *)((unsigned long)(_stext
) + __entry
->caller_offs
),
32 (void *)((unsigned long)(_stext
) + __entry
->parent_offs
))
35 #ifndef CONFIG_PROVE_LOCKING
36 DEFINE_EVENT(preemptirq_template
, irq_disable
,
37 TP_PROTO(unsigned long ip
, unsigned long parent_ip
),
38 TP_ARGS(ip
, parent_ip
));
40 DEFINE_EVENT(preemptirq_template
, irq_enable
,
41 TP_PROTO(unsigned long ip
, unsigned long parent_ip
),
42 TP_ARGS(ip
, parent_ip
));
45 #ifdef CONFIG_DEBUG_PREEMPT
46 DEFINE_EVENT(preemptirq_template
, preempt_disable
,
47 TP_PROTO(unsigned long ip
, unsigned long parent_ip
),
48 TP_ARGS(ip
, parent_ip
));
50 DEFINE_EVENT(preemptirq_template
, preempt_enable
,
51 TP_PROTO(unsigned long ip
, unsigned long parent_ip
),
52 TP_ARGS(ip
, parent_ip
));
55 #endif /* _TRACE_PREEMPTIRQ_H */
57 #include <trace/define_trace.h>
59 #else /* !CONFIG_PREEMPTIRQ_EVENTS */
61 #define trace_irq_enable(...)
62 #define trace_irq_disable(...)
63 #define trace_preempt_enable(...)
64 #define trace_preempt_disable(...)
65 #define trace_irq_enable_rcuidle(...)
66 #define trace_irq_disable_rcuidle(...)
67 #define trace_preempt_enable_rcuidle(...)
68 #define trace_preempt_disable_rcuidle(...)