linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/6] Enable Nomadik NHK15 graphics
@ 2016-09-09 21:25 Linus Walleij
  2016-09-09 21:25 ` [PATCH 1/6] ARM: dts: add STMPE PWM to the NHK15 device tree Linus Walleij
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Linus Walleij @ 2016-09-09 21:25 UTC (permalink / raw)
  To: linux-arm-kernel

As all other pieces have been merged into the PWM and fbdev
subsystems, we can turn on graphics on the Nomadik NHK15
board.

Tested and works like a charm with boot penguin, console if
desired and fbsplash. Even blanks the screen properly to save
energy.

The missing DT bindings should probably have been merged in
the fbdev tree, but it doesn't matter where they are merged
so I plan to send this whole series as a pull request to
ARM SoC. The only non-DT change is the Kconfig change to
select MFD_SYSCON.

Linus Walleij (6):
  ARM: dts: add STMPE PWM to the NHK15 device tree
  dt-bindings: add vendor TPO
  dt-bindings: Add TPO TPG110 binding
  ARM: nomadik: select MFD_SYSCON
  ARM: dts: add PMU to the NHK15 device tree
  ARM: dts: add the CLCD LCD display to the NHK15

 .../bindings/display/panel/tpo,tpg110.txt          | 47 +++++++++++++++
 .../devicetree/bindings/vendor-prefixes.txt        |  1 +
 arch/arm/boot/dts/ste-nomadik-nhk15.dts            | 68 ++++++++++++++++++++++
 arch/arm/boot/dts/ste-nomadik-stn8815.dtsi         | 28 +++++++++
 arch/arm/mach-nomadik/Kconfig                      |  1 +
 5 files changed, 145 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt

-- 
2.7.4


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

* [PATCH 1/6] ARM: dts: add STMPE PWM to the NHK15 device tree
  2016-09-09 21:25 [PATCH 0/6] Enable Nomadik NHK15 graphics Linus Walleij
@ 2016-09-09 21:25 ` Linus Walleij
  2016-09-09 21:25 ` [PATCH 2/6] dt-bindings: add vendor TPO Linus Walleij
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: Linus Walleij @ 2016-09-09 21:25 UTC (permalink / raw)
  To: linux-arm-kernel

This adds the STMPE PWM to the NHK15 device tree.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 arch/arm/boot/dts/ste-nomadik-nhk15.dts | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/arch/arm/boot/dts/ste-nomadik-nhk15.dts b/arch/arm/boot/dts/ste-nomadik-nhk15.dts
index d35aa88791ad..3ec5c653ad56 100644
--- a/arch/arm/boot/dts/ste-nomadik-nhk15.dts
+++ b/arch/arm/boot/dts/ste-nomadik-nhk15.dts
@@ -140,6 +140,10 @@
 						0x03020067 // Up
 						0x0303006c>; // Down
 			};
+			stmpe0_pwm: stmpe_pwm {
+				compatible = "st,stmpe-pwm";
+				#pwm-cells = <2>;
+			};
 		};
 		stmpe1: stmpe2401@44 {
 			compatible = "st,stmpe2401";
@@ -183,4 +187,24 @@
 			wp-gpios = <&stmpe_gpio44 18 GPIO_ACTIVE_HIGH>;
 		};
 	};
+
+	bl: backlight {
+		compatible = "pwm-backlight";
+		pwms = <&stmpe0_pwm 0 500000>;
+		pwm-names = "backlight";
+		brightness-levels = <
+			0  1  2  3  4  5  6  7  8  9
+			10 11 12 13 14 15 16 17 18 19
+			20 21 22 23 24 25 26 27 28 29
+			30 31 32 33 34 35 36 37 38 39
+			40 41 42 43 44 45 46 47 48 49
+			50 51 52 53 54 55 56 57 58 59
+			60 61 62 63 64 65 66 67 68 69
+			70 71 72 73 74 75 76 77 78 79
+			80 81 82 83 84 85 86 87 88 89
+			90 91 92 93 94 95 96 97 98 99
+			100
+		>;
+		default-brightness-level = <100>;
+	};
 };
-- 
2.7.4


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

* [PATCH 2/6] dt-bindings: add vendor TPO
  2016-09-09 21:25 [PATCH 0/6] Enable Nomadik NHK15 graphics Linus Walleij
  2016-09-09 21:25 ` [PATCH 1/6] ARM: dts: add STMPE PWM to the NHK15 device tree Linus Walleij
