Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp1927830rwb; Fri, 19 Aug 2022 11:52:04 -0700 (PDT) X-Google-Smtp-Source: AA6agR4T/3HBdQne1xPoIJI4pLiWcoUQBAadWVxPJCdtVJW0UDZFH2Abeql2NuW3kXx2sLJUICMG X-Received: by 2002:a17:907:2e19:b0:730:acf0:4921 with SMTP id ig25-20020a1709072e1900b00730acf04921mr5473438ejc.416.1660935124122; Fri, 19 Aug 2022 11:52:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660935124; cv=none; d=google.com; s=arc-20160816; b=jxx63jiNrsubX8wKFAPydPVcUbeyXIXokEw0SOUZUWEZRlMYhA8PxJiUiep/c3cb/B uNFqFeNJa0fCTiQ8Cjj1a/0/8SuSkc0rVLcF/uSUdTaawJyqt+KBcRvmWfJoKdwaTD6t erdFtR1UDcFtKtwYSa/EqStrGEJGGNNorpSQZbHDIsGH7Cz1PIze/73Fo9iAlNPv0FtJ 2eIdKftSaZLi7x4oHKFJKXHicvlBdckldfReeL2vojE95qYS5Zvzu9bqGPKIgVCE1N1m YCiGq7n2zDJtEacZk0TtoA6DjfddaY5gTYRR1TmnXqnxQGk1O1a4pKLvioUEMpJq7DHz VDyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=PyT9/85JVzGP3jC5Crgn58YIj9u1Pbo5FkHQe8ujXP8=; b=A+Sk51i9wDkONNBzUrnx1Ftw9+QzAZ1jybS35jenJ0MsTldmadyoDcgHNxRrn9teuK 9RaXljQxHFJt2UOy+Mp84d62tWina5bQRME4ii5CAP6ic11iGpezp80j9rCXrPxly9WF slZdF+UrX/zpkSS+ZcZLFNbii4VtzjXuASLX+xjUMMHgG6BjT8TTTmwiAqx2fGX+kb+0 BnkywZfGNJmWsM3TqHZkDrOjDJR5qCzbxLT5k5Olo83NC/imIZIGq8kIdLXQ/WwXzruT ig5VKOtoR7slCCmSe64cnYoBpg6i7HvSJ9nsaUin5ubT75qdw6auKb2yV+/80cg+M/fS yTMA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=Yjg2XX6u; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f16-20020a056402355000b0044622a80b6bsi3091189edd.188.2022.08.19.11.51.38; Fri, 19 Aug 2022 11:52:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=Yjg2XX6u; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S1350731AbiHSSaA (ORCPT + 99 others); Fri, 19 Aug 2022 14:30:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49530 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1349836AbiHSS36 (ORCPT ); Fri, 19 Aug 2022 14:29:58 -0400 Received: from mail.skyhub.de (mail.skyhub.de [5.9.137.197]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 62BFC13F8C; Fri, 19 Aug 2022 11:29:57 -0700 (PDT) Received: from zn.tnic (p200300ea971b9849329c23fffea6a903.dip0.t-ipconnect.de [IPv6:2003:ea:971b:9849:329c:23ff:fea6:a903]) (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 B63901EC04E4; Fri, 19 Aug 2022 20:29:51 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1660933791; 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=PyT9/85JVzGP3jC5Crgn58YIj9u1Pbo5FkHQe8ujXP8=; b=Yjg2XX6u5aFtsDOFXcFvWGnQGNa4sHsElGU3UAOCQEQIKYIiI5EfB39BmVQpFBqkq8Rij2 ntm6FbkBzr3YJIJrUX66ZF0WB8gsT2khVCY3kVEL2LGG9nAugXJiEYDIhD7t/JG1kJVDD9 dRfJh9Pa6Q/tX9tLiq0JzSMJPwf/gtE= Date: Fri, 19 Aug 2022 20:29:47 +0200 From: Borislav Petkov To: "Kani, Toshi" Cc: Justin He , "linux-acpi@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-edac@vger.kernel.org" , "devel@acpica.org" , "Rafael J . Wysocki" , Shuai Xue , Jarkko Sakkinen , "linux-efi@vger.kernel.org" , nd , Ard Biesheuvel , Len Brown , James Morse , Tony Luck , Mauro Carvalho Chehab , Robert Richter , Robert Moore , Qiuxu Zhuo , Yazen Ghannam Subject: Re: [PATCH v2 5/7] EDAC/ghes: Prevent chipset-specific edac from loading after ghes_edac is registered Message-ID: References: <20220817143458.335938-1-justin.he@arm.com> <20220817143458.335938-6-justin.he@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Aug 19, 2022 at 05:48:39PM +0000, Kani, Toshi wrote: > This flag is a static variable, say ghes_present, which is set to > false initially. ghes_probe() sets it to true. ghes_edac_preferred() > (aka. ghes_get_device) checks this flag at beginning and returns false > if this flag is false. It does not get unlatched since ACPI GHES table > is static. What is that flag needed for at all? There are two possibilities: 1. ghes_probe() succeeds. ghes_edac loads properly and other drivers use ghes_get_devices() to know when to load. 2. ghes_probe() fails and that is caught during platform testing of all those platforms who wish to use ghes_edac. BIOS is fixed and goto 1. No need for funky flags whatsoever. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette