diff options
author | jhb <jhb@FreeBSD.org> | 2009-05-13 17:53:04 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2009-05-13 17:53:04 +0000 |
commit | 370298a10816df8eee3cd3453607323546e4cf9c (patch) | |
tree | e92a8666a427cd3b54074a55134d6d643f102bf6 /sys/conf/files.i386 | |
parent | deae02e77d33ac35960ebc9548741d1c2b9a22c2 (diff) | |
download | FreeBSD-src-370298a10816df8eee3cd3453607323546e4cf9c.zip FreeBSD-src-370298a10816df8eee3cd3453607323546e4cf9c.tar.gz |
Implement simple machine check support for amd64 and i386.
- For CPUs that only support MCE (the machine check exception) but not MCA
(i.e. Pentium), all this does is print out the value of the machine check
registers and then panic when a machine check exception occurs.
- For CPUs that support MCA (the machine check architecture), the support is
a bit more involved.
- First, there is limited support for decoding the CPU-independent MCA
error codes in the kernel, and the kernel uses this to output a short
description of any machine check events that occur.
- When a machine check exception occurs, all of the MCx banks on the
current CPU are scanned and any events are reported to the console
before panic'ing.
- To catch events for correctable errors, a periodic timer kicks off a
task which scans the MCx banks on all CPUs. The frequency of these
checks is controlled via the "hw.mca.interval" sysctl.
- Userland can request an immediate scan of the MCx banks by writing
a non-zero value to "hw.mca.force_scan".
- If any correctable events are encountered, the appropriate details
are stored in a 'struct mca_record' (defined in <machine/mca.h>).
The "hw.mca.count" is a count of such records and each record may
be queried via the "hw.mca.records" tree by specifying the record
index (0 .. count - 1) as the next name in the MIB similar to using
PIDs with the kern.proc.* sysctls. The idea is to export machine
check events to userland for more detailed processing.
- The periodic timer and hw.mca sysctls are only present if the CPU
supports MCA.
Discussed with: emaste (briefly)
MFC after: 1 month
Diffstat (limited to 'sys/conf/files.i386')
-rw-r--r-- | sys/conf/files.i386 | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/conf/files.i386 b/sys/conf/files.i386 index d88be04..5a1ed91 100644 --- a/sys/conf/files.i386 +++ b/sys/conf/files.i386 @@ -278,6 +278,7 @@ i386/xen/locore.s optional xen no-obj i386/i386/longrun.c optional cpu_enable_longrun i386/i386/machdep.c standard i386/xen/xen_machdep.c optional xen +i386/i386/mca.c standard i386/i386/mem.c optional mem i386/i386/minidump_machdep.c standard i386/i386/mp_clock.c optional smp |