From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S968793AbdAEX4X (ORCPT ); Thu, 5 Jan 2017 18:56:23 -0500 Received: from mx2.suse.de ([195.135.220.15]:46131 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965089AbdAEX4Q (ORCPT ); Thu, 5 Jan 2017 18:56:16 -0500 Date: Fri, 6 Jan 2017 00:56:11 +0100 From: Borislav Petkov To: "Raj, Ashok" Cc: Alexander Alemayhu , Daniel J Blueman , Paul Menzel , tony.luck@intel.com, linux@leemhuis.info, len.brown@intel.com, Linux Kernel Subject: Re: Dell XPS13: MCE (Hardware Error) reported Message-ID: <20170105235611.yj4ayqpg2ysibeqy@pd.tnic> References: <20170105201034.GA15245@gmail.com> <20170105203146.egi3kveypclmwllp@pd.tnic> <20170105232800.GA82321@otc-brkl-03> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20170105232800.GA82321@otc-brkl-03> User-Agent: NeoMutt/20161014 (1.7.1) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 05, 2017 at 03:28:00PM -0800, Raj, Ashok wrote: > After looking at the code, seems like these events are logged as MCE's > but are really picked from real lvt thermal event interrupts. via a fake > bank 128 for MCE_THERMAL. These are not really HW MCE's, but fake ones created > and logged as mcelog entries. (arch/x86/kernel/cpu/mcheck/therm_throt.c) Right, we've done that since forever but I do think that it confuses people. This thread case-in-point. I mean, we already scream: pr_crit("CPU%d: %s temperature above threshold, cpu clock throttled (total events = %lu)\n", to dmesg, why do we have to log a fake MCE too?! Hell, we even log an MCE when things go back to normal: if (old_event) { if (event == THERMAL_THROTTLING_EVENT) pr_info("CPU%d: %s temperature/speed normal\n", this_cpu, level == CORE_LEVEL ? "Core" : "Package"); return 1; And Alexander's log shows exactly that: [ 6338.170924] CPU1: Core temperature above threshold, cpu clock throttled (total events = 21068) [ 6338.170925] CPU5: Core temperature above threshold, cpu clock throttled (total events = 21068) [ 6338.170928] CPU7: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170931] CPU4: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170932] CPU0: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170933] CPU6: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170935] CPU2: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170936] CPU3: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170937] CPU5: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170945] CPU1: Package temperature above threshold, cpu clock throttled (total events = 22842) [ 6338.170947] mce_notify_irq: 1 callbacks suppressed [ 6338.170948] mce: [Hardware Error]: Machine check events logged <--- new event [ 6338.171917] CPU1: Core temperature/speed normal [ 6338.171918] CPU5: Core temperature/speed normal [ 6338.171920] CPU4: Package temperature/speed normal [ 6338.171920] CPU0: Package temperature/speed normal [ 6338.171922] CPU2: Package temperature/speed normal [ 6338.171923] CPU6: Package temperature/speed normal [ 6338.171924] CPU3: Package temperature/speed normal [ 6338.171925] CPU7: Package temperature/speed normal [ 6338.171927] CPU5: Package temperature/speed normal [ 6338.171929] CPU1: Package temperature/speed normal [ 6338.171930] mce: [Hardware Error]: Machine check events logged <--- old event Oh, and it's not like the user can do anything - there's a thermald which is supposed to deal with all that. Which is not really trouble-free too, TBH. What happens if that thing dies? Fried CPU? So I say we should rip out that mce_log_therm_throt_event() and never ever handle thermal events with MCEs. It is a bad idea. -- Regards/Gruss, Boris. SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) --