@ 2016-09-09 21:25 ` Linus Walleij
  2016-09-09 21:25 ` [PATCH 3/6] dt-bindings: Add TPO TPG110 binding Linus Walleij
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: Linus Walleij @ 2016-09-09 21:25 UTC (permalink / raw)
  To: linux-arm-kernel

TPO was a merger on June 5 2006 of Toppoly Optoelectronics and
Philips Mobile Display Systems. They manufactured small and medium
mobile displays.

Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 Documentation/devicetree/bindings/vendor-prefixes.txt | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt b/Documentation/devicetree/bindings/vendor-prefixes.txt
index 1992aa97d45a..65b7bbbc893f 100644
--- a/Documentation/devicetree/bindings/vendor-prefixes.txt
+++ b/Documentation/devicetree/bindings/vendor-prefixes.txt
@@ -270,6 +270,7 @@ toshiba	Toshiba Corporation
 toumaz	Toumaz
 tplink	TP-LINK Technologies Co., Ltd.
 tpk	TPK U.S.A. LLC
+tpo	TPO
 tronfy	Tronfy
 tronsmart	Tronsmart
 truly	Truly Semiconductors Limited
-- 
2.7.4


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

* [PATCH 3/6] dt-bindings: Add TPO TPG110 binding
  2016-09-09 21:25 [PATCH 0/6] Enable Nomadik NHK15 graphics Linus Walleij
  2016-09-09 21:25 ` [PATCH 1/6] ARM: dts: add STMPE PWM to the NHK15 device tree Linus Walleij
  2016-09-09 21:25 ` [PATCH 2/6] dt-bindings: add vendor TPO Linus Walleij
@ 2016-09-09 21:25 ` Linus Walleij
  2016-09-09 21:25 ` [PATCH 4/6] ARM: nomadik: select MFD_SYSCON Linus Walleij
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: Linus Walleij @ 2016-09-09 21:25 UTC (permalink / raw)
  To: linux-arm-kernel

This adds device tree bindings for the TPO TPG110 panel found
mounted in the Nomadik NHK8815.

Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 .../bindings/display/panel/tpo,tpg110.txt          | 47 ++++++++++++++++++++++
 1 file changed, 47 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt

diff --git a/Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt b/Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt
new file mode 100644
index 000000000000..f5e3c6f2095a
--- /dev/null
+++ b/Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt
@@ -0,0 +1,47 @@
+TPO TPG110 Panel
+========
+
+This binding builds on the DPI bindings, adding a few properties
+as a superset of a DPI. See panel-dpi.txt for the required DPI
+bindings.
+
+Required properties:
+- compatible : "tpo,tpg110"
+- grestb-gpios : panel reset GPIO
+- scen-gpios : serial control enable GPIO
+- scl-gpios : serial control clock line GPIO
+- sda-gpios : serial control data line GPIO
+
+Required nodes:
+- Video port for DPI input, see panel-dpi.txt
+- Panel timing for DPI setup, see panel-dpi.txt
+
+Example
+-------
+
+panel {
+	compatible = "tpo,tpg110", "panel-dpi";
+	grestb-gpios = <&stmpe_gpio44 5 GPIO_ACTIVE_LOW>;
+	scen-gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+	scl-gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+	sda-gpios = <&gpio0 4 GPIO_ACTIVE_HIGH>;
+	backlight = <&bl>;
+
+	port {
+		nomadik_clcd_panel: endpoint {
+			remote-endpoint = <&nomadik_clcd_pads>;
+		};
+	};
+
+	panel-timing {
+		clock-frequency = <33200000>;
+		hactive = <800>;
+		hback-porch = <216>;
+		hfront-porch = <40>;
+		hsync-len = <1>;
+		vactive = <480>;
+		vback-porch = <35>;
+		vfront-porch = <10>;
+		vsync-len = <1>;
+	};
+};
-- 
2.7.4


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

