Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 245667
b: refs/heads/master
c: dffa4b2
h: refs/heads/master
i:
  245665: 5945322
  245663: 7058de5
v: v3
  • Loading branch information
Borislav Petkov authored and Ingo Molnar committed Apr 21, 2011
1 parent 28e879b commit 230082f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 20 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7b70bd3441437b7bc04fc9d321e17c8ed0e8f958
refs/heads/master: dffa4b2f62ff28c982144c7033001b1ece4d3532
2 changes: 0 additions & 2 deletions trunk/arch/x86/include/asm/mce.h
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,6 @@ static inline void winchip_mcheck_init(struct cpuinfo_x86 *c) {}
static inline void enable_p5_mce(void) {}
#endif

extern void (*x86_mce_decode_callback)(struct mce *m);

void mce_setup(struct mce *m);
void mce_log(struct mce *m);
DECLARE_PER_CPU(struct sys_device, mce_dev);
Expand Down
24 changes: 7 additions & 17 deletions trunk/arch/x86/kernel/cpu/mcheck/mce.c
Original file line number Diff line number Diff line change
Expand Up @@ -105,20 +105,6 @@ static int cpu_missing;
ATOMIC_NOTIFIER_HEAD(x86_mce_decoder_chain);
EXPORT_SYMBOL_GPL(x86_mce_decoder_chain);

static int default_decode_mce(struct notifier_block *nb, unsigned long val,
void *data)
{
pr_emerg(HW_ERR "No human readable MCE decoding support on this CPU type.\n");
pr_emerg(HW_ERR "Run the message through 'mcelog --ascii' to decode.\n");

return NOTIFY_STOP;
}

static struct notifier_block mce_dec_nb = {
.notifier_call = default_decode_mce,
.priority = -1,
};

/* MCA banks polled by the period polling timer for corrected events */
DEFINE_PER_CPU(mce_banks_t, mce_poll_banks) = {
[0 ... BITS_TO_LONGS(MAX_NR_BANKS)-1] = ~0UL
Expand Down Expand Up @@ -212,6 +198,8 @@ void mce_log(struct mce *mce)

static void print_mce(struct mce *m)
{
int ret = 0;

pr_emerg(HW_ERR "CPU %d: Machine Check Exception: %Lx Bank %d: %016Lx\n",
m->extcpu, m->mcgstatus, m->bank, m->status);

Expand Down Expand Up @@ -239,7 +227,11 @@ static void print_mce(struct mce *m)
* Print out human-readable details about the MCE error,
* (if the CPU has an implementation for that)
*/
atomic_notifier_call_chain(&x86_mce_decoder_chain, 0, m);
ret = atomic_notifier_call_chain(&x86_mce_decoder_chain, 0, m);
if (ret == NOTIFY_STOP)
return;

pr_emerg_ratelimited(HW_ERR "Run the above through 'mcelog --ascii'\n");
}

#define PANIC_TIMEOUT 5 /* 5 seconds */
Expand Down Expand Up @@ -1721,8 +1713,6 @@ __setup("mce", mcheck_enable);

int __init mcheck_init(void)
{
atomic_notifier_chain_register(&x86_mce_decoder_chain, &mce_dec_nb);

mcheck_intel_therm_init();

return 0;
Expand Down

0 comments on commit 230082f

Please sign in to comment.