diff mbox series

arm64: dts: qcom: sc8280xp: make dispcc cast minimal vote on MMCX

Message ID 20240226211123.4192907-1-dmitry.baryshkov@linaro.org
State New
Headers show
Series arm64: dts: qcom: sc8280xp: make dispcc cast minimal vote on MMCX | expand

Commit Message

Dmitry Baryshkov Feb. 26, 2024, 9:11 p.m. UTC
Add required-opps property to the display clock controller. This makes
it cast minimal vote on the MMCX lane to prevents resets caused by the
DisplayPort / panel probing.

Fixes: 57d6ef683a15 ("arm64: dts: qcom: sc8280xp: Define some of the display blocks")
Cc: Johan Hovold <johan+linaro@kernel.org>
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
---
 arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 2 ++
 1 file changed, 2 insertions(+)

Comments

Konrad Dybcio Feb. 26, 2024, 9:52 p.m. UTC | #1
On 2/26/24 22:11, Dmitry Baryshkov wrote:
> Add required-opps property to the display clock controller. This makes
> it cast minimal vote on the MMCX lane to prevents resets caused by the
> DisplayPort / panel probing.
> 
> Fixes: 57d6ef683a15 ("arm64: dts: qcom: sc8280xp: Define some of the display blocks")
> Cc: Johan Hovold <johan+linaro@kernel.org>
> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> ---

Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>

Konrad
Bjorn Andersson Feb. 27, 2024, 1:51 a.m. UTC | #2
On Mon, Feb 26, 2024 at 11:11:23PM +0200, Dmitry Baryshkov wrote:
> Add required-opps property to the display clock controller. This makes
> it cast minimal vote on the MMCX lane to prevents resets caused by the
> DisplayPort / panel probing.
> 

Interesting wording, this is exactly what e3e56c050ab6 ("soc: qcom:
rpmhpd: Make power_on actually enable the domain") was supposed to do
(cast minimal enabled vote).

And sure enough, there's a bug in my patch:
https://lore.kernel.org/linux-arm-msm/20240226-rpmhpd-enable-corner-fix-v1-1-68c004cec48c@quicinc.com/T/#u

Regards,
Bjorn

> Fixes: 57d6ef683a15 ("arm64: dts: qcom: sc8280xp: Define some of the display blocks")
> Cc: Johan Hovold <johan+linaro@kernel.org>
> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> ---
>  arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
> index febf28356ff8..ec85c81f65cd 100644
> --- a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
> @@ -3938,6 +3938,7 @@ dispcc0: clock-controller@af00000 {
>  				 <0>,
>  				 <0>;
>  			power-domains = <&rpmhpd SC8280XP_MMCX>;
> +			required-opps = <&rpmhpd_opp_low_svs>;
>  
>  			#clock-cells = <1>;
>  			#power-domain-cells = <1>;
> @@ -5034,6 +5035,7 @@ dispcc1: clock-controller@22100000 {
>  				 <0>,
>  				 <0>;
>  			power-domains = <&rpmhpd SC8280XP_MMCX>;
> +			required-opps = <&rpmhpd_opp_low_svs>;
>  
>  			#clock-cells = <1>;
>  			#power-domain-cells = <1>;
> -- 
> 2.39.2
>
Johan Hovold Feb. 27, 2024, 9:55 a.m. UTC | #3
On Mon, Feb 26, 2024 at 07:51:05PM -0600, Bjorn Andersson wrote:
> On Mon, Feb 26, 2024 at 11:11:23PM +0200, Dmitry Baryshkov wrote:
> > Add required-opps property to the display clock controller. This makes
> > it cast minimal vote on the MMCX lane to prevents resets caused by the
> > DisplayPort / panel probing.
> > 
> 
> Interesting wording, this is exactly what e3e56c050ab6 ("soc: qcom:
> rpmhpd: Make power_on actually enable the domain") was supposed to do
> (cast minimal enabled vote).
> 
> And sure enough, there's a bug in my patch:
> https://lore.kernel.org/linux-arm-msm/20240226-rpmhpd-enable-corner-fix-v1-1-68c004cec48c@quicinc.com/T/#u

I've confirmed that Bjorn's patch fixes the hard resets I've seen at
boot.

I assume this patch should be discarded (and eventually also all the
related DT workarounds we have for this).

Johan
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
index febf28356ff8..ec85c81f65cd 100644
--- a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
@@ -3938,6 +3938,7 @@  dispcc0: clock-controller@af00000 {
 				 <0>,
 				 <0>;
 			power-domains = <&rpmhpd SC8280XP_MMCX>;
+			required-opps = <&rpmhpd_opp_low_svs>;
 
 			#clock-cells = <1>;
 			#power-domain-cells = <1>;
@@ -5034,6 +5035,7 @@  dispcc1: clock-controller@22100000 {
 				 <0>,
 				 <0>;
 			power-domains = <&rpmhpd SC8280XP_MMCX>;
+			required-opps = <&rpmhpd_opp_low_svs>;
 
 			#clock-cells = <1>;
 			#power-domain-cells = <1>;