diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-02-19 21:26:22 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-02-21 14:16:27 -0300 |
commit | 8dd93d450bff251575c56b8f058393124e1f00fb (patch) | |
tree | bee1cae0a29936d2897a5d84afdc20e524b1022b /include/linux/edac.h | |
parent | e7e248304c8ccf02b89e04c3b3b66006b993b5a7 (diff) |
edac: add support for error type "Info"
The CPER spec defines a forth type of error: informational
logs. Add support for it at the edac API and at the
trace event interface.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'include/linux/edac.h')
-rw-r--r-- | include/linux/edac.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/include/linux/edac.h b/include/linux/edac.h index 096b7fcdf48..4fd4999ccb5 100644 --- a/include/linux/edac.h +++ b/include/linux/edac.h @@ -109,8 +109,24 @@ enum hw_event_mc_err_type { HW_EVENT_ERR_CORRECTED, HW_EVENT_ERR_UNCORRECTED, HW_EVENT_ERR_FATAL, + HW_EVENT_ERR_INFO, }; +static inline char *mc_event_error_type(const unsigned int err_type) +{ + switch (err_type) { + case HW_EVENT_ERR_CORRECTED: + return "Corrected"; + case HW_EVENT_ERR_UNCORRECTED: + return "Uncorrected"; + case HW_EVENT_ERR_FATAL: + return "Fatal"; + default: + case HW_EVENT_ERR_INFO: + return "Info"; + } +} + /** * enum mem_type - memory types. For a more detailed reference, please see * http://en.wikipedia.org/wiki/DRAM |