linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] ARM: dts: sun5i: q8-tablet: Complete LCD panel description
@ 2019-01-27 14:48 Chen-Yu Tsai
  2019-01-27 14:48 ` [PATCH 1/5] ARM: dts: sun5i: Add backlight GPIO for reference design tablet Chen-Yu Tsai
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Chen-Yu Tsai @ 2019-01-27 14:48 UTC (permalink / raw)
  To: Maxime Ripard; +Cc: Chen-Yu Tsai, devicetree, linux-arm-kernel, linux-kernel

Hi,

This series adds the missing bits for the LCD panel of the A13 Q8
tablets. The panel and backlight were missing their enable GPIOs.
The panel can have its power supply added as well, though it is not
a complete description. See the commit log of that patch for more
details. The backlight's power supply is the unregulator output of
the PMIC, which does not have a device tree representation.

For the Q8 tablets, the backlight GPIO is driven by a GPIO pin from
the PMIC. This needs a fix in the pwm backlight driver to avoid a
runtime warning. This will be sent separately.


Please have a look.

Regards
ChenYu

Chen-Yu Tsai (5):
  ARM: dts: sun5i: Add backlight GPIO for reference design tablet
  ARM: dts: sun5i: q8-tablet: Move panel properties to correct node
    level
  ARM: dts: sun5i: q8-tablet: Add LCD Panel enable GPIO
  ARM: dts: sun5i: q8-tablet: Add LCD Panel power supply
  ARM: dts: sun5i: q8-tablet: Use bananapi,s070wv20-ct16 panel
    compatible

 arch/arm/boot/dts/sun5i-a13-q8-tablet.dts            | 7 ++++---
 arch/arm/boot/dts/sun5i-reference-design-tablet.dtsi | 2 +-
 2 files changed, 5 insertions(+), 4 deletions(-)

-- 
2.20.1


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

* [PATCH 1/5] ARM: dts: sun5i: Add backlight GPIO for reference design tablet
  2019-01-27 14:48 [PATCH 0/5] ARM: dts: sun5i: q8-tablet: Complete LCD panel description Chen-Yu Tsai
@ 2019-01-27 14:48 ` Chen-Yu Tsai
  2019-01-28 10:51   ` Maxime Ripard
  2019-01-27 14:48 ` [PATCH 2/5] ARM: dts: sun5i: q8-tablet: Move panel properties to correct node level Chen-Yu Tsai
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 11+ messages in thread
From: Chen-Yu Tsai @ 2019-01-27 14:48 UTC (permalink / raw)
  To: Maxime Ripard; +Cc: Chen-Yu Tsai, devicetree, linux-arm-kernel, linux-kernel

Now that we support the GPIOs on the AXP209, we can control the LCD
backlight with them.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm/boot/dts/sun5i-reference-design-tablet.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/sun5i-reference-design-tablet.dtsi b/arch/arm/boot/dts/sun5i-reference-design-tablet.dtsi
index 6202aabedbfe..5b1f0e198eb6 100644
--- a/arch/arm/boot/dts/sun5i-reference-design-tablet.dtsi
+++ b/arch/arm/boot/dts/sun5i-reference-design-tablet.dtsi
@@ -54,7 +54,7 @@
 		pwms = <&pwm 0 50000 PWM_POLARITY_INVERTED>;
 		brightness-levels = <0 10 20 30 40 50 60 70 80 90 100>;
 		default-brightness-level = <8>;
