Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp3644451ybx; Sat, 9 Nov 2019 01:10:47 -0800 (PST) X-Google-Smtp-Source: APXvYqwUSUoR7rQihyl307RYkxLsKWM36UVXExik/gJ6iLLB+kcWN0CrZier/Du2FWlWNur5SAtB X-Received: by 2002:a05:6402:158d:: with SMTP id c13mr15036356edv.62.1573290647028; Sat, 09 Nov 2019 01:10:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573290647; cv=none; d=google.com; s=arc-20160816; b=Gvw7PaBnO/iYiBUkQZRR8VhfnsuM4kSpe2txz+5o6tV7A1V8CLB1tjcnOIszfqFwa5 uo2/yv0KQCzOATHvXeHBt1tENnQOxw1NrLOpleerWcZIrUqV7Ih8zWfmMoNzDu+nyhpo 4rEyZaeMJG6XhdP+roEtYN2+sABjUxElRjIx4zNuphvsot2DgBMw9sQqQZP7tyyfCgHm GnCNC29WK9rGdKf5kArxUgj81/hxl0Mz2DRQfymSu02bUGScuMlVrCJGQVNz0QHklWP1 YW6EwgX9bXiFUQamOvgLU4hyW5l0hDmdQP+czJ4xpof656kpVYYtOne2YKz4vaPZrpqa 246Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=No8b8en5ogzJh4B5ENDF8gmhuPMql4+9x8/mZNC194c=; b=NbN3kIWO4bYjxgsZNnUyHh/Hs1w8ZK8P0px+eVYe/H5Fhb3OHofmixzUcEq/pEk01O Tug2zDHgR7pm131fW9ah+ANr7Qbiw+13F3C9Ok2ApznpwG7vlU9hR9oTvlFHXCeceTkm U3bw04pUghbPMCEtf7lSIWzQA7FA0z8oW8/vQMo7G46mprdZCwOr6g8SgJknUVMYiEQZ oZM5WwJnE9W/QK/NzAx2W6rnlvpvKHv8U7pagRTVLh6uVCvKE9p5jD9SV7TORgqSVhNA B3WvDlBxRaf4MPz4hpa1NqEr3Zz5Yw6z/RL7V2jqSqpKcLW7UGEDWnJrrjEpZo+hBiAc oxOQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b="F/Doc6ae"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 7si7040878edx.33.2019.11.09.01.10.23; Sat, 09 Nov 2019 01:10:47 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b="F/Doc6ae"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726275AbfKIJIg (ORCPT + 99 others); Sat, 9 Nov 2019 04:08:36 -0500 Received: from mail.skyhub.de ([5.9.137.197]:37090 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726136AbfKIJIg (ORCPT ); Sat, 9 Nov 2019 04:08:36 -0500 Received: from zn.tnic (p200300EC2F1EA7009D7000FE00A4E362.dip0.t-ipconnect.de [IPv6:2003:ec:2f1e:a700:9d70:fe:a4:e362]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 3D52C1EC0716; Sat, 9 Nov 2019 10:08:34 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1573290514; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=No8b8en5ogzJh4B5ENDF8gmhuPMql4+9x8/mZNC194c=; b=F/Doc6ae6PZ+fX5F4GB/cGgnirsztA3mK7rp8bTmxXmu21kAfTH+bOqCD+hliwndAlb/6X wmdy1J793ES47X29MsutOWd0FQojmjuubtFMh4Tx9dTmJobf4CewQnIDoM1DKobMR1orEL JgUkuEd86etFPnNlOvVYYU7K2g6d+s8= Date: Sat, 9 Nov 2019 10:08:29 +0100 From: Borislav Petkov To: "Ghannam, Yazen" Cc: "linux-edac@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: [PATCH] EDAC/amd64: Get rid of the ECC disabled long message Message-ID: <20191109090829.GA2699@zn.tnic> References: <20191106012448.243970-1-Yazen.Ghannam@amd.com> <20191106160607.GC28380@zn.tnic> <20191106195417.GF28380@zn.tnic> <20191107103857.GC19501@zn.tnic> <20191107154006.GF19501@zn.tnic> <20191107193429.GI19501@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Ok, I've queued this: --- From: Borislav Petkov Date: Sat, 9 Nov 2019 10:00:54 +0100 This message keeps flooding dmesg on boxes where ECC is disabled or the DIMMs do not support ECC but the module gets auto-probed. What's even worse is that autoprobing happens on every CPU due to the CPU-family matching the driver does and uevent being generated for each CPU device. What is more, this message is becoming even more useless on newer systems where forcing ECC is not recommended and it should be done in the BIOS so the BIOS can do all the necessary work, i.e., just setting a bit in an MSR is not enough anymore. So get rid of it. Signed-off-by: Borislav Petkov Cc: Yazen Ghannam Cc: linux-edac@vger.kernel.org Link: https://lkml.kernel.org/r/20191106160607.GC28380@zn.tnic --- drivers/edac/amd64_edac.c | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/drivers/edac/amd64_edac.c b/drivers/edac/amd64_edac.c index 3aeb5173e200..428ce98f6776 100644 --- a/drivers/edac/amd64_edac.c +++ b/drivers/edac/amd64_edac.c @@ -3188,18 +3188,6 @@ static void restore_ecc_error_reporting(struct ecc_settings *s, u16 nid, amd64_warn("Error restoring NB MCGCTL settings!\n"); } -/* - * EDAC requires that the BIOS have ECC enabled before - * taking over the processing of ECC errors. A command line - * option allows to force-enable hardware ECC later in - * enable_ecc_error_reporting(). - */ -static const char *ecc_msg = - "ECC disabled in the BIOS or no ECC capability, module will not load.\n" - " Either enable ECC checking or force module loading by setting " - "'ecc_enable_override'.\n" - " (Note that use of the override may cause unknown side effects.)\n"; - static bool ecc_enabled(struct amd64_pvt *pvt) { u16 nid = pvt->mc_node_id; @@ -3246,11 +3234,10 @@ static bool ecc_enabled(struct amd64_pvt *pvt) amd64_info("Node %d: DRAM ECC %s.\n", nid, (ecc_en ? "enabled" : "disabled")); - if (!ecc_en || !nb_mce_en) { - amd64_info("%s", ecc_msg); + if (!ecc_en || !nb_mce_en) return false; - } - return true; + else + return true; } static inline void -- 2.21.0 -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette