Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753608AbdHNQYw (ORCPT ); Mon, 14 Aug 2017 12:24:52 -0400 Received: from mail.skyhub.de ([5.9.137.197]:40622 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753534AbdHNQYs (ORCPT ); Mon, 14 Aug 2017 12:24:48 -0400 Date: Mon, 14 Aug 2017 18:24:36 +0200 From: Borislav Petkov To: "Kani, Toshimitsu" Cc: "rjw@rjwysocki.net" , "lenb@kernel.org" , "mchehab@kernel.org" , "tony.luck@intel.com" , "linux-kernel@vger.kernel.org" , "linux-acpi@vger.kernel.org" , "linux-edac@vger.kernel.org" Subject: Re: [PATCH v2 4/7] ghes_edac: avoid multiple calls to dmi_walk() Message-ID: <20170814162436.lta5xm742hh6g7yk@pd.tnic> References: <20170803215753.30553-1-toshi.kani@hpe.com> <20170803215753.30553-5-toshi.kani@hpe.com> <20170804040525.GE12082@nazgul.tnic> <1501879964.2042.117.camel@hpe.com> <20170805051615.GC23214@nazgul.tnic> <1502128177.2042.131.camel@hpe.com> <20170811090414.GB9432@nazgul.tnic> <1502725671.2042.137.camel@hpe.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1502725671.2042.137.camel@hpe.com> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 554 Lines: 19 On Mon, Aug 14, 2017 at 03:57:35PM +0000, Kani, Toshimitsu wrote: > Hmm... Sorry, I failed to see how your patchset solved it. Would you > mind to explain how it is done? +static int __init ghes_edac_register(void) { + struct ghes_edac_pvt *pvt = ghes_pvt; Only one local ghes_pvt structure. And you handle multiple calls into ghes_edac_register() by exiting all those which are not the first one as the first one already did all the init. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.