From patchwork Thu Sep 8 18:24:27 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephan Gerhold X-Patchwork-Id: 603952 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 D624BC6FA95 for ; Thu, 8 Sep 2022 18:25:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231561AbiIHSZV (ORCPT ); Thu, 8 Sep 2022 14:25:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37816 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230096AbiIHSZR (ORCPT ); Thu, 8 Sep 2022 14:25:17 -0400 Received: from mx.kernkonzept.com (serv1.kernkonzept.com [IPv6:2a01:4f8:1c1c:b490::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 008C14DB26; Thu, 8 Sep 2022 11:25:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kernkonzept.com; s=mx1; h=Content-Transfer-Encoding:MIME-Version:References :In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=NT7X1Sz5W6hQSIsiU4ULlcCcuruRhLO5lb17p/kGl3E=; b=CjAh+JtQhKpfLiqP2XIz1gTKh+ DDDQHx4rrvytIgiOrQws6xJ5nju0emEA+QOfRb0326lxcsZApak4HClhUm2IOuEyl91QMIe7GZ6jv fpFYneR36uv9h1OmIocVJizTrRTuv9GPlF5FqK2012GuSXUw2Puw3M3VhTDR9nI7pkEwgc+/Wy9s7 ZUuwudK4jR9D/DDWioINXeCLIS6uAIHoO7LvteMSkxhoWgcvB0E6rgAENK2W/Jm8l3KvT188W4b7N 7rCjdCtro6FybO7YfWsktSFM28BcSr0oHNk1y1ppjpId99k27H16Hms5t/rvlT1puYphktLbEvb0f CFHchNvg==; Received: from [10.22.3.24] (helo=kernkonzept.com) by mx.kernkonzept.com with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.94.2) id 1oWMCy-004g9E-LC; Thu, 08 Sep 2022 20:25:00 +0200 From: Stephan Gerhold To: Bjorn Andersson Cc: Andy Gross , Konrad Dybcio , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Sireesh Kodali , Luca Weiss , Stephan Gerhold , linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, Stephan Gerhold , Krzysztof Kozlowski Subject: [PATCH v4 1/7] arm64: dts: qcom: msm8916: Drop MSS fallback compatible Date: Thu, 8 Sep 2022 20:24:27 +0200 Message-Id: <20220908182433.466908-2-stephan.gerhold@kernkonzept.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220908182433.466908-1-stephan.gerhold@kernkonzept.com> References: <20220908182433.466908-1-stephan.gerhold@kernkonzept.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org MSM8916 was originally using the "qcom,q6v5-pil" compatible for the MSS remoteproc. Later it was decided to use SoC-specific compatibles instead, so "qcom,msm8916-mss-pil" is now the preferred compatible. Commit 60a05ed059a0 ("arm64: dts: qcom: msm8916: Add MSM8916-specific compatibles to SCM/MSS") updated the MSM8916 device tree to make use of the new compatible but still kept the old "qcom,q6v5-pil" as fallback. This is inconsistent with other SoCs and conflicts with the description in the binding documentation (which says that only one compatible should be present). Also, it has no functional advantage since older kernels could not handle this DT anyway (e.g. "power-domains" in the MSS node is only supported by kernels that also support "qcom,msm8916-mss-pil"). Make this consistent with other SoCs by using only the "qcom,msm8916-mss-pil" compatible. Fixes: 60a05ed059a0 ("arm64: dts: qcom: msm8916: Add MSM8916-specific compatibles to SCM/MSS") Signed-off-by: Stephan Gerhold Reviewed-by: Krzysztof Kozlowski --- Changes in v4: None Changes in v3: None Changes in v2: Add Krzysztof's Reviewed-by --- This fixes the following dtbs_check warning after the DT schema conversion: remoteproc@4080000: compatible: 'oneOf' conditional failed, one must be fixed: ['qcom,msm8916-mss-pil', 'qcom,q6v5-pil'] is too long, or 'qcom,q6v5-pil' was expected From schema: remoteproc/qcom,msm8916-mss-pil.yaml --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/msm8916.dtsi b/arch/arm64/boot/dts/qcom/msm8916.dtsi index de741f287e1d..147c6aa3f046 100644 --- a/arch/arm64/boot/dts/qcom/msm8916.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8916.dtsi @@ -1345,7 +1345,7 @@ bam_dmux_dma: dma-controller@4044000 { }; mpss: remoteproc@4080000 { - compatible = "qcom,msm8916-mss-pil", "qcom,q6v5-pil"; + compatible = "qcom,msm8916-mss-pil"; reg = <0x04080000 0x100>, <0x04020000 0x040>; From patchwork Thu Sep 8 18:24:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephan Gerhold X-Patchwork-Id: 603953 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 D572AC6FA8D for ; Thu, 8 Sep 2022 18:25:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230457AbiIHSZT (ORCPT ); Thu, 8 Sep 2022 14:25:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38618 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229822AbiIHSZR (ORCPT ); Thu, 8 Sep 2022 14:25:17 -0400 Received: from mx.kernkonzept.com (serv1.kernkonzept.com [IPv6:2a01:4f8:1c1c:b490::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E420E29CAE; Thu, 8 Sep 2022 11:25:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kernkonzept.com; s=mx1; h=Content-Transfer-Encoding:MIME-Version:References :In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=50QxB3s4Ts4GqsY0TmPOx4VxPARKM+OSsYpAOCkBf78=; b=H7fBnWTeF6ISd7lwity5eTXo4O sFDc0ZtjGMvNtDAmHQrV+fjfXpo54jyWSc7Q4b79VHCrwtWE4nC/h4Btu8jFysiwCN0XT3ldvnD58 eMZpPOcNc2XgG/8uic0Jeq1+W1udAx3+r2KfrqLD9tuQTBI+xImoJrZSmAyePOpkKGCTzDYQxIh+k vmkyp6UzIospB/Qe5pPJWvdSEQYjGekAorUkahXJ6k6LIyLJUmoyIL9dbYQISolHqwNQVCzJCzH5T UigE8oBNQrL2NzPMZgyzph8FeEXuIsQCXGIQjASMbgde+/EL/IaJbUT0tqErqNzfDPjfj4pjTTXTR MJjV9gZQ==; Received: from [10.22.3.24] (helo=kernkonzept.com) by mx.kernkonzept.com with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.94.2) id 1oWMD2-004g9E-5o; Thu, 08 Sep 2022 20:25:04 +0200 From: Stephan Gerhold To: Bjorn Andersson Cc: Andy Gross , Konrad Dybcio , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Sireesh Kodali , Luca Weiss , Stephan Gerhold , linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, Stephan Gerhold , Krzysztof Kozlowski Subject: [PATCH v4 3/7] dt-bindings: remoteproc: qcom,msm8916-mss-pil: Add MSM8974 Date: Thu, 8 Sep 2022 20:24:29 +0200 Message-Id: <20220908182433.466908-4-stephan.gerhold@kernkonzept.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220908182433.466908-1-stephan.gerhold@kernkonzept.com> References: <20220908182433.466908-1-stephan.gerhold@kernkonzept.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The "qcom,msm8974-mss-pil" binding is still similar enough to MSM8916 to be covered by the same DT schema. The only difference is the additional "mss-supply", which can be easily handled using a single if statement. Signed-off-by: Stephan Gerhold Reviewed-by: Krzysztof Kozlowski --- Changes in v4: Drop obvious comment, add Krzysztof's Reviewed-by Changes in v3: None Changes in v2: - Add if to the "allOf" list (suggested by Krzysztof) --- .../remoteproc/qcom,msm8916-mss-pil.yaml | 15 +++++++++++++++ .../devicetree/bindings/remoteproc/qcom,q6v5.txt | 16 ---------------- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml index ce95e025b54a..d7d05f9ec8ae 100644 --- a/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml +++ b/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml @@ -18,6 +18,7 @@ properties: oneOf: - enum: - qcom,msm8916-mss-pil + - qcom,msm8974-mss-pil - const: qcom,q6v5-pil description: Deprecated, prefer using qcom,msm8916-mss-pil @@ -76,6 +77,9 @@ properties: pll-supply: description: PLL proxy supply (control handed over after startup) + mss-supply: + description: MSS power domain supply (only valid for qcom,msm8974-mss-pil) + resets: items: - description: MSS restart control @@ -181,6 +185,17 @@ required: - smd-edge allOf: + - if: + properties: + compatible: + const: qcom,msm8974-mss-pil + then: + required: + - mss-supply + else: + properties: + mss-supply: false + # Fallbacks for deprecated properties - oneOf: - required: diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt b/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt index 11862b6c2339..5923c0447e2d 100644 --- a/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt +++ b/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt @@ -9,7 +9,6 @@ on the Qualcomm Hexagon core. Definition: must be one of: "qcom,ipq8074-wcss-pil" "qcom,qcs404-wcss-pil" - "qcom,msm8974-mss-pil" "qcom,msm8996-mss-pil" "qcom,msm8998-mss-pil" "qcom,sdm845-mss-pil" @@ -37,7 +36,6 @@ on the Qualcomm Hexagon core. string: qcom,ipq8074-wcss-pil: qcom,qcs404-wcss-pil: - qcom,msm8974-mss-pil: must be "wdog", "fatal", "ready", "handover", "stop-ack" qcom,msm8996-mss-pil: qcom,msm8998-mss-pil: @@ -68,8 +66,6 @@ on the Qualcomm Hexagon core. "gcc_axim_cbcr", "lcc_ahbfabric_cbc", "tcsr_lcc_cbc", "lcc_abhs_cbc", "lcc_tcm_slave_cbc", "lcc_abhm_cbc", "lcc_axim_cbc", "lcc_bcr_sleep" - qcom,msm8974-mss-pil: - must be "iface", "bus", "mem", "xo" qcom,msm8996-mss-pil: must be "iface", "bus", "mem", "xo", "gpll0_mss", "snoc_axi", "mnoc_axi", "pnoc", "qdss" @@ -106,17 +102,6 @@ should be referenced as follows: Definition: reference to the reserved-memory for the mba region followed by the mpss region -For the compatible string below the following supplies are required: - "qcom,msm8974-mss-pil" -- cx-supply: (deprecated, use power domain instead) -- mss-supply: -- mx-supply: (deprecated, use power domain instead) -- pll-supply: - Usage: required - Value type: - Definition: reference to the regulators to be held on behalf of the - booting of the Hexagon core - For the compatible string below the following supplies are required: "qcom,qcs404-wcss-pil" - cx-supply: @@ -144,7 +129,6 @@ For the compatible string below the following supplies are required: Definition: The power-domains needed depend on the compatible string: qcom,ipq8074-wcss-pil: no power-domain names required - qcom,msm8974-mss-pil: qcom,msm8996-mss-pil: qcom,msm8998-mss-pil: must be "cx", "mx" From patchwork Thu Sep 8 18:24:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephan Gerhold X-Patchwork-Id: 603951 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 9EE0CC38145 for ; Thu, 8 Sep 2022 18:25:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231965AbiIHSZY (ORCPT ); Thu, 8 Sep 2022 14:25:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38942 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231894AbiIHSZU (ORCPT ); Thu, 8 Sep 2022 14:25:20 -0400 Received: from mx.kernkonzept.com (serv1.kernkonzept.com [IPv6:2a01:4f8:1c1c:b490::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9D3EF5A2ED; Thu, 8 Sep 2022 11:25:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kernkonzept.com; s=mx1; h=Content-Transfer-Encoding:MIME-Version:References :In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=HySvzKRlrbsyWfKOvvMkyCrlXhMS/1H92OjLfJ53SIk=; b=Ucuo3B6vXUj31S5yrirXr3SUjw aFkbzxPKbpXO2bQ8xDGhm9AToz9Y9b/BIY5uaz7/6C3Bhm7gnqVNu8INSFo4/pATU2l9shV9T8G8N WRY4E+Jeq72KcxcXCCkhgidY5VN7PV++hXcRyU6Ca/TZ3FFBAIVTIix+mUt+dF16+kLIlEZpch9Nb wIFLq5gjU0+soAlgZEP99mZiaW7hBuknS+6enc0nghQcKpTf4bR6H7g8MEANaz8aE7bE+Kxs94meU Ha6zIvHpSun2H7VQ4BoQzjHKpzt/7GGqqJUfOa7AEk6FdCB37q5mzrRjJu4Eb2v7fS02Jac7zVgUT BQBVxScg==; Received: from [10.22.3.24] (helo=kernkonzept.com) by mx.kernkonzept.com with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.94.2) id 1oWMD7-004g9E-LM; Thu, 08 Sep 2022 20:25:09 +0200 From: Stephan Gerhold To: Bjorn Andersson Cc: Andy Gross , Konrad Dybcio , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Sireesh Kodali , Luca Weiss , Stephan Gerhold , linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, Stephan Gerhold , Krzysztof Kozlowski Subject: [PATCH v4 6/7] dt-bindings: remoteproc: qcom,msm8916-mss-pil: Add MSM8953 Date: Thu, 8 Sep 2022 20:24:32 +0200 Message-Id: <20220908182433.466908-7-stephan.gerhold@kernkonzept.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220908182433.466908-1-stephan.gerhold@kernkonzept.com> References: <20220908182433.466908-1-stephan.gerhold@kernkonzept.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add the compatible for MSS as found on the MSM8953 platform. The situation is similar to the existing bindings for MSM8974: there is an additional "mss" power domain that must be voted for while starting up the remote processor. The difference is that on MSM8974 the power domain is represented as a regulator (firmware expects specific voltage) while on MSM8953 it is represented as power domain (firmware expects performance state instead of voltage). Handle this difference by adding the "mss" power domain as optional third item, and then restrict it (and make it required) only when using the MSM8953 compatible. Co-developed-by: Sireesh Kodali Signed-off-by: Sireesh Kodali Signed-off-by: Stephan Gerhold Reviewed-by: Krzysztof Kozlowski --- Changes in v4: Drop obvious comment, add Krzysztof's Reviewed-by Changes in v3: Combine series with Sireesh's patches for MSM8953 --- .../remoteproc/qcom,msm8916-mss-pil.yaml | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml index 250bf4afab10..6e6e69ad9cd7 100644 --- a/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml +++ b/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml @@ -19,6 +19,7 @@ properties: - enum: - qcom,msm8909-mss-pil - qcom,msm8916-mss-pil + - qcom,msm8953-mss-pil - qcom,msm8974-mss-pil - const: qcom,q6v5-pil @@ -69,11 +70,16 @@ properties: items: - description: CX proxy power domain (control handed over after startup) - description: MX proxy power domain (control handed over after startup) + - description: MSS proxy power domain (control handed over after startup) + (only valid for qcom,msm8953-mss-pil) + minItems: 2 power-domain-names: items: - const: cx - const: mx + - const: mss # only valid for qcom,msm8953-mss-pil + minItems: 2 pll-supply: description: PLL proxy supply (control handed over after startup) @@ -186,6 +192,26 @@ required: - smd-edge allOf: + - if: + properties: + compatible: + const: qcom,msm8953-mss-pil + then: + properties: + power-domains: + minItems: 3 + power-domain-names: + minItems: 3 + required: + - power-domains + - power-domain-names + else: + properties: + power-domains: + maxItems: 2 + power-domain-names: + maxItems: 2 + - if: properties: compatible: