linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller
@ 2022-02-08  4:16 Bjorn Andersson
  2022-02-08  4:16 ` [PATCH 2/2] arm64: dts: qcom: c630: Move panel to aux-bus Bjorn Andersson
  2022-02-08 12:35 ` [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller Steev Klimaszewski
  0 siblings, 2 replies; 4+ messages in thread
From: Bjorn Andersson @ 2022-02-08  4:16 UTC (permalink / raw)
  To: Bjorn Andersson, Steev Klimaszewski
  Cc: Rob Herring, linux-arm-msm, devicetree, linux-kernel

The Lenovo Yoga C630 uses the PWM controller in the TI SN65DSI86 bridge
chip to provide a signal for the backlight control and has TLMM GPIO 11
attached to some regulator that drives the backlight.

Unfortunately the regulator attached to this gpio is also powering the
camera, so turning off backlight result in the detachment of the camera
as well.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
---
 arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
index 58845a14805f..55fb7302245b 100644
--- a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
+++ b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
@@ -59,6 +59,7 @@ mode {
 	panel {
 		compatible = "boe,nv133fhm-n61";
 		no-hpd;
+		backlight = <&backlight>;
 
 		ports {
 			port {
@@ -98,6 +99,12 @@ sn65dsi86_refclk: sn65dsi86-refclk {
 
 		clock-frequency = <19200000>;
 	};
+
+	backlight: backlight {
+		compatible = "pwm-backlight";
+		pwms = <&sn65dsi86 1000000>;
+		enable-gpios = <&tlmm 11 GPIO_ACTIVE_HIGH>;
+	};
 };
 
 &adsp_pas {
@@ -419,6 +426,7 @@ sn65dsi86: bridge@2c {
 		clock-names = "refclk";
 
 		no-hpd;
+		#pwm-cells = <1>;
 
 		ports {
 			#address-cells = <1>;
-- 
2.32.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 2/2] arm64: dts: qcom: c630: Move panel to aux-bus
  2022-02-08  4:16 [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller Bjorn Andersson
@ 2022-02-08  4:16 ` Bjorn Andersson
  2022-02-08 12:35   ` Steev Klimaszewski
  2022-02-08 12:35 ` [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller Steev Klimaszewski
  1 sibling, 1 reply; 4+ messages in thread
From: Bjorn Andersson @ 2022-02-08  4:16 UTC (permalink / raw)
  To: Bjorn Andersson, Steev Klimaszewski
  Cc: Rob Herring, linux-arm-msm, devicetree, linux-kernel

With the newly introduced aux-bus under the TI SN65DSI86 the panel
node should be described as a child instead of a standalone node, move
it there.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
---
 .../boot/dts/qcom/sdm850-lenovo-yoga-c630.dts | 27 +++++++++----------
 1 file changed, 13 insertions(+), 14 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
index 55fb7302245b..fd1261901ab5 100644
--- a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
+++ b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
@@ -56,20 +56,6 @@ mode {
 		};
 	};
 
-	panel {
-		compatible = "boe,nv133fhm-n61";
-		no-hpd;
-		backlight = <&backlight>;
-
-		ports {
-			port {
-				panel_in_edp: endpoint {
-					remote-endpoint = <&sn65dsi86_out>;
-				};
-			};
-		};
-	};
-
 	/* Reserved memory changes for IPA */
 	reserved-memory {
 		wlan_msa_mem: memory@8c400000 {
@@ -446,6 +432,19 @@ sn65dsi86_out: endpoint {
 				};
 			};
 		};
+
+		aux-bus {
+			panel: panel {
+				compatible = "boe,nv133fhm-n61";
+				backlight = <&backlight>;
+
+				port {
+					panel_in_edp: endpoint {
+						remote-endpoint = <&sn65dsi86_out>;
+					};
+				};
+			};
+		};
 	};
 };
 
-- 
2.32.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller
  2022-02-08  4:16 [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller Bjorn Andersson
  2022-02-08  4:16 ` [PATCH 2/2] arm64: dts: qcom: c630: Move panel to aux-bus Bjorn Andersson
@ 2022-02-08 12:35 ` Steev Klimaszewski
  1 sibling, 0 replies; 4+ messages in thread
From: Steev Klimaszewski @ 2022-02-08 12:35 UTC (permalink / raw)
  To: Bjorn Andersson; +Cc: Rob Herring, linux-arm-msm, devicetree, linux-kernel


On 2/7/22 10:16 PM, Bjorn Andersson wrote:
> The Lenovo Yoga C630 uses the PWM controller in the TI SN65DSI86 bridge
> chip to provide a signal for the backlight control and has TLMM GPIO 11
> attached to some regulator that drives the backlight.
>
> Unfortunately the regulator attached to this gpio is also powering the
> camera, so turning off backlight result in the detachment of the camera
> as well.
>
> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
> ---
>   arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts | 8 ++++++++
>   1 file changed, 8 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> index 58845a14805f..55fb7302245b 100644
> --- a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> +++ b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> @@ -59,6 +59,7 @@ mode {
>   	panel {
>   		compatible = "boe,nv133fhm-n61";
>   		no-hpd;
> +		backlight = <&backlight>;
>   
>   		ports {
>   			port {
> @@ -98,6 +99,12 @@ sn65dsi86_refclk: sn65dsi86-refclk {
>   
>   		clock-frequency = <19200000>;
>   	};
> +
> +	backlight: backlight {
> +		compatible = "pwm-backlight";
> +		pwms = <&sn65dsi86 1000000>;
> +		enable-gpios = <&tlmm 11 GPIO_ACTIVE_HIGH>;
> +	};
>   };
>   
>   &adsp_pas {
> @@ -419,6 +426,7 @@ sn65dsi86: bridge@2c {
>   		clock-names = "refclk";
>   
>   		no-hpd;
> +		#pwm-cells = <1>;
>   
>   		ports {
>   			#address-cells = <1>;
Tested-by: Steev Klimaszewski <steev@kali.org>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/2] arm64: dts: qcom: c630: Move panel to aux-bus
  2022-02-08  4:16 ` [PATCH 2/2] arm64: dts: qcom: c630: Move panel to aux-bus Bjorn Andersson
@ 2022-02-08 12:35   ` Steev Klimaszewski
  0 siblings, 0 replies; 4+ messages in thread
From: Steev Klimaszewski @ 2022-02-08 12:35 UTC (permalink / raw)
  To: Bjorn Andersson; +Cc: Rob Herring, linux-arm-msm, devicetree, linux-kernel


On 2/7/22 10:16 PM, Bjorn Andersson wrote:
> With the newly introduced aux-bus under the TI SN65DSI86 the panel
> node should be described as a child instead of a standalone node, move
> it there.
>
> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
> ---
>   .../boot/dts/qcom/sdm850-lenovo-yoga-c630.dts | 27 +++++++++----------
>   1 file changed, 13 insertions(+), 14 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> index 55fb7302245b..fd1261901ab5 100644
> --- a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> +++ b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts
> @@ -56,20 +56,6 @@ mode {
>   		};
>   	};
>   
> -	panel {
> -		compatible = "boe,nv133fhm-n61";
> -		no-hpd;
> -		backlight = <&backlight>;
> -
> -		ports {
> -			port {
> -				panel_in_edp: endpoint {
> -					remote-endpoint = <&sn65dsi86_out>;
> -				};
> -			};
> -		};
> -	};
> -
>   	/* Reserved memory changes for IPA */
>   	reserved-memory {
>   		wlan_msa_mem: memory@8c400000 {
> @@ -446,6 +432,19 @@ sn65dsi86_out: endpoint {
>   				};
>   			};
>   		};
> +
> +		aux-bus {
> +			panel: panel {
> +				compatible = "boe,nv133fhm-n61";
> +				backlight = <&backlight>;
> +
> +				port {
> +					panel_in_edp: endpoint {
> +						remote-endpoint = <&sn65dsi86_out>;
> +					};
> +				};
> +			};
> +		};
>   	};
>   };
>   
Tested-by: Steev Klimaszewski <steev@kali.org>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-02-08 13:22 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-08  4:16 [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller Bjorn Andersson
2022-02-08  4:16 ` [PATCH 2/2] arm64: dts: qcom: c630: Move panel to aux-bus Bjorn Andersson
2022-02-08 12:35   ` Steev Klimaszewski
2022-02-08 12:35 ` [PATCH 1/2] arm64: dts: qcom: c630: Add backlight controller Steev Klimaszewski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).