Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rasdaemon: generic fixes and ras-mc-ctl: add support for CXL error events #149

Closed
wants to merge 10 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions ras-aer-handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,11 @@ int ras_aer_event_handler(struct trace_seq *s,
struct tm *tm;
struct ras_aer_event ev;
char buf[BUF_LEN];
#ifdef HAVE_AMP_NS_DECODE
char ipmi_add_sel[105];
uint8_t sel_data[5];
int seg, bus, dev, fn;
#endif

/*
* Newer kernels (3.10-rc1 or upper) provide an uptime clock.
Expand Down Expand Up @@ -132,19 +134,27 @@ int ras_aer_event_handler(struct trace_seq *s,
switch (severity_val) {
case HW_EVENT_AER_UNCORRECTED_NON_FATAL:
ev.error_type = "Uncorrected (Non-Fatal)";
#ifdef HAVE_AMP_NS_DECODE
sel_data[0] = 0xca;
#endif
break;
case HW_EVENT_AER_UNCORRECTED_FATAL:
ev.error_type = "Uncorrected (Fatal)";
#ifdef HAVE_AMP_NS_DECODE
sel_data[0] = 0xca;
#endif
break;
case HW_EVENT_AER_CORRECTED:
ev.error_type = "Corrected";
#ifdef HAVE_AMP_NS_DECODE
sel_data[0] = 0xbf;
#endif
break;
default:
ev.error_type = "Unknown severity";
#ifdef HAVE_AMP_NS_DECODE
sel_data[0] = 0xbf;
#endif
}
trace_seq_puts(s, ev.error_type);

Expand Down
6 changes: 0 additions & 6 deletions ras-memory-failure-handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,8 @@ enum mf_action_page_type {
MF_MSG_KERNEL_HIGH_ORDER,
MF_MSG_SLAB,
MF_MSG_DIFFERENT_COMPOUND,
MF_MSG_POISONED_HUGE,
MF_MSG_HUGE,
MF_MSG_FREE_HUGE,
MF_MSG_NON_PMD_HUGE,
MF_MSG_UNMAP_FAILED,
MF_MSG_DIRTY_SWAPCACHE,
MF_MSG_CLEAN_SWAPCACHE,
Expand All @@ -41,7 +39,6 @@ enum mf_action_page_type {
MF_MSG_CLEAN_LRU,
MF_MSG_TRUNCATED_LRU,
MF_MSG_BUDDY,
MF_MSG_BUDDY_2ND,
MF_MSG_DAX,
MF_MSG_UNSPLIT_THP,
MF_MSG_UNKNOWN,
Expand All @@ -64,10 +61,8 @@ static const struct {
{ MF_MSG_KERNEL_HIGH_ORDER, "high-order kernel page"},
{ MF_MSG_SLAB, "kernel slab page"},
{ MF_MSG_DIFFERENT_COMPOUND, "different compound page after locking"},
{ MF_MSG_POISONED_HUGE, "huge page already hardware poisoned"},
{ MF_MSG_HUGE, "huge page"},
{ MF_MSG_FREE_HUGE, "free huge page"},
{ MF_MSG_NON_PMD_HUGE, "non-pmd-sized huge page"},
{ MF_MSG_UNMAP_FAILED, "unmapping failed page"},
{ MF_MSG_DIRTY_SWAPCACHE, "dirty swapcache page"},
{ MF_MSG_CLEAN_SWAPCACHE, "clean swapcache page"},
Expand All @@ -79,7 +74,6 @@ static const struct {
{ MF_MSG_CLEAN_LRU, "clean LRU page"},
{ MF_MSG_TRUNCATED_LRU, "already truncated LRU page"},
{ MF_MSG_BUDDY, "free buddy page"},
{ MF_MSG_BUDDY_2ND, "free buddy page (2nd try)"},
{ MF_MSG_DAX, "dax page"},
{ MF_MSG_UNSPLIT_THP, "unsplit thp"},
{ MF_MSG_UNKNOWN, "unknown page"},
Expand Down
Loading
Loading