From patchwork Mon Nov 9 08:54:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vinod Koul X-Patchwork-Id: 320903 Delivered-To: patch@linaro.org Received: by 2002:a17:906:d156:0:0:0:0 with SMTP id br22csp2484181ejb; Mon, 9 Nov 2020 00:55:08 -0800 (PST) X-Google-Smtp-Source: ABdhPJwXo6pURvGqvw+6gMDVf6zV9PBBzv9rjX0cqInzThULx5uaigDUr7erPJdX1s7HJudm14QK X-Received: by 2002:aa7:da0a:: with SMTP id r10mr14733852eds.102.1604912107894; Mon, 09 Nov 2020 00:55:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604912107; cv=none; d=google.com; s=arc-20160816; b=hCeEgAohDmP1qzddueW3G+QJjhr9bw+bTywsKvLc4Qos15NOujq7fFgibItGofacAK QcCyEWT39nl0CLfWnnaXp7H5JQdr5B6a+RuCd+SnYlWD8Co0jAX3JEDbTmv5MDbAAyCq f9EADfCCeJw7Q4mtZ1s1IpZoRcI5vB/gKH4tnolpAaeQRQDlucNG3zCSofBAn9ijjz5T G/gRZxF03cFlSOOgqgxN7SnMnna48w2Ewh5Pkho6gr6/LlcE2Jtr6mRt3yVAnyWgINMR JrWXKoQ75iBIfFCVhXI+alHPf01tmv9z6vqDHDL9ZqD0bZVfhE6CuVKF0KfR7JDO5e3f d6Yw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=u8+icukwKXWnPKad+895Gu4zDsuW6jIjieYvi4fde1g=; b=mAOHRMj5JPRCNuYucd2mPZfpIqr8Rtr10bgqA6xL4RixQHF0mo9WWfAl3CQYcmLF55 huohWA/ZqIzN8SqwiumPtvScBlfWsimvY6F2jrI0Yqzn9Fb1PJBWRKp497ZHxAaB1QUB AEJOtkOlDt4q0XLngUPHaevH7d9yP/9dXckpVq93lmNoHXjFHSrNq4G9UJ+Q3LMTRo+z 2R9Y8QzQ9AMhw2/xRKg67rGH6Vk/n0GX6NdZYUMXuVkah5wPij+nY3HhpzBT+cerxNHN OZnddikJZ8dQnX15xPDBKxDTV3f7NDm5PBHvhEngs/mjFQaKho7DzSFvbS7GV+8gTEHs btzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=JbH9E821; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e15si6716010ejr.176.2020.11.09.00.55.07; Mon, 09 Nov 2020 00:55:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=JbH9E821; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729770AbgKIIzD (ORCPT + 15 others); Mon, 9 Nov 2020 03:55:03 -0500 Received: from mail.kernel.org ([198.145.29.99]:44526 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726127AbgKIIzD (ORCPT ); Mon, 9 Nov 2020 03:55:03 -0500 Received: from localhost.localdomain (unknown [122.171.147.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 8A37020719; Mon, 9 Nov 2020 08:54:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1604912102; bh=efD4scUagp2SIrCLpQcuOkpG1aZ/vgaraZRaowDiHr0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=JbH9E821yP74bqKwdP0/+hej1Zt8nl4L2PoXXBUEqSafQx7LdlGgzdfEcHfvyyBAI NveVOAhOiT1RhviJ4iXU61nA6BCPyNOW8BI20lL04IOn9McHv9xbYFz6EYUWquxLld MV7ZbQoY+Ua9DQJszV9k9ZLDWbRe1cXcr2cgmrTc= From: Vinod Koul To: dmaengine@vger.kernel.org Cc: linux-arm-msm@vger.kernel.org, Bjorn Andersson , Vinod Koul , Rob Herring , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Peter Ujfalusi , Rob Herring Subject: [PATCH v6 1/3] dt-bindings: dmaengine: Document qcom, gpi dma binding Date: Mon, 9 Nov 2020 14:24:48 +0530 Message-Id: <20201109085450.24843-2-vkoul@kernel.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201109085450.24843-1-vkoul@kernel.org> References: <20201109085450.24843-1-vkoul@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add devicetree binding documentation for GPI DMA controller implemented on Qualcomm SoCs Reviewed-by: Rob Herring Signed-off-by: Vinod Koul --- .../devicetree/bindings/dma/qcom,gpi.yaml | 88 +++++++++++++++++++ include/dt-bindings/dma/qcom-gpi.h | 11 +++ 2 files changed, 99 insertions(+) create mode 100644 Documentation/devicetree/bindings/dma/qcom,gpi.yaml create mode 100644 include/dt-bindings/dma/qcom-gpi.h -- 2.26.2 diff --git a/Documentation/devicetree/bindings/dma/qcom,gpi.yaml b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml new file mode 100644 index 000000000000..f8142adf9aea --- /dev/null +++ b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml @@ -0,0 +1,88 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/dma/qcom,gpi.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm Technologies Inc GPI DMA controller + +maintainers: + - Vinod Koul + +description: | + QCOM GPI DMA controller provides DMA capabilities for + peripheral buses such as I2C, UART, and SPI. + +allOf: + - $ref: "dma-controller.yaml#" + +properties: + compatible: + enum: + - qcom,sdm845-gpi-dma + + reg: + maxItems: 1 + + interrupts: + description: + Interrupt lines for each GPI instance + maxItems: 13 + + "#dma-cells": + const: 3 + description: > + DMA clients must use the format described in dma.txt, giving a phandle + to the DMA controller plus the following 3 integer cells: + - channel: if set to 0xffffffff, any available channel will be allocated + for the client. Otherwise, the exact channel specified will be used. + - seid: serial id of the client as defined in the SoC documentation. + - client: type of the client as defined in dt-bindings/dma/qcom-gpi.h + + iommus: + maxItems: 1 + + dma-channels: + maximum: 31 + + dma-channel-mask: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - "#dma-cells" + - iommus + - dma-channels + - dma-channel-mask + +additionalProperties: false + +examples: + - | + #include + #include + gpi_dma0: dma-controller@800000 { + compatible = "qcom,gpi-dma"; + #dma-cells = <3>; + reg = <0x00800000 0x60000>; + iommus = <&apps_smmu 0x0016 0x0>; + dma-channels = <13>; + dma-channel-mask = <0xfa>; + interrupts = , + , + , + , + , + , + , + , + , + , + , + , + ; + }; + +... diff --git a/include/dt-bindings/dma/qcom-gpi.h b/include/dt-bindings/dma/qcom-gpi.h new file mode 100644 index 000000000000..ebda2a37f52a --- /dev/null +++ b/include/dt-bindings/dma/qcom-gpi.h @@ -0,0 +1,11 @@ +/* SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause */ +/* Copyright (c) 2020, Linaro Ltd. */ + +#ifndef __DT_BINDINGS_DMA_QCOM_GPI_H__ +#define __DT_BINDINGS_DMA_QCOM_GPI_H__ + +#define QCOM_GPI_SPI 1 +#define QCOM_GPI_UART 2 +#define QCOM_GPI_I2C 3 + +#endif /* __DT_BINDINGS_DMA_QCOM_GPI_H__ */