* [PATCH 4/6] ARM: nomadik: select MFD_SYSCON
  2016-09-09 21:25 [PATCH 0/6] Enable Nomadik NHK15 graphics Linus Walleij
                   ` (2 preceding siblings ...)
  2016-09-09 21:25 ` [PATCH 3/6] dt-bindings: Add TPO TPG110 binding Linus Walleij
@ 2016-09-09 21:25 ` Linus Walleij
  2016-09-09 21:25 ` [PATCH 5/6] ARM: dts: add PMU to the NHK15 device tree Linus Walleij
  2016-09-09 21:25 ` [PATCH 6/6] ARM: dts: add the CLCD LCD display to the NHK15 Linus Walleij
  5 siblings, 0 replies; 7+ messages in thread
From: Linus Walleij @ 2016-09-09 21:25 UTC (permalink / raw)
  To: linux-arm-kernel

Since the Power Management Unit is using syscon to access a
set of necessary hardware muxing, let's select MFD_SYSCON for
the Nomadik subarchitecture.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 arch/arm/mach-nomadik/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/mach-nomadik/Kconfig b/arch/arm/mach-nomadik/Kconfig
index b7e9801fdaa4..3ae45b8d7b0a 100644
--- a/arch/arm/mach-nomadik/Kconfig
+++ b/arch/arm/mach-nomadik/Kconfig
@@ -7,6 +7,7 @@ menuconfig ARCH_NOMADIK
 	select CLKSRC_NOMADIK_MTU_SCHED_CLOCK
 	select CPU_ARM926T
 	select GPIOLIB
+	select MFD_SYSCON
 	select MIGHT_HAVE_CACHE_L2X0
 	select PINCTRL
 	select PINCTRL_NOMADIK
-- 
2.7.4


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

* [PATCH 5/6] ARM: dts: add PMU to the NHK15 device tree
  2016-09-09 21:25 [PATCH 0/6] Enable Nomadik NHK15 graphics Linus Walleij
                   ` (3 preceding siblings ...)
  2016-09-09 21:25 ` [PATCH 4/6] ARM: nomadik: select MFD_SYSCON Linus Walleij
@ 2016-09-09 21:25 ` Linus Walleij
  2016-09-09 21:25 ` [PATCH 6/6] ARM: dts: add the CLCD LCD display to the NHK15 Linus Walleij
  5 siblings, 0 replies; 7+ messages in thread
From: Linus Walleij @ 2016-09-09 21:25 UTC (permalink / raw)
  To: linux-arm-kernel

The so-called Nomadik Power Mangament Unit is actually a set
of some power management registers and some miscellaneous
system control stuff like muxing of entire hardware units.
Add this as a system controller.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 arch/arm/boot/dts/ste-nomadik-stn8815.dtsi | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi b/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
index d2d532a9d783..80a3c9ccccd9 100644
--- a/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
+++ b/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
@@ -168,6 +168,12 @@
 		};
 	};
 
+	/* Power Management Unit */
+	pmu: pmu@101e9000 {
+		compatible = "stericsson,nomadik-pmu", "syscon";
+		reg = <0x101e0000 0x1000>;
+	};
+
 	src: src@101e0000 {
 		compatible = "stericsson,nomadik-src";
 		reg = <0x101e0000 0x1000>;
-- 
2.7.4


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

* [PATCH 6/6] ARM: dts: add the CLCD LCD display to the NHK15
  2016-09-09 21:25 [PATCH 0/6] Enable Nomadik NHK15 graphics Linus Walleij
                   ` (4 preceding siblings ...)
  2016-09-09 21:25 ` [PATCH 5/6] ARM: dts: add PMU to the NHK15 device tree Linus Walleij
@ 2016-09-09 21:25 ` Linus Walleij
  5 siblings, 0 replies; 7+ messages in thread
From: Linus Walleij @ 2016-09-09 21:25 UTC (permalink / raw)
  To: linux-arm-kernel

This adds the TPG110 TDO43MTEA2 24-bit RGB LCD panel and sets
up the Nomadik device tree to activate the CLCD and connect it
to this panel.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 arch/arm/boot/dts/ste-nomadik-nhk15.dts    | 44 ++++++++++++++++++++++++++++++
 arch/arm/boot/dts/ste-nomadik-stn8815.dtsi | 22 +++++++++++++++
 2 files changed, 66 insertions(+)

