1MCE-INJECT(8)           Linux's Administrator's Manual           MCE-INJECT(8)
2
3
4

NAME

6       mce-inject - Inject machine checks into x86 kernel for testing
7

SYNOPSIS

9       mce-inject mce-file1 ...
10       mce-inject < mce-file
11

DESCRIPTION

13       mce-inject  allows to inject machine checks in a running x86 Linux ker‐
14       nel.  machine checks are internal CPU errors. This tool is intended  to
15       test  the  machine  check handling code.  The injection only happens on
16       the software level and does not simulate full machine check handling on
17       the platform level.  The machine checks to be injected are described in
18       a input language similar to the format the kernel outputs  on  a  panic
19       message  (with a few extension).  In general you should be able to pipe
20       in a panic message to inject that mce.  See the IA32 SDM Vol3a  chapter
21       14 for the details on fields. They correspond to the machine check MSRs
22       of the standard IA32 Machine check architecture described there.
23

INPUT LANGUAGE

25       These generally represent the similarly CPU MSRs, with some metadata on
26       where  to  inject  the exception. Please see the IA software developers
27       Manual for more details.
28
29       The machine check always starts with MCE or CPU number|broadcast [bank-
30       number] Machine check is injected on CPU xx or broadcasted to all CPUs
31
32       BANK bank-number Machine check bank to inject on.
33
34       STATUS                                   {number|fatal|corrected|uncor‐
35       rected|pcc|uc|val|en|over|ar|ucna|srao|srar|s}
36
37       The symbols generally represent hardware register bits,  as  documented
38       in  the  Intel  software  developer's manual.  When multiple are listed
39       they are ored together.
40
41       MCGSTATUS {number|mcip|ripv|eipv}
42
43       The symbols generally represent hardware register bits,  as  documented
44       in  the  Intel  software  developer's manual.  When multiple are listed
45       they are ored together.
46
47       ADDR number
48
49       RIP number RIP number:<number>{string} RIP number:number
50
51       MISC number
52
53       CPU number : machine check exception :  number  BANK  number  :  number
54       parsed for compatibility with kernel output. Use explicit statements
55
56       TSC number TSC state injected in machine check
57
58       NOBROADCAST  Don't  broadcast  exceptions  to  all  CPUs. Default is to
59       broadcast UC
60
61       IRQBROADCAST Broadcast IRQ to all CPUs that not  getting  error  injec‐
62       tion.
63
64       NMIBROADCAST  Broadcast  NMI  to all CPUs that not getting error injec‐
65       tion.
66
67       IN_IRQ MCE should be injected in interrupt context
68
69       IN_PROC MCE injected in process context.
70
71       HOLD Don't inject MCE immediately but hold it for later injection. This
72       is useful for testing injection on multiple CPUs in parallel
73
74       SOCKETID number Socketid. Ignored by kernel on injection.
75
76       MCGCAP  number  Machine  check  capabilities  register value. Currently
77       ignored by kernel on injection.
78
79       POLL Inject in machine check poller code.
80
81       EXCP Inject as machine check exception.
82
83       APICID number APIC ID of CPU. Ignored by kernel on injection.
84
85       A list of symbols ors the symbols together.
86
87
88       Multiple fields can be on a line.  number can be  hex/octal/decimal  in
89       the  usual  C format.  Multiple machine checks can be in a single file,
90       each new one starts with "CPU" or "MCE".  For all missing  fields  rea‐
91       sonable  default values are filled in (hopefully) Comments start with #
92       until the end of the line The keywords are case-insensitive.
93

REQUIREMENTS

95       mce-inject to run as root. /dev/mcelog has to exist. The kernels  needs
96       to  have  machine check injection ( CONFIG_X86_MCE_INJECT ) enabled and
97       if modular the mce-inject module loaded. This option  is  available  in
98       Linux 2.6.31 or later.
99

NOTES

101       The mce-test package has a lot of input file examples.
102

SEE ALSO

104       Intel  64 and IA32 Architectures Software Developer's manual, Volume 3,
105       System programming guide Parts 1 and 2. Machine checks are described in
106       Chapter 14 in Part1 and in Append ix E in Part2.
107
108       Datasheet of your CPU.
109
110
111
112
113
114
115Intel OTC                          May 2009                      MCE-INJECT(8)
Impressum