Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0EB8DC433F5 for ; Mon, 29 Nov 2021 11:04:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376820AbhK2LIF (ORCPT ); Mon, 29 Nov 2021 06:08:05 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49502 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244164AbhK2LF5 (ORCPT ); Mon, 29 Nov 2021 06:05:57 -0500 Received: from mail-wr1-x431.google.com (mail-wr1-x431.google.com [IPv6:2a00:1450:4864:20::431]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 13D6FC08E6E1 for ; Mon, 29 Nov 2021 02:19:45 -0800 (PST) Received: by mail-wr1-x431.google.com with SMTP id s13so35639065wrb.3 for ; Mon, 29 Nov 2021 02:19:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=bwSCk0wXrHcMz/Ne5LcNLW8DULwM2fwTr0/wYCbZbNw=; b=TfPZa9b2Gfmja+xE08xKdHPUCAVBrBPkXc15EwzdPUPGX5QfmkK5zsfFVOn0lNwg2F O8e75gE2wIHLt9IWg8od0YWQ69Sg3XiNVUNJEj9JWLyAK9CWJZY+/GGRgHeDZH1LbP3G wUlCi0brMqcF0uvfQ+IgwEyHnEF9eqsmTR6W7/PTwMIf8gLwAf21HmQxBTI06ClpNV52 5OiE94DK5RnbAxtvRTF3acy9RSQakMF4FD6Jr0tEMF8SkAWGAiLXE9x4ujeqNeOVbQly nNBqB5aNzOtWCAnRjnFEvtLueJcJZX+GLI6aJqoF1R8ZhiqkFSNCGnp/+oQodUD686zH HuoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=bwSCk0wXrHcMz/Ne5LcNLW8DULwM2fwTr0/wYCbZbNw=; b=ukGrqV9mBScH6u4temPK1Qh6ebKnEHyVqz5ZVZPseU8goo1iAszHHPRAQccc5bFhfD x57DldmF1+jCG13257WXTUdB5FfAZMERMNLSUF/QoGhkGpEFGyyy9IZDuiyeLZ4VMaKi tDJavqCQEhD55BQF9p+Mnl1diPfAQwof1OQaHt8z1n+eBScykqrm3yAWQe3gTYRt62GP V5XAfeF3DoTkaK/mAeAyQBCKgR97iH7M37ZnnYSvVjXskqLAdKVOMWdAG8oHDum4TMUk X++mSB9ANz0Xo8eOs0zWYGczsPOE2et3SgTRSpAwFKodRzYpv+GO6560KRoSlhUXzu2G fYLg== X-Gm-Message-State: AOAM530WpBgjVojMfUrYZktLn0DQ2qUbhabgR+RQ7gY6qM0/W7ZoCC0o ojmM5EbqDxPuOqok8fTzeQKteA== X-Google-Smtp-Source: ABdhPJypnvKfy+kf/FJbr+uN3rHCCx0U4LXPrPEBo44DZLZosm9/D7/09nOVKfxhmKlD9a+7SN9h2g== X-Received: by 2002:a05:6000:1868:: with SMTP id d8mr33585975wri.285.1638181183558; Mon, 29 Nov 2021 02:19:43 -0800 (PST) Received: from srini-hackbox.lan (cpc90716-aztw32-2-0-cust825.18-1.cable.virginm.net. [86.26.103.58]) by smtp.gmail.com with ESMTPSA id j11sm13224841wrt.3.2021.11.29.02.19.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Nov 2021 02:19:42 -0800 (PST) From: Srinivas Kandagatla To: robh+dt@kernel.org, gregkh@linuxfoundation.org Cc: devicetree@vger.kernel.org, ekangupt@qti.qualcomm.com, jeyr@codeaurora.org, bkumar@qti.qualcomm.com, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Srinivas Kandagatla Subject: [PATCH v2] dt-bindings: misc: fastrpc convert bindings to yaml Date: Mon, 29 Nov 2021 10:19:30 +0000 Message-Id: <20211129101931.28154-1-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Convert Qualcomm FastRPC bindings to yaml format, so that we could validate dt-entries correctly and any future additions can go into yaml format. Signed-off-by: Srinivas Kandagatla --- .../devicetree/bindings/misc/qcom,fastrpc.txt | 78 ---------------- .../bindings/misc/qcom,fastrpc.yaml | 92 +++++++++++++++++++ 2 files changed, 92 insertions(+), 78 deletions(-) delete mode 100644 Documentation/devicetree/bindings/misc/qcom,fastrpc.txt create mode 100644 Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml diff --git a/Documentation/devicetree/bindings/misc/qcom,fastrpc.txt b/Documentation/devicetree/bindings/misc/qcom,fastrpc.txt deleted file mode 100644 index 2a1827ab50d2..000000000000 --- a/Documentation/devicetree/bindings/misc/qcom,fastrpc.txt +++ /dev/null @@ -1,78 +0,0 @@ -Qualcomm Technologies, Inc. FastRPC Driver - -The FastRPC implements an IPC (Inter-Processor Communication) -mechanism that allows for clients to transparently make remote method -invocations across DSP and APPS boundaries. This enables developers -to offload tasks to the DSP and free up the application processor for -other tasks. - -- compatible: - Usage: required - Value type: - Definition: must be "qcom,fastrpc" - -- label - Usage: required - Value type: - Definition: should specify the dsp domain name this fastrpc - corresponds to. must be one of this: "adsp", "mdsp", "sdsp", "cdsp" - -- #address-cells - Usage: required - Value type: - Definition: Must be 1 - -- #size-cells - Usage: required - Value type: - Definition: Must be 0 - -= COMPUTE BANKS -Each subnode of the Fastrpc represents compute context banks available -on the dsp. -- All Compute context banks MUST contain the following properties: - -- compatible: - Usage: required - Value type: - Definition: must be "qcom,fastrpc-compute-cb" - -- reg - Usage: required - Value type: - Definition: Context Bank ID. - -- qcom,nsessions: - Usage: Optional - Value type: - Defination: A value indicating how many sessions can share this - context bank. Defaults to 1 when this property - is not specified. - -Example: - -adsp-pil { - compatible = "qcom,msm8996-adsp-pil"; - ... - smd-edge { - label = "lpass"; - fastrpc { - compatible = "qcom,fastrpc"; - qcom,smd-channels = "fastrpcsmd-apps-dsp"; - label = "adsp"; - #address-cells = <1>; - #size-cells = <0>; - - cb@1 { - compatible = "qcom,fastrpc-compute-cb"; - reg = <1>; - }; - - cb@2 { - compatible = "qcom,fastrpc-compute-cb"; - reg = <2>; - }; - ... - }; - }; -}; diff --git a/Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml b/Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml new file mode 100644 index 000000000000..9dc8d584ed63 --- /dev/null +++ b/Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml @@ -0,0 +1,92 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: "http://devicetree.org/schemas/misc/qcom,fastrpc.yaml#" +$schema: "http://devicetree.org/meta-schemas/core.yaml#" + +title: Qualcomm Technologies, Inc. FastRPC Driver + +maintainers: + - Srinivas Kandagatla + +description: | + This binding describes Qualcomm FastRPC an IPC (Inter-Processor Communication) + mechanism that allows for clients to transparently make remote method + invocations across DSP and APPS boundaries. This enables developers + to offload tasks to the DSP and free up the application processor for + other tasks. + +properties: + compatible: + const: qcom,fastrpc + + label: + enum: + - adsp + - mdsp + - sdsp + - cdsp + + "#address-cells": + const: 1 + + "#size-cells": + const: 0 + +patternProperties: + "^cb@[0-9a-f]$": + type: object + description: | + Compute context bank + + properties: + compatible: + const: qcom,fastrpc-compute-cb + + reg: + maxItems: 1 + description: Context Bank ID + + qcom,nsessions: + $ref: /schemas/types.yaml#/definitions/uint32 + description: How many sessions can share this context bank. + Defaults to 1 when this property is not specified. + + required: + - compatible + - reg + + additionalProperties: false + +required: + - compatible + - label + +additionalProperties: false + +examples: + - | + adsp-pil { + compatible = "qqcom,msm8996-adsp-pil"; + + smd-edge { + label = "lpass"; + + fastrpc { + compatible = "qcom,fastrpc"; + label = "adsp"; + #address-cells = <1>; + #size-cells = <0>; + + cb@1 { + compatible = "qcom,fastrpc-compute-cb"; + reg = <1>; + }; + + cb@2 { + compatible = "qcom,fastrpc-compute-cb"; + reg = <2>; + }; + }; + }; + }; -- 2.21.0