[PATCH 3/4] arm64: dts: qcom: sm8350-sagami: Hook up USB-C Display Port

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Sagami devices feature Display Port on their USB-C port. Add the
necessary nodes to support it.

Signed-off-by: Konrad Dybcio <konrad.dybcio@xxxxxxxxxx>
---
 .../boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi   | 72 ++++++++++++++++++++++
 1 file changed, 72 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi b/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi
index 21462b6de686..b2baa81baf5e 100644
--- a/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi
@@ -120,6 +120,23 @@ pmic_glink_dwc3_ss_in: endpoint {
 						remote-endpoint = <&usb_1_dwc3_ss>;
 					};
 				};
+
+				port@2 {
+					reg = <2>;
+
+					#address-cells = <1>;
+					#size-cells = <0>;
+
+					pmic_glink_dp_in: endpoint@0 {
+						reg = <0>;
+						remote-endpoint = <&mdss_dp_altmode>;
+					};
+
+					pmic_glink_sbu_mux_out: endpoint@1 {
+						reg = <1>;
+						remote-endpoint = <&sbu_mux_in>;
+					};
+				};
 			};
 		};
 	};
@@ -140,6 +157,26 @@ ramoops@ffc00000 {
 		};
 	};
 
+	sbu-mux {
+		/* TODO: switch to a proper driver when one gets upstreamed */
+		compatible = "onnn,nb7vpq904m-mux", "gpio-sbu-mux";
+
+		enable-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
+		select-gpios = <&tlmm 55 GPIO_ACTIVE_HIGH>;
+		svid = /bits/ 16 <0xff01>;
+
+		mode-switch;
+		orientation-switch;
+
+		pinctrl-0 = <&sbu_sw_oe &sbu_sw_sel>;
+
+		port {
+			sbu_mux_in: endpoint {
+				remote-endpoint = <&pmic_glink_sbu_mux_out>;
+			};
+		};
+	};
+
 	vph_pwr: vph-pwr-regulator {
 		compatible = "regulator-fixed";
 		regulator-name = "vph_pwr";
@@ -595,6 +632,25 @@ &ipa {
 	status = "okay";
 };
 
+&mdss {
+	status = "okay";
+};
+
+&mdss_dp {
+	data-lanes = <0 1 2 3>;
+	status = "okay";
+
+	ports {
+		port@1 {
+			reg = <1>;
+
+			mdss_dp_altmode: endpoint {
+				remote-endpoint = <&pmic_glink_dp_in>;
+			};
+		};
+	};
+};
+
 &mpss {
 	status = "okay";
 	firmware-name = "qcom/sm8350/Sony/sagami/modem.mbn";
@@ -916,6 +972,22 @@ ts_int_default: ts-int-default-state {
 		input-enable;
 	};
 
+	sbu_sw_oe: sbu-sw-oe-state {
+		pins = "gpio54";
+		function = "gpio";
+		drive-strength = <2>;
+		bias-disable;
+		output-low;
+	};
+
+	sbu_sw_sel: sbu-sw-sel-state {
+		pins = "gpio55";
+		function = "gpio";
+		drive-strength = <2>;
+		bias-disable;
+		output-low;
+	};
+
 	sdc2_card_det_active: sd-card-det-active-state {
 		pins = "gpio92";
 		function = "gpio";

-- 
2.40.0




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux