From patchwork Mon Nov 6 08:39:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 13446478 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 CB034C0018A for ; Mon, 6 Nov 2023 08:39:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231377AbjKFIjg (ORCPT ); Mon, 6 Nov 2023 03:39:36 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37236 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231295AbjKFIjb (ORCPT ); Mon, 6 Nov 2023 03:39:31 -0500 Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 68C9CD4C for ; Mon, 6 Nov 2023 00:39:26 -0800 (PST) Received: by mail-wr1-x429.google.com with SMTP id ffacd0b85a97d-32da7ac5c4fso2577960f8f.1 for ; Mon, 06 Nov 2023 00:39:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1699259965; x=1699864765; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=kjOsFDQztBv7JBssd9VOLzlAJ44GvB+yTBqZW4SMwig=; b=FpVaYm8Yh4h89kl+3VTlBmqB7Cmdw0sJp8eYujHL4AtcwNmPOcBuJ7kgkFW7M7BcnZ vSQjiaYLnsXdTc3QAFuoy8RIAioeLQsFZXG1twmDDkTNwobHAj2uyqTltfd03T5SSKkc CZVKVmVTNSAuMGnwMbb5e5MvQmvckcNlCLJotgHALxyUkHLqtvQYGyl0xmmzlmHEa7U0 uPZxOM2vw7Fk1JjEVeDTe9JPmk/xXNKqlYg/A8kL/j7M0Et740FnleGz0um0gbumEvtH 5ugkePI9KmJPraw37Jj1zjOzh9YNRaCqR8Qw3i9jZQG0RTQ7w/otLffSG/28+ycXB+UD fNdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699259965; x=1699864765; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=kjOsFDQztBv7JBssd9VOLzlAJ44GvB+yTBqZW4SMwig=; b=Bo5cPOxwxIRrBBb4NQplyuWyuEAAYEkiUO5tHJVoWBIxacRpfMVdhzikjygqmVwh7N swqlSvpZW2K8muLe2fyBR66J/c2jy+OBDsX2/CGBcUef+MC+3JrUL+pfN0CoSqZ1s86G K4MXl9UrXDYL5mLkWNGUvMyAJv2/y7JIh/iPxViiJbEITs+9b1DnYeGoB48L+qcsdV2n ZkRM+e2yl6EEdAKYMwzvgPWHHnk/1SaxVjFkijBCLadTQllL22HMG4Nx0k5JtA10/uDa Tw2mVKqAggA8t0+D8di498SOVKIbBtGh4pIjfDLm8JYz5tgV2GgynQ1OElOA2Xoz4RED Ee7w== X-Gm-Message-State: AOJu0YxJQ6EMdB5ysEidzwMRsYC6T5pBUQvRBbF3+52c4E3rTq1G0hNX rBS5r/iYuxRbdM+7ir6Ufc3FLw== X-Google-Smtp-Source: AGHT+IELVYmywMxm3rqhUiNyrkumOFtG2c8pRDLmgmoytBVHrCGXz5ADUvTeIZvaU5pZ1q6DxEFgKg== X-Received: by 2002:adf:ef02:0:b0:323:1887:dd6d with SMTP id e2-20020adfef02000000b003231887dd6dmr25263409wro.3.1699259964860; Mon, 06 Nov 2023 00:39:24 -0800 (PST) Received: from arrakeen.starnux.net ([2a01:e0a:982:cbb0:8261:5fff:fe11:bdda]) by smtp.gmail.com with ESMTPSA id t5-20020adfe445000000b00323293bd023sm8829830wrm.6.2023.11.06.00.39.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Nov 2023 00:39:24 -0800 (PST) From: Neil Armstrong Date: Mon, 06 Nov 2023 09:39:15 +0100 Subject: [PATCH v2 7/8] arm64: dts: qcom: sm8650-mtp: add interconnect dependent device nodes MIME-Version: 1.0 Message-Id: <20231106-topic-sm8650-upstream-dt-v2-7-44d6f9710fa7@linaro.org> References: <20231106-topic-sm8650-upstream-dt-v2-0-44d6f9710fa7@linaro.org> In-Reply-To: <20231106-topic-sm8650-upstream-dt-v2-0-44d6f9710fa7@linaro.org> To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Neil Armstrong X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=openpgp-sha256; l=6103; i=neil.armstrong@linaro.org; h=from:subject:message-id; bh=5+2nr7rIiZ5VAf0fMNPNaeNI5ob74n0b4wAX9QvoqWQ=; b=owEBbQKS/ZANAwAKAXfc29rIyEnRAcsmYgBlSKY0URC5yKB0fUK1tJKYDjZuar0az4pVWpPZGczn HyAy1cuJAjMEAAEKAB0WIQQ9U8YmyFYF/h30LIt33NvayMhJ0QUCZUimNAAKCRB33NvayMhJ0WXJD/ 9hNJAHIHZgnPv6IGg4AyCtNvfLCUG8m/4zvepB2j0hI9rcBykQ0TvfLwVaETHDB9qCzITpuyPJ7Hpe AO27ZOgONXA+Z0vgxeIJpUHkh/Sy2eTQf2C5UjDwU+/bzXUgpvBZU9Me97aV+wFcb7WqB0idp7cg/S iOOlat+epuNmXul3G170i49H7DSZNv01LI3SWc8VAYfQkllg860pLOrIoTJmn97kHuho2aAhuVaWbK x8pDtoiVHuxB5srtzaJjjGaOfE1PHw3O+qB48wqHECdDP0xBS5azBIUV6STqgzQ0pPX6mg52nVPeut DcLHRUKy5d5PhR1WrD54wGX9CmtzP9UfUk5h0lu8NEoHcHXE6coQpL7Tyl6CEp8nFmf/+B3aDJREhX JVzi1GOZ1ppPZLYh8uRWciQEA6ORVuZEyCTuQTrYLDdM887nTDpbwy7jvViAkWZFripRoBTB0sZgZL uAjfCy1kPU6+2/6eqnNkj0PBzp/6QPmYjL1XK9ImnIjWBTYAbL+8YNS8hf2eFhYycCuc0DIHD4uZib is7HLgUehjcPxjwqIXaxo9LUn6cT8bOCjafcKOXKmZu460h6K9fpeDK2hf/OXgO4589QxVN1+rhjTb Qx5jh/0uBHRkTcUtVRqCa3Kw/PWOrQbrF16HXgAeInbxi1mjSXQx0yjzGSEg== X-Developer-Key: i=neil.armstrong@linaro.org; a=openpgp; fpr=89EC3D058446217450F22848169AB7B1A4CFF8AE Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Now interconnect dependent devices are added in sm8650 DTSI, now enable more devices for the Qualcomm SM8650 MTP board: - PCIe - Display - DSPs - SDCard - UFS - USB role switch with PMIC Glink Signed-off-by: Neil Armstrong --- arch/arm64/boot/dts/qcom/sm8650-mtp.dts | 235 +++++++++++++++++++++++++++++++- 1 file changed, 234 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/sm8650-mtp.dts b/arch/arm64/boot/dts/qcom/sm8650-mtp.dts index 5738791fea2a..73c781089425 100644 --- a/arch/arm64/boot/dts/qcom/sm8650-mtp.dts +++ b/arch/arm64/boot/dts/qcom/sm8650-mtp.dts @@ -28,6 +28,44 @@ chosen { stdout-path = "serial0:115200n8"; }; + pmic-glink { + compatible = "qcom,sm8650-pmic-glink", + "qcom,sm8550-pmic-glink", + "qcom,pmic-glink"; + #address-cells = <1>; + #size-cells = <0>; + orientation-gpios = <&tlmm 29 GPIO_ACTIVE_HIGH>; + + connector@0 { + compatible = "usb-c-connector"; + reg = <0>; + + power-role = "dual"; + data-role = "dual"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + pmic_glink_hs_in: endpoint { + remote-endpoint = <&usb_1_dwc3_hs>; + }; + }; + + port@1 { + reg = <1>; + + pmic_glink_ss_in: endpoint { + remote-endpoint = <&usb_1_dwc3_ss>; + }; + }; + }; + }; + }; + vph_pwr: vph-pwr-regulator { compatible = "regulator-fixed"; @@ -77,6 +115,9 @@ vreg_l2b_3p0: ldo2 { regulator-min-microvolt = <3008000>; regulator-max-microvolt = <3008000>; regulator-initial-mode = ; + regulator-allow-set-load; + regulator-allowed-modes = ; }; vreg_l5b_3p1: ldo5 { @@ -389,6 +430,106 @@ vreg_l3i_1p2: ldo3 { }; }; +&dispcc { + status = "okay"; +}; + +&mdss { + status = "okay"; +}; + +&mdss_dsi0 { + vdda-supply = <&vreg_l3i_1p2>; + + status = "okay"; + + panel@0 { + compatible = "visionox,vtdr6130"; + reg = <0>; + + reset-gpios = <&tlmm 133 GPIO_ACTIVE_LOW>; + + vddio-supply = <&vreg_l12b_1p8>; + vci-supply = <&vreg_l13b_3p0>; + vdd-supply = <&vreg_l11b_1p2>; + + pinctrl-0 = <&sde_dsi_active>, <&sde_te_active>; + pinctrl-1 = <&sde_dsi_suspend>, <&sde_te_suspend>; + pinctrl-names = "default", "sleep"; + + port { + panel0_in: endpoint { + remote-endpoint = <&mdss_dsi0_out>; + }; + }; + }; +}; + +&mdss_dsi0_out { + remote-endpoint = <&panel0_in>; + data-lanes = <0 1 2 3>; +}; + +&mdss_dsi0_phy { + vdds-supply = <&vreg_l1i_0p88>; + + status = "okay"; +}; + +&mdss_mdp { + status = "okay"; +}; + +&pcie_1_phy_aux_clk { + clock-frequency = <1000>; +}; + +&pcie0 { + wake-gpios = <&tlmm 96 GPIO_ACTIVE_HIGH>; + perst-gpios = <&tlmm 94 GPIO_ACTIVE_LOW>; + + pinctrl-0 = <&pcie0_default_state>; + pinctrl-names = "default"; + + status = "okay"; +}; + +&pcie0_phy { + vdda-phy-supply = <&vreg_l1i_0p88>; + vdda-pll-supply = <&vreg_l3i_1p2>; + + status = "okay"; +}; + +&pcie1 { + wake-gpios = <&tlmm 99 GPIO_ACTIVE_HIGH>; + perst-gpios = <&tlmm 97 GPIO_ACTIVE_LOW>; + + pinctrl-0 = <&pcie1_default_state>; + pinctrl-names = "default"; + + status = "okay"; +}; + +&pcie1_phy { + vdda-phy-supply = <&vreg_l3e_0p9>; + vdda-pll-supply = <&vreg_l3i_1p2>; + vdda-qref-supply = <&vreg_l1i_0p88>; + + status = "okay"; +}; + +&pm8550_gpios { + sdc2_card_det_n: sdc2-card-det-state { + pins = "gpio12"; + function = "normal"; + bias-pull-up; + input-enable; + output-disable; + power-source = <1>; /* 1.8 V */ + }; +}; + &pm8550b_eusb2_repeater { vdd18-supply = <&vreg_l15b_1p8>; vdd3-supply = <&vreg_l5b_3p1>; @@ -398,18 +539,101 @@ &qupv3_id_1 { status = "okay"; }; +&remoteproc_adsp { + firmware-name = "qcom/sm8650/adsp.mbn", + "qcom/sm8650/adsp_dtb.mbn"; + + status = "okay"; +}; + +&remoteproc_cdsp { + firmware-name = "qcom/sm8650/cdsp.mbn", + "qcom/sm8650/cdsp_dtb.mbn"; + + status = "okay"; +}; + +&remoteproc_mpss { + firmware-name = "qcom/sm8650/modem.mbn", + "qcom/sm8650/modem_dtb.mbn"; + + status = "okay"; +}; + +&sdhc_2 { + cd-gpios = <&pm8550_gpios 12 GPIO_ACTIVE_LOW>; + + vmmc-supply = <&vreg_l9b_2p9>; + vqmmc-supply = <&vreg_l8b_1p8>; + bus-width = <4>; + no-sdio; + no-mmc; + + pinctrl-0 = <&sdc2_default>, <&sdc2_card_det_n>; + pinctrl-1 = <&sdc2_sleep>, <&sdc2_card_det_n>; + pinctrl-names = "default", "sleep"; + + status = "okay"; +}; + &sleep_clk { clock-frequency = <32000>; }; &tlmm { gpio-reserved-ranges = <32 8>; + + sde_dsi_active: sde-dsi-active-state { + pins = "gpio133"; + function = "gpio"; + drive-strength = <8>; + bias-disable; + }; + + sde_dsi_suspend: sde-dsi-suspend-state { + pins = "gpio133"; + function = "gpio"; + drive-strength = <2>; + bias-pull-down; + }; + + sde_te_active: sde-te-active-state { + pins = "gpio86"; + function = "mdp_vsync"; + drive-strength = <2>; + bias-pull-down; + }; + + sde_te_suspend: sde-te-suspend-state { + pins = "gpio86"; + function = "mdp_vsync"; + drive-strength = <2>; + bias-pull-down; + }; }; &uart15 { status = "okay"; }; +&ufs_mem_hc { + reset-gpios = <&tlmm 210 GPIO_ACTIVE_LOW>; + + vcc-supply = <&vreg_l17b_2p5>; + vcc-max-microamp = <1300000>; + vccq-supply = <&vreg_l1c_1p2>; + vccq-max-microamp = <1200000>; + + status = "okay"; +}; + +&ufs_mem_phy { + vdda-phy-supply = <&vreg_l1d_0p88>; + vdda-pll-supply = <&vreg_l3i_1p2>; + + status = "okay"; +}; + /* * DPAUX -> WCD9395 -> USB_SBU -> USB-C * eUSB2 DP/DM -> PM85550HS -> eUSB2 DP/DM -> USB-C @@ -421,7 +645,16 @@ &usb_1 { }; &usb_1_dwc3 { - dr_mode = "peripheral"; + dr_mode = "otg"; + usb-role-switch; +}; + +&usb_1_dwc3_hs { + remote-endpoint = <&pmic_glink_hs_in>; +}; + +&usb_1_dwc3_ss { + remote-endpoint = <&pmic_glink_ss_in>; }; &usb_1_hsphy {