diff --git a/arch/arm/boot/dts/ste-nomadik-nhk15.dts b/arch/arm/boot/dts/ste-nomadik-nhk15.dts
index 3ec5c653ad56..1ec46a794a4d 100644
--- a/arch/arm/boot/dts/ste-nomadik-nhk15.dts
+++ b/arch/arm/boot/dts/ste-nomadik-nhk15.dts
@@ -176,6 +176,50 @@
 	};
 
 	amba {
+		clcd@10120000 {
+			status = "okay";
+			pinctrl-names = "default";
+			pinctrl-0 = <&clcd_24bit_mux>;
+			port {
+				nomadik_clcd_pads: endpoint {
+					remote-endpoint = <&nomadik_clcd_panel>;
+					arm,pl11x,tft-r0g0b0-pads = <16 8 0>;
+				};
+			};
+
+			/*
+			 * WVGA connector 21
+			 * WVGA (800x480): 4.3" TPG110 TDO43MTEA2 24-bit RGB
+			 * with TPO touch screen.
+			 */
+			panel {
+				compatible = "tpo,tpg110", "panel-dpi";
+				grestb-gpios = <&stmpe_gpio44 5 GPIO_ACTIVE_LOW>;
+				scen-gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+				scl-gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+				sda-gpios = <&gpio0 4 GPIO_ACTIVE_HIGH>;
+				backlight = <&bl>;
+
+				port {
+					nomadik_clcd_panel: endpoint {
+						remote-endpoint = <&nomadik_clcd_pads>;
+					};
+				};
+
+				panel-timing {
+					clock-frequency = <33200000>;
+					hactive = <800>;
+					hback-porch = <216>;
+					hfront-porch = <40>;
+					hsync-len = <1>;
+					vactive = <480>;
+					vback-porch = <35>;
+					vfront-porch = <10>;
+					vsync-len = <1>;
+				};
+			};
+		};
+
 		/* Activate RX/TX and CTS/RTS on UART 0 */
 		uart0: uart@101fd000 {
 			pinctrl-names = "default";
diff --git a/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi b/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
index 80a3c9ccccd9..adb1c0998b81 100644
--- a/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
+++ b/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
@@ -166,6 +166,18 @@
 				};
 			};
 		};
+		clcd {
+			/*
+			 * This should be activated to use the additional
+			 * 8 lines for bits 16 thru 23 from the CLCD block.
+			 */
+			clcd_24bit_mux: clcd_mux {
+				clcd_24bit_mux {
+					function = "clcd";
+					groups = "clcd_16_23_b_1";
+				};
+			};
+		};
 	};
 
 	/* Power Management Unit */
@@ -732,6 +744,16 @@
 		#size-cells = <1>;
 		ranges;
 
+		clcd@10120000 {
+			compatible = "arm,pl110", "arm,primecell";
+			reg = <0x10120000 0x1000>;
+			interrupt-names = "combined";
+			interrupts = <14>;
+			clocks = <&clcdclk>, <&hclkclcd>;
+			clock-names = "clcdclk", "apb_pclk";
+			status = "disabled";
+		};
+
 		vica: intc@10140000 {
 			compatible = "arm,versatile-vic";
 			interrupt-controller;
-- 
2.7.4


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

end of thread, other threads:[~2016-09-09 21:25 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-09 21:25 [PATCH 0/6] Enable Nomadik NHK15 graphics Linus Walleij
2016-09-09 21:25 ` [PATCH 1/6] ARM: dts: add STMPE PWM to the NHK15 device tree Linus Walleij
2016-09-09 21:25 ` [PATCH 2/6] dt-bindings: add vendor TPO Linus Walleij
2016-09-09 21:25 ` [PATCH 3/6] dt-bindings: Add TPO TPG110 binding Linus Walleij
2016-09-09 21:25 ` [PATCH 4/6] ARM: nomadik: select MFD_SYSCON Linus Walleij
2016-09-09 21:25 ` [PATCH 5/6] ARM: dts: add PMU to the NHK15 device tree Linus Walleij
2016-09-09 21:25 ` [PATCH 6/6] ARM: dts: add the CLCD LCD display to the NHK15 Linus Walleij

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