From patchwork Sat Jul 19 10:48:45 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Guennadi Liakhovetski X-Patchwork-Id: 4588991 X-Patchwork-Delegate: vinod.koul@intel.com Return-Path: X-Original-To: patchwork-dmaengine@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 905B49F26C for ; Sat, 19 Jul 2014 10:49:05 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A9EE0201BA for ; Sat, 19 Jul 2014 10:49:04 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id BE80A200C1 for ; Sat, 19 Jul 2014 10:49:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759978AbaGSKtD (ORCPT ); Sat, 19 Jul 2014 06:49:03 -0400 Received: from mout.kundenserver.de ([212.227.17.13]:51862 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759621AbaGSKtB (ORCPT ); Sat, 19 Jul 2014 06:49:01 -0400 Received: from axis700.grange (xdsl-85-197-51-144.netcologne.de [85.197.51.144]) by mrelayeu.kundenserver.de (node=mreue103) with ESMTP (Nemesis) id 0LmNdq-1WYqWi2VbW-00ZvxJ; Sat, 19 Jul 2014 12:48:46 +0200 Received: by axis700.grange (Postfix, from userid 1000) id 07F2C40BDB; Sat, 19 Jul 2014 12:48:45 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by axis700.grange (Postfix) with ESMTP id E984A40BD9; Sat, 19 Jul 2014 12:48:45 +0200 (CEST) Date: Sat, 19 Jul 2014 12:48:45 +0200 (CEST) From: Guennadi Liakhovetski X-X-Sender: lyakh@axis700.grange To: dmaengine@vger.kernel.org cc: Vinod Koul , "Shevchenko, Andriy" , devicetree@vger.kernel.org, Grant Likely , Rob Herring , Phil Edworthy , Arnd Bergmann Subject: [PATCH v4 1/2] dmaengine: add device tree binding documentation for the nbpfaxi driver Message-ID: MIME-Version: 1.0 X-Provags-ID: V02:K0:j0Nxqnd4ZhNBsr50Xzn34AlidTQc000LOoTZLnlepb3 zqx6NiEfTK1MGVlYgH8BYxKEz6UScrGimUpOMSVP9bxCVO9W9N sFs29633gTXuMFcOCtfAgttHxaWh0gL1iAP6/6kvsaYJJGj/t+ G+LKRrsb66vWrZ9XPH3DGKaVKVpre0HPEkJvDGCSXn6aX0xgM4 CCrwq2gu/OL3wC6Ed3yDBTynrHN8kGuTvxxGcmaJTPII+roUlk /1bKfXmqytwM1/L9/vhEQvSuu/mnmiL6O2Yx46AV2nvZuPNLMR qDL6iW6bjiY4N8IUeePO/wO8Z/+ECah0ERin5SJ2O3Y5p9ENyU +jnUEerMVxankAxO9kEV/XYtOJ7DUlwYZiNYY2UBJmWxEIkOcg Qp4LWgzUG6Upw== Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The nbpfaxi dmaengine driver doesn't define any new bindings, it only uses standard dmaengine bindings and defines 3 flags for the 3rd parameter of the "dmas" property. Signed-off-by: Guennadi Liakhovetski Acked-by: Arnd Bergmann --- v4: no change, added Arnd's ack - thanks! Documentation/devicetree/bindings/dma/nbpfaxi.txt | 61 +++++++++++++++++++++++ include/dt-bindings/dma/nbpfaxi.h | 20 ++++++++ 2 files changed, 81 insertions(+) create mode 100644 Documentation/devicetree/bindings/dma/nbpfaxi.txt create mode 100644 include/dt-bindings/dma/nbpfaxi.h diff --git a/Documentation/devicetree/bindings/dma/nbpfaxi.txt b/Documentation/devicetree/bindings/dma/nbpfaxi.txt new file mode 100644 index 0000000..d5e2522 --- /dev/null +++ b/Documentation/devicetree/bindings/dma/nbpfaxi.txt @@ -0,0 +1,61 @@ +* Renesas "Type-AXI" NBPFAXI* DMA controllers + +* DMA controller + +Required properties + +- compatible: must be one of + "renesas,nbpfaxi64dmac1b4" + "renesas,nbpfaxi64dmac1b8" + "renesas,nbpfaxi64dmac1b16" + "renesas,nbpfaxi64dmac4b4" + "renesas,nbpfaxi64dmac4b8" + "renesas,nbpfaxi64dmac4b16" + "renesas,nbpfaxi64dmac8b4" + "renesas,nbpfaxi64dmac8b8" + "renesas,nbpfaxi64dmac8b16" +- #dma-cells: must be 2: the first integer is a terminal number, to which this + slave is connected, the second one is flags. Flags is a bitmask + with the following bits defined: + +#define NBPF_SLAVE_RQ_HIGH 1 +#define NBPF_SLAVE_RQ_LOW 2 +#define NBPF_SLAVE_RQ_LEVEL 4 + +Optional properties: + +You can use dma-channels and dma-requests as described in dma.txt, although they +won't be used, this information is derived from the compatibility string. + +Example: + + dma: dma-controller@48000000 { + compatible = "renesas,nbpfaxi64dmac8b4"; + reg = <0x48000000 0x400>; + interrupts = <0 12 0x4 + 0 13 0x4 + 0 14 0x4 + 0 15 0x4 + 0 16 0x4 + 0 17 0x4 + 0 18 0x4 + 0 19 0x4>; + #dma-cells = <2>; + dma-channels = <8>; + dma-requests = <8>; + }; + +* DMA client + +Required properties: + +dmas and dma-names are required, as described in dma.txt. + +Example: + +#include + +... + dmas = <&dma 0 (NBPF_SLAVE_RQ_HIGH | NBPF_SLAVE_RQ_LEVEL) + &dma 1 (NBPF_SLAVE_RQ_HIGH | NBPF_SLAVE_RQ_LEVEL)>; + dma-names = "rx", "tx"; diff --git a/include/dt-bindings/dma/nbpfaxi.h b/include/dt-bindings/dma/nbpfaxi.h new file mode 100644 index 0000000..c1a5b9e --- /dev/null +++ b/include/dt-bindings/dma/nbpfaxi.h @@ -0,0 +1,20 @@ +/* + * Copyright (C) 2013-2014 Renesas Electronics Europe Ltd. + * Author: Guennadi Liakhovetski + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of version 2 of the GNU General Public License as + * published by the Free Software Foundation. + */ + +#ifndef DT_BINDINGS_NBPFAXI_H +#define DT_BINDINGS_NBPFAXI_H + +/** + * Use "#dma-cells = <2>;" with the second integer defining slave DMA flags: + */ +#define NBPF_SLAVE_RQ_HIGH 1 +#define NBPF_SLAVE_RQ_LOW 2 +#define NBPF_SLAVE_RQ_LEVEL 4 + +#endif