ARM: dts: renesas: r8a7740/armadillo800eva: Add LCD support
Subsystems (3)
Geert Uytterhoeven
maintainerv2 cover ARM: dts: renesas: r8a7740/armadillo800eva: Add LCD support
Hi all,
This patch series adds support for the two LCD Controllers (LCDC) on the R-Mobile A1 SoC, and for the 5" WVGA TFT LCD panel on the Armadillo-800-EVA development board, using the shmobile-drm driver, which gained support for DT recently.
Changes compared to v1:
- New patch "ARM: shmobile: defconfig: Switch to DRM_SHMOBILE",
- Add Reviewed-by.
To be queued in renesas-devel for v6.8.
Thanks for your comment!
Geert Uytterhoeven (3):
ARM: shmobile: defconfig: Switch to DRM_SHMOBILE
ARM: dts: renesas: r8a7740: Add LCDC nodes
ARM: dts: renesas: armadillo800eva: Add LCD panel
.../dts/renesas/r8a7740-armadillo800eva.dts | 28 +++++++- arch/arm/boot/dts/renesas/r8a7740.dtsi | 65 +++++++++++++++++++ arch/arm/configs/shmobile_defconfig | 5 +- 3 files changed, 94 insertions(+), 4 deletions(-)
Signature · 12 lines
2.34.1
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus TorvaldsGeert Uytterhoeven
maintainerPATCH v2 1/3 ARM: shmobile: defconfig: Switch to DRM_SHMOBILE
Now the DRM driver for the SH-Mobile LCD Controller supports DT, replace the legacy frame buffer device driver by the DRM driver.
Disable frame buffer device drivers, as this was the last frame buffer device driver for Renesas ARM systems.
Enable CONFIG_DRM_FBDEV_EMULATION and CONFIG_FB_DEVICE, as these are no longer auto-enabled since commit bb6c4507fe825f1b ("drm: fix up fbdev Kconfig defaults").
---
v2:
- New.
--- arch/arm/configs/shmobile_defconfig | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
arch/arm/configs/shmobile_defconfig +3 -2
@@ -135,8 +135,10 @@ CONFIG_VIDEO_ADV7604=y CONFIG_VIDEO_ADV7604_CEC=y CONFIG_VIDEO_ML86V7667=y CONFIG_DRM=y +CONFIG_DRM_FBDEV_EMULATION=y CONFIG_DRM_RCAR_DU=y # CONFIG_DRM_RCAR_USE_MIPI_DSI is not set +CONFIG_DRM_SHMOBILE=y CONFIG_DRM_PANEL_SIMPLE=y CONFIG_DRM_PANEL_EDP=y CONFIG_DRM_DISPLAY_CONNECTOR=y
@@ -145,8 +147,7 @@ CONFIG_DRM_SII902X=y CONFIG_DRM_SIMPLE_BRIDGE=y CONFIG_DRM_I2C_ADV7511=y CONFIG_DRM_I2C_ADV7511_AUDIO=y -CONFIG_FB=y -CONFIG_FB_SH_MOBILE_LCDC=y +CONFIG_FB_DEVICE=y CONFIG_BACKLIGHT_PWM=y CONFIG_BACKLIGHT_AS3711=y CONFIG_SOUND=y
Signature · 1 line
2.34.1
Geert Uytterhoeven
maintainerPATCH v2 2/3 ARM: dts: renesas: r8a7740: Add LCDC nodes
In reply to Geert UytterhoevenAdd device nodes for the two LCD Controllers (LCDC) on the R-Mobile A1 SoC, and for the two optional external LCDL clock inputs.
Note that the HDMI clock for LCDC1 is not added, as this clock is not yet supported.
Based on a patch by Laurent Pinchart adding the first LCDC device node.
---
v2:
- No changes.
Changes compared to Laurent's original:
- Add lcdc0 label,
- Rename node from display to lcdc-controller,
- Rename compatible value from "renesas,lcdc-r8a7740" to
"renesas,r8a7740-lcdc", - Correct syntax of reg property, - Use GIC_SPI macro, - Add more clocks, - Add power-domains property, - Add status disabled, - Remove second port from lcdc0, as only lcdc1 has an HDMI port, - Add lcdc1 device node. --- arch/arm/boot/dts/renesas/r8a7740.dtsi | 65 ++++++++++++++++++++++++++ 1 file changed, 65 insertions(+)
arch/arm/boot/dts/renesas/r8a7740.dtsi +65 -0
@@ -398,6 +398,61 @@ sh_fsi2: sound@fe1f0000 { status = "disabled"; }; + lcdc0: lcd-controller@fe940000 { + compatible = "renesas,r8a7740-lcdc"; + reg = <0xfe940000 0x4000>; + interrupts = <GIC_SPI 177 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&mstp1_clks R8A7740_CLK_LCDC0>, + <&cpg_clocks R8A7740_CLK_M3>, <&lcdlclk0_clk>, + <&vou_clk>; + clock-names = "fck", "media", "lclk", "video"; + power-domains = <&pd_a4lc>; + status = "disabled"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + lcdc0_rgb: endpoint { + }; + }; + }; + }; + + lcdc1: lcd-controller@fe944000 { + compatible = "renesas,r8a7740-lcdc"; + reg = <0xfe944000 0x4000>; + interrupts = <GIC_SPI 178 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&mstp1_clks R8A7740_CLK_LCDC1>, + <&cpg_clocks R8A7740_CLK_M3>, <&lcdlclk1_clk>, + <&vou_clk>; + clock-names = "fck", "media", "lclk", "video"; + power-domains = <&pd_a4lc>; + status = "disabled"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + lcdc1_rgb: endpoint { + }; + }; + + port@1 { + reg = <1>; + + lcdc1_hdmi: endpoint { + }; + }; + }; + }; + tmu0: timer@fff80000 { compatible = "renesas,tmu-r8a7740", "renesas,tmu"; reg = <0xfff80000 0x2c>;
@@ -474,6 +529,16 @@ fsibck_clk: fsibck { #clock-cells = <0>; clock-frequency = <0>; }; + lcdlclk0_clk: lcdlclk0 { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-frequency = <0>; + }; + lcdlclk1_clk: lcdlclk1 { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-frequency = <0>; + }; /* Special CPG clocks */ cpg_clocks: cpg_clocks@e6150000 {
Signature · 1 line
2.34.1
Geert Uytterhoeven
maintainerPATCH v2 3/3 ARM: dts: renesas: armadillo800eva: Add LCD panel
In reply to Geert UytterhoevenDescribe the 5" WVGA TFT LCD panel on the Armadillo-800-EVA development board, and enable the LCD controller that drives it.
---
v2:
- Add Reviewed-by.
For proper operation, this depends on:
1. commit 410bb21319f69c2e ("drm/panel: simple: Add Ampire
AM-800480L1TMQW-T00H") in drm/drm-next,
2. Patch series "[PATCH 00/39] drm: renesas: shmobile: Atomic
conversion + DT support"
https://lore.kernel.org/r/[email protected]
3. Enabling CONFIG_DRM_SHMOBILE instead of CONFIG_FB_SH_MOBILE_LCDC.
---
.../dts/renesas/r8a7740-armadillo800eva.dts | 28 +++++++++++++++++--
1 file changed, 26 insertions(+), 2 deletions(-)arch/arm/boot/dts/renesas/r8a7740-armadillo800eva.dts +26 -2
@@ -132,7 +132,7 @@ i2c2: i2c-2 { i2c-gpio,delay-us = <5>; }; - backlight { + backlight: backlight { compatible = "pwm-backlight"; pwms = <&tpu 2 33333 PWM_POLARITY_INVERTED>; brightness-levels = <0 1 2 4 8 16 32 64 128 255>;
@@ -143,6 +143,18 @@ backlight { enable-gpios = <&pfc 61 GPIO_ACTIVE_HIGH>; }; + panel { + compatible = "ampire,am-800480l1tmqw-t00h"; + backlight = <&backlight>; + power-supply = <®_5p0v>; + + port { + panel_in: endpoint { + remote-endpoint = <&lcdc0_rgb>; + }; + }; + }; + sound { compatible = "simple-audio-card";
@@ -228,10 +240,22 @@ rtc@30 { }; }; -&pfc { +&lcdc0 { pinctrl-0 = <&lcd0_pins>; pinctrl-names = "default"; + status = "okay"; + + ports { + port@0 { + endpoint { + remote-endpoint = <&panel_in>; + }; + }; + }; +}; + +&pfc { ether_pins: ether { groups = "gether_mii", "gether_int"; function = "gether";
Signature · 1 line
2.34.1