Skip to contentSkip to conversation

video: Add simple driver for ST-Ericsson MCDE with pre-configured display

PATCH In review Stephan Gerhold 3 participants 3 messages Jul 2, 2021 – Aug 6, 2021 Framebuffer layer

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 video: Add simple driver for ST-Ericsson MCDE with pre-configured display

The U-Boot port for ST-Ericsson Ux500 is currently only used on the "stemmy" board, where U-Boot runs after firmware that already sets up a boot splash screen. This means that the display is already on and we can just continue using it for U-Boot.

Add a simple driver that simplifies this by reading the display configuration (e.g. screen size, bpp) from the hardware registers.

It also checks the configured "source synchronization" - for some displays (usually DSI command mode displays) we need to explicitly trigger a software sync. This is done through the video_sync() callback that triggers the sync and wait for completion.

---

 drivers/video/Kconfig       |  12 +++
 drivers/video/Makefile      |   1 +
 drivers/video/mcde_simple.c | 141 ++++++++++++++++++++++++++++++++++++
 3 files changed, 154 insertions(+)
 create mode 100644 drivers/video/mcde_simple.c
drivers/video/Kconfig +12 -0
index b69ffcae4b..e614a04aab 100644
@@ -854,6 +854,18 @@ config VIDEO_DT_SIMPLEFB
 	  The video output is initialized by U-Boot, and kept by the
 	  kernel.
 
+config VIDEO_MCDE_SIMPLE
+	bool "Simple driver for ST-Ericsson MCDE with preconfigured display"
+	depends on DM_VIDEO
+	help
+	  Enables a simple display driver for ST-Ericsson MCDE
+	  (Multichannel Display Engine), which reads the configuration from
+	  the MCDE registers.
+
+	  This driver assumes that the display hardware has been initialized
+	  before u-boot starts, and u-boot will simply render to the pre-
+	  allocated frame buffer surface.
+
 config OSD
 	bool "Enable OSD support"
 	depends on DM
drivers/video/Makefile +1 -0
index 933f06e9d8..8a70c9deb5 100644
@@ -58,6 +58,7 @@ obj-$(CONFIG_VIDEO_LCD_ORISETECH_OTM8009A) += orisetech_otm8009a.o
 obj-$(CONFIG_VIDEO_LCD_RAYDIUM_RM68200) += raydium-rm68200.o
 obj-$(CONFIG_VIDEO_LCD_SSD2828) += ssd2828.o
 obj-$(CONFIG_VIDEO_LCD_TDO_TL070WSH30) += tdo-tl070wsh30.o
+obj-$(CONFIG_VIDEO_MCDE_SIMPLE) += mcde_simple.o
 obj-${CONFIG_VIDEO_MESON} += meson/
 obj-${CONFIG_VIDEO_MIPI_DSI} += mipi_dsi.o
 obj-$(CONFIG_VIDEO_MVEBU) += mvebu_lcd.o
drivers/video/mcde_simple.c new file +141 -0

141 lines not on this page · raw message

Signature · 1 line
2.32.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 8 lines · Stephan Gerhold

The U-Boot port for ST-Ericsson Ux500 is currently only used on the "stemmy" board, where U-Boot runs after firmware that already sets up a boot splash screen. This means that the display is already on and we can just continue using it for U-Boot.

Add a simple driver that simplifies this by reading the display configuration (e.g. screen size, bpp) from the hardware registers.

Quoted 7 lines

It also checks the configured "source synchronization" - for some displays (usually DSI command mode displays) we need to explicitly trigger a software sync. This is done through the video_sync() callback that triggers the sync and wait for completion.

Yours,
Linus Walleij

#2 lore raw
In reply to Stephan Gerhold

On Fri, 2 Jul 2021 19:21:56 +0200
Stephan Gerhold [email protected] wrote:
...

Quoted 5 lines
 drivers/video/Kconfig       |  12 +++
 drivers/video/Makefile      |   1 +
 drivers/video/mcde_simple.c | 141 ++++++++++++++++++++++++++++++++++++
 3 files changed, 154 insertions(+)
 create mode 100644 drivers/video/mcde_simple.c

applied to u-boot-video/master, thanks!

--
Anatolij