From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B86A8C433FE for ; Tue, 22 Feb 2022 15:36:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233143AbiBVPgt (ORCPT ); Tue, 22 Feb 2022 10:36:49 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44000 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233643AbiBVPg2 (ORCPT ); Tue, 22 Feb 2022 10:36:28 -0500 Received: from mail.skyhub.de (mail.skyhub.de [5.9.137.197]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B1FE116307C; Tue, 22 Feb 2022 07:35:49 -0800 (PST) Received: from zn.tnic (dslb-088-067-221-104.088.067.pools.vodafone-ip.de [88.67.221.104]) (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 298FC1EC053C; Tue, 22 Feb 2022 16:35:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1645544144; 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=2a4MMuFTNxjhQiCqxEjybhzusRfnc7p6n/cb/C5lpOA=; b=PfeIMI9ocvfjFEcOI3SzzRkKbcAOcPH5ei+5N8bovdeOZV3r1xEW9x3tYpDO6seM5u2vGN AyYeF2ex4LFSnqs4li238N4ok9BKuwQwUyxD/qo/SOOAoR9Bsse165mVQ/Y+DgtAZgJtSu f+6/aSXRX3AkZb69kQu7Yvbf+9k/xYE= Date: Tue, 22 Feb 2022 16:35:51 +0100 From: Borislav Petkov To: Smita Koralahalli Cc: x86@kernel.org, linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org, Tony Luck , Dave Hansen , "H . Peter Anvin" , James Morse , Robert Richter , Yazen Ghannam Subject: Re: [PATCH v3 3/4] x86/mce, EDAC/mce_amd: Cache MCA_CONFIG[McaX] in struct mce_bank Message-ID: References: <20220211223442.254489-1-Smita.KoralahalliChannabasappa@amd.com> <20220211223442.254489-4-Smita.KoralahalliChannabasappa@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20220211223442.254489-4-Smita.KoralahalliChannabasappa@amd.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 11, 2022 at 04:34:41PM -0600, Smita Koralahalli wrote: > Cache the value of MCA_CONFIG[McaX] in the existing mce_bank struct > similar to MCA_CONFIG[McaLsbInStatusSupported]. > > This simplifies and eliminates the need to read MCA_CONFIG register each > time to check McaX. I don't see the point for this change, frankly. I doubt it is speed because those are not really hot paths. Code savings ain't either: 5 files changed, 36 insertions(+), 22 deletions(-) Having yet another exported function to modules if not really necessary doesn't make it prettier too. So if there's no point for it, you can simply drop it. Thx. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette