From nobody Fri Dec 27 18:28:52 2024 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8150C19F104; Fri, 29 Nov 2024 17:20:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732900847; cv=none; b=BFK8ntXj7V5qwGi06Bu38Mrjy4zet1bWze5O9t5IaRVmIbNwNID74pvYV+b2x1JC+qq4mjKeDhtaol37A7a62qjpKLncvE4DPFbbhjW2u0EzKdofMXL0+OdTgv7abTZ6XS34+TLPejRswXA6L2oBQNmxoKpvdyr27esimHXBT9I= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732900847; c=relaxed/simple; bh=OK0b/iAk8XA2hHOO7hH1+0N8JU61opaxvC0xaGSjrhE=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=QeDYJ+qJMVy7AhdP869SMS4UYDWQ5by9OFtOjpwKmxugjcW9A2Skpzsb0n/3vZHZ9f23+QnVPBDOH2fTucDinrr0iGnB8AKwhkq9UR7diVgt3tisvl4fyeAVgPz2G11vB/oDCV0IbUChW9monV9BxEGSsMw3/vbp35+2pBJz16w= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=CfX6sX9K; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="CfX6sX9K" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7A481C4CED7; Fri, 29 Nov 2024 17:20:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1732900847; bh=OK0b/iAk8XA2hHOO7hH1+0N8JU61opaxvC0xaGSjrhE=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=CfX6sX9KUmWNjE+9aYcAgGeF5XgHxPYmZ36c+qbcnLtPmPbCuSZrKRS3QqUie8rU2 g1vzpO3nFJUHFU2CW2NhF0W8g3dACrXVoXZhjwdiRLZbW6EuQv4Z4GpakwUU7k4byE 1ZoGM8QZuMz7PoY7KL8HL1ASIyZ2UrK/FZaM7B2YaWyeude7G0d+F8o8DAIs6lX01L f1GZBh/IGeQnZE45UCrKfM0sW5MpxDVHYLXz8lKqS9szKwxD42MdQH03dcoDFPPtny 1daCa/WwiIqhADXBFvIhIMNfUe+mYKvSsXgcZzABkRqNUyCFj7c0pb3X1jnw5BPYdy Q338plipJ8v6w== From: Konrad Dybcio Date: Fri, 29 Nov 2024 18:20:27 +0100 Subject: [PATCH v2 3/3] arm64: dts: qcom: x1e80100-romulus: Set up PS8830s Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241129-topic-sl7_feat2-v2-3-fb6cf5660cfc@oss.qualcomm.com> References: <20241129-topic-sl7_feat2-v2-0-fb6cf5660cfc@oss.qualcomm.com> In-Reply-To: <20241129-topic-sl7_feat2-v2-0-fb6cf5660cfc@oss.qualcomm.com> To: Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio , Dmitry Baryshkov X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1732900833; l=8142; i=konrad.dybcio@oss.qualcomm.com; s=20230215; h=from:subject:message-id; bh=it7d7Q/VrGGxeDA7ZhRAC50l7vb8sbXeAKg9jGri0OE=; b=RFQAZyTOE6vp8YtVIuz/FjABgqX7kVLlkekXJEyGOBG+ug7qypctOAQY7VNOdZGVIp2f9Y1rF Mp8uSvTa6NGCdPz0RDQdFMl7+ONEKr77skMfSGoDjdPEDbZuoeauq7D X-Developer-Key: i=konrad.dybcio@oss.qualcomm.com; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= From: Konrad Dybcio The Laptop 7 features two USB-C ports, each one sporting a PS8830 USB-C retimer/mux. Wire them up. Reviewed-by: Dmitry Baryshkov Signed-off-by: Konrad Dybcio --- .../boot/dts/qcom/x1e80100-microsoft-romulus.dtsi | 282 +++++++++++++++++= +++- 1 file changed, 276 insertions(+), 6 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/x1e80100-microsoft-romulus.dtsi b/arc= h/arm64/boot/dts/qcom/x1e80100-microsoft-romulus.dtsi index 80fbcaea5d83e1147a74dd3320ae8fe8c953db57..2236095023a135d8fb1baaede11= 1a34be54d160c 100644 --- a/arch/arm64/boot/dts/qcom/x1e80100-microsoft-romulus.dtsi +++ b/arch/arm64/boot/dts/qcom/x1e80100-microsoft-romulus.dtsi @@ -124,7 +124,15 @@ port@1 { reg =3D <1>; =20 pmic_glink_ss0_ss_in: endpoint { - remote-endpoint =3D <&usb_1_ss0_qmpphy_out>; + remote-endpoint =3D <&retimer_ss0_ss_out>; + }; + }; + + port@2 { + reg =3D <2>; + + pmic_glink_ss0_con_sbu_in: endpoint { + remote-endpoint =3D <&retimer_ss0_con_sbu_out>; }; }; }; @@ -153,7 +161,15 @@ port@1 { reg =3D <1>; =20 pmic_glink_ss1_ss_in: endpoint { - remote-endpoint =3D <&usb_1_ss1_qmpphy_out>; + remote-endpoint =3D <&retimer_ss1_ss_out>; + }; + }; + + port@2 { + reg =3D <2>; + + pmic_glink_ss1_con_sbu_in: endpoint { + remote-endpoint =3D <&retimer_ss1_con_sbu_out>; }; }; }; @@ -185,6 +201,109 @@ vreg_edp_3p3: regulator-edp-3p3 { regulator-boot-on; }; =20 + vreg_rtmr0_1p15: regulator-rtmr0-1p15 { + compatible =3D "regulator-fixed"; + + regulator-name =3D "VREG_RTMR0_1P15"; + + regulator-min-microvolt =3D <1150000>; + regulator-max-microvolt =3D <1150000>; + + gpio =3D <&pmc8380_5_gpios 8 GPIO_ACTIVE_HIGH>; + enable-active-high; + + pinctrl-0 =3D <&rtmr0_1p15_reg_en>; + pinctrl-names =3D "default"; + + regulator-boot-on; + }; + + vreg_rtmr0_1p8: regulator-rtmr0-1p8 { + compatible =3D "regulator-fixed"; + + regulator-name =3D "VREG_RTMR0_1P8"; + + regulator-min-microvolt =3D <1800000>; + regulator-max-microvolt =3D <1800000>; + + gpio =3D <&pm8550ve_9_gpios 8 GPIO_ACTIVE_HIGH>; + enable-active-high; + + pinctrl-0 =3D <&rtmr0_1p8_reg_en>; + pinctrl-names =3D "default"; + + regulator-boot-on; + }; + + vreg_rtmr0_3p3: regulator-rtmr0-3p3 { + compatible =3D "regulator-fixed"; + + regulator-name =3D "VREG_RTMR0_3P3"; + + regulator-min-microvolt =3D <3300000>; + regulator-max-microvolt =3D <3300000>; + + gpio =3D <&pm8550_gpios 11 GPIO_ACTIVE_HIGH>; + enable-active-high; + + pinctrl-0 =3D <&rtmr0_3p3_reg_en>; + pinctrl-names =3D "default"; + + regulator-boot-on; + }; + + vreg_rtmr1_1p15: regulator-rtmr1-1p15 { + compatible =3D "regulator-fixed"; + + regulator-name =3D "VREG_RTMR1_1P15"; + + regulator-min-microvolt =3D <1150000>; + regulator-max-microvolt =3D <1150000>; + + gpio =3D <&tlmm 188 GPIO_ACTIVE_HIGH>; + enable-active-high; + + pinctrl-0 =3D <&rtmr1_1p15_reg_en>; + pinctrl-names =3D "default"; + + regulator-boot-on; + }; + + vreg_rtmr1_1p8: regulator-rtmr1-1p8 { + compatible =3D "regulator-fixed"; + + regulator-name =3D "VREG_RTMR1_1P8"; + + regulator-min-microvolt =3D <1800000>; + regulator-max-microvolt =3D <1800000>; + + gpio =3D <&tlmm 175 GPIO_ACTIVE_HIGH>; + enable-active-high; + + pinctrl-0 =3D <&rtmr1_1p8_reg_en>; + pinctrl-names =3D "default"; + + regulator-boot-on; + }; + + vreg_rtmr1_3p3: regulator-rtmr1-3p3 { + compatible =3D "regulator-fixed"; + + regulator-name =3D "VREG_RTMR1_3P3"; + + regulator-min-microvolt =3D <3300000>; + regulator-max-microvolt =3D <3300000>; + + gpio =3D <&tlmm 186 GPIO_ACTIVE_HIGH>; + enable-active-high; + + pinctrl-0 =3D <&rtmr1_3p3_reg_en>; + pinctrl-names =3D "default"; + + regulator-boot-on; + }; + + vreg_nvme: regulator-nvme { compatible =3D "regulator-fixed"; =20 @@ -665,7 +784,59 @@ &i2c3 { =20 status =3D "okay"; =20 - /* PS8830 USB retimer @8 */ + /* Left-side rear port */ + typec-mux@8 { + compatible =3D "parade,ps8830"; + reg =3D <0x8>; + + reset-gpios =3D <&pm8550_gpios 10 GPIO_ACTIVE_LOW>; + + clocks =3D <&rpmhcc RPMH_RF_CLK3>; + clock-names =3D "xo"; + + vdd-supply =3D <&vreg_rtmr0_1p15>; + vdd33-supply =3D <&vreg_rtmr0_3p3>; + vdd33-cap-supply =3D <&vreg_rtmr0_3p3>; + vddar-supply =3D <&vreg_rtmr0_1p15>; + vddat-supply =3D <&vreg_rtmr0_1p15>; + vddio-supply =3D <&vreg_rtmr0_1p8>; + + pinctrl-0 =3D <&rtmr0_default>; + pinctrl-names =3D "default"; + + retimer-switch; + orientation-switch; + + ports { + #address-cells =3D <1>; + #size-cells =3D <0>; + + port@0 { + reg =3D <0>; + + retimer_ss0_ss_out: endpoint { + remote-endpoint =3D <&pmic_glink_ss0_ss_in>; + }; + }; + + port@1 { + reg =3D <1>; + + retimer_ss0_ss_in: endpoint { + remote-endpoint =3D <&usb_1_ss0_qmpphy_out>; + }; + }; + + port@2 { + reg =3D <2>; + + retimer_ss0_con_sbu_out: endpoint { + remote-endpoint =3D <&pmic_glink_ss0_con_sbu_in>; + }; + }; + }; + }; + }; =20 &i2c4 { @@ -699,7 +870,55 @@ &i2c7 { =20 status =3D "okay"; =20 - /* PS8830 USB retimer @8 */ + /* Left-side front port */ + typec-mux@8 { + compatible =3D "parade,ps8830"; + reg =3D <0x8>; + + reset-gpios =3D <&tlmm 176 GPIO_ACTIVE_LOW>; + + clocks =3D <&rpmhcc RPMH_RF_CLK4>; + clock-names =3D "xo"; + + vdd-supply =3D <&vreg_rtmr1_1p15>; + vdd33-supply =3D <&vreg_rtmr1_3p3>; + vdd33-cap-supply =3D <&vreg_rtmr1_3p3>; + vddar-supply =3D <&vreg_rtmr1_1p15>; + vddat-supply =3D <&vreg_rtmr1_1p15>; + vddio-supply =3D <&vreg_rtmr1_1p8>; + + retimer-switch; + orientation-switch; + + ports { + #address-cells =3D <1>; + #size-cells =3D <0>; + + port@0 { + reg =3D <0>; + + retimer_ss1_ss_out: endpoint { + remote-endpoint =3D <&pmic_glink_ss1_ss_in>; + }; + }; + + port@1 { + reg =3D <1>; + + retimer_ss1_ss_in: endpoint { + remote-endpoint =3D <&usb_1_ss1_qmpphy_out>; + }; + }; + + port@2 { + reg =3D <2>; + + retimer_ss1_con_sbu_out: endpoint { + remote-endpoint =3D <&pmic_glink_ss1_con_sbu_in>; + }; + }; + }; + }; }; =20 &lpass_tlmm { @@ -816,6 +1035,28 @@ &pcie6a_phy { status =3D "okay"; }; =20 +&pm8550_gpios { + rtmr0_default: rtmr0-reset-n-active-state { + pins =3D "gpio10"; + function =3D "normal"; + power-source =3D <1>; /* 1.8V */ + }; + + rtmr0_3p3_reg_en: rtmr0-3p3-reg-en-state { + pins =3D "gpio11"; + function =3D "normal"; + power-source =3D <1>; /* 1.8V */ + }; +}; + +&pm8550ve_9_gpios { + rtmr0_1p8_reg_en: rtmr0-1p8-reg-en-state { + pins =3D "gpio8"; + function =3D "normal"; + power-source =3D <1>; /* 1.8V */ + }; +}; + &pmc8380_3_gpios { edp_bl_en: edp-bl-en-state { pins =3D "gpio4"; @@ -826,6 +1067,14 @@ edp_bl_en: edp-bl-en-state { }; }; =20 +&pmc8380_5_gpios { + rtmr0_1p15_reg_en: rtmr0-1p15-reg-en-state { + pins =3D "gpio8"; + function =3D "normal"; + power-source =3D <1>; /* 1.8V */ + }; +}; + &pmk8550_pwm { status =3D "okay"; }; @@ -1011,6 +1260,27 @@ wake-n-pins { }; }; =20 + rtmr1_1p8_reg_en: rtmr1-1p8-reg-en-state { + pins =3D "gpio175"; + function =3D "gpio"; + drive-strength =3D <2>; + bias-disable; + }; + + rtmr1_3p3_reg_en: rtmr1-3p3-reg-en-state { + pins =3D "gpio186"; + function =3D "gpio"; + drive-strength =3D <2>; + bias-disable; + }; + + rtmr1_1p15_reg_en: rtmr1-1p15-reg-en-state { + pins =3D "gpio188"; + function =3D "gpio"; + drive-strength =3D <2>; + bias-disable; + }; + wcd_default: wcd-reset-n-active-state { pins =3D "gpio191"; function =3D "gpio"; @@ -1071,7 +1341,7 @@ &usb_1_ss0_dwc3_hs { }; =20 &usb_1_ss0_qmpphy_out { - remote-endpoint =3D <&pmic_glink_ss0_ss_in>; + remote-endpoint =3D <&retimer_ss0_ss_in>; }; =20 &usb_1_ss1_hsphy { @@ -1103,7 +1373,7 @@ &usb_1_ss1_dwc3_hs { }; =20 &usb_1_ss1_qmpphy_out { - remote-endpoint =3D <&pmic_glink_ss1_ss_in>; + remote-endpoint =3D <&retimer_ss1_ss_in>; }; =20 /* MP0 goes to the Surface Connector, MP1 goes to the USB-A port */ --=20 2.47.1