-		/* TODO: backlight uses axp gpio1 as enable pin */
+		enable-gpios = <&axp_gpio 1 GPIO_ACTIVE_HIGH>; /* AXP GPIO1 */
 	};
 
 	chosen {
-- 
2.20.1


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

* [PATCH 2/5] ARM: dts: sun5i: q8-tablet: Move panel properties to correct node level
  2019-01-27 14:48 [PATCH 0/5] ARM: dts: sun5i: q8-tablet: Complete LCD panel description Chen-Yu Tsai
  2019-01-27 14:48 ` [PATCH 1/5] ARM: dts: sun5i: Add backlight GPIO for reference design tablet Chen-Yu Tsai
@ 2019-01-27 14:48 ` Chen-Yu Tsai
  2019-01-28 10:52   ` Maxime Ripard
  2019-01-27 14:48 ` [PATCH 3/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel enable GPIO Chen-Yu Tsai
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 11+ messages in thread
From: Chen-Yu Tsai @ 2019-01-27 14:48 UTC (permalink / raw)
  To: Maxime Ripard; +Cc: Chen-Yu Tsai, devicetree, linux-arm-kernel, linux-kernel

The panel backlight and enable GPIO comments were incorrectly placed
in the input port, while it should have been in the panel node itself.

Move them to the correct position.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm/boot/dts/sun5i-a13-q8-tablet.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
index a89f29fa3e40..3a844dae26f7 100644
--- a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
+++ b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
@@ -50,13 +50,13 @@
 
 	panel: panel {
 		compatible = "urt,umsh-8596md-t", "simple-panel";
+		/* TODO: lcd panel uses axp gpio0 as enable pin */
+		backlight = <&backlight>;
 		#address-cells = <1>;
 		#size-cells = <0>;
 
 		port@0 {
 			reg = <0>;
-			/* TODO: lcd panel uses axp gpio0 as enable pin */
-			backlight = <&backlight>;
 			#address-cells = <1>;
 			#size-cells = <0>;
 
-- 
2.20.1


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

* [PATCH 3/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel enable GPIO
  2019-01-27 14:48 [PATCH 0/5] ARM: dts: sun5i: q8-tablet: Complete LCD panel description Chen-Yu Tsai
  2019-01-27 14:48 ` [PATCH 1/5] ARM: dts: sun5i: Add backlight GPIO for reference design tablet Chen-Yu Tsai
  2019-01-27 14:48 ` [PATCH 2/5] ARM: dts: sun5i: q8-tablet: Move panel properties to correct node level Chen-Yu Tsai
@ 2019-01-27 14:48 ` Chen-Yu Tsai
  2019-01-28 10:52   ` Maxime Ripard
  2019-01-27 14:48 ` [PATCH 4/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel power supply Chen-Yu Tsai
  2019-01-27 14:48 ` [PATCH 5/5] ARM: dts: sun5i: q8-tablet: Use bananapi,s070wv20-ct16 panel compatible Chen-Yu Tsai
  4 siblings, 1 reply; 11+ messages in thread
From: Chen-Yu Tsai @ 2019-01-27 14:48 UTC (permalink / raw)
  To: Maxime Ripard; +Cc: Chen-Yu Tsai, devicetree, linux-arm-kernel, linux-kernel

Now that we support the AXP209 GPIOs, we can toggle the LCD panel enable
line. Add the GPIO phandle to the panel.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm/boot/dts/sun5i-a13-q8-tablet.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
index 3a844dae26f7..ead159f89e74 100644
--- a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
+++ b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
@@ -50,7 +50,7 @@
 
 	panel: panel {
 		compatible = "urt,umsh-8596md-t", "simple-panel";
-		/* TODO: lcd panel uses axp gpio0 as enable pin */
+		enable-gpios = <&axp_gpio 0 GPIO_ACTIVE_HIGH>; /* AXP GPIO0 */
 		backlight = <&backlight>;
 		#address-cells = <1>;
 		#size-cells = <0>;
-- 
2.20.1


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

* [PATCH 4/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel power supply
  2019-01-27 14:48 [PATCH 0/5] ARM: dts: sun5i: q8-tablet: Complete LCD panel description Chen-Yu Tsai
                   ` (2 preceding siblings ...)
  2019-01-27 14:48 ` [PATCH 3/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel enable GPIO Chen-Yu Tsai
@ 2019-01-27 14:48 ` Chen-Yu Tsai
  2019-01-28 10:53   ` Maxime Ripard
  2019-01-27 14:48 ` [PATCH 5/5] ARM: dts: sun5i: q8-tablet: Use bananapi,s070wv20-ct16 panel compatible Chen-Yu Tsai
  4 siblings, 1 reply; 11+ messages in thread
From: Chen-Yu Tsai @ 2019-01-27 14:48 UTC (permalink / raw)
  To: Maxime Ripard; +Cc: Chen-Yu Tsai, devicetree, linux-arm-kernel, linux-kernel

The A13 Q8 tablet, following the A13 reference tablet design, has the
system's fixed 3.3V rail feed the VCC supply of the LCD panel.
Additional voltage rails used by the panel are generated using a
regulator fed from the unregulated IPSOUT output of the PMIC. The latter
is unrepresentable in the device tree. Both are controlled with MOSFETs
by the enable GPIO added in the previous patch. The actual enable or
reset pin for the panel is tied directly to LCD-VCC after the MOSFET.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm/boot/dts/sun5i-a13-q8-tablet.dts | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
index ead159f89e74..c77c0758145a 100644
--- a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
+++ b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
@@ -50,6 +50,7 @@
 
 	panel: panel {
 		compatible = "urt,umsh-8596md-t", "simple-panel";
+		power-supply = <&reg_vcc3v3>;
 		enable-gpios = <&axp_gpio 0 GPIO_ACTIVE_HIGH>; /* AXP GPIO0 */
 		backlight = <&backlight>;
 		#address-cells = <1>;
-- 
2.20.1


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

* [PATCH 5/5] ARM: dts: sun5i: q8-tablet: Use bananapi,s070wv20-ct16 panel compatible
  2019-01-27 14:48 [PATCH 0/5] ARM: dts: sun5i: q8-tablet: Complete LCD panel description Chen-Yu Tsai
                   ` (3 preceding siblings ...)
  2019-01-27 14:48 ` [PATCH 4/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel power supply Chen-Yu Tsai
@ 2019-01-27 14:48 ` Chen-Yu Tsai
  2019-01-28 10:53   ` Maxime Ripard
  4 siblings, 1 reply; 11+ messages in thread
From: Chen-Yu Tsai @ 2019-01-27 14:48 UTC (permalink / raw)
  To: Maxime Ripard; +Cc: Chen-Yu Tsai, devicetree, linux-arm-kernel, linux-kernel

The compatible string for the LCD panel used for the Q8 tablets are just
a placeholder that was shown to be compatible with the actual panels
found on these devices. The real panels do not have any identifiable
markings and vary between production runs.

The compatibe string previously used had a pixel clock that could not
be accurately reproduced on Allwinner hardware, and discussions on
whether a margin should be added to the display drivers and how large
a margin was acceptable had stalled.

Now that we have a panel model that is actually used with Allwinner
hardware, has the same dimensions, and the timings have been shown to
work with the nameless panels, we can use that one instead.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm/boot/dts/sun5i-a13-q8-tablet.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
index c77c0758145a..7257f39b31ce 100644
--- a/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
+++ b/arch/arm/boot/dts/sun5i-a13-q8-tablet.dts
@@ -49,7 +49,7 @@
 	compatible = "allwinner,q8-a13", "allwinner,sun5i-a13";
 
 	panel: panel {
-		compatible = "urt,umsh-8596md-t", "simple-panel";
+		compatible = "bananapi,s070wv20-ct16", "simple-panel";
 		power-supply = <&reg_vcc3v3>;
 		enable-gpios = <&axp_gpio 0 GPIO_ACTIVE_HIGH>; /* AXP GPIO0 */
 		backlight = <&backlight>;
-- 
2.20.1


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

* Re: [PATCH 1/5] ARM: dts: sun5i: Add backlight GPIO for reference design tablet
  2019-01-27 14:48 ` [PATCH 1/5] ARM: dts: sun5i: Add backlight GPIO for reference design tablet Chen-Yu Tsai
@ 2019-01-28 10:51   ` Maxime Ripard
  0 siblings, 0 replies; 11+ messages in thread
From: Maxime Ripard @ 2019-01-28 10:51 UTC (permalink / raw)
  To: Chen-Yu Tsai; +Cc: devicetree, linux-arm-kernel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 328 bytes --]

On Sun, Jan 27, 2019 at 10:48:34PM +0800, Chen-Yu Tsai wrote:
> Now that we support the GPIOs on the AXP209, we can control the LCD
> backlight with them.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>

Applied, thanks!
Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

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

* Re: [PATCH 2/5] ARM: dts: sun5i: q8-tablet: Move panel properties to correct node level
  2019-01-27 14:48 ` [PATCH 2/5] ARM: dts: sun5i: q8-tablet: Move panel properties to correct node level Chen-Yu Tsai
@ 2019-01-28 10:52   ` Maxime Ripard
  0 siblings, 0 replies; 11+ messages in thread
From: Maxime Ripard @ 2019-01-28 10:52 UTC (permalink / raw)
  To: Chen-Yu Tsai; +Cc: devicetree, linux-arm-kernel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 421 bytes --]

On Sun, Jan 27, 2019 at 10:48:35PM +0800, Chen-Yu Tsai wrote:
> The panel backlight and enable GPIO comments were incorrectly placed
> in the input port, while it should have been in the panel node itself.
> 
> Move them to the correct position.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>

Applied, thanks!
Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

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

* Re: [PATCH 3/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel enable GPIO
  2019-01-27 14:48 ` [PATCH 3/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel enable GPIO Chen-Yu Tsai
@ 2019-01-28 10:52   ` Maxime Ripard
  0 siblings, 0 replies; 11+ messages in thread
From: Maxime Ripard @ 2019-01-28 10:52 UTC (permalink / raw)
  To: Chen-Yu Tsai; +Cc: devicetree, linux-arm-kernel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 353 bytes --]

On Sun, Jan 27, 2019 at 10:48:36PM +0800, Chen-Yu Tsai wrote:
> Now that we support the AXP209 GPIOs, we can toggle the LCD panel enable
> line. Add the GPIO phandle to the panel.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>

Applied, thanks!
Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

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

* Re: [PATCH 4/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel power supply
  2019-01-27 14:48 ` [PATCH 4/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel power supply Chen-Yu Tsai
@ 2019-01-28 10:53   ` Maxime Ripard
  0 siblings, 0 replies; 11+ messages in thread
From: Maxime Ripard @ 2019-01-28 10:53 UTC (permalink / raw)
  To: Chen-Yu Tsai; +Cc: devicetree, linux-arm-kernel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 736 bytes --]

On Sun, Jan 27, 2019 at 10:48:37PM +0800, Chen-Yu Tsai wrote:
> The A13 Q8 tablet, following the A13 reference tablet design, has the
> system's fixed 3.3V rail feed the VCC supply of the LCD panel.
> Additional voltage rails used by the panel are generated using a
> regulator fed from the unregulated IPSOUT output of the PMIC. The latter
> is unrepresentable in the device tree. Both are controlled with MOSFETs
> by the enable GPIO added in the previous patch. The actual enable or
> reset pin for the panel is tied directly to LCD-VCC after the MOSFET.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>

Applied, thanks!
Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

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

* Re: [PATCH 5/5] ARM: dts: sun5i: q8-tablet: Use bananapi,s070wv20-ct16 panel compatible
  2019-01-27 14:48 ` [PATCH 5/5] ARM: dts: sun5i: q8-tablet: Use bananapi,s070wv20-ct16 panel compatible Chen-Yu Tsai
@ 2019-01-28 10:53   ` Maxime Ripard
  0 siblings, 0 replies; 11+ messages in thread
From: Maxime Ripard @ 2019-01-28 10:53 UTC (permalink / raw)
  To: Chen-Yu Tsai; +Cc: devicetree, linux-arm-kernel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 970 bytes --]

On Sun, Jan 27, 2019 at 10:48:38PM +0800, Chen-Yu Tsai wrote:
> The compatible string for the LCD panel used for the Q8 tablets are just
> a placeholder that was shown to be compatible with the actual panels
> found on these devices. The real panels do not have any identifiable
> markings and vary between production runs.
> 
> The compatibe string previously used had a pixel clock that could not
> be accurately reproduced on Allwinner hardware, and discussions on
> whether a margin should be added to the display drivers and how large
> a margin was acceptable had stalled.
> 
> Now that we have a panel model that is actually used with Allwinner
> hardware, has the same dimensions, and the timings have been shown to
> work with the nameless panels, we can use that one instead.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>

Applied, thanks!
Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

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

end of thread, other threads:[~2019-01-28 10:53 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-27 14:48 [PATCH 0/5] ARM: dts: sun5i: q8-tablet: Complete LCD panel description Chen-Yu Tsai
2019-01-27 14:48 ` [PATCH 1/5] ARM: dts: sun5i: Add backlight GPIO for reference design tablet Chen-Yu Tsai
2019-01-28 10:51   ` Maxime Ripard
2019-01-27 14:48 ` [PATCH 2/5] ARM: dts: sun5i: q8-tablet: Move panel properties to correct node level Chen-Yu Tsai
2019-01-28 10:52   ` Maxime Ripard
2019-01-27 14:48 ` [PATCH 3/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel enable GPIO Chen-Yu Tsai
2019-01-28 10:52   ` Maxime Ripard
2019-01-27 14:48 ` [PATCH 4/5] ARM: dts: sun5i: q8-tablet: Add LCD Panel power supply Chen-Yu Tsai
2019-01-28 10:53   ` Maxime Ripard
2019-01-27 14:48 ` [PATCH 5/5] ARM: dts: sun5i: q8-tablet: Use bananapi,s070wv20-ct16 panel compatible Chen-Yu Tsai
2019-01-28 10:53   ` Maxime Ripard

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).