Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp878216ybx; Tue, 5 Nov 2019 07:00:03 -0800 (PST) X-Google-Smtp-Source: APXvYqxd5hlg8BgJFM0OdDXCRcmXRH98snIbdWLZvmzyKTPjtbaojfXSDgyJFgfgqMbqYk9nDBiH X-Received: by 2002:a17:906:c797:: with SMTP id cw23mr29652183ejb.19.1572966003846; Tue, 05 Nov 2019 07:00:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1572966003; cv=none; d=google.com; s=arc-20160816; b=qSSP6gVajTY7bdp+UOmKBGFTUUgiAzs5rVEcr4lrPqm3AHnKAx1GPVtojKyoaAzLDv r8xbAdFLoTl/ylDRHJKzI0c8dAAgsoVqBU3q3QVDm3+4DxhORhex5fwLTA/q+A8vxJ42 sqCzj9SwA8QUZZ2jnk8uvPSaCMT9hSOhl6HUckRqZqY4gnS6K23mu18S3H5VlxPv+K9x smR388CqwINFD+Ow+py7K+88K4YBYuDmfbdWEXC2/0uo5BBKuiZ6bfHgcVL7r28cnpxk M8yfKUOnY7bZCd+BxCcwRhFLX1BHXpkdFmGxaCIutshjrl3NnD9g8q9vW9NzfCw5FRLG TUjw== 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=ukquyBILKVfbO4SjqBe2FVU0Y8O1nG4L04w2gtXFP9U=; b=ogIYGPTlYJgXM6XqiQcddPaQ1NAZftUUCPVBxvv2LZz9mnbH5hhga7BcL9mlcLSl23 SBZ6HUXGiYcRY2N9sRuOG685JQpzs4vOpKHwPjVn7UmoX1ya066opNZ5kJV1RzEuKx+Y 8awuaOXCUuAbLwnLFuxd2Hh+gkZDGMMK/a6Vc076O9G3g70/01tAA6erEAA76Fn7DscT B8cuApBUmA5Rqp/Ds8wfoYBFE239Wbaa5EokTdc2+cphcet3IxaExjFugkRt9R4UL7up UVV0wW/R0fgAN8mUoqOMrBJmUjdHWi+LHz7omljZujYf+VPO1FVTkaQPEvAMt1nlIHIc J71Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=AdEtYm7T; 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 v6si10274436ejw.412.2019.11.05.06.59.39; Tue, 05 Nov 2019 07:00:03 -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=AdEtYm7T; 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 S2389751AbfKEO62 (ORCPT + 99 others); Tue, 5 Nov 2019 09:58:28 -0500 Received: from mail.skyhub.de ([5.9.137.197]:56348 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388842AbfKEO62 (ORCPT ); Tue, 5 Nov 2019 09:58:28 -0500 Received: from zn.tnic (p200300EC2F0EF00014F02C62D0694FB9.dip0.t-ipconnect.de [IPv6:2003:ec:2f0e:f000:14f0:2c62:d069:4fb9]) (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 C79DC1EC0C82; Tue, 5 Nov 2019 15:58:26 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1572965906; 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=ukquyBILKVfbO4SjqBe2FVU0Y8O1nG4L04w2gtXFP9U=; b=AdEtYm7TCtDhkmWzPhuAHMxWych/WpMnM3d4v8Un2zgsiA7PfYmottof0RpjhGu3xx4cUA 4uD2crjiFFLtcFu6rj6lJiZiK6I1jRPt2oCrav789mERt/4bKD2VxOTlBrbEdStnA/15k/ wGR4dg7miVBMm1bkEqGX9WfrBrL2OMo= Date: Tue, 5 Nov 2019 15:58:21 +0100 From: Borislav Petkov To: Robert Richter Cc: James Morse , Mauro Carvalho Chehab , Tony Luck , "linux-edac@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH] EDAC, ghes: Fix locking and memory barrier issues Message-ID: <20191105145821.GD28418@zn.tnic> References: <20191025211226.2444-1-rrichter@marvell.com> <20191105110511.GA28418@zn.tnic> <20191105141734.ubw5qegth3hdahls@rric.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20191105141734.ubw5qegth3hdahls@rric.localdomain> 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 Just to hold down what we discussed on IRC. On Tue, Nov 05, 2019 at 02:17:42PM +0000, Robert Richter wrote: > Here the bypass: > > 1) Entering ghes_edac_register(), instance #1 That was a misunderstanding, I know what Robert means now. > Right, there will be a parent device created for each instance. But an > array is not required as this also can be part of the private data. > Only some sort of list head is needed to collect them all. Ok. > I would rather avoid an own implementation of reference counting and > also better switch from atomic_* to refcount_* which also provides > range checks. There is no benefit doing this our own. > > Any objections here for the renaming and using the refcount API? None. Thx. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette