Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp7561378imu; Fri, 28 Dec 2018 00:17:02 -0800 (PST) X-Google-Smtp-Source: ALg8bN4s2Rl0HpIm7Ex3tp/WuJSdVZUGAZBKBxFi39OnFrmGXAo7eDqkPTTqTRw002YBgjvfhqWx X-Received: by 2002:a17:902:20b:: with SMTP id 11mr26742669plc.57.1545985022366; Fri, 28 Dec 2018 00:17:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545985022; cv=none; d=google.com; s=arc-20160816; b=IlT9XhQKLB88F+E8qQ5KvidiFWCe9kkoXjRWA7dtC3GkFPTVOmZta4ZBsagabkojFz jO++48NVmoX2C99J1oUgfvh89YDgOAEWipv2QjWeXLfA7ivRO8z5nwWYTmttzZOhrJD1 VXV09XRnVvvB5AMxbm7mPfA8KTvbyZWz/UY5gogFsJegtfdl7Z7Af1Hxk7sipvz4Uw1b t5exL6vSAWh+k5lK4/Dk2bP9/XZ/kijxhORlowPN6Mjlw+ILPM9qUelF5P+qXMyp5boB KnQON6lH1SoAjSD1voO3KBHHeGLEU96IWXKO3n/6g18A69/T/lXBcT51dBsWd3dbrE6I ouqQ== 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; bh=Z2ZjfZha2uDoYBpSDCAZu8yTreOdNaRPpM3WOoiacdw=; b=pSPfjOQ9b11oBn9sCdShabZqZYv2zdgD41HuE+kvu7LBHtC8I7Y3Wbj+JotW01vlnG 3SeX+3pQlAOWoDfUgDdF1R54V0msall+wRiWOW4bNbLWTG8ZO8HdNTXeuwVl++iMSUJX 8FSv3h82aaeLveBBaWtk7dftR5Zc/eeSlNSVl6db9lH2SSp5SPZy3CPBN1HagWF84eZm UY9nMa/dZkRfQ1ykCfmBkT/vGRp0crh1LS+y9pRRAY/WgB/oQYxR/GVLsXVZz16Sx4Ng 2p6u1d05yBZkvpW298SmbGx8kt7HW5ySv7ffMe+4XW3nirsRK2OqAWLMyb2z750OuY5Q TwdA== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i96si18873980plb.188.2018.12.28.00.16.46; Fri, 28 Dec 2018 00:17:02 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732178AbeL0WJL (ORCPT + 99 others); Thu, 27 Dec 2018 17:09:11 -0500 Received: from mail-it1-f194.google.com ([209.85.166.194]:52084 "EHLO mail-it1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732159AbeL0WJJ (ORCPT ); Thu, 27 Dec 2018 17:09:09 -0500 Received: by mail-it1-f194.google.com with SMTP id w18so26251857ite.1; Thu, 27 Dec 2018 14:09:08 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=Z2ZjfZha2uDoYBpSDCAZu8yTreOdNaRPpM3WOoiacdw=; b=IhgktlN6N+ygWRlLViUCKDcH/hC20nY2zigBzwLpvdxkNr+3Fo7hlngHh/XxGMRUkU tOsaSeWW11ixegvY/dhlU2LBXdWOnvhcFSkzyhEdFVFpmjEmCPtJEV7DRX45R6D6nDiY yZLBNed2TuuvO7zMB5psNEGmHo1a4X1JotMd1pLvsuQp/ea1o3G0xLnqGs75XxX7zO5r aFP0VXqHQRx4ZavSD1QdTT7J5H49lRqQeBa8e+jDm6aVPAlZyRw23K/YqKcHongympBD IiAr8veo4Y2qjyxUwslmKvBY/82lSkB3p6NTrSbliuh+KheoCpQzx8sN1M6YVhCmVn1i BOBw== X-Gm-Message-State: AA+aEWZ61rw+aOQ/1UpuqwbE4GcL30NQFWGCo2n00RaO0YO7YDz39/5C LbwJUOLn2qVdF1A8ixW2D9TlGCY= X-Received: by 2002:a02:b70c:: with SMTP id g12mr16228757jam.60.1545948548150; Thu, 27 Dec 2018 14:09:08 -0800 (PST) Received: from localhost ([24.51.61.172]) by smtp.gmail.com with ESMTPSA id w3sm349102ior.28.2018.12.27.14.09.07 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 27 Dec 2018 14:09:07 -0800 (PST) Date: Thu, 27 Dec 2018 16:09:06 -0600 From: Rob Herring To: Stefan Schaeckeler Cc: Mark Rutland , Joel Stanley , Andrew Jeffery , Borislav Petkov , Mauro Carvalho Chehab , linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org, linux-edac@vger.kernel.org, Stefan M Schaeckeler Subject: Re: [PATCH 2/2] dt-bindings: edac: Aspeed AST2500 Message-ID: <20181227220906.GA14320@bogus> References: <1545026517-64069-1-git-send-email-schaecsn@gmx.net> <1545026517-64069-3-git-send-email-schaecsn@gmx.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1545026517-64069-3-git-send-email-schaecsn@gmx.net> 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 On Sun, Dec 16, 2018 at 10:01:57PM -0800, Stefan Schaeckeler wrote: > From: Stefan M Schaeckeler > > Add support for the Aspeed AST2500 SoC EDAC driver. > > Signed-off-by: Stefan M Schaeckeler > --- > .../bindings/edac/aspeed-sdram-edac.txt | 34 +++++++++++++++++++ > 1 file changed, 34 insertions(+) > create mode 100644 Documentation/devicetree/bindings/edac/aspeed-sdram-edac.txt > > diff --git a/Documentation/devicetree/bindings/edac/aspeed-sdram-edac.txt b/Documentation/devicetree/bindings/edac/aspeed-sdram-edac.txt > new file mode 100644 > index 000000000000..57ba852883c7 > --- /dev/null > +++ b/Documentation/devicetree/bindings/edac/aspeed-sdram-edac.txt > @@ -0,0 +1,34 @@ > +Aspeed AST2500 SoC EDAC device driver Bindings are for h/w, not drivers > + > +The Aspeed AST2500 SoC supports DDR3 and DDR4 memory with and without ECC (error > +correction check). > + > +The memory controller supports SECDED (single bit error correction, double bit > +error detection) and single bit error auto scrubbing by reserving 8 bits for > +every 64 bit word (effectively reducing available memory to 8/9). > + > +First, ECC must be configured in u-boot. Then, this driver will expose error > +counters via the edac kernel framework. Please reword this to not be u-boot or kernel specific. Maybe this node is enabled in the bootloader or the OS can just read the registers to see if ECC is enabled. The latter is more future proof if you need to access the DDR ctrl registers for other reasons. > + > +A note on memory organization in ECC mode: every 512 bytes are followed by 64 > +bytes of ECC codes. That sounds strange. Normally, the memory would be 72-bits wide to hold the ECC byte for each 64-bit chunk. It would be inefficient to access the ECC byte in a discontiguous location. In any case, none of this is really important for the binding. > The address remapping is done in hardware and is fully > +transparent to firmware and software. Because of this, ECC mode must be > +configured in u-boot as part of the memory initialization as one can not switch > +from one mode to another when executing in memory. > + > + > + > +Required properties: > +- compatible: should be "aspeed,ast2500-sdram-edac" > +- reg: sdram controller register set should be <0x1e6e0000 0x174> > +- interrupts: should be AVIC interrupt #0 > + > + > +Example: > + > + edac: sdram@1e6e0000 { > + compatible = "aspeed,ast2500-sdram-edac"; > + reg = <0x1e6e0000 0x174>; > + interrupts = <0>; > + status = "okay"; Don't show status in examples. > + }; > -- > 2.19.1 >