| 1 | #undef TRACE_SYSTEM |
| 2 | #define TRACE_SYSTEM rseq |
| 3 | |
| 4 | #if !defined(_TRACE_RSEQ_H) || defined(TRACE_HEADER_MULTI_READ) |
| 5 | #define _TRACE_RSEQ_H |
| 6 | |
| 7 | #include <linux/tracepoint.h> |
| 8 | #include <linux/types.h> |
| 9 | |
| 10 | TRACE_EVENT(rseq_update, |
| 11 | |
| 12 | TP_PROTO(struct task_struct *t), |
| 13 | |
| 14 | TP_ARGS(t), |
| 15 | |
| 16 | TP_STRUCT__entry( |
| 17 | __field(s32, cpu_id) |
| 18 | __field(u32, event_counter) |
| 19 | ), |
| 20 | |
| 21 | TP_fast_assign( |
| 22 | __entry->cpu_id = raw_smp_processor_id(); |
| 23 | __entry->event_counter = t->rseq_event_counter; |
| 24 | ), |
| 25 | |
| 26 | TP_printk("cpu_id=%d event_counter=%u", |
| 27 | __entry->cpu_id, __entry->event_counter) |
| 28 | ); |
| 29 | |
| 30 | TRACE_EVENT(rseq_ip_fixup, |
| 31 | |
| 32 | TP_PROTO(void __user *regs_ip, void __user *start_ip, |
| 33 | void __user *post_commit_ip, void __user *abort_ip, |
| 34 | u32 kevcount, int ret), |
| 35 | |
| 36 | TP_ARGS(regs_ip, start_ip, post_commit_ip, abort_ip, kevcount, ret), |
| 37 | |
| 38 | TP_STRUCT__entry( |
| 39 | __field(void __user *, regs_ip) |
| 40 | __field(void __user *, start_ip) |
| 41 | __field(void __user *, post_commit_ip) |
| 42 | __field(void __user *, abort_ip) |
| 43 | __field(u32, kevcount) |
| 44 | __field(int, ret) |
| 45 | ), |
| 46 | |
| 47 | TP_fast_assign( |
| 48 | __entry->regs_ip = regs_ip; |
| 49 | __entry->start_ip = start_ip; |
| 50 | __entry->post_commit_ip = post_commit_ip; |
| 51 | __entry->abort_ip = abort_ip; |
| 52 | __entry->kevcount = kevcount; |
| 53 | __entry->ret = ret; |
| 54 | ), |
| 55 | |
| 56 | TP_printk("regs_ip=%p start_ip=%p post_commit_ip=%p abort_ip=%p kevcount=%u ret=%d", |
| 57 | __entry->regs_ip, __entry->start_ip, __entry->post_commit_ip, |
| 58 | __entry->abort_ip, __entry->kevcount, __entry->ret) |
| 59 | ); |
| 60 | |
| 61 | #endif /* _TRACE_SOCK_H */ |
| 62 | |
| 63 | /* This part must be outside protection */ |
| 64 | #include <trace/define_trace.h> |