1 /* SPDX-License-Identifier: GPL-2.0 */
3 #define TRACE_SYSTEM mce
5 #if !defined(_TRACE_MCE_H) || defined(TRACE_HEADER_MULTI_READ)
8 #include <linux/ktime.h>
9 #include <linux/tracepoint.h>
15 * Only very relevant and transient information which cannot be
16 * gathered from a system by any other means or which can only be
17 * acquired arduously should be added to this record.
20 TRACE_EVENT(mce_record,
22 TP_PROTO(struct mce *m),
27 __field( u64, mcgcap )
28 __field( u64, mcgstatus )
29 __field( u64, status )
37 __field( u64, walltime )
40 __field( u32, apicid )
41 __field( u32, socketid )
44 __field( u8, cpuvendor )
45 __field( u32, microcode )
49 __entry->mcgcap = m->mcgcap;
50 __entry->mcgstatus = m->mcgstatus;
51 __entry->status = m->status;
52 __entry->addr = m->addr;
53 __entry->misc = m->misc;
54 __entry->synd = m->synd;
55 __entry->ipid = m->ipid;
57 __entry->tsc = m->tsc;
58 __entry->ppin = m->ppin;
59 __entry->walltime = m->time;
60 __entry->cpu = m->extcpu;
61 __entry->cpuid = m->cpuid;
62 __entry->apicid = m->apicid;
63 __entry->socketid = m->socketid;
65 __entry->bank = m->bank;
66 __entry->cpuvendor = m->cpuvendor;
67 __entry->microcode = m->microcode;
70 TP_printk("CPU: %d, MCGc/s: %llx/%llx, MC%d: %016Lx, IPID: %016Lx, ADDR: %016Lx, MISC: %016Lx, SYND: %016Lx, RIP: %02x:<%016Lx>, TSC: %llx, PPIN: %llx, vendor: %u, CPUID: %x, time: %llu, socket: %u, APIC: %x, microcode: %x",
72 __entry->mcgcap, __entry->mcgstatus,
73 __entry->bank, __entry->status,
78 __entry->cs, __entry->ip,
89 #endif /* _TRACE_MCE_H */
91 /* This part must be outside protection */
92 #include <trace/define_trace.h>