From patchwork Fri Dec 15 17:40:33 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 754918 Received: from mail-lf1-f43.google.com (mail-lf1-f43.google.com [209.85.167.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 983C330109 for ; Fri, 15 Dec 2023 17:41:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="hydavoa2" Received: by mail-lf1-f43.google.com with SMTP id 2adb3069b0e04-50c0f6b1015so1035109e87.3 for ; Fri, 15 Dec 2023 09:41:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702662116; x=1703266916; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=05m2TTjXO8qRbBF1AwJ78a9lW4yXOGZ2LJactcujacI=; b=hydavoa22AyJTMEVxLkz7q2iy4JhKP6ICzExVPHfI9GOCLkfPof9045dAAu/VSlOB/ KuUWvtYF7aRahBYf/zDYA37X6EReaZf2PAhT6OpIOBCbAH05mFcP3Dk/BSqk6TizF06G YWm0gXAufYmMMgKu4MNB67IPM3IbTtI5aa2/ykip4XbqWd4eEvkSkGlrlOHrpAMayXu6 KHttK3S8QJIJ2BHwhff0/xyj94fwOUcrNTBzHfUvdVswKWtuEbRXekcl2m0Unw2Rop0+ yOfTkb2l0qx03KNsa5pl8vUBO+DlppzRx0/9kjZ4ybzYJ3yY3SclmCOez08s1Am+boMI kIWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702662116; x=1703266916; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=05m2TTjXO8qRbBF1AwJ78a9lW4yXOGZ2LJactcujacI=; b=TAr46Re+7b0aLblddrrRwgDcffIvvXRa/yzJ2spygbbJIOEH6STjN9pYsx7i4re9Rb VGjOLfR6vGW/WupK9SEINeIbRCQ5OdwqgI1I53okqyavr5EqN+qbWO3ji5fSIiMwJECU Oa17CvmSMq+DP/UTV+akqYCYKVGMZHAqEbD9z1/t83TNqKbMlBDiUQhbtHckdDBp7k9v fZ96cSrjPfcRRWGg9tAr62z9B3ISfdRetq+4Kb2HKEiSc6boVxPB1Kl4nx615SDPMmyN 1nwPInfBpwpgtSBevKqS3hJxhumJBlev8mhrjmyh9tQ4IyiKvPI9mX+OXKI+yrMOvKd7 +5Tg== X-Gm-Message-State: AOJu0YxALoqFTxKuO39Hh6JVv3+9nOIra4tpHErTd/+lE6tfZzczinkh FbjumVbxGi4LtA4SDFx1cuFoiQ== X-Google-Smtp-Source: AGHT+IFX9tez/i09CQndRfQ6lADZJ2grBe3Db83nFkfalE8QYv/sN7r7tEzrIxu27f6ewcbJKJkSTg== X-Received: by 2002:a05:6512:68a:b0:50d:15be:f07e with SMTP id t10-20020a056512068a00b0050d15bef07emr7492031lfe.74.1702662116687; Fri, 15 Dec 2023 09:41:56 -0800 (PST) Received: from eriador.lumag.spb.ru (85-76-13-188-nat.elisa-mobile.fi. [85.76.13.188]) by smtp.gmail.com with ESMTPSA id c16-20020a056512239000b0050dff5bb793sm1389263lfv.143.2023.12.15.09.41.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 09:41:56 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 1/7] arm64: dts: qcom: sm8150: make dispcc cast minimal vote on MMCX Date: Fri, 15 Dec 2023 19:40:33 +0200 Message-ID: <20231215174152.315403-2-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> References: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Add required-opps property to the display clock controller. This makes it cast minimal vote on the MMCX lane and prevents further 'clock stuck' errors when enabling the display. Fixes: 2ef3bb17c45c ("arm64: dts: qcom: sm8150: Add DISPCC node") Acked-by: Konrad Dybcio Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/sm8150.dtsi | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/boot/dts/qcom/sm8150.dtsi b/arch/arm64/boot/dts/qcom/sm8150.dtsi index 2ce07910dd13..ad03ede906bb 100644 --- a/arch/arm64/boot/dts/qcom/sm8150.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8150.dtsi @@ -3925,6 +3925,7 @@ dispcc: clock-controller@af00000 { "dp_phy_pll_link_clk", "dp_phy_pll_vco_div_clk"; power-domains = <&rpmhpd SM8150_MMCX>; + required-opps = <&rpmhpd_opp_low_svs>; #clock-cells = <1>; #reset-cells = <1>; #power-domain-cells = <1>; From patchwork Fri Dec 15 17:40:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 754407 Received: from mail-lf1-f44.google.com (mail-lf1-f44.google.com [209.85.167.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0A5BA82EEF for ; Fri, 15 Dec 2023 17:41:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="mIarOCv+" Received: by mail-lf1-f44.google.com with SMTP id 2adb3069b0e04-50bdec453c8so1012648e87.3 for ; Fri, 15 Dec 2023 09:41:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702662118; x=1703266918; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=VkZ0d7wqWaT2Oid/3peHdN8kAaqN3lW46U8589k3qIY=; b=mIarOCv+IT/rqIjg9GlRLCJmvHsWMr4tZHNQ2X/KO8RsEYFHCuDi5qeF3mEFSWdLfj QTC0W4Slkl+r/ZpuLw5CmQBRMCiFZc4cFk5A9C7dwqEoCdzxNbiqI/+6M8XS/U1yOYEb JYLlHVuFePhAfyhewCakOYGONprWjKXh0e3bmMt9HjENcvvq6qsV/jfwiqpxZVWDPwdc unDwPqEt6fpP9rC6QLZcloI85+HIz/4SbQGkSnzI9JLnUKhviHoeyksUXMPluN2iv011 yTxYJyFxvdmrlHrTNa0FqDq9oxtiBaW9ZJqIs40cMdgTjfo3yl+LdtoCQTN+rWx5Sfaf Ke/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702662118; x=1703266918; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=VkZ0d7wqWaT2Oid/3peHdN8kAaqN3lW46U8589k3qIY=; b=DphTwOfbvn3Yrw8iuglCZz7NgOgTb6Z+ZY1MVHxVMYQ2IRnFB2tucIjzXs9pOhpnIk f3LhWNQjYt72fFRT6BQqvZgRICRw4PCnDquo2iFKNr+q/qn6/5Wd26kEV+4R04d9hvyH wEPMXJJUB7XD/cEAY06dmn12WgFsRnw7Bd6l2AU+g4xJfWYrGWY7yQ1wmz0nS8khOQPD e9XJbHco0uoouQWv5v9+uPVmwVRWqnqcmnTRLol2FTk5XK/KyN0KKQ7RVoTkRi6oSXbz 9X3fhVi5j87BuVKW1/hPFjhYUgwmkph5GNczGyCakn83PJA7xjbWYjHZUeExlTLL1yRJ uMlQ== X-Gm-Message-State: AOJu0YyINVy3MCt+9mscMsDKuOuFoqKp4+gUnYTXejL2tqRMCNRujMK7 jWQmoLMNHRVoJYHH8RfWH0hzew== X-Google-Smtp-Source: AGHT+IG6asdVxl3ZeJA5fGQH0/rlG1vk8xcqUDsS9ognza44Q/oogrHhARfDGbPNCDjGQm306HdzZQ== X-Received: by 2002:a05:6512:36d2:b0:50b:fc6d:bb8d with SMTP id e18-20020a05651236d200b0050bfc6dbb8dmr5348985lfs.56.1702662118229; Fri, 15 Dec 2023 09:41:58 -0800 (PST) Received: from eriador.lumag.spb.ru (85-76-13-188-nat.elisa-mobile.fi. [85.76.13.188]) by smtp.gmail.com with ESMTPSA id c16-20020a056512239000b0050dff5bb793sm1389263lfv.143.2023.12.15.09.41.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 09:41:57 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 2/7] arm64: dts: qcom: sm8150-hdk: enable HDMI output Date: Fri, 15 Dec 2023 19:40:34 +0200 Message-ID: <20231215174152.315403-3-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> References: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Add DSI outputs and link them to the onboard Lontium LT9611 DSI-to-HDMI bridge, enabling HDMI output on this board. While adding the display resources, also drop the headless ("amd,imageon") compat string from the GPU node, since the board now has output. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/sm8150-hdk.dts | 128 +++++++++++++++++++++++- 1 file changed, 123 insertions(+), 5 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm8150-hdk.dts b/arch/arm64/boot/dts/qcom/sm8150-hdk.dts index bb161b536da4..6a036f9ba1c9 100644 --- a/arch/arm64/boot/dts/qcom/sm8150-hdk.dts +++ b/arch/arm64/boot/dts/qcom/sm8150-hdk.dts @@ -54,6 +54,17 @@ key-vol-up { gpios = <&pm8150_gpios 6 GPIO_ACTIVE_LOW>; }; }; + + hdmi-out { + compatible = "hdmi-connector"; + type = "a"; + + port { + hdmi_con: endpoint { + remote-endpoint = <<9611_out>; + }; + }; + }; }; &apps_rsc { @@ -359,12 +370,112 @@ &gmu { status = "okay"; }; +&gpi_dma1 { + status = "okay"; +}; + &gpu { - /* - * NOTE: "amd,imageon" makes Adreno start in headless mode, remove it - * after display support is added on this board. - */ - compatible = "qcom,adreno-640.1", "qcom,adreno", "amd,imageon"; + status = "okay"; +}; + +&i2c9 { + status = "okay"; + clock-frequency = <400000>; + + lt9611_codec: hdmi-bridge@3b { + compatible = "lontium,lt9611"; + reg = <0x3b>; + #sound-dai-cells = <1>; + + interrupts-extended = <&tlmm 9 IRQ_TYPE_EDGE_FALLING>; + + reset-gpios = <&tlmm 7 GPIO_ACTIVE_HIGH>; + + vdd-supply = <&vreg_s4a_1p8>; + vcc-supply = <&vreg_bob>; + + pinctrl-names = "default"; + pinctrl-0 = <<9611_irq_pin>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + lt9611_a: endpoint { + remote-endpoint = <&mdss_dsi0_out>; + }; + }; + + port@1 { + reg = <1>; + + lt9611_b: endpoint { + remote-endpoint = <&mdss_dsi1_out>; + }; + }; + + port@2 { + reg = <2>; + + lt9611_out: endpoint { + remote-endpoint = <&hdmi_con>; + }; + }; + }; + }; +}; + +&mdss { + status = "okay"; +}; + +&mdss_dsi0 { + status = "okay"; + vdda-supply = <&vreg_l3c_1p2>; + + qcom,dual-dsi-mode; + qcom,master-dsi; + + ports { + port@1 { + endpoint { + remote-endpoint = <<9611_a>; + data-lanes = <0 1 2 3>; + }; + }; + }; +}; + +&mdss_dsi0_phy { + status = "okay"; + vdds-supply = <&vreg_l5a_0p875>; +}; + +&mdss_dsi1 { + vdda-supply = <&vreg_l3c_1p2>; + + qcom,dual-dsi-mode; + + /* DSI1 is slave, so use DSI0 clocks */ + assigned-clock-parents = <&mdss_dsi0_phy 0>, <&mdss_dsi0_phy 1>; + + status = "okay"; + + ports { + port@1 { + endpoint { + remote-endpoint = <<9611_b>; + data-lanes = <0 1 2 3>; + }; + }; + }; +}; + +&mdss_dsi1_phy { + vdds-supply = <&vreg_l5a_0p875>; status = "okay"; }; @@ -402,6 +513,13 @@ &remoteproc_slpi { &tlmm { gpio-reserved-ranges = <0 4>, <126 4>; + + lt9611_irq_pin: lt9611-irq-state { + pins = "gpio9"; + function = "gpio"; + bias-disable; + }; + }; &uart2 { From patchwork Fri Dec 15 17:40:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 754917 Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AC99E82EFA for ; Fri, 15 Dec 2023 17:42:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="Mx1cxwIO" Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-50c0f6b1015so1035204e87.3 for ; Fri, 15 Dec 2023 09:42:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702662120; x=1703266920; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=1h24XTHlxIOXc1I+zL+zjCVse/5Gc8JfYae1eKP47QU=; b=Mx1cxwIO0DbNKHUdXXMqUFw532veSzxApeMO/ALh4bGc7MJH+HNCOsYTnTRoQRFSO7 xCK1QvzEb6HOfk2IOP70lQNI0jJWpHx4EiRN7wjAjXkWXrMbsBMyR5Vi9tzAgZrwhj/3 9qsdPtb5rSr270gbr2yeVTNm3XWhTbI3BS42mm7XTt4vdfPZ1WNlIhzCrcTO1LUUkKqe W3lcAQTCZNMZtmFpz+wKVL7PAyJia0ZKdeDfs+w5Af1ElvtA0l5FzijfMzu9nl5f2eFx RMoWa5PxE3ZSdX35x30x+S0N82FfF0ZFdpcXnmhXrt6UT3IyXX/7ULiyVW6y0rvBBTRF P5wQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702662120; x=1703266920; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=1h24XTHlxIOXc1I+zL+zjCVse/5Gc8JfYae1eKP47QU=; b=uUgTo2bKvq5UK2aHooBZyW+hNR+62Hy2breEhMuqvHPkLDvSR1h+4imb92NUeUlT6l sJiNRSYocJYcI93IDsQP6sSClP/eMzNc3csB1n/9lIMB8FILp0sGSJ0O/PkCWTNgls2P aElAwQsYvc5/jdRH7IL2O585VfkUFHZm2mGEliOnOO/bHKOzht2bKITSaaiRMIdh2DoC YW3M4aGMioQGh+YBHvOSurtL3jbSTnBigGzXh0J5iXI9mDgJRp1FmwXuMhlseUDeoZRa NyCb0YTN2NHJcJ2vZLWKdJuZpG8uJW2OAR4dNvj5WS4MnV98wQDqpr5Y1rOS9Ufm/CJD DBKQ== X-Gm-Message-State: AOJu0Yzi+p8KRna2NsXFrNTB8FtnXdFlx3wo7e6Z9ysaI95Pb4Rkwski SLXUIP2/zPlL1676M2ex6+cYq8GZgjPz3uqfPN4oQg== X-Google-Smtp-Source: AGHT+IHi/8CwvK473h10Dt4Q9PARgxUmIcOoD7lTXpv8FNk2lhn9KXSTEwk0m60SEhTDsP9996jr/A== X-Received: by 2002:ac2:598a:0:b0:50b:f7c6:2f72 with SMTP id w10-20020ac2598a000000b0050bf7c62f72mr5002545lfn.106.1702662119800; Fri, 15 Dec 2023 09:41:59 -0800 (PST) Received: from eriador.lumag.spb.ru (85-76-13-188-nat.elisa-mobile.fi. [85.76.13.188]) by smtp.gmail.com with ESMTPSA id c16-20020a056512239000b0050dff5bb793sm1389263lfv.143.2023.12.15.09.41.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 09:41:59 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 3/7] arm64: dts: qcom: sm8150-hdk: fix SS USB regulators Date: Fri, 15 Dec 2023 19:40:35 +0200 Message-ID: <20231215174152.315403-4-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> References: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 The SM8150-HDK uses two different regulators to power up SuperSpeed USB PHYs. The L5A regulator is used for the second USB host, while the first (OTG) USB host uses different regulator, L18A. Fix the regulator for the usb_1 QMPPHY and (to remove possible confusion) drop the usb_ss_dp_core_1/_2 labels. Fixes: 0ab1b2d10afe ("arm64: dts: qcom: add sm8150 hdk dts") Reviewed-by: Konrad Dybcio Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/sm8150-hdk.dts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm8150-hdk.dts b/arch/arm64/boot/dts/qcom/sm8150-hdk.dts index 6a036f9ba1c9..ea4d75308ac8 100644 --- a/arch/arm64/boot/dts/qcom/sm8150-hdk.dts +++ b/arch/arm64/boot/dts/qcom/sm8150-hdk.dts @@ -138,8 +138,6 @@ vdda_qrefs_0p875_5: vdda_sp_sensor: vdda_ufs_2ln_core_1: vdda_ufs_2ln_core_2: - vdda_usb_ss_dp_core_1: - vdda_usb_ss_dp_core_2: vdda_qlink_lv: vdda_qlink_lv_ck: vreg_l5a_0p875: ldo5 { @@ -221,6 +219,12 @@ vreg_l17a_3p0: ldo17 { regulator-max-microvolt = <3008000>; regulator-initial-mode = ; }; + + vreg_l18a_0p8: ldo18 { + regulator-min-microvolt = <880000>; + regulator-max-microvolt = <880000>; + regulator-initial-mode = ; + }; }; regulators-1 { @@ -563,13 +567,13 @@ &usb_2_hsphy { &usb_1_qmpphy { status = "okay"; vdda-phy-supply = <&vreg_l3c_1p2>; - vdda-pll-supply = <&vdda_usb_ss_dp_core_1>; + vdda-pll-supply = <&vreg_l18a_0p8>; }; &usb_2_qmpphy { status = "okay"; vdda-phy-supply = <&vreg_l3c_1p2>; - vdda-pll-supply = <&vdda_usb_ss_dp_core_1>; + vdda-pll-supply = <&vreg_l5a_0p875>; }; &usb_1 { From patchwork Fri Dec 15 17:40:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 754406 Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1E6F330104 for ; Fri, 15 Dec 2023 17:42:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="uEBIgFuq" Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-50bf2d9b3fdso1208684e87.3 for ; Fri, 15 Dec 2023 09:42:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702662121; x=1703266921; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=jb3yyT60JxfN3wtZfqwGr6jtCxjpRC2WofuVNBbqItw=; b=uEBIgFuqPzfjKvP7GY3qWkFuXCQIE5PBGffr+b7YkRHeVs+4oD7jSXcwrlQJ0+qHfx vEtY80+nn3nNxsBWY2vS9EqbLRm8DnVidFx5pa7la0MYTTZZXtZvqIaP2i8zNmJm1hDP o5g9eYgfhHUl4bV8STk3ny4bfhIUMi4FSpBrcwZqAM9BkujMBPI2KwFSr1+Ktx/fBz0v wKpu4vWx/CnHcfP4LHfjZf0LxGicaVXMveB408RjgN1kHRNpPC0O5Gmo0MgQRN7GiN65 h2PW3e8V1So8MgAHPUWiS3NlekLA9wgIz+gp+iZn8wDJcT4UkggUNVjEXyCX1U6f0CMz WQBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702662121; x=1703266921; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=jb3yyT60JxfN3wtZfqwGr6jtCxjpRC2WofuVNBbqItw=; b=eLQ2BJRyYAeEgQOx65w+tRZbu8mSs8q8bSYM14oZqZ76pmHPr5jEE7SpaWnViGJy45 f9HkysCizS2MHSY4fvc2Ye7hcAQPPjKPBKVEkPvYeN5Q4fcPMkhicrkpLn1ldjaUZzp2 47jajOAB5eHNlqHRyxTKNSVQDmCifxjDrcuuDc5q1YuKIX3WhlOBMKyc7EmiA3BxqjTQ Xq4L2UAiB8VpbYZXquVQjeYDmA518bAbDMcUhefH1GXRWuBzFrTWNj5BkH1GTIICq2Cq tjXnLNPdfHU+crYpwD1lMU281X0FILdWSEO+VVADFCfbuCrYe6NsVnMCUP39PKHPQ97K SQ8w== X-Gm-Message-State: AOJu0YznSDe3Fz03BBhkGB/+1os1HVR1qjMUJWtoLsfIX20Y7OUalSKN hLoFx/b6ULEAA1IyGSTJsbPhqw== X-Google-Smtp-Source: AGHT+IG+QLXDAXKKgY6LgrZ851rUXPmXG2u94e0dOIK+um/QxLnD+u3sgh5+dYP4UwoEbHFk6s1aSQ== X-Received: by 2002:a05:6512:36c4:b0:50b:ffb9:7a4e with SMTP id e4-20020a05651236c400b0050bffb97a4emr5039637lfs.46.1702662121338; Fri, 15 Dec 2023 09:42:01 -0800 (PST) Received: from eriador.lumag.spb.ru (85-76-13-188-nat.elisa-mobile.fi. [85.76.13.188]) by smtp.gmail.com with ESMTPSA id c16-20020a056512239000b0050dff5bb793sm1389263lfv.143.2023.12.15.09.41.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 09:42:01 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 4/7] arm64: dts: qcom: sm8150: add DisplayPort controller Date: Fri, 15 Dec 2023 19:40:36 +0200 Message-ID: <20231215174152.315403-5-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> References: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Add device tree node for the DisplayPort controller and link it to the display controller interface. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/sm8150.dtsi | 87 ++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sm8150.dtsi b/arch/arm64/boot/dts/qcom/sm8150.dtsi index ad03ede906bb..0a002ac744e5 100644 --- a/arch/arm64/boot/dts/qcom/sm8150.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8150.dtsi @@ -3712,6 +3712,13 @@ dpu_intf2_out: endpoint { remote-endpoint = <&mdss_dsi1_in>; }; }; + + port@2 { + reg = <2>; + dpu_intf0_out: endpoint { + remote-endpoint = <&mdss_dp_in>; + }; + }; }; mdp_opp_table: opp-table { @@ -3739,6 +3746,86 @@ opp-460000000 { }; }; + mdss_dp: displayport-controller@ae90000 { + compatible = "qcom,sm8150-dp", "qcom,sm8350-dp"; + reg = <0 0xae90000 0 0x200>, + <0 0xae90200 0 0x200>, + <0 0xae90400 0 0x600>, + <0 0x0ae90a00 0 0x600>, + <0 0x0ae91000 0 0x600>; + + interrupt-parent = <&mdss>; + interrupts = <12>; + clocks = <&dispcc DISP_CC_MDSS_AHB_CLK>, + <&dispcc DISP_CC_MDSS_DP_AUX_CLK>, + <&dispcc DISP_CC_MDSS_DP_LINK_CLK>, + <&dispcc DISP_CC_MDSS_DP_LINK_INTF_CLK>, + <&dispcc DISP_CC_MDSS_DP_PIXEL_CLK>; + clock-names = "core_iface", + "core_aux", + "ctrl_link", + "ctrl_link_iface", + "stream_pixel"; + + assigned-clocks = <&dispcc DISP_CC_MDSS_DP_LINK_CLK_SRC>, + <&dispcc DISP_CC_MDSS_DP_PIXEL_CLK_SRC>; + assigned-clock-parents = <&usb_1_qmpphy QMP_USB43DP_DP_LINK_CLK>, + <&usb_1_qmpphy QMP_USB43DP_DP_VCO_DIV_CLK>; + + phys = <&usb_1_qmpphy QMP_USB43DP_DP_PHY>; + phy-names = "dp"; + + #sound-dai-cells = <0>; + + operating-points-v2 = <&dp_opp_table>; + power-domains = <&rpmhpd SM8250_MMCX>; + + status = "disabled"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + mdss_dp_in: endpoint { + remote-endpoint = <&dpu_intf0_out>; + }; + }; + + port@1 { + reg = <1>; + + mdss_dp_out: endpoint { + }; + }; + }; + + dp_opp_table: opp-table { + compatible = "operating-points-v2"; + + opp-160000000 { + opp-hz = /bits/ 64 <160000000>; + required-opps = <&rpmhpd_opp_low_svs>; + }; + + opp-270000000 { + opp-hz = /bits/ 64 <270000000>; + required-opps = <&rpmhpd_opp_svs>; + }; + + opp-540000000 { + opp-hz = /bits/ 64 <540000000>; + required-opps = <&rpmhpd_opp_svs_l1>; + }; + + opp-810000000 { + opp-hz = /bits/ 64 <810000000>; + required-opps = <&rpmhpd_opp_nom>; + }; + }; + }; + mdss_dsi0: dsi@ae94000 { compatible = "qcom,sm8150-dsi-ctrl", "qcom,mdss-dsi-ctrl"; reg = <0 0x0ae94000 0 0x400>; From patchwork Fri Dec 15 17:40:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 754916 Received: from mail-lf1-f53.google.com (mail-lf1-f53.google.com [209.85.167.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D272F30119 for ; Fri, 15 Dec 2023 17:42:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="f+ZkY0ds" Received: by mail-lf1-f53.google.com with SMTP id 2adb3069b0e04-50bf2d9b3fdso1208732e87.3 for ; Fri, 15 Dec 2023 09:42:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702662123; x=1703266923; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=UhbQd1vUvvpEtI2ZOqTGTRH3HwBYCdsjTdlr5KRWrfo=; b=f+ZkY0ds0tDVp8khQIQhzC+WBZBYnZWw8GzayCCCueNk8XYa7zRePrY6bo09FNB3BD VdE9+QBDWmtW7jstztT/aT6H6HFEQN1qWzUnIkCWMSAANOHHq3CWf133ALh0PaaF3LNs OazFwKZyltgKSxDGSFNONRlJAJsczm8RHgYLqK9FlwR1TYIt+ON2QDk4Tx/X91yAKzOg blGlmEDF1Ehwj97sGbqyxMzeT2v6p9nUdbOJ8yBjXYf3IU12u5TsCuyGrpf18c340K/7 XcUa5k9sVRWgdZDX/CmE7jvvVzxtUrMTLX3Ar/Ikti/p2avYp7lnngdZiZsiQbWz+TD2 o3gA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702662123; x=1703266923; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=UhbQd1vUvvpEtI2ZOqTGTRH3HwBYCdsjTdlr5KRWrfo=; b=WneVViLEw8FM4bd+rHfJflb09iuzGm5pMqRFOJ85am7OsMrlCTXf+qROeWVHEaTJfx V0e+O+F0CjT6gynM5JcujcSrtuEHIJoSsAwDbGQMwdp41YJ/zhSXNJkb1ZEeUfrZ4jNH aRn4P+/vnvitdYCVukhBvbAKNNc6+JiIUZg+9C9KxeO4MUa0AD7fbvDxbEq5mZ0032NM ivWXiFB/2PZkN//+R1We2ES0yhAjI+4oMNEANVaPpj4WV6spPaoKY/+eQZQY76fbr4OK 92IQbC9dPmguiIeZQXnEREHUQ6cgSWzcfPuQlwJpZm5x8tn3e4HbEReeMUCFKV9YA817 6o0Q== X-Gm-Message-State: AOJu0YxCOL3Djl4lWmnhghTWrrdFjAIZyFi6QSZZwQHhmycaQ4vRxMwb BzSNV4pSx9+SdS4iQua5FG2v0w== X-Google-Smtp-Source: AGHT+IG+v15rIm/rmQenOWMne7VqTk/cv/zpw52FSDiTavJc0NzdFBwS0Ur80FyHEla6blcNs5Q77A== X-Received: by 2002:a05:6512:608:b0:50b:f715:387d with SMTP id b8-20020a056512060800b0050bf715387dmr5517133lfe.50.1702662123021; Fri, 15 Dec 2023 09:42:03 -0800 (PST) Received: from eriador.lumag.spb.ru (85-76-13-188-nat.elisa-mobile.fi. [85.76.13.188]) by smtp.gmail.com with ESMTPSA id c16-20020a056512239000b0050dff5bb793sm1389263lfv.143.2023.12.15.09.42.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 09:42:02 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 5/7] arm64: dts: qcom: sm8150: add USB-C ports to the USB+DP QMP PHY Date: Fri, 15 Dec 2023 19:40:37 +0200 Message-ID: <20231215174152.315403-6-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> References: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Expand Combo USB+DP QMP PHY device node with the OF ports required to support USB-C / DisplayPort switching. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/sm8150.dtsi | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sm8150.dtsi b/arch/arm64/boot/dts/qcom/sm8150.dtsi index 0a002ac744e5..d29dfdd0583c 100644 --- a/arch/arm64/boot/dts/qcom/sm8150.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8150.dtsi @@ -3447,6 +3447,32 @@ usb_1_qmpphy: phy@88e8000 { #phy-cells = <1>; status = "disabled"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + usb_1_qmpphy_out: endpoint { + }; + }; + + port@1 { + reg = <1>; + + usb_1_qmpphy_usb_ss_in: endpoint { + }; + }; + + port@2 { + reg = <2>; + + usb_1_qmpphy_dp_in: endpoint { + }; + }; + }; }; usb_2_qmpphy: phy@88eb000 { From patchwork Fri Dec 15 17:40:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 754405 Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6B3BB30120 for ; Fri, 15 Dec 2023 17:42:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="UKKnEbME" Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-50bfd3a5b54so1015129e87.3 for ; Fri, 15 Dec 2023 09:42:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702662124; x=1703266924; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=KnnM4NLYYXQL9h/0MUW7hGGl0ViRyq8ukmFIOJoxzgQ=; b=UKKnEbMEKj1eBV1g1ZKv1c+cObyXkcVDWhBnGj0OU53tcpRvqUsu/4fVXfRT8w4LR5 GVCwcCgzvtA+jFQB510txW2VAHeejyLT1Ywht4eti6Hqy6RA2EH5ZbRcayY2Shlibo6k 6BUovs1mxarKqAmp3teXzN0852hsxCZlW2y/UPnbVepPOxN6z/gVsspiuOxXTKG4XMtd 6Nnx9VuO5ByyU4RQ2+N2Jlj6xgQx+I05CR1Hy9MaPYaY8gq6uOdftRmL0PuDhXzc0Tiq BnJmugmuHN8d3wLPzHQIo7l5yvHRQBiRI9BwuK2OF3SvVOnIKYZqAd6lcPMyA7ITGTZR GE0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702662124; x=1703266924; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=KnnM4NLYYXQL9h/0MUW7hGGl0ViRyq8ukmFIOJoxzgQ=; b=rUN8sGJnOWz0aO/UcTL6SrMGGeJByzFeaimI6mAAbtXyh1fyao6rVBdFuspWqwtlSw yoCdP82Bjgc7rHxztGDpRm5AaexVaXgtBVtuW38V97lvbQq316SRcBliofnwONHzA0Vj JK4L8nMk1xWOXQ/rFNECkU6RvlCiLrhNB7EPkZTEWJ/erL/29jK5UO8eLmHFCXf4PXZN xKoc7QMVHkk4xWeiS9stUwc+oeTcikCXUYqmo1pNiF+KZG6egXrVSmUsDcggEgn8DnBG dMzVkwl1rkSL8kWcCD9Rs3qnqM9/uICOvSfUxHTiOiES6Jf1NJB5SBBGK8FCszVlNUhS 3chA== X-Gm-Message-State: AOJu0YyptNHhoOFL/oBgpovfqVTbKqIG8I6NKJZYvworsij7gYUYhKqO VRMstRQ/GTOhRrx2sPwMcHxfPA== X-Google-Smtp-Source: AGHT+IHkwyZNCl+tIBTF8hgjNJYrcVRsjpKNHb8C2OrOlBAiZNUrlviD7eIsR4mKIlz+PVc+wmHZSw== X-Received: by 2002:a05:6512:2807:b0:50c:c63:1d20 with SMTP id cf7-20020a056512280700b0050c0c631d20mr6510772lfb.76.1702662124630; Fri, 15 Dec 2023 09:42:04 -0800 (PST) Received: from eriador.lumag.spb.ru (85-76-13-188-nat.elisa-mobile.fi. [85.76.13.188]) by smtp.gmail.com with ESMTPSA id c16-20020a056512239000b0050dff5bb793sm1389263lfv.143.2023.12.15.09.42.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 09:42:04 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 6/7] arm64: dts: qcom: sm8150: add USB-C ports to the OTG USB host Date: Fri, 15 Dec 2023 19:40:38 +0200 Message-ID: <20231215174152.315403-7-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> References: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Expand first USB host controller device node with the OF ports required to support USB-C / DisplayPort switching. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/sm8150.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sm8150.dtsi b/arch/arm64/boot/dts/qcom/sm8150.dtsi index d29dfdd0583c..fd50fa79dff1 100644 --- a/arch/arm64/boot/dts/qcom/sm8150.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8150.dtsi @@ -3608,6 +3608,25 @@ usb_1_dwc3: usb@a600000 { snps,dis_enblslpm_quirk; phys = <&usb_1_hsphy>, <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; phy-names = "usb2-phy", "usb3-phy"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + usb_1_dwc3_hs: endpoint { + }; + }; + + port@1 { + reg = <1>; + + usb_1_dwc3_ss: endpoint { + }; + }; + }; }; }; From patchwork Fri Dec 15 17:40:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 754915 Received: from mail-lf1-f48.google.com (mail-lf1-f48.google.com [209.85.167.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 058A630123 for ; Fri, 15 Dec 2023 17:42:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="kT3VhiU9" Received: by mail-lf1-f48.google.com with SMTP id 2adb3069b0e04-50bf898c43cso939456e87.1 for ; Fri, 15 Dec 2023 09:42:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702662126; x=1703266926; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=CKgsVk0fjSxD37WNiVSTe954mlFL2bYCq2rQX68jkaY=; b=kT3VhiU9QeQt9z22Kstvbm4CmeiQYmsTiyXzKhrycGhCPyCOAdFKhD39HUmlc7BsRg tgXB+4hkY2uYVU6Pv9bqTsCl4q2VhleplgQ9+vcbqIC7ey11wdygLERnEcCMmjMiR5Un PLeam/3MDjCSCe1oXABxStmuNkBy2zUi34OdWtLBRrycubda2i6C53Pfj4CihCVkTBYu 8hhyECtpt7+s6r7PfU62A2WeXjZ/2Lbc4dZ9POwWt1pyPx7eiWJQVA7RfAY/5POOgjdK fJOEnp1e3XmJZBSrQLGqxhJBGdh2/lH6EpSF3lsOwWJC2jTU5OXieiPah4SlKg7YWkVv 7s1Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702662126; x=1703266926; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CKgsVk0fjSxD37WNiVSTe954mlFL2bYCq2rQX68jkaY=; b=iX5IJKb1xm6eWAhV63VbNu/gc3VZA/2dkGCDcumkUYu5O/ap8MaoNL7NqFe+0fUU3K PXXwxLpKbbQARyMGe3QuB8zM35HjoBxMVc9NrC9qLhx/WntUEjG6Mme8kIvRU1cs5tNw nIjMR/MAx5iDX3GeU4m3hEYkUHvwua8+bEv+WUxiHH7Qyb6W5QXCDnV3B3zHLf7ImVML 0cg2d0fgmkydmQzAi16Wdsc9dghoVry6Q2xHw/G6ExoXiM6OaNuS8l9oV/wVcZ8BjRt4 beJNiqahkIBIeD1UtzqKf1YfZWx4Q9sExN1NtwnOe88pNWEk3FcKohLvAKA/h/j9ubRV xZyw== X-Gm-Message-State: AOJu0YxA3/ji0S2/lqJQEnrOlfysLSsdNfw3McNVluSE9epl8N/2Z0qG 427x94dOOXFIWf5tQzc7WOYdVI/JSerJkMPutOThew== X-Google-Smtp-Source: AGHT+IFlvxXC5TE5auDkzGipxwETeZ8JnKAa47UPmrKiIe2mKiF+REikFN6qCk/43O/2LJaQMRKjcg== X-Received: by 2002:a19:4f49:0:b0:50e:2222:6ca3 with SMTP id a9-20020a194f49000000b0050e22226ca3mr175189lfk.90.1702662126180; Fri, 15 Dec 2023 09:42:06 -0800 (PST) Received: from eriador.lumag.spb.ru (85-76-13-188-nat.elisa-mobile.fi. [85.76.13.188]) by smtp.gmail.com with ESMTPSA id c16-20020a056512239000b0050dff5bb793sm1389263lfv.143.2023.12.15.09.42.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 09:42:05 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 7/7] arm64: dts: qcom: sm8150-hdk: enable DisplayPort and USB-C altmode Date: Fri, 15 Dec 2023 19:40:39 +0200 Message-ID: <20231215174152.315403-8-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> References: <20231215174152.315403-1-dmitry.baryshkov@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Enable the USB-C related functionality for the USB-C port on this board. This includes OTG, PowerDelivery and DP AltMode. Also enable the DisplayPort itself. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/sm8150-hdk.dts | 124 +++++++++++++++++++++++- 1 file changed, 123 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/sm8150-hdk.dts b/arch/arm64/boot/dts/qcom/sm8150-hdk.dts index ea4d75308ac8..de670b407ef1 100644 --- a/arch/arm64/boot/dts/qcom/sm8150-hdk.dts +++ b/arch/arm64/boot/dts/qcom/sm8150-hdk.dts @@ -7,6 +7,7 @@ #include #include +#include #include "sm8150.dtsi" #include "pm8150.dtsi" #include "pm8150b.dtsi" @@ -374,6 +375,10 @@ &gmu { status = "okay"; }; +&gpi_dma0 { + status = "okay"; +}; + &gpi_dma1 { status = "okay"; }; @@ -382,6 +387,29 @@ &gpu { status = "okay"; }; +&i2c4 { + clock-frequency = <100000>; + + status = "okay"; + + typec-mux@42 { + compatible = "fcs,fsa4480"; + reg = <0x42>; + + interrupts-extended = <&tlmm 152 IRQ_TYPE_LEVEL_LOW>; + + vcc-supply = <&vreg_bob>; + mode-switch; + orientation-switch; + + port { + fsa4480_sbu_mux: endpoint { + remote-endpoint = <&pm8150b_typec_sbu_out>; + }; + }; + }; +}; + &i2c9 { status = "okay"; clock-frequency = <400000>; @@ -436,6 +464,15 @@ &mdss { status = "okay"; }; +&mdss_dp { + status = "okay"; +}; + +&mdss_dp_out { + data-lanes = <0 1>; + remote-endpoint = <&usb_1_qmpphy_dp_in>; +}; + &mdss_dsi0 { status = "okay"; vdda-supply = <&vreg_l3c_1p2>; @@ -483,6 +520,65 @@ &mdss_dsi1_phy { status = "okay"; }; +&pm8150b_vbus { + regulator-min-microamp = <500000>; + regulator-max-microamp = <3000000>; + status = "okay"; +}; + +&pm8150b_typec { + status = "okay"; + + vdd-pdphy-supply = <&vreg_l2a_3p1>; + + connector { + compatible = "usb-c-connector"; + + power-role = "source"; + data-role = "dual"; + self-powered; + + source-pdos = ; + + altmodes { + displayport { + svid = /bits/ 16 <0xff01>; + vdo = <0x00001c46>; + }; + }; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + pm8150b_role_switch_in: endpoint { + remote-endpoint = <&usb_1_dwc3_hs>; + }; + }; + + port@1 { + reg = <1>; + pm8150b_typec_mux_in: endpoint { + remote-endpoint = <&usb_1_qmpphy_out>; + }; + }; + + port@2 { + reg = <2>; + + pm8150b_typec_sbu_out: endpoint { + remote-endpoint = <&fsa4480_sbu_mux>; + }; + }; + }; + }; +}; + &pon_pwrkey { status = "okay"; }; @@ -493,6 +589,10 @@ &pon_resin { linux,code = ; }; +&qupv3_id_0 { + status = "okay"; +}; + &qupv3_id_1 { status = "okay"; }; @@ -568,6 +668,19 @@ &usb_1_qmpphy { status = "okay"; vdda-phy-supply = <&vreg_l3c_1p2>; vdda-pll-supply = <&vreg_l18a_0p8>; + orientation-switch; +}; + +&usb_1_qmpphy_dp_in { + remote-endpoint = <&mdss_dp_out>; +}; + +&usb_1_qmpphy_out { + remote-endpoint = <&pm8150b_typec_mux_in>; +}; + +&usb_1_qmpphy_usb_ss_in { + remote-endpoint = <&usb_1_dwc3_ss>; }; &usb_2_qmpphy { @@ -585,7 +698,16 @@ &usb_2 { }; &usb_1_dwc3 { - dr_mode = "peripheral"; + dr_mode = "otg"; + usb-role-switch; +}; + +&usb_1_dwc3_hs { + remote-endpoint = <&pm8150b_role_switch_in>; +}; + +&usb_1_dwc3_ss { + remote-endpoint = <&usb_1_qmpphy_usb_ss_in>; }; &usb_2_dwc3 {