From: Martin Cerveny <m.cerveny@computer.org>
To: u-boot@lists.denx.de
Subject: [PATCH 4/5] arm: dts: v3s: Add support for simple-framebuffer with DE2/TCON
Date: Wed, 16 Sep 2020 16:10:51 +0200 [thread overview]
Message-ID: <20200916141052.4808-5-m.cerveny@computer.org> (raw)
In-Reply-To: <20200916141052.4808-1-m.cerveny@computer.org>
Add support for DE2 and TCON connected LCD display.
Add support for export as "allwinner,simple-framebuffer"
with "mixer0-lcd0" pipeline.
Signed-off-by: Martin Cerveny <m.cerveny@computer.org>
---
arch/arm/dts/sun8i-v3s.dtsi | 128 ++++++++++++++++++++++++++++++++++--
1 file changed, 124 insertions(+), 4 deletions(-)
diff --git a/arch/arm/dts/sun8i-v3s.dtsi b/arch/arm/dts/sun8i-v3s.dtsi
index ebefc0fefe..59ad5945a1 100644
--- a/arch/arm/dts/sun8i-v3s.dtsi
+++ b/arch/arm/dts/sun8i-v3s.dtsi
@@ -44,12 +44,28 @@
#include <dt-bindings/reset/sun8i-v3s-ccu.h>
#include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
+#include <dt-bindings/clock/sun8i-de2.h>
/ {
#address-cells = <1>;
#size-cells = <1>;
interrupt-parent = <&gic>;
+ chosen {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ ranges;
+
+ framebuffer-lcd {
+ compatible = "allwinner,simple-framebuffer",
+ "simple-framebuffer";
+ allwinner,pipeline = "mixer0-lcd0";
+ clocks = <&display_clocks CLK_MIXER0>,
+ <&ccu CLK_TCON0>;
+ status = "disabled";
+ };
+ };
+
cpus {
#address-cells = <1>;
#size-cells = <0>;
@@ -90,12 +106,90 @@
};
};
+ de: display-engine {
+ compatible = "allwinner,sun8i-v3s-display-engine";
+ allwinner,pipelines = <&mixer0>;
+ status = "disabled";
+ };
+
soc {
compatible = "simple-bus";
#address-cells = <1>;
#size-cells = <1>;
ranges;
+ display_clocks: clock at 1000000 {
+ compatible = "allwinner,sun8i-v3s-de2-clk";
+ reg = <0x01000000 0x10000>;
+ clocks = <&ccu CLK_BUS_DE>,
+ <&ccu CLK_DE>;
+ clock-names = "bus",
+ "mod";
+ resets = <&ccu RST_BUS_DE>;
+ #clock-cells = <1>;
+ #reset-cells = <1>;
+ };
+
+ mixer0: mixer at 1100000 {
+ compatible = "allwinner,sun8i-v3s-de2-mixer";
+ reg = <0x01100000 0x100000>;
+ clocks = <&display_clocks 0>,
+ <&display_clocks 6>;
+ clock-names = "bus",
+ "mod";
+ resets = <&display_clocks 0>;
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ mixer0_out: port at 1 {
+ reg = <1>;
+
+ mixer0_out_tcon0: endpoint {
+ remote-endpoint = <&tcon0_in_mixer0>;
+ };
+ };
+ };
+ };
+
+ tcon0: lcd-controller at 1c0c000 {
+ compatible = "allwinner,sun8i-v3s-tcon";
+ reg = <0x01c0c000 0x1000>;
+ interrupts = <GIC_SPI 86 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&ccu CLK_BUS_TCON0>,
+ <&ccu CLK_TCON0>;
+ clock-names = "ahb",
+ "tcon-ch0";
+ clock-output-names = "tcon-pixel-clock";
+ #clock-cells = <0>;
+ resets = <&ccu RST_BUS_TCON0>;
+ reset-names = "lcd";
+ status = "disabled";
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ tcon0_in: port at 0 {
+ reg = <0>;
+
+ tcon0_in_mixer0: endpoint {
+ remote-endpoint = <&mixer0_out_tcon0>;
+ };
+ };
+
+ tcon0_out: port at 1 {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ reg = <1>;
+ tcon0_out_lcd: endpoint at 0 {
+ reg = <0>;
+ };
+ };
+ };
+ };
+
mmc0: mmc at 01c0f000 {
compatible = "allwinner,sun7i-a20-mmc";
reg = <0x01c0f000 0x1000>;
@@ -208,10 +302,12 @@
interrupt-controller;
#interrupt-cells = <3>;
- uart0_pins_a: uart0 at 0 {
- pins = "PB8", "PB9";
- function = "uart0";
- bias-pull-up;
+ lcd_pins: lcd-pins {
+ pins = "PE0", "PE1", "PE2", "PE3", "PE4", "PE5",
+ "PE6", "PE7", "PE8", "PE9", "PE10", "PE11",
+ "PE12", "PE13", "PE14", "PE15", "PE16", "PE17",
+ "PE18", "PE19", "PE23", "PE24";
+ function = "lcd";
};
mmc0_pins_a: mmc0 at 0 {
@@ -221,6 +317,22 @@
drive-strength = <30>;
bias-pull-up;
};
+
+ pwm0_pins: pwm0-pins {
+ pins = "PB4";
+ function = "pwm0";
+ };
+
+ pwm1_pins: pwm1-pins {
+ pins = "PB5";
+ function = "pwm1";
+ };
+
+ uart0_pins_a: uart0 at 0 {
+ pins = "PB8", "PB9";
+ function = "uart0";
+ bias-pull-up;
+ };
};
timer at 01c20c00 {
@@ -280,5 +392,13 @@
#interrupt-cells = <3>;
interrupts = <GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
};
+
+ pwm: pwm at 1c21400 {
+ compatible = "allwinner,sun7i-a20-pwm";
+ reg = <0x01c21400 0x400>;
+ clocks = <&osc24M>;
+ #pwm-cells = <3>;
+ status = "disabled";
+ };
};
};
--
2.17.1
next prev parent reply other threads:[~2020-09-16 14:10 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-16 14:10 [PATCH 0/5] sunxi: video: Add V3S simple-framebuffer Martin Cerveny
2020-09-16 14:10 ` [PATCH 1/5] sunxi: video: No double clock on DE2 Martin Cerveny
2020-09-16 14:48 ` Maxime Ripard
2020-09-16 16:25 ` Martin Cerveny
2020-09-16 20:32 ` Vasily Khoruzhick
2020-09-16 14:10 ` [PATCH 2/5] pwm: sunxi: v3s: Enable PWM0 Martin Cerveny
2020-09-16 14:10 ` [PATCH 3/5] sunxi: video: v3s: Enable LCD support Martin Cerveny
2020-09-16 14:10 ` Martin Cerveny [this message]
2020-09-16 14:50 ` [PATCH 4/5] arm: dts: v3s: Add support for simple-framebuffer with DE2/TCON Maxime Ripard
2020-09-16 15:53 ` Martin Cerveny
2020-09-21 13:05 ` Maxime Ripard
2020-09-16 14:10 ` [PATCH 5/5] sunxi: add drivers and configs needed for LCD display Martin Cerveny
2020-09-16 14:51 ` Maxime Ripard
2020-09-16 15:44 ` Martin Cerveny
2020-09-21 12:59 ` Maxime Ripard
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200916141052.4808-5-m.cerveny@computer.org \
--to=m.cerveny@computer.org \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox