Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp211635pxu; Wed, 2 Dec 2020 20:17:43 -0800 (PST) X-Google-Smtp-Source: ABdhPJwSCsiRYmg39U5gfDz9abI/D19MdD3Yyz5aogJ3wynSgxowrD3iiEpouZ8ldXcMSHztJtfO X-Received: by 2002:a17:906:4d8d:: with SMTP id s13mr910443eju.305.1606969063543; Wed, 02 Dec 2020 20:17:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606969063; cv=none; d=google.com; s=arc-20160816; b=k2aMWxaw37OJqErvAgGbeSClwkdB7TcrEMIZjkI/VSJwtCxIKrMRM7MZygApNLOuGG GgEeG1cprpyz3vQeUMb/f+sKfNRY52GTBsuq8YkZdm74gocs7Zhq+ewmZqQ5nJTjDRSX 41NDpTC1m3xPS4XTU1PdemsXsFmw0mvMrFVXEwrYAv41vPd51iYCSvPUn50OuyqIKdcA naGkMTHK7UB0jLSFzbw8Ie7NygtuOwW6OidF5Nf/yQhjIY/NXxQmr6tVf423Qya9oFOj MzKhvVErppFnwCnfp6CO5f1LtPDcuyNQdbUS3DR871UpArJftl49SOgf8Lisgx2Tfze4 77aw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:references:in-reply-to :message-id:date:subject:cc:to:from:ironport-sdr:ironport-sdr; bh=Z/4byaSIw5VVJoDd4jCDYntNx0ywJaP5kL7D5ZLgr2I=; b=AnVsHK/sdtx4CszPktkB5VM1M8kgQgWVmSRbikobe5ghh388XCzpQM9eu7UZdcuzKy HBkE7M7HSJCZXdrC3GR3jqKdvYwPXO71BJKi1hrn9nrVLToMbmuXqscsKd6Lj86XPNxi c/QAOr4/1ejMu52vTYwvDhkJVHYrzcnkaKclCuUFheXstfYqZSjYnIp2kFxRM+LQ5Fwg R7CuXG4ownI96hbtNMt9Op1K188bO/sLbGx/rBAzNPDvUtpL3PxBQiMDlZgEQfKULzUE oI5WHkDTVBW7aL/lPh4jsRf1L+5N7kV358P5zzdo1CxBNt85gEZUGxEdE5TciZJjq8Tr RvCw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bt25si192216edb.572.2020.12.02.20.17.20; Wed, 02 Dec 2020 20:17:43 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727745AbgLCEMg (ORCPT + 99 others); Wed, 2 Dec 2020 23:12:36 -0500 Received: from mga05.intel.com ([192.55.52.43]:13548 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726071AbgLCEMg (ORCPT ); Wed, 2 Dec 2020 23:12:36 -0500 IronPort-SDR: nEgj7EI8YE3RD55hVbReMIoakgr2OekYWEjSzgE+AJbX9UsgW827AMZDmU9MkvADWvkbJ3xbKy LsKt28FAKEbw== X-IronPort-AV: E=McAfee;i="6000,8403,9823"; a="257844430" X-IronPort-AV: E=Sophos;i="5.78,388,1599548400"; d="scan'208";a="257844430" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Dec 2020 20:10:55 -0800 IronPort-SDR: JWxcdP8e3Uur8aKgRSYbAhv6RVmdyLFJMFIZwrUSqKUcW4Gb9lQ6UrQQJtQswGNuPfk5BRCAaY u+XtqDGPdidg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.78,388,1599548400"; d="scan'208";a="316329880" Received: from sgsxdev004.isng.phoenix.local (HELO localhost) ([10.226.81.179]) by fmsmga007.fm.intel.com with ESMTP; 02 Dec 2020 20:10:51 -0800 From: Amireddy Mallikarjuna reddy To: dmaengine@vger.kernel.org, vkoul@kernel.org, devicetree@vger.kernel.org, robh+dt@kernel.org Cc: linux-kernel@vger.kernel.org, andriy.shevchenko@intel.com, chuanhua.lei@linux.intel.com, cheol.yong.kim@intel.com, qi-ming.wu@intel.com, mallikarjunax.reddy@linux.intel.com, malliamireddy009@gmail.com, peter.ujfalusi@ti.com Subject: [PATCH v10 1/2] dt-bindings: dma: Add bindings for Intel LGM SoC Date: Thu, 3 Dec 2020 12:10:43 +0800 Message-Id: X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add DT bindings YAML schema for DMA controller driver of Lightning Mountain (LGM) SoC. Signed-off-by: Amireddy Mallikarjuna reddy Reviewed-by: Rob Herring --- v1: - Initial version. v2: - Fix bot errors. v3: - No change. v4: - Address Thomas langer comments - use node name pattern as dma-controller as in common binding. - Remove "_" (underscore) in instance name. - Remove "port-" and "chan-" in attribute name for both 'dma-ports' & 'dma-channels' child nodes. v5: - Moved some of the attributes in 'dma-ports' & 'dma-channels' child nodes to dma client/consumer side as cells in 'dmas' properties. v6: - Add additionalProperties: false - completely removed 'dma-ports' and 'dma-channels' child nodes. - Moved channel dt properties to client side dmas. - Use standard dma-channels and dma-channel-mask properties. - Documented reset-names - Add description for dma-cells v7: - modified compatible to oneof - Reduced number of dma-cells to 3 - Fine tune the description of some properties. v7-resend: - rebase to 5.10-rc1 v8: - rebased to 5.10-rc3 - Fixing the bot issues (wrong indentation) v9: - rebased to 5.10-rc3 - Use 'enum' instead of oneOf+const - Drop '#dma-cells' in required:, already covered in dma-common.yaml - Drop nodename Already covered by dma-controller.yaml v10: - Add Reviewed-by: Rob Herring - Fixed typo. - moved property dma-desc-in-sram to driver side. - Moved property dma-orrc to driver side. --- .../devicetree/bindings/dma/intel,ldma.yaml | 116 ++++++++++++++++++ 1 file changed, 116 insertions(+) create mode 100644 Documentation/devicetree/bindings/dma/intel,ldma.yaml diff --git a/Documentation/devicetree/bindings/dma/intel,ldma.yaml b/Documentation/devicetree/bindings/dma/intel,ldma.yaml new file mode 100644 index 000000000000..866d4c758a7a --- /dev/null +++ b/Documentation/devicetree/bindings/dma/intel,ldma.yaml @@ -0,0 +1,116 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/dma/intel,ldma.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Lightning Mountain centralized DMA controllers. + +maintainers: + - chuanhua.lei@intel.com + - mallikarjunax.reddy@intel.com + +allOf: + - $ref: "dma-controller.yaml#" + +properties: + compatible: + enum: + - intel,lgm-cdma + - intel,lgm-dma2tx + - intel,lgm-dma1rx + - intel,lgm-dma1tx + - intel,lgm-dma0tx + - intel,lgm-dma3 + - intel,lgm-toe-dma30 + - intel,lgm-toe-dma31 + + reg: + maxItems: 1 + + "#dma-cells": + const: 3 + description: + The first cell is the peripheral's DMA request line. + The second cell is the peripheral's (port) number corresponding to the channel. + The third cell is the burst length of the channel. + + dma-channels: + minimum: 1 + maximum: 16 + + dma-channel-mask: + maxItems: 1 + + clocks: + maxItems: 1 + + resets: + maxItems: 1 + + reset-names: + items: + - const: ctrl + + interrupts: + maxItems: 1 + + intel,dma-poll-cnt: + $ref: /schemas/types.yaml#definitions/uint32 + description: + DMA descriptor polling counter is used to control the poling mechanism + for the descriptor fetching for all channels. + + intel,dma-byte-en: + type: boolean + description: + DMA byte enable is only valid for DMA write(RX). + Byte enable(1) means DMA write will be based on the number of dwords + instead of the whole burst. + + intel,dma-drb: + type: boolean + description: + DMA descriptor read back to make sure data and desc synchronization. + + intel,dma-dburst-wr: + type: boolean + description: + Enable RX dynamic burst write. When it is enabled, the DMA does RX dynamic burst; + if it is disabled, the DMA RX will still support programmable fixed burst size of 2,4,8,16. + It only applies to RX DMA and memcopy DMA. + +required: + - compatible + - reg + +additionalProperties: false + +examples: + - | + dma0: dma-controller@e0e00000 { + compatible = "intel,lgm-cdma"; + reg = <0xe0e00000 0x1000>; + #dma-cells = <3>; + dma-channels = <16>; + dma-channel-mask = <0xFFFF>; + interrupt-parent = <&ioapic1>; + interrupts = <82 1>; + resets = <&rcu0 0x30 0>; + reset-names = "ctrl"; + clocks = <&cgu0 80>; + intel,dma-poll-cnt = <4>; + intel,dma-byte-en; + intel,dma-drb; + }; + - | + dma3: dma-controller@ec800000 { + compatible = "intel,lgm-dma3"; + reg = <0xec800000 0x1000>; + clocks = <&cgu0 71>; + resets = <&rcu0 0x10 9>; + #dma-cells = <3>; + intel,dma-poll-cnt = <16>; + intel,dma-byte-en; + intel,dma-dburst-wr; + }; -- 2.17.1