Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp363637imu; Fri, 16 Nov 2018 03:51:50 -0800 (PST) X-Google-Smtp-Source: AJdET5fSe6/S8hM5a8z5QOv5yWzmONPaj/TMxh47Z3JCbnp6lvCejhqYnVP+mDJ8Bqx0ckh0Zrps X-Received: by 2002:a65:5387:: with SMTP id x7mr9694575pgq.412.1542369110536; Fri, 16 Nov 2018 03:51:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542369110; cv=none; d=google.com; s=arc-20160816; b=pw/kL3YXD7CsN83bsupcFhRxDE/PGsXan7dYkgPdsCRdblMmdMcnqIoI0VlnSYa4YI qkGOYV9oByGBzVfBMQ9qqWF1/KT+OjF9YLTgdM06qRoKM2FcQpU9N/g9d+VKmW/WniLj 3uYbA4uK65mUHiUpPK1MrR0oIHA9Vse2iTjZ+6Bsz0QvRgIZW4eRD6DfeiUQF2e0A844 qUuFCt6dGrSjUBnRtWdOek5IGk4ofkeNio5r3g1MsxhHphyvTGKLuiFazP8mDJq2tyGK wC7lZGavVEdE+oeFK+CfZhCxq6EhBq33Q9FGMkjYQOMhQLzzTxYwM7bdltFRtKp8uyqs 9bGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=1TPtwYwd+PAodAbzzuiBREPH4lKj7OY00f7M652OHqA=; b=WpAY4j3kj0owT96vRWH4loD48dJd5QT1/lbsFL1qDkS6TBcAmeoYGMQ6jehkIylIzr xKQHUIuRb9nJiCa8Mfj87ztBqywk4a/ZKxgeDi36w5U1OYC4RCMPBBztPFCagyt5AiQD avct5bOrc7FS1KPN+1mdl51cksj83sOSa9TtSiMlFmJ/+HQg1Zx+/sHvqtW1QKdBn0bk RE1DQz+4XbgIASCV/AuPGnd/m+ieYwFgLQTt1ZBlzKdbj4UKHwAPZqSR+4hkxnvSHspz rG39qQGGQ90tQGkZc5HvA32lfuzlqpo46Q1ZbYCkZD+FPFLQNMfIHtC4KoYmBNAVCAlP bQ6w== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 31-v6si31439651plz.181.2018.11.16.03.51.35; Fri, 16 Nov 2018 03:51:50 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389534AbeKPWCY (ORCPT + 99 others); Fri, 16 Nov 2018 17:02:24 -0500 Received: from martinlund.org ([173.255.130.145]:34299 "EHLO slmp-550-86.slc.westdc.net" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727767AbeKPWCY (ORCPT ); Fri, 16 Nov 2018 17:02:24 -0500 Received: from mail-oi1-f169.google.com ([209.85.167.169]:41806) by slmp-550-86.slc.westdc.net with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.91) (envelope-from ) id 1gNcdh-00DguJ-K2 for linux-kernel@vger.kernel.org; Fri, 16 Nov 2018 04:50:21 -0700 Received: by mail-oi1-f169.google.com with SMTP id g188-v6so19405232oif.8 for ; Fri, 16 Nov 2018 03:50:21 -0800 (PST) X-Gm-Message-State: AA+aEWZJipkGeBPhD50/4dPhyGMOXUZyQIwgbINzpPkQCGtjemb/EIcD 53czyQtw3jRjsMLjt1vFlVsg6bbLhVEPL2StpDc= X-Received: by 2002:aca:be45:: with SMTP id o66-v6mr748362oif.164.1542369021146; Fri, 16 Nov 2018 03:50:21 -0800 (PST) MIME-Version: 1.0 References: <1541739641-17789-1-git-send-email-naga.sureshkumar.relli@xilinx.com> <1541739641-17789-2-git-send-email-naga.sureshkumar.relli@xilinx.com> In-Reply-To: <1541739641-17789-2-git-send-email-naga.sureshkumar.relli@xilinx.com> From: Martin Lund Date: Fri, 16 Nov 2018 12:50:10 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [LINUX PATCH v12 1/3] dt-bindings: mtd: arasan: Add device tree binding documentation To: naga.sureshkumar.relli@xilinx.com Cc: boris.brezillon@bootlin.com, miquel.raynal@bootlin.com, richard@nod.at, David Woodhouse , Brian Norris , =?UTF-8?B?TWFyZWsgVmHFoXV0?= , michals@xilinx.com, naga sureshkumar , linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, robh@kernel.org Content-Type: text/plain; charset="UTF-8" X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - slmp-550-86.slc.westdc.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - keep-it-simple.com X-Get-Message-Sender-Via: slmp-550-86.slc.westdc.net: authenticated_id: martin.lund+keep-it-simple.com/only user confirmed/virtual account not confirmed X-Authenticated-Sender: slmp-550-86.slc.westdc.net: martin.lund@keep-it-simple.com X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Naga, I've been working on running up the latest kernel (v4.20-rc2) on our custom Xilinx hw board so that I can test the v12 version of your Arasan nand driver. I've managed to get the driver successfully up and running and ready for testing with a Micron MT29F64G08AFAAAWP device. However, setting it up I've found a few inaccuracies in the documentation of the device tree bindings. This is the device configuration that ended up working for me with linux v4.20-rc2: nfc: nand@ff100000 { compatible = "xlnx,zynqmp-nand", "arasan,nfc-v3p10"; reg = <0x0 0xff100000 0x0 0x1000>; clock-names = "clk_sys", "clk_flash"; clocks = <&clk200>, <&clk100>; interrupt-parent = <&gic>; interrupts = <0 14 4>; #address-cells = <1>; #size-cells = <0>; nand@0 { reg = <0>; nand-ecc-mode = "hw"; }; }; Compared with the example you will notice that "clock-name" should be "clock-names". reg was missing a "0x0". I think it is helpful to provide a real-world working example, so you might also consider changing the example "clocks" configuration to clk200/clk100 since there is no clk_misc among the clock sources of any of the xilinx zynqmp board device tree configurations. Br, Martin On Fri, Nov 9, 2018 at 6:00 AM Naga Sureshkumar Relli wrote: > > This patch adds the dts binding document for arasan nand flash controller > > Signed-off-by: Naga Sureshkumar Relli > --- > Changes in v12: > - Removed interrupt-parent description as it is implied as suggested by > Rob Herring > - Added missing ';' as required > Changes in v11: > - Updated compatible description as suggested by Boris > - Removed arasan-has-dma property > Changes in v10: > - None > Changes in v9: > - None > Changes in v8: > - Updated compatible and clock-names as per Boris comments > Changes in v7: > - Corrected the acronyms those should be in caps > Changes in v6: > - Removed num-cs property > - Separated nandchip from nand controller > Changes in v5: > - None > Changes in v4: > - Added num-cs property > - Added clock support > Changes in v3: > - None > Changes in v2: > - None > --- > .../devicetree/bindings/mtd/arasan_nand.txt | 32 ++++++++++++++++++++++ > 1 file changed, 32 insertions(+) > create mode 100644 Documentation/devicetree/bindings/mtd/arasan_nand.txt > > diff --git a/Documentation/devicetree/bindings/mtd/arasan_nand.txt b/Documentation/devicetree/bindings/mtd/arasan_nand.txt > new file mode 100644 > index 0000000..b522daf > --- /dev/null > +++ b/Documentation/devicetree/bindings/mtd/arasan_nand.txt > @@ -0,0 +1,32 @@ > +Arasan NAND Flash Controller with ONFI 3.1 support > + > +Required properties: > +- compatible: Should be "xlnx,zynqmp-nand", "arasan,nfc-v3p10" > +- reg: Memory map for module access > +- interrupts: Should contain the interrupt for the device > +- clock-name: List of input clocks - "sys", "flash" > + (See clock bindings for details) > +- clocks: Clock phandles (see clock bindings for details) > + > +Required properties for child node: > +- nand-ecc-mode: see nand.txt > + > +For NAND partition information please refer the below file > +Documentation/devicetree/bindings/mtd/partition.txt > + > +Example: > + nfc: nand@ff100000 { > + compatible = "xlnx,zynqmp-nand", "arasan,nfc-v3p10"; > + reg = <0x0 0xff100000 0x1000>; > + clock-name = "sys", "flash"; > + clocks = <&misc_clk &misc_clk>; > + interrupt-parent = <&gic>; > + interrupts = <0 14 4>; > + #address-cells = <1>; > + #size-cells = <0>; > + > + nand@0 { > + reg = <0>; > + nand-ecc-mode = "hw"; > + }; > + }; > -- > 2.7.4 > > > ______________________________________________________ > Linux MTD discussion mailing list > http://lists.infradead.org/mailman/listinfo/linux-mtd/