lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20090826091407.GA7743@elte.hu>
Date:	Wed, 26 Aug 2009 11:14:07 +0200
From:	Ingo Molnar <mingo@...e.hu>
To:	Hidetoshi Seto <seto.hidetoshi@...fujitsu.com>
Cc:	linux-kernel@...r.kernel.org, Andi Kleen <ak@...ux.intel.com>,
	"H. Peter Anvin" <hpa@...or.com>,
	Jin Dongming <jin.dongming@...css.fujitsu.com>
Subject: Re: [PATCH -tip] x86, mce: CE in last bank prevents panic by
	unknown MCE


* Hidetoshi Seto <seto.hidetoshi@...fujitsu.com> wrote:

> [based on tip/x86/mce]
> 
> If MCE handler is called but none of mces_seen have machine check 
> event which might signal the MCE (i.e. event higher than 
> MCE_KEEP_SEVERITY), panic with "Machine check from unknown source" 
> will be taken since the MCE is assumed to be signaled from 
> external agent or so.
> 
> Usually mces_seen never point MCE_KEEP_SEVERITY event such as CE. 
> But it can happen because initial value of mces_seen is 
> accidentally modified by mce_no_way_out() - in case if 
> mce_no_way_out() run through all banks and the last bank has the 
> CE, mces_seen points the CE and the "panic by unknown" will not be 
> taken.
> 
> This patch fix this undesired behavior, and clarify the logic.
> 
> Signed-off-by: Hidetoshi Seto <seto.hidetoshi@...fujitsu.com>
> Reported-by: Jin Dongming <jin.dongming@...css.fujitsu.com>
> 
> ---
>  arch/x86/kernel/cpu/mcheck/mce.c |    6 +++---
>  1 files changed, 3 insertions(+), 3 deletions(-)

applied, thanks!

Btw., i had a quick look at 
arch/x86/kernel/cpu/mcheck/mce-severity.c, and it is quite a pile of 
unclean, over-engineered crap really.

Would you be interested in sending me a patch that converts that to 
clean, proper C code that just checks the bits in a straightforward, 
readable way? We dont need that silly, unreadable table with the 
macro jungle and we definitely dont want to expose it via debugfs - 
the debugfs bits can be removed altogether.

[ Plus in the mce_severity() implementation please rename 'a' to at
  least 'm' - that name choice for a variable shows zero taste. We
  dont program the kernel in BASIC with 'A', 'B' and 'C' variable
  names anymore. ]

Thanks,

	Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