From patchwork Wed Aug 13 09:12:04 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 35333 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-oi0-f70.google.com (mail-oi0-f70.google.com [209.85.218.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id B8653203C5 for ; Wed, 13 Aug 2014 09:13:02 +0000 (UTC) Received: by mail-oi0-f70.google.com with SMTP id u20sf45290029oif.5 for ; Wed, 13 Aug 2014 02:13:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=UYaeG9Phl+j59AcB9tqWqBUl6eCIY61/WjWjrK02Ouo=; b=mU5sOJoJsSsFkOrDJm7FIZ1B5A3JxVNrip14H10JKLoKjqKdll1TS3e4Dc2NJY1hLI fx6Qbzr0SkOxSCeI894+fu6zTihaKKs8WGBd5vK/KyRdYtFkdo0RxJamNCObV3Zr3mFA FWVz6/+ZepyxIwmQ8oeuQa3A/SRz3+wLYs2oxRx7aUqRewA4qTmJmo2/dBf6k4JBJrW1 JNn+y05jKzjcJpWesy/p79scJgl3k5RCE6SoiLOmxPns7T2FsQ0mh7HOOEU5YGJAdg16 LzoPUfE/278E14k1IMpxk+axB+nHI/+ruSb+KfhZv5DMy3ivxa1Tb/h7aTUQrSg9G8OE T4zg== X-Gm-Message-State: ALoCoQkv6gtLCi6vRAJCbWlSSPrX/BuYzCJQDFSuo4+qr/a8RRwcP1yYjHsRqgYw2o3hAdge4lc5 X-Received: by 10.42.212.207 with SMTP id gt15mr2341781icb.31.1407921182359; Wed, 13 Aug 2014 02:13:02 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.93.228 with SMTP id d91ls562286qge.41.gmail; Wed, 13 Aug 2014 02:13:02 -0700 (PDT) X-Received: by 10.52.3.40 with SMTP id 8mr2158614vdz.24.1407921182260; Wed, 13 Aug 2014 02:13:02 -0700 (PDT) Received: from mail-vc0-f179.google.com (mail-vc0-f179.google.com [209.85.220.179]) by mx.google.com with ESMTPS id py3si729231vdb.107.2014.08.13.02.13.02 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 13 Aug 2014 02:13:02 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.179 as permitted sender) client-ip=209.85.220.179; Received: by mail-vc0-f179.google.com with SMTP id hq11so14738921vcb.10 for ; Wed, 13 Aug 2014 02:13:02 -0700 (PDT) X-Received: by 10.221.44.69 with SMTP id uf5mr2583688vcb.4.1407921182146; Wed, 13 Aug 2014 02:13:02 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp314615vcb; Wed, 13 Aug 2014 02:13:01 -0700 (PDT) X-Received: by 10.70.56.101 with SMTP id z5mr2732355pdp.47.1407921181215; Wed, 13 Aug 2014 02:13:01 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id qt10si1034576pbb.221.2014.08.13.02.13.00 for ; Wed, 13 Aug 2014 02:13:01 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751964AbaHMJMf (ORCPT + 24 others); Wed, 13 Aug 2014 05:12:35 -0400 Received: from mail-ig0-f178.google.com ([209.85.213.178]:38937 "EHLO mail-ig0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750815AbaHMJMc (ORCPT ); Wed, 13 Aug 2014 05:12:32 -0400 Received: by mail-ig0-f178.google.com with SMTP id uq10so1065799igb.17 for ; Wed, 13 Aug 2014 02:12:31 -0700 (PDT) X-Received: by 10.50.80.39 with SMTP id o7mr13458502igx.0.1407921151784; Wed, 13 Aug 2014 02:12:31 -0700 (PDT) Received: from localhost.localdomain (host109-148-113-192.range109-148.btcentralplus.com. [109.148.113.192]) by mx.google.com with ESMTPSA id ga11sm6628023igd.8.2014.08.13.02.12.29 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 13 Aug 2014 02:12:31 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: lee.jones@linaro.org, kernel@stlinux.com, computersforpeace@gmail.com, pekon@pek-sem.com, linux-mtd@lists.infradead.org, devicetree@vger.kernel.org Subject: [PATCH 5/8] mtd: nand: stm_nand_bch: provide Device Tree documentation Date: Wed, 13 Aug 2014 10:12:04 +0100 Message-Id: <1407921127-8590-6-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1407921127-8590-1-git-send-email-lee.jones@linaro.org> References: <1407921127-8590-1-git-send-email-lee.jones@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: lee.jones@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.179 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , This is where we describe the different new and generic options used by the ST BCH driver. Cc: devicetree@vger.kernel.org Signed-off-by: Lee Jones --- Documentation/devicetree/bindings/mtd/stm-nand.txt | 74 ++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 Documentation/devicetree/bindings/mtd/stm-nand.txt diff --git a/Documentation/devicetree/bindings/mtd/stm-nand.txt b/Documentation/devicetree/bindings/mtd/stm-nand.txt new file mode 100644 index 0000000..3176252 --- /dev/null +++ b/Documentation/devicetree/bindings/mtd/stm-nand.txt @@ -0,0 +1,74 @@ +STM BCH NAND Support +-------------------- + +Required properties: + +- compatible : Should be "st,nand-bch" +- reg : Should contain register's location and length +- reg-names : "nand_mem" - NAND Controller register map + "nand_dma" - BCH Controller DMA configuration map +- interrupts : Interrupt number +- interrupt-names : "nand_irq" - NAND Controller IRQ +- st,nand-banks : Subnode representing one or more "banks" of NAND + Flash, connected to an STM NAND Controller (see + description below). +- nand-ecc-strength : Generic NAND property (See mtd/nand.txt) + Options are; 0, 18 or 30. If not present, the driver + will choose the strongest scheme compatible if the + OOB size. + +Properties describing Bank of NAND Flash ("st,nand-banks"): + +- st,nand-csn : Chip select associated with the Bank. + +- st,nand-timing-relax : [Optional] Number of IP clock cycles by which to + "relax" timing configuration. Required on some boards + to accommodate board-level limitations. Applies to + ONFI timing mode configuration. + +- nand-on-flash-bbt : Generic NAND property (See mtd/nand.txt) + +- partitions : [Optional] Subnode describing MTD partition map + (see mtd/partition.txt) + +Note, during initialisation, the NAND Controller timing registers are configured +according to one of the following methods, in order of precedence: + + 1. Configuration based on ONFI timing mode, as advertised by the + device during ONFI-probing (ONFI-compliant NAND only). + + 2. Use reset/safe timing values + +Example: + + nand@fe901000 { + compatible = "st,nand-bch"; + reg = <0xfe901000 0x1000>, <0xfef00800 0x0800>; + reg-names = "nand_mem", "nand_dma"; + interrupts = <0 139 0x0>; + interrupt-names = "nand_irq"; + nand-ecc-strength = <30>; + + status = "okay"; + + bank0 { + /* NAND_BBT_USE_FLASH */ + nand-on-flash-bbt; + st,nand-csn = <0>; + + partitions { + #address-cells = <1>; + #size-cells = <1>; + + partition@0{ + label = "NANDFlash1"; + reg = <0x00000000 0x00800000>; + }; + + partition@800000{ + label = "NANDFlash2"; + reg = <0x00800000 0x0f800000>; + }; + }; + }; + };