From patchwork Tue Jun 7 18:58:00 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12872249 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 07A71CCA483 for ; Tue, 7 Jun 2022 18:58:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6F9F610F021; Tue, 7 Jun 2022 18:58:12 +0000 (UTC) Received: from mail-lf1-x12c.google.com (mail-lf1-x12c.google.com [IPv6:2a00:1450:4864:20::12c]) by gabe.freedesktop.org (Postfix) with ESMTPS id 5D61E10EF32 for ; Tue, 7 Jun 2022 18:58:10 +0000 (UTC) Received: by mail-lf1-x12c.google.com with SMTP id h23so29728186lfe.4 for ; Tue, 07 Jun 2022 11:58:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=SW3uTnCI0m++1ZDWVuzx/aiaV+RkUBOb3ippKLfWJEQ=; b=RlaJCxPAMBMhzuJbHWnOcGHU938hTjhGo64PGI8AFFRRvnEeNMTFblPQCXERNu8xJE DBoU28nYpDsG5eapauaFVL4TtlPBhHkIBy3aNev2tegQjj1DCGAEhfHdem22R5iEcNvb HepraBMGr1E52sxVLrsHHmyxO81uyqRJ1bucUfyrDq04P1G14FtRcg2ogSkOne5+oYCD BFevL7yWjBHlhbhKI4Dtn7yZ+71lMcjyVcwAI9exWbr4ekezO+oLKpTisqqdMcA7xN81 8O9qKFsx0PQJki10Cg8DWvI0+n9dJ6T1munTw65PePfWuxIz+VWz+HgbR01oZf9eHeQY a6mQ== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=SW3uTnCI0m++1ZDWVuzx/aiaV+RkUBOb3ippKLfWJEQ=; b=gArzFmiEDd7Ah8bGskt+jDb38F8p9JVym7u70S5cgVvwYmR33fZhO0V1IxSneL745z TFPb21b/4qzNB8H5ggjotWzVn57u27Lwlabu/g6gfEFVEZZImeCYaBJfSUaHC0qLgLrJ xcr1NLuaYdoy0mMUfOLV7cstKo1doGT0tfjxlg1qJBO9Z7jqL4Hy7aCQf18vQR2x9Yru JCUgXXoXmiCyl9//yShYYpltmy7ghsLj6ib5+fQ9RsVqjEA6BGgLHI328cmBW9f49oci DNoWpeeBYanq5NWDVchXqZrJCzm4EUi1lJy4lJIpTtsPzBmC/3j260p++BxE754YD4Qi Um8g== X-Gm-Message-State: AOAM533YCLi+5PlOUQNF0TFQcnEqijY0Uo0+DOhTeZiOR2KdWRn89TeZ iL8lLpJF6duMUCgXrtXFg8r0jA== X-Google-Smtp-Source: ABdhPJwdCs5iGfl1tpN1AhkJPBCcLbEKhSFw11CVJ8adBLNwenzSxSTUTe0XyWgN/UXAP3I1KJNU4g== X-Received: by 2002:a05:6512:3b26:b0:479:5610:5672 with SMTP id f38-20020a0565123b2600b0047956105672mr5667750lfv.464.1654628288534; Tue, 07 Jun 2022 11:58:08 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id d19-20020a2eb053000000b0025587b872cesm1611668ljl.70.2022.06.07.11.58.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 11:58:08 -0700 (PDT) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Rob Herring , Krzysztof Kozlowski Subject: [PATCH v1 1/7] dt-bindings: display/msm: hdmi: split and convert to yaml Date: Tue, 7 Jun 2022 21:58:00 +0300 Message-Id: <20220607185806.2771739-2-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> References: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , David Heidelberg , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Convert Qualcomm HDMI binding into HDMI TX and PHY yaml bindings. Changes to schema: HDMI: - fixed reg-names numbering to match 0..3 instead 0,1,3,4 PHY: - moved into phy/ directory - split into QMP and non-QMP PHY schemas Co-developed-by: David Heidelberg Signed-off-by: Dmitry Baryshkov Reviewed-by: David Heidelberg --- .../devicetree/bindings/display/msm/hdmi.txt | 99 -------- .../bindings/display/msm/qcom,hdmi.yaml | 237 ++++++++++++++++++ .../bindings/phy/qcom,hdmi-phy-other.yaml | 103 ++++++++ .../bindings/phy/qcom,hdmi-phy-qmp.yaml | 84 +++++++ 4 files changed, 424 insertions(+), 99 deletions(-) delete mode 100644 Documentation/devicetree/bindings/display/msm/hdmi.txt create mode 100644 Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml create mode 100644 Documentation/devicetree/bindings/phy/qcom,hdmi-phy-other.yaml create mode 100644 Documentation/devicetree/bindings/phy/qcom,hdmi-phy-qmp.yaml diff --git a/Documentation/devicetree/bindings/display/msm/hdmi.txt b/Documentation/devicetree/bindings/display/msm/hdmi.txt deleted file mode 100644 index 5f90a40da51b..000000000000 --- a/Documentation/devicetree/bindings/display/msm/hdmi.txt +++ /dev/null @@ -1,99 +0,0 @@ -Qualcomm adreno/snapdragon hdmi output - -Required properties: -- compatible: one of the following - * "qcom,hdmi-tx-8996" - * "qcom,hdmi-tx-8994" - * "qcom,hdmi-tx-8084" - * "qcom,hdmi-tx-8974" - * "qcom,hdmi-tx-8660" - * "qcom,hdmi-tx-8960" -- reg: Physical base address and length of the controller's registers -- reg-names: "core_physical" -- interrupts: The interrupt signal from the hdmi block. -- power-domains: Should be <&mmcc MDSS_GDSC>. -- clocks: device clocks - See ../clocks/clock-bindings.txt for details. -- core-vdda-supply: phandle to supply regulator -- hdmi-mux-supply: phandle to mux regulator -- phys: the phandle for the HDMI PHY device -- phy-names: the name of the corresponding PHY device - -Optional properties: -- hpd-gpios: hpd pin -- qcom,hdmi-tx-mux-en-gpios: hdmi mux enable pin -- qcom,hdmi-tx-mux-sel-gpios: hdmi mux select pin -- qcom,hdmi-tx-mux-lpm-gpios: hdmi mux lpm pin -- power-domains: reference to the power domain(s), if available. -- pinctrl-names: the pin control state names; should contain "default" -- pinctrl-0: the default pinctrl state (active) -- pinctrl-1: the "sleep" pinctrl state - -HDMI PHY: -Required properties: -- compatible: Could be the following - * "qcom,hdmi-phy-8660" - * "qcom,hdmi-phy-8960" - * "qcom,hdmi-phy-8974" - * "qcom,hdmi-phy-8084" - * "qcom,hdmi-phy-8996" -- #phy-cells: Number of cells in a PHY specifier; Should be 0. -- reg: Physical base address and length of the registers of the PHY sub blocks. -- reg-names: The names of register regions. The following regions are required: - * "hdmi_phy" - * "hdmi_pll" - For HDMI PHY on msm8996, these additional register regions are required: - * "hdmi_tx_l0" - * "hdmi_tx_l1" - * "hdmi_tx_l3" - * "hdmi_tx_l4" -- power-domains: Should be <&mmcc MDSS_GDSC>. -- clocks: device clocks - See Documentation/devicetree/bindings/clock/clock-bindings.txt for details. -- core-vdda-supply: phandle to vdda regulator device node - -Example: - -/ { - ... - - hdmi: hdmi@4a00000 { - compatible = "qcom,hdmi-tx-8960"; - reg-names = "core_physical"; - reg = <0x04a00000 0x2f0>; - interrupts = ; - power-domains = <&mmcc MDSS_GDSC>; - clock-names = - "core", - "master_iface", - "slave_iface"; - clocks = - <&mmcc HDMI_APP_CLK>, - <&mmcc HDMI_M_AHB_CLK>, - <&mmcc HDMI_S_AHB_CLK>; - qcom,hdmi-tx-ddc-clk = <&msmgpio 70 GPIO_ACTIVE_HIGH>; - qcom,hdmi-tx-ddc-data = <&msmgpio 71 GPIO_ACTIVE_HIGH>; - qcom,hdmi-tx-hpd = <&msmgpio 72 GPIO_ACTIVE_HIGH>; - core-vdda-supply = <&pm8921_hdmi_mvs>; - hdmi-mux-supply = <&ext_3p3v>; - pinctrl-names = "default", "sleep"; - pinctrl-0 = <&hpd_active &ddc_active &cec_active>; - pinctrl-1 = <&hpd_suspend &ddc_suspend &cec_suspend>; - - phys = <&hdmi_phy>; - phy-names = "hdmi_phy"; - }; - - hdmi_phy: phy@4a00400 { - compatible = "qcom,hdmi-phy-8960"; - reg-names = "hdmi_phy", - "hdmi_pll"; - reg = <0x4a00400 0x60>, - <0x4a00500 0x100>; - #phy-cells = <0>; - power-domains = <&mmcc MDSS_GDSC>; - clock-names = "slave_iface"; - clocks = <&mmcc HDMI_S_AHB_CLK>; - core-vdda-supply = <&pm8921_hdmi_mvs>; - }; -}; diff --git a/Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml b/Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml new file mode 100644 index 000000000000..2f485b5d1c5d --- /dev/null +++ b/Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml @@ -0,0 +1,237 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- + +$id: "http://devicetree.org/schemas/display/msm/qcom,hdmi.yaml#" +$schema: "http://devicetree.org/meta-schemas/core.yaml#" + +title: Qualcomm Adreno/Snapdragon HDMI output + +maintainers: + - Rob Clark + +properties: + compatible: + enum: + - qcom,hdmi-tx-8660 + - qcom,hdmi-tx-8960 + - qcom,hdmi-tx-8974 + - qcom,hdmi-tx-8084 + - qcom,hdmi-tx-8994 + - qcom,hdmi-tx-8996 + + clocks: + minItems: 1 + maxItems: 5 + + clock-names: + minItems: 1 + maxItems: 5 + + reg: + minItems: 1 + maxItems: 3 + description: Physical base address and length of the controller's registers + + reg-names: + minItems: 1 + items: + - const: core_physical + - const: qfprom_physical + - const: hdcp_physical + + interrupts: + maxItems: 1 + description: The interrupt signal from the hdmi block. + + phys: + description: the phandle for the HDMI PHY device + maxItems: 1 + + phy-names: + enum: + - hdmi_phy + - hdmi-phy + + hpd-gpios: + maxItems: 1 + description: hpd pin + + qcom,hdmi-tx-ddc-clk-gpios: + maxItems: 1 + description: HDMI DDC clock + + qcom,hdmi-tx-ddc-data-gpios: + maxItems: 1 + description: HDMI DDC data + + qcom,hdmi-tx-mux-en-gpios: + maxItems: 1 + description: HDMI mux enable pin + + qcom,hdmi-tx-mux-sel-gpios: + maxItems: 1 + description: HDMI mux select pin + + qcom,hdmi-tx-mux-lpm-gpios: + maxItems: 1 + description: HDMI mux lpm pin + + '#sound-dai-cells': + const: 1 + + ports: + type: object + $ref: /schemas/graph.yaml#/properties/ports + properties: + port@0: + $ref: /schemas/graph.yaml#/$defs/port-base + description: | + Input endpoints of the controller. + + port@1: + $ref: /schemas/graph.yaml#/$defs/port-base + description: | + Output endpoints of the controller. + + required: + - port@0 + +required: + - compatible + - clocks + - clock-names + - reg + - reg-names + - interrupts + - phys + - phy-names + +allOf: + - if: + properties: + compatible: + contains: + enum: + - qcom,hdmi-tx-8960 + then: + properties: + clocks: + minItems: 3 + maxItems: 3 + clock-names: + items: + - const: core + - const: master_iface + - const: slave_iface + core-vdda-supply: + description: phandle to VDDA supply regulator + hdmi-mux-supply: + description: phandle to mux regulator + + - if: + properties: + compatible: + contains: + enum: + - qcom,hdmi-tx-8974 + - qcom,hdmi-tx-8084 + - qcom,hdmi-tx-8994 + - qcom,hdmi-tx-8996 + then: + properties: + clocks: + minItems: 5 + clock-names: + items: + - const: mdp_core + - const: iface + - const: core + - const: alt_iface + - const: extp + core-vdda-supply: + description: phandle to VDDA supply regulator + core-vcc-supply: + description: phandle to VCC supply regulator + +unevaluatedProperties: false + +examples: + - | + hdmi: hdmi@4a00000 { + compatible = "qcom,hdmi-tx-8960"; + reg-names = "core_physical"; + reg = <0x04a00000 0x2f0>; + interrupts = <0 79 0>; + clock-names = + "core", + "master_iface", + "slave_iface"; + clocks = + <&clk 61>, + <&clk 72>, + <&clk 98>; + qcom,hdmi-tx-ddc-clk-gpios = <&msmgpio 70 0>; + qcom,hdmi-tx-ddc-data-gpios = <&msmgpio 71 0>; + hpd-gpios = <&msmgpio 72 0>; + core-vdda-supply = <&pm8921_hdmi_mvs>; + hdmi-mux-supply = <&ext_3p3v>; + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&hpd_active &ddc_active &cec_active>; + pinctrl-1 = <&hpd_suspend &ddc_suspend &cec_suspend>; + + phys = <&hdmi_phy>; + phy-names = "hdmi_phy"; + }; + - | + #include + #include + #include + #include + hdmi-tx@9a0000 { + compatible = "qcom,hdmi-tx-8996"; + reg = <0x009a0000 0x50c>, + <0x00070000 0x6158>, + <0x009e0000 0xfff>; + reg-names = "core_physical", + "qfprom_physical", + "hdcp_physical"; + + interrupt-parent = <&mdss>; + interrupts = <8 IRQ_TYPE_LEVEL_HIGH>; + + clocks = <&mmcc MDSS_MDP_CLK>, + <&mmcc MDSS_AHB_CLK>, + <&mmcc MDSS_HDMI_CLK>, + <&mmcc MDSS_HDMI_AHB_CLK>, + <&mmcc MDSS_EXTPCLK_CLK>; + clock-names = "mdp_core", + "iface", + "core", + "alt_iface", + "extp"; + + phys = <&hdmi_phy>; + phy-names = "hdmi_phy"; + #sound-dai-cells = <1>; + + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&hdmi_hpd_active &hdmi_ddc_active>; + pinctrl-1 = <&hdmi_hpd_suspend &hdmi_ddc_suspend>; + + core-vdda-supply = <&vreg_l12a_1p8>; + core-vcc-supply = <&vreg_s4a_1p8>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + endpoint { + remote-endpoint = <&mdp5_intf3_out>; + }; + }; + }; + }; +... diff --git a/Documentation/devicetree/bindings/phy/qcom,hdmi-phy-other.yaml b/Documentation/devicetree/bindings/phy/qcom,hdmi-phy-other.yaml new file mode 100644 index 000000000000..79193cf71828 --- /dev/null +++ b/Documentation/devicetree/bindings/phy/qcom,hdmi-phy-other.yaml @@ -0,0 +1,103 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- + +$id: "http://devicetree.org/schemas/phy/qcom,hdmi-phy-other.yaml#" +$schema: "http://devicetree.org/meta-schemas/core.yaml#" + +title: Qualcomm Adreno/Snapdragon HDMI phy + +maintainers: + - Rob Clark + +properties: + compatible: + contains: + enum: + - qcom,hdmi-phy-8660 + - qcom,hdmi-phy-8960 + - qcom,hdmi-phy-8974 + - qcom,hdmi-phy-8084 + + reg: + minItems: 2 + maxItems: 2 + + reg-names: + items: + - const: hdmi_phy + - const: hdmi_pll + + clocks: + minItems: 1 + maxItems: 2 + + clock-names: + minItems: 1 + maxItems: 2 + + power-domains: + maxItems: 1 + + '#phy-cells': + const: 0 + +allOf: + - if: + properties: + compatible: + contains: + enum: + - qcom,hdmi-phy-8960 + then: + properties: + clocks: + maxItems: 1 + clock-names: + items: + - const: slave_iface + core-vdda-supply: + description: phandle to VDDA supply regulator + + - if: + properties: + compatible: + contains: + enum: + - qcom,hdmi-phy-8974 + then: + properties: + clocks: + maxItems: 2 + clock-names: + items: + - const: iface + - const: alt_iface + core-vdda-supply: + description: phandle to VDDA supply regulator + vddio-supply: + description: phandle to VDD I/O supply regulator + +required: + - compatible + - clocks + - reg + - reg-names + - '#phy-cells' + +unevaluatedProperties: false + +examples: + - | + hdmi_phy: phy@4a00400 { + compatible = "qcom,hdmi-phy-8960"; + reg-names = "hdmi_phy", + "hdmi_pll"; + reg = <0x4a00400 0x60>, + <0x4a00500 0x100>; + #phy-cells = <0>; + power-domains = <&mmcc 1>; + clock-names = "slave_iface"; + clocks = <&clk 21>; + core-vdda-supply = <&pm8921_hdmi_mvs>; + }; diff --git a/Documentation/devicetree/bindings/phy/qcom,hdmi-phy-qmp.yaml b/Documentation/devicetree/bindings/phy/qcom,hdmi-phy-qmp.yaml new file mode 100644 index 000000000000..2b36a4c3d4c3 --- /dev/null +++ b/Documentation/devicetree/bindings/phy/qcom,hdmi-phy-qmp.yaml @@ -0,0 +1,84 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- + +$id: "http://devicetree.org/schemas/phy/qcom,hdmi-phy-qmp.yaml#" +$schema: "http://devicetree.org/meta-schemas/core.yaml#" + +title: Qualcomm Adreno/Snapdragon QMP HDMI phy + +maintainers: + - Rob Clark + +properties: + compatible: + contains: + enum: + - qcom,hdmi-phy-8996 + + reg: + maxItems: 6 + + reg-names: + items: + - const: hdmi_pll + - const: hdmi_tx_l0 + - const: hdmi_tx_l1 + - const: hdmi_tx_l2 + - const: hdmi_tx_l3 + - const: hdmi_phy + + clocks: + maxItems: 2 + + clock-names: + items: + - const: iface + - const: ref + + power-domains: + maxItems: 1 + + vcca-supply: true + + vddio-supply: true + + '#phy-cells': + const: 0 + +required: + - compatible + - clocks + - clock-names + - reg + - reg-names + - '#phy-cells' + +unevaluatedProperties: false + +examples: + - | + hdmi-phy@9a0600 { + compatible = "qcom,hdmi-phy-8996"; + reg = <0x009a0600 0x1c4>, + <0x009a0a00 0x124>, + <0x009a0c00 0x124>, + <0x009a0e00 0x124>, + <0x009a1000 0x124>, + <0x009a1200 0x0c8>; + reg-names = "hdmi_pll", + "hdmi_tx_l0", + "hdmi_tx_l1", + "hdmi_tx_l2", + "hdmi_tx_l3", + "hdmi_phy"; + + clocks = <&mmcc 116>, + <&gcc 214>; + clock-names = "iface", + "ref"; + #phy-cells = <0>; + + vddio-supply = <&vreg_l12a_1p8>; + vcca-supply = <&vreg_l28a_0p925>; + }; From patchwork Tue Jun 7 18:58:01 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12872245 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9F2CDCCA487 for ; Tue, 7 Jun 2022 18:58:20 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 583C710EF0D; Tue, 7 Jun 2022 18:58:13 +0000 (UTC) Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by gabe.freedesktop.org (Postfix) with ESMTPS id 85C6810EF32 for ; Tue, 7 Jun 2022 18:58:11 +0000 (UTC) Received: by mail-lf1-x12f.google.com with SMTP id c2so10309056lfk.0 for ; Tue, 07 Jun 2022 11:58:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=aGzqYEGQn+If9ubvMiuRbk2B+EdJKY+QHOiiUFFUgLA=; b=Sj2qVill9L+8Omi1aXH+ITfabJemTKGx5YdS65gfo5MKRt51SxHahuPZdrVhAwkqWi 6GKL8CY71YignAnsb7FS5qEuahe4EHe2lDKvSxCklkwaVDn54B0+wwMWOWzCWr5ehS8g wQGVjfEIc1i2TdNEZUwLSaLPDCiWtcZvnKr+urn/LGuirb3I4yYJPQSCq/lcaeGOJ5NK e8IbYxw2bZ7pzXXFGmnBOdaxAvL5YHPS+QM8Fx3iWbkDbaeXuagC9CQ4i5vSQ1GWaY0b O8yGgBqnp5VzG7pMTLEZh0E9dU1V+Iq3LNEYIq6hWRP3kuLZB8Dnc6Zf0B3H2V6fkfiD Wqow== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=aGzqYEGQn+If9ubvMiuRbk2B+EdJKY+QHOiiUFFUgLA=; b=VqCZUOpZqqPDvtOU8+/8W4y/RtT9fyVqmB1Fj+8nkQfCYMwNaZ1r17rWz5gmlt5ojU 0CmYvJhAw1hBD0dIYtiXpO6qb8lRlP+ocQfK5HgJWcDR1XHgHrK746f1jZZf/wJ/yu53 ST+Xw3iTmsdz3huAPrS72EB/m6ASD3SHlw64vqYsGmrCnKCefJJr5g0hPHTsZ2dpu30I ASuFSi5wijYjaOnMEL+2jjOEs8EC3NU1OqIKRqcX0lqN409M+JYoGP2IX2kQeCNllVIy wd2BvUlPntMmaiLTAtZTYx6SL9bYGkTvxnLSiu4bNrado511xmzBbIshudfmNigFWHlD KDew== X-Gm-Message-State: AOAM530IOWmrEtG72uc1zT6+ErCbnKh+wZrPLBMBBiFV9GfCJrw/HSU3 DVI6iAX20whxF5wssMYAyF1D4w== X-Google-Smtp-Source: ABdhPJzEpQjDU9eJCieoZIm+7e2VEurWFXSje1/LOnq676gG9dGxHWnm+QON/hUbK3UpJK4BXh8MKA== X-Received: by 2002:a05:6512:22c1:b0:479:54b6:8281 with SMTP id g1-20020a05651222c100b0047954b68281mr5727582lfu.291.1654628289821; Tue, 07 Jun 2022 11:58:09 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id d19-20020a2eb053000000b0025587b872cesm1611668ljl.70.2022.06.07.11.58.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 11:58:08 -0700 (PDT) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Rob Herring , Krzysztof Kozlowski Subject: [PATCH v1 2/7] dt-bindings: display/msm: hdmi: mark old GPIO properties as deprecated Date: Tue, 7 Jun 2022 21:58:01 +0300 Message-Id: <20220607185806.2771739-3-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> References: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , David Heidelberg , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Mark obsolete GPIO properties as deprecated. They are not used by existing device trees. While we are at it, also drop them from the schema example. Signed-off-by: Dmitry Baryshkov --- .../devicetree/bindings/display/msm/qcom,hdmi.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml b/Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml index 2f485b5d1c5d..2b1cac0851ce 100644 --- a/Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml +++ b/Documentation/devicetree/bindings/display/msm/qcom,hdmi.yaml @@ -59,22 +59,27 @@ properties: qcom,hdmi-tx-ddc-clk-gpios: maxItems: 1 + deprecated: true description: HDMI DDC clock qcom,hdmi-tx-ddc-data-gpios: maxItems: 1 + deprecated: true description: HDMI DDC data qcom,hdmi-tx-mux-en-gpios: maxItems: 1 + deprecated: true description: HDMI mux enable pin qcom,hdmi-tx-mux-sel-gpios: maxItems: 1 + deprecated: true description: HDMI mux select pin qcom,hdmi-tx-mux-lpm-gpios: maxItems: 1 + deprecated: true description: HDMI mux lpm pin '#sound-dai-cells': @@ -171,8 +176,6 @@ examples: <&clk 61>, <&clk 72>, <&clk 98>; - qcom,hdmi-tx-ddc-clk-gpios = <&msmgpio 70 0>; - qcom,hdmi-tx-ddc-data-gpios = <&msmgpio 71 0>; hpd-gpios = <&msmgpio 72 0>; core-vdda-supply = <&pm8921_hdmi_mvs>; hdmi-mux-supply = <&ext_3p3v>; From patchwork Tue Jun 7 18:58:02 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12872247 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A0370CCA48D for ; Tue, 7 Jun 2022 18:58:25 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3C8E910F032; Tue, 7 Jun 2022 18:58:15 +0000 (UTC) Received: from mail-lf1-x12b.google.com (mail-lf1-x12b.google.com [IPv6:2a00:1450:4864:20::12b]) by gabe.freedesktop.org (Postfix) with ESMTPS id ED80210F023 for ; Tue, 7 Jun 2022 18:58:12 +0000 (UTC) Received: by mail-lf1-x12b.google.com with SMTP id j10so29707044lfe.12 for ; Tue, 07 Jun 2022 11:58:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZRvqaLg9Fcf4jlsPh9c6YwzET9xrw630tpzPuxWOrO4=; b=CeOYMPInmK/MmilRJiTU8MA381dXLGAAZ6ucBnfn5n4+9ckYsuXXcpxsMToMGTXDL5 Y3Z1W/c7mRIEcX797rMBpcYx/Acwhu1RweB+xKOdZVdXI6Jdox8ayDjoug5Po++B7Ofd SYwU1F8dNkOmw9QGiUmIhNxEPvxpj5Ehx3EFd3Po1IL5TSZxt0JrCKmhUCSBVlGJ7HR4 O8lbKAZj77Nk1BTEAYfZtcs6NGiICEpqBWaQ8rfF4doHZGgaElUBWyam16qdCRk9FGXI 9NCU65BXNUFk8zEL1CWAUlHhnKTSs8pBaVH3uVi3JLssvBXXcixtBZIk4fcsBhfjW1eR MCMA== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZRvqaLg9Fcf4jlsPh9c6YwzET9xrw630tpzPuxWOrO4=; b=tCjKUzyonPVnRjNjNaid00dmiczG8tBe2yCEp9ADUFHbSKco5oEH2Ox+JFIDz7V6tj FLRDQcCnkT+/rhTrHoLwFuUhZAyBRUp60NLkP943on66BBtRqyQfqNBY7Q6J0zjYtBop ew3foPtcIP6o6ZWVEorSdIzHXyxYJuwnujoEX7ovOfaH+ZDh4IMr8Vb/0KlnTtW9jOGx Dy0/dqEamoeYMq7FZX/6JQJCrap8O4OYfb8z4EwyoLswov/HayqbAiZO1LJpXktK83OZ Z0uQ39sPpBMqNNZz2IOuJkc4H4Xfs1u1MWDCBVzoXSX+2ix2hIWJDmrNPKu90PiBE8ZI 7QJg== X-Gm-Message-State: AOAM5323cC0Zpscfa/lSu1QLEdrATcjokB9ykOiPyzXcocciLiPt6gko 4BAU2GqA/y+pdmC72ZTP+ZY2GSIGQk/KjTINJWlBEA== X-Google-Smtp-Source: ABdhPJx4ZMil7KcF9WHeSOD7rwGeH9GMRYuU6TJA6G4D+9mryjqrkeAibiz1fIlGt4x0HF4D/rI7bw== X-Received: by 2002:ac2:47f1:0:b0:479:7517:d41 with SMTP id b17-20020ac247f1000000b0047975170d41mr1440176lfp.254.1654628291221; Tue, 07 Jun 2022 11:58:11 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id d19-20020a2eb053000000b0025587b872cesm1611668ljl.70.2022.06.07.11.58.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 11:58:10 -0700 (PDT) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Rob Herring , Krzysztof Kozlowski Subject: [PATCH v1 3/7] drm/msm/hdmi: drop unused GPIO support Date: Tue, 7 Jun 2022 21:58:02 +0300 Message-Id: <20220607185806.2771739-4-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> References: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , David Heidelberg , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The HDMI driver has code to configure extra GPIOs, which predates pinctrl support. Nowadays all platforms should use pinctrl instead. Neither of upstreamed Qualcomm pltforms uses these properties, so it's safe to drop them. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/hdmi/hdmi.c | 61 +++++----------------------- drivers/gpu/drm/msm/hdmi/hdmi.h | 13 +----- drivers/gpu/drm/msm/hdmi/hdmi_hpd.c | 62 ++--------------------------- 3 files changed, 17 insertions(+), 119 deletions(-) diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c index cf24e68864ba..6a22d6977ead 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi.c @@ -406,20 +406,6 @@ static struct hdmi_platform_config hdmi_tx_8996_config = { .hpd_freq = hpd_clk_freq_8x74, }; -static const struct { - const char *name; - const bool output; - const int value; - const char *label; -} msm_hdmi_gpio_pdata[] = { - { "qcom,hdmi-tx-ddc-clk", true, 1, "HDMI_DDC_CLK" }, - { "qcom,hdmi-tx-ddc-data", true, 1, "HDMI_DDC_DATA" }, - { "qcom,hdmi-tx-hpd", false, 1, "HDMI_HPD" }, - { "qcom,hdmi-tx-mux-en", true, 1, "HDMI_MUX_EN" }, - { "qcom,hdmi-tx-mux-sel", true, 0, "HDMI_MUX_SEL" }, - { "qcom,hdmi-tx-mux-lpm", true, 1, "HDMI_MUX_LPM" }, -}; - /* * HDMI audio codec callbacks */ @@ -531,7 +517,7 @@ static int msm_hdmi_bind(struct device *dev, struct device *master, void *data) struct hdmi_platform_config *hdmi_cfg; struct hdmi *hdmi; struct device_node *of_node = dev->of_node; - int i, err; + int err; hdmi_cfg = (struct hdmi_platform_config *) of_device_get_match_data(dev); @@ -543,41 +529,16 @@ static int msm_hdmi_bind(struct device *dev, struct device *master, void *data) hdmi_cfg->mmio_name = "core_physical"; hdmi_cfg->qfprom_mmio_name = "qfprom_physical"; - for (i = 0; i < HDMI_MAX_NUM_GPIO; i++) { - const char *name = msm_hdmi_gpio_pdata[i].name; - struct gpio_desc *gpiod; - - /* - * We are fetching the GPIO lines "as is" since the connector - * code is enabling and disabling the lines. Until that point - * the power-on default value will be kept. - */ - gpiod = devm_gpiod_get_optional(dev, name, GPIOD_ASIS); - /* This will catch e.g. -PROBE_DEFER */ - if (IS_ERR(gpiod)) - return PTR_ERR(gpiod); - if (!gpiod) { - /* Try a second time, stripping down the name */ - char name3[32]; - - /* - * Try again after stripping out the "qcom,hdmi-tx" - * prefix. This is mainly to match "hpd-gpios" used - * in the upstream bindings. - */ - if (sscanf(name, "qcom,hdmi-tx-%s", name3)) - gpiod = devm_gpiod_get_optional(dev, name3, GPIOD_ASIS); - if (IS_ERR(gpiod)) - return PTR_ERR(gpiod); - if (!gpiod) - DBG("failed to get gpio: %s", name); - } - hdmi_cfg->gpios[i].gpiod = gpiod; - if (gpiod) - gpiod_set_consumer_name(gpiod, msm_hdmi_gpio_pdata[i].label); - hdmi_cfg->gpios[i].output = msm_hdmi_gpio_pdata[i].output; - hdmi_cfg->gpios[i].value = msm_hdmi_gpio_pdata[i].value; - } + hdmi->hpd_gpiod = devm_gpiod_get_optional(dev, "hpd", GPIOD_IN); + /* This will catch e.g. -PROBE_DEFER */ + if (IS_ERR(hdmi->hpd_gpiod)) + return PTR_ERR(hdmi->hpd_gpiod); + + if (!hdmi->hpd_gpiod) + DBG("failed to get HPD gpio"); + + if (hdmi->hpd_gpiod) + gpiod_set_consumer_name(hdmi->hpd_gpiod, "HDMI_HPD"); dev->platform_data = hdmi_cfg; diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.h b/drivers/gpu/drm/msm/hdmi/hdmi.h index 736f348befb3..a6c88d157bc3 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi.h +++ b/drivers/gpu/drm/msm/hdmi/hdmi.h @@ -19,17 +19,9 @@ #include "msm_drv.h" #include "hdmi.xml.h" -#define HDMI_MAX_NUM_GPIO 6 - struct hdmi_phy; struct hdmi_platform_config; -struct hdmi_gpio_data { - struct gpio_desc *gpiod; - bool output; - int value; -}; - struct hdmi_audio { bool enabled; struct hdmi_audio_infoframe infoframe; @@ -61,6 +53,8 @@ struct hdmi { struct clk **hpd_clks; struct clk **pwr_clks; + struct gpio_desc *hpd_gpiod; + struct hdmi_phy *phy; struct device *phy_dev; @@ -109,9 +103,6 @@ struct hdmi_platform_config { /* clks that need to be on for screen pwr (ie pixel clk): */ const char **pwr_clk_names; int pwr_clk_cnt; - - /* gpio's: */ - struct hdmi_gpio_data gpios[HDMI_MAX_NUM_GPIO]; }; struct hdmi_bridge { diff --git a/drivers/gpu/drm/msm/hdmi/hdmi_hpd.c b/drivers/gpu/drm/msm/hdmi/hdmi_hpd.c index 75605ddac7c4..bfa827b47989 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi_hpd.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi_hpd.c @@ -60,48 +60,6 @@ static void msm_hdmi_phy_reset(struct hdmi *hdmi) } } -static int gpio_config(struct hdmi *hdmi, bool on) -{ - const struct hdmi_platform_config *config = hdmi->config; - int i; - - if (on) { - for (i = 0; i < HDMI_MAX_NUM_GPIO; i++) { - struct hdmi_gpio_data gpio = config->gpios[i]; - - if (gpio.gpiod) { - if (gpio.output) { - gpiod_direction_output(gpio.gpiod, - gpio.value); - } else { - gpiod_direction_input(gpio.gpiod); - gpiod_set_value_cansleep(gpio.gpiod, - gpio.value); - } - } - } - - DBG("gpio on"); - } else { - for (i = 0; i < HDMI_MAX_NUM_GPIO; i++) { - struct hdmi_gpio_data gpio = config->gpios[i]; - - if (!gpio.gpiod) - continue; - - if (gpio.output) { - int value = gpio.value ? 0 : 1; - - gpiod_set_value_cansleep(gpio.gpiod, value); - } - } - - DBG("gpio off"); - } - - return 0; -} - static void enable_hpd_clocks(struct hdmi *hdmi, bool enable) { const struct hdmi_platform_config *config = hdmi->config; @@ -154,11 +112,8 @@ int msm_hdmi_hpd_enable(struct drm_bridge *bridge) goto fail; } - ret = gpio_config(hdmi, true); - if (ret) { - DRM_DEV_ERROR(dev, "failed to configure GPIOs: %d\n", ret); - goto fail; - } + if (hdmi->hpd_gpiod) + gpiod_set_value_cansleep(hdmi->hpd_gpiod, 1); pm_runtime_get_sync(dev); enable_hpd_clocks(hdmi, true); @@ -207,10 +162,6 @@ void msm_hdmi_hpd_disable(struct hdmi_bridge *hdmi_bridge) enable_hpd_clocks(hdmi, false); pm_runtime_put(dev); - ret = gpio_config(hdmi, false); - if (ret) - dev_warn(dev, "failed to unconfigure GPIOs: %d\n", ret); - ret = pinctrl_pm_select_sleep_state(dev); if (ret) dev_warn(dev, "pinctrl state chg failed: %d\n", ret); @@ -269,10 +220,7 @@ static enum drm_connector_status detect_reg(struct hdmi *hdmi) #define HPD_GPIO_INDEX 2 static enum drm_connector_status detect_gpio(struct hdmi *hdmi) { - const struct hdmi_platform_config *config = hdmi->config; - struct hdmi_gpio_data hpd_gpio = config->gpios[HPD_GPIO_INDEX]; - - return gpiod_get_value(hpd_gpio.gpiod) ? + return gpiod_get_value(hdmi->hpd_gpiod) ? connector_status_connected : connector_status_disconnected; } @@ -282,8 +230,6 @@ enum drm_connector_status msm_hdmi_bridge_detect( { struct hdmi_bridge *hdmi_bridge = to_hdmi_bridge(bridge); struct hdmi *hdmi = hdmi_bridge->hdmi; - const struct hdmi_platform_config *config = hdmi->config; - struct hdmi_gpio_data hpd_gpio = config->gpios[HPD_GPIO_INDEX]; enum drm_connector_status stat_gpio, stat_reg; int retry = 20; @@ -291,7 +237,7 @@ enum drm_connector_status msm_hdmi_bridge_detect( * some platforms may not have hpd gpio. Rely only on the status * provided by REG_HDMI_HPD_INT_STATUS in this case. */ - if (!hpd_gpio.gpiod) + if (!hdmi->hpd_gpiod) return detect_reg(hdmi); do { From patchwork Tue Jun 7 18:58:03 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12872251 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CCCB5C43334 for ; Tue, 7 Jun 2022 18:58:29 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3A80610F0E6; Tue, 7 Jun 2022 18:58:16 +0000 (UTC) Received: from mail-lf1-x135.google.com (mail-lf1-x135.google.com [IPv6:2a00:1450:4864:20::135]) by gabe.freedesktop.org (Postfix) with ESMTPS id C2AB610F047 for ; Tue, 7 Jun 2022 18:58:13 +0000 (UTC) Received: by mail-lf1-x135.google.com with SMTP id i29so12971434lfp.3 for ; Tue, 07 Jun 2022 11:58:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=gv5EYCl70d4UF6tOM09XneWfVdh1zgj+7SojFdpo+zc=; b=yKYk7Q8nnTwrMBpssl31f24fbF3pY7T9HGazI+DZHx4+585LFDXw9KhEeNNkPD+4xB tkcxZR7H3H8k1VkN8nYcQbhSGRVYLr/bZVWR/NrzW6ZXGI5lclkDSYyT42AuJWhOIbHm TGv9L1GkLDIcDMW/ZO1e8o57aIM0kiQQsB71d6jKwWeAlYEu3oTbcDw3XvbchQGhD8Xr ioOxKKPM9dEsslR6d+uX4pPA1Mh4YIfFHSu87zrYrC3Qj1sv6Kw06qb+CQ9hyH8bDyBz vtf3cSc51zm7YVHQPipVkKeCZh2k9sPJMKB5D56ksbMmuUdNo1PH3clNIFhBlsKDC8Yk Vt1g== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=gv5EYCl70d4UF6tOM09XneWfVdh1zgj+7SojFdpo+zc=; b=gwGWWejVj8stSdWKMCTpluiCEygUcT4ldPANBmvUaaFD+BPhWIWJk9Vk+IoaHD3oR5 Vr5uzJmNw+a2ZRs5wHR6hhJrlWylNI8iUhwEy0BCpJ2O7gdTKXs8k07Td8IX/Nc7WIem 4aMng51ov9t15Kb43ktkjrbb4AeK1AuRgsQDABXOOMs7dZue+2i0cwB1DJEO8S6mjPBI UltKxomqAikWp3v9CmVxNU+J33pxDdleup4Tj8ytaCpJoz86mmPCH0K/Hi52Cj42AY04 WIj2Hn2dFiQBzkUK9NWLEvkHiZmx09mk+OyE0rut5/J2+4Gihn1/pbcIU8WAsYgKfy4B 3nHA== X-Gm-Message-State: AOAM530N35tEEJqaNiwWHsPgmMjr9VaHYieeFi2emjc5opxmGjrzfzLr K4fXp3Z7XVGECvkNOSaWe8FPqifJevqCMnG3kGw6nQ== X-Google-Smtp-Source: ABdhPJzAFNmVm1dYKasPIIqCWjqt4kOQVLQ3EaOAUgzny8Plt2Ngih2S2CB+D7ih2p2lMcN59i5vrA== X-Received: by 2002:a19:4302:0:b0:479:52ea:af4a with SMTP id q2-20020a194302000000b0047952eaaf4amr6247458lfa.454.1654628292088; Tue, 07 Jun 2022 11:58:12 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id d19-20020a2eb053000000b0025587b872cesm1611668ljl.70.2022.06.07.11.58.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 11:58:11 -0700 (PDT) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Rob Herring , Krzysztof Kozlowski Subject: [PATCH v1 4/7] drm/msm/hdmi: enable core-vcc/core-vdda-supply for 8996 platform Date: Tue, 7 Jun 2022 21:58:03 +0300 Message-Id: <20220607185806.2771739-5-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> References: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , David Heidelberg , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" DB820c makes use of core-vcc-supply and core-vdda-supply, however the driver code doesn't support these regulators. Enable them for HDMI on 8996 platform. Fixes: 0afbe59edd3f ("drm/msm/hdmi: Add basic HDMI support for msm8996") Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/hdmi/hdmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c index 6a22d6977ead..125712c3fca2 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi.c @@ -399,7 +399,7 @@ static struct hdmi_platform_config hdmi_tx_8994_config = { }; static struct hdmi_platform_config hdmi_tx_8996_config = { - HDMI_CFG(pwr_reg, none), + HDMI_CFG(pwr_reg, 8x74), HDMI_CFG(hpd_reg, none), HDMI_CFG(pwr_clk, 8x74), HDMI_CFG(hpd_clk, 8x74), From patchwork Tue Jun 7 18:58:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12872253 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C03D6CCA47C for ; Tue, 7 Jun 2022 18:58:33 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 65A0610F225; Tue, 7 Jun 2022 18:58:16 +0000 (UTC) Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by gabe.freedesktop.org (Postfix) with ESMTPS id EDF8D10EF7A for ; Tue, 7 Jun 2022 18:58:14 +0000 (UTC) Received: by mail-lf1-x132.google.com with SMTP id u23so29765127lfc.1 for ; Tue, 07 Jun 2022 11:58:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=fIR2tgZYRWBLnmVAd7m2XmX6eAHJSTYm0LMHENEbRWE=; b=Z9BNMiMWD8ai815uoPih/wJvYyzn8lNCz/NcNp/njpUTlCMhxuWY9AczbOdSGN2aET JdHaDCq29y99l4I4k0nFsgiZcDfJ0LJoIXHnzQ+innSecoOrJGy3ZXTcq2iHue0KdZOX IWWshIKaJzw5HM54uW72ChqJfg+E3Jjw5o2eQAXtQGG6qiOJiMTKtcKMnX25/OebaKA7 0vip1wJhXDEqFhPQ5gKJk8+wTZWro850lV3bg0Rs/gyKgjjF275lP+iWQaBYEOFQxP5v dIDlLBY08Lxt2qk793Sz739pxUbriQV2bVj+NYXz8W/kS/Jxba/xCv+yMdst320AU4m3 dE5A== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=fIR2tgZYRWBLnmVAd7m2XmX6eAHJSTYm0LMHENEbRWE=; b=TVas27jh3BaeXWUKI1VFVxpa5fzJOVipxriYHWWCJd1KZolQWrTVIDcfkksrqd8gcs nwHMajSmSO5O4HqQlQeGwtkv4Hn+ZqAVcMZQvkMXPSu0O8yj/RK4sGb9JgYnQjVt9fYQ 3z6h8fqndTht8R4txHzsXiIgZLwMtsc9tho/brqRc2znQt5gudGbAzZ5N7EELaaoY6cP dTsx9L3rtm6u5NW6D8LFlg7FYdXg+j/VR/tLPXpOPrWcKuKrixbyyqvRNbrJ0UliSFSi Qx0az8AJJ4xqqwV3X8ZPYpXrG8mt/cNaP3tSCcEZKIkqjr7EMTnPtVU+KPCHNyqSC0xP JJBQ== X-Gm-Message-State: AOAM533ELxeXW+ZWGrLd2zQnPq6nSEBdNMVvzj51yrXB8XAws3WyWIcK 7XFWLqhvziWzDvfAOTQi7iUBqA== X-Google-Smtp-Source: ABdhPJwu0bgwWIs2JvK72GIJagzrhqPdQjv0dGrZtc353kYRQPaEmFzS2q1TS6FRQpFMGlAYnMdMqg== X-Received: by 2002:a05:6512:3401:b0:479:4000:fbe1 with SMTP id i1-20020a056512340100b004794000fbe1mr8543546lfr.228.1654628293281; Tue, 07 Jun 2022 11:58:13 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id d19-20020a2eb053000000b0025587b872cesm1611668ljl.70.2022.06.07.11.58.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 11:58:12 -0700 (PDT) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Rob Herring , Krzysztof Kozlowski Subject: [PATCH v1 5/7] drm/msm/hdmi: drop empty 'none' regulator lists Date: Tue, 7 Jun 2022 21:58:04 +0300 Message-Id: <20220607185806.2771739-6-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> References: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , David Heidelberg , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Several platform configs use empty 'none' regulator arrays. They are not necessary, as the code will use corresponding _cnt field and skip the array completely. Drop them now. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/hdmi/hdmi.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c index 125712c3fca2..c87a0386647f 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi.c @@ -353,9 +353,6 @@ int msm_hdmi_modeset_init(struct hdmi *hdmi, .item ## _names = item ##_names_ ## entry, \ .item ## _cnt = ARRAY_SIZE(item ## _names_ ## entry) -static const char *pwr_reg_names_none[] = {}; -static const char *hpd_reg_names_none[] = {}; - static struct hdmi_platform_config hdmi_tx_8660_config; static const char *hpd_reg_names_8960[] = {"core-vdda", "hdmi-mux"}; @@ -392,7 +389,6 @@ static struct hdmi_platform_config hdmi_tx_8084_config = { static struct hdmi_platform_config hdmi_tx_8994_config = { HDMI_CFG(pwr_reg, 8x74), - HDMI_CFG(hpd_reg, none), HDMI_CFG(pwr_clk, 8x74), HDMI_CFG(hpd_clk, 8x74), .hpd_freq = hpd_clk_freq_8x74, @@ -400,7 +396,6 @@ static struct hdmi_platform_config hdmi_tx_8994_config = { static struct hdmi_platform_config hdmi_tx_8996_config = { HDMI_CFG(pwr_reg, 8x74), - HDMI_CFG(hpd_reg, none), HDMI_CFG(pwr_clk, 8x74), HDMI_CFG(hpd_clk, 8x74), .hpd_freq = hpd_clk_freq_8x74, From patchwork Tue Jun 7 18:58:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12872255 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C7B96C433EF for ; Tue, 7 Jun 2022 18:58:38 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 9438F10F08F; Tue, 7 Jun 2022 18:58:24 +0000 (UTC) Received: from mail-lf1-x135.google.com (mail-lf1-x135.google.com [IPv6:2a00:1450:4864:20::135]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3705E10F0B1 for ; Tue, 7 Jun 2022 18:58:16 +0000 (UTC) Received: by mail-lf1-x135.google.com with SMTP id a2so23606465lfg.5 for ; Tue, 07 Jun 2022 11:58:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=O2qnycNDjzB4dFQbZvnsZ97Ybjd2s1ka1P5LN2rGpnU=; b=fY4eVUItigtJgeHvg3VY5lGy/icGDdNLR2Uii/vrXdboDbdcDAKK88eJdn2gr+LaqJ ogln0wHjW1rbVyh+N+RQPlnoDEDVKirAriNiC4Jkt/oieE7BgNg4OBF+BsCaGdjIH71K 2jd23jlGPMOaHLYje1sSuwHIQ9QgPP+FNuZJFc44Qg37Q9ImWlrhW9kSBSk0jNvWrywg vPGfXG5VGQhHxm9sjcYpiPS6XPeFrhTOncC914wxcXQL1f8BxY7wlCTHjCBY5t9OqS1X ILeYPxGqOP1JERYYbVI+TsWLISpXrTq9nT85aYuHIKUKqoLvcbbpZVWjpuKxay+nFhAB FzrQ== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=O2qnycNDjzB4dFQbZvnsZ97Ybjd2s1ka1P5LN2rGpnU=; b=z0cUI6J9j6nwWtyzv5Vw85r5gpeF3Vrk2Z950QWHiwBbgJMHwhi0z7CZ3Kb6neVUiU gLnHTS10yO/42HMcixeB3lI/l1HGDFONvQ84yZV+O3Gc7pK8JpdBOm6qXeoj5q0jnBrB f4jPkS4FXbYgTiM0l0oQeH5XZKAnJkAp+Wvpfa3Mq7niuOVbWgc6nC1P1tVC7z3e9jpa 34hMXViGI4ZXFOFtowHJ00o18wBEecgeZlszLXmIFmY04v/s4ocqL0Vp8NQ+m6ihv3uf +mIxJ8HRo1hkz3Id7x0eiT1xh+vDK86O0GVHZw+kFYsakozOcwxixQ/IuFcL/zY2a7kL WBBw== X-Gm-Message-State: AOAM532wPu9UklhSy4jAqEXoMjCgsjihsbvhfX5ddRhYZe8Uzg+tnDb9 fu6PuiPir+xrPSrMo5ftIQO/ZA== X-Google-Smtp-Source: ABdhPJw/wSeZ9pSV5Cvm8QerCzYILQ0LyHXjlHxADb8Lhw3dxneUxf67wqRAasEeFvmt1KMzvY0/Bg== X-Received: by 2002:ac2:4e0b:0:b0:478:6b05:7038 with SMTP id e11-20020ac24e0b000000b004786b057038mr19465595lfr.13.1654628294542; Tue, 07 Jun 2022 11:58:14 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id d19-20020a2eb053000000b0025587b872cesm1611668ljl.70.2022.06.07.11.58.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 11:58:13 -0700 (PDT) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Rob Herring , Krzysztof Kozlowski Subject: [PATCH v1 6/7] drm/msm/hdmi: drop hpd_regs usage on 8x74/8084 Date: Tue, 7 Jun 2022 21:58:05 +0300 Message-Id: <20220607185806.2771739-7-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> References: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , David Heidelberg , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The MSM HDMI driver has support for hpd_regs on 8x74/8084: supply regulators that are to be enabled for HPD to work. Currently these regulators contain the hpd_gdsc, which was replaced by the power-domains support and hpd-5v/hpd-5v-en, which are not used by the chip itself. They power up the ESD bridge. However it is a separate device which should be represented separately in the device tree. None of upstreamed devices support these properties. Thus drop support for them from the HDMI driver. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/hdmi/hdmi.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c index c87a0386647f..03d8f97b0cd8 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi.c @@ -364,24 +364,19 @@ static struct hdmi_platform_config hdmi_tx_8960_config = { }; static const char *pwr_reg_names_8x74[] = {"core-vdda", "core-vcc"}; -static const char *hpd_reg_names_8x74[] = {"hpd-gdsc", "hpd-5v"}; static const char *pwr_clk_names_8x74[] = {"extp", "alt_iface"}; static const char *hpd_clk_names_8x74[] = {"iface", "core", "mdp_core"}; static unsigned long hpd_clk_freq_8x74[] = {0, 19200000, 0}; static struct hdmi_platform_config hdmi_tx_8974_config = { HDMI_CFG(pwr_reg, 8x74), - HDMI_CFG(hpd_reg, 8x74), HDMI_CFG(pwr_clk, 8x74), HDMI_CFG(hpd_clk, 8x74), .hpd_freq = hpd_clk_freq_8x74, }; -static const char *hpd_reg_names_8084[] = {"hpd-gdsc", "hpd-5v", "hpd-5v-en"}; - static struct hdmi_platform_config hdmi_tx_8084_config = { HDMI_CFG(pwr_reg, 8x74), - HDMI_CFG(hpd_reg, 8084), HDMI_CFG(pwr_clk, 8x74), HDMI_CFG(hpd_clk, 8x74), .hpd_freq = hpd_clk_freq_8x74, From patchwork Tue Jun 7 18:58:06 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12872256 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 245E8C43334 for ; Tue, 7 Jun 2022 18:58:41 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6F52A10F341; Tue, 7 Jun 2022 18:58:25 +0000 (UTC) Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by gabe.freedesktop.org (Postfix) with ESMTPS id E9EA910F047 for ; Tue, 7 Jun 2022 18:58:15 +0000 (UTC) Received: by mail-lf1-x12f.google.com with SMTP id c2so10309056lfk.0 for ; Tue, 07 Jun 2022 11:58:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=yBKwPOiE2yNJ0h72czELiOyk+g2uWrk6+KM2TvTz5JU=; b=Yks/q3su0YHCpP1GZiev8M6GFNTj/3QTyI/Ndrs53Y55o0csQ1hVU4LwAIIwQ1IUA8 +c8piT29CypwfC4legDBxZZwLyPxAueBvOI0cTL5z0ciBVniJGYgb5TnNRKbyMGfkFef XGmf76jAhEZHLHskC+nHi6zFOlIsr0+cUZ+SpDHRQYp5FIJSJ3wmAjATYAnfnzc9bqDX vWgAtgUYsKGJiCZg31C+DxRgkODuIMf5EC3TfuPT0UrLuxdnGO3oPuZb6oReRe0Yaw50 mvCNAEHspgbqg1KrOwxjqEXNCUI4/HaVIl0z0fPopLAIINbFd/2k15Q0nTo2443jmeyb IMog== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=yBKwPOiE2yNJ0h72czELiOyk+g2uWrk6+KM2TvTz5JU=; b=J+12C/4K1PNQ0ii1HZNz2i0C/eZl7K/E6fblIFY3d/s0alXS2bR3TuV5kn/qkURnPV K7CVVjwNDRF6qZJRjiCeudkDu/qQVAsIRoBHCIz7KC83aJrC6zF29fSUDAWtewQpLmXR lT9FRZ1eCci/XfNeXqLUh1qasgRqjDdJUz6YKIFmBrjQlLJ8oKKUdOqo5BeoRKd8q6by PdJso2DPUcw+nu9KLxRngnJgBv2cGmL3g6Hwt2pcQqs5Qs3poAAh9jIYA9gxV/FUyYGw WGnb14vuMM1X3x8aQtoZa68pRPeeOrAolVw4NHoUfg/2gR3q50w3aQEEQzsUM6qgGt/3 PQFw== X-Gm-Message-State: AOAM532GDnPSIr1S3X0hz8qqCQ3t8/Txf+OrdCOoSt5RstJEjwjg9oGv QQUq7IfJeVDSrxXhybOBidZ9qA== X-Google-Smtp-Source: ABdhPJy9e5t8nWUlQ5axbawTm+yy688KCIdLqxL6iY8tn6zylCOr28nbh97saNaGf6LTXBhAevBKLw== X-Received: by 2002:a19:4918:0:b0:478:7e82:86f1 with SMTP id w24-20020a194918000000b004787e8286f1mr54777219lfa.353.1654628295453; Tue, 07 Jun 2022 11:58:15 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id d19-20020a2eb053000000b0025587b872cesm1611668ljl.70.2022.06.07.11.58.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 11:58:15 -0700 (PDT) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Rob Herring , Krzysztof Kozlowski Subject: [PATCH v1 7/7] drm/msm/hdmi: merge platform config for 8974/8084/8994/8996 Date: Tue, 7 Jun 2022 21:58:06 +0300 Message-Id: <20220607185806.2771739-8-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> References: <20220607185806.2771739-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , David Heidelberg , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Since there is no more difference between the HDMI platform data between MSM8974/APQ8084/MSM8994/MSM8996, merge these configs into a single entry. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/hdmi/hdmi.c | 27 +++------------------------ 1 file changed, 3 insertions(+), 24 deletions(-) diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c index 03d8f97b0cd8..8ae60e97cc94 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi.c @@ -375,27 +375,6 @@ static struct hdmi_platform_config hdmi_tx_8974_config = { .hpd_freq = hpd_clk_freq_8x74, }; -static struct hdmi_platform_config hdmi_tx_8084_config = { - HDMI_CFG(pwr_reg, 8x74), - HDMI_CFG(pwr_clk, 8x74), - HDMI_CFG(hpd_clk, 8x74), - .hpd_freq = hpd_clk_freq_8x74, -}; - -static struct hdmi_platform_config hdmi_tx_8994_config = { - HDMI_CFG(pwr_reg, 8x74), - HDMI_CFG(pwr_clk, 8x74), - HDMI_CFG(hpd_clk, 8x74), - .hpd_freq = hpd_clk_freq_8x74, -}; - -static struct hdmi_platform_config hdmi_tx_8996_config = { - HDMI_CFG(pwr_reg, 8x74), - HDMI_CFG(pwr_clk, 8x74), - HDMI_CFG(hpd_clk, 8x74), - .hpd_freq = hpd_clk_freq_8x74, -}; - /* * HDMI audio codec callbacks */ @@ -577,9 +556,9 @@ static int msm_hdmi_dev_remove(struct platform_device *pdev) } static const struct of_device_id msm_hdmi_dt_match[] = { - { .compatible = "qcom,hdmi-tx-8996", .data = &hdmi_tx_8996_config }, - { .compatible = "qcom,hdmi-tx-8994", .data = &hdmi_tx_8994_config }, - { .compatible = "qcom,hdmi-tx-8084", .data = &hdmi_tx_8084_config }, + { .compatible = "qcom,hdmi-tx-8996", .data = &hdmi_tx_8974_config }, + { .compatible = "qcom,hdmi-tx-8994", .data = &hdmi_tx_8974_config }, + { .compatible = "qcom,hdmi-tx-8084", .data = &hdmi_tx_8974_config }, { .compatible = "qcom,hdmi-tx-8974", .data = &hdmi_tx_8974_config }, { .compatible = "qcom,hdmi-tx-8960", .data = &hdmi_tx_8960_config }, { .compatible = "qcom,hdmi-tx-8660", .data = &hdmi_tx_8660_config },