2 #define TRACE_SYSTEM x86_fpu
4 #if !defined(_TRACE_FPU_H) || defined(TRACE_HEADER_MULTI_READ)
7 #include <linux/tracepoint.h>
9 DECLARE_EVENT_CLASS(x86_fpu,
10 TP_PROTO(struct fpu *fpu),
14 __field(struct fpu *, fpu)
15 __field(bool, fpregs_active)
16 __field(bool, fpstate_active)
17 __field(u64, xfeatures)
18 __field(u64, xcomp_bv)
23 __entry->fpregs_active = fpu->fpregs_active;
24 __entry->fpstate_active = fpu->fpstate_active;
25 if (boot_cpu_has(X86_FEATURE_OSXSAVE)) {
26 __entry->xfeatures = fpu->state.xsave.header.xfeatures;
27 __entry->xcomp_bv = fpu->state.xsave.header.xcomp_bv;
30 TP_printk("x86/fpu: %p fpregs_active: %d fpstate_active: %d xfeatures: %llx xcomp_bv: %llx",
32 __entry->fpregs_active,
33 __entry->fpstate_active,
39 DEFINE_EVENT(x86_fpu, x86_fpu_state,
40 TP_PROTO(struct fpu *fpu),
44 DEFINE_EVENT(x86_fpu, x86_fpu_before_save,
45 TP_PROTO(struct fpu *fpu),
49 DEFINE_EVENT(x86_fpu, x86_fpu_after_save,
50 TP_PROTO(struct fpu *fpu),
54 DEFINE_EVENT(x86_fpu, x86_fpu_before_restore,
55 TP_PROTO(struct fpu *fpu),
59 DEFINE_EVENT(x86_fpu, x86_fpu_after_restore,
60 TP_PROTO(struct fpu *fpu),
64 DEFINE_EVENT(x86_fpu, x86_fpu_regs_activated,
65 TP_PROTO(struct fpu *fpu),
69 DEFINE_EVENT(x86_fpu, x86_fpu_regs_deactivated,
70 TP_PROTO(struct fpu *fpu),
74 DEFINE_EVENT(x86_fpu, x86_fpu_activate_state,
75 TP_PROTO(struct fpu *fpu),
79 DEFINE_EVENT(x86_fpu, x86_fpu_deactivate_state,
80 TP_PROTO(struct fpu *fpu),
84 DEFINE_EVENT(x86_fpu, x86_fpu_init_state,
85 TP_PROTO(struct fpu *fpu),
89 DEFINE_EVENT(x86_fpu, x86_fpu_dropped,
90 TP_PROTO(struct fpu *fpu),
94 DEFINE_EVENT(x86_fpu, x86_fpu_copy_src,
95 TP_PROTO(struct fpu *fpu),
99 DEFINE_EVENT(x86_fpu, x86_fpu_copy_dst,
100 TP_PROTO(struct fpu *fpu),
104 DEFINE_EVENT(x86_fpu, x86_fpu_xstate_check_failed,
105 TP_PROTO(struct fpu *fpu),
109 #undef TRACE_INCLUDE_PATH
110 #define TRACE_INCLUDE_PATH asm/trace/
111 #undef TRACE_INCLUDE_FILE
112 #define TRACE_INCLUDE_FILE fpu
113 #endif /* _TRACE_FPU_H */
115 /* This part must be outside protection */
116 #include <trace/define_trace.h>