mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Johannes Schneider <johannes.schneider@leica-geosystems.com>
To: barebox@lists.infradead.org, a.fatoum@pengutronix.de,
	mgr@kernel.org, l.stach@pengutronix.de
Cc: thomas.haemmerle@leica-geosystems.com,
	Johannes Schneider <johannes.schneider@leica-geosystems.com>
Subject: [PATCH v2 00/11] video: enable boot splash on i.MX8MP with LVDS panel
Date: Thu,  4 Jun 2026 06:49:55 +0000	[thread overview]
Message-ID: <20260604065006.2933142-1-johannes.schneider@leica-geosystems.com> (raw)

v1: https://lists.infradead.org/pipermail/barebox/2026-June/056588.html

This is v2 of the i.MX8MP boot-splash series.  Review on v1 pointed out
that barebox already has in-tree drivers covering work v1 was
duplicating, plus several detail issues; v2 replaces the two new
drivers with extensions to the existing ones and addresses the
remaining review feedback.

Changes since v1:

 * Drop drivers/video/imx-lcdif.c (Michael).  drivers/video/lcdif_drv.c
   already matches "fsl,imx8mp-lcdif" and "fsl,imx93-lcdif" but had
   only been exercised on i.MX93.  Three latent issues kept it unusable
   on i.MX8MP; v2 extends it instead of duplicating:

     - Kconfig depends-on widened to ARCH_IMX8MP.  The symbol was
       silently forced to n on i.MX8MP defconfigs even though the help
       text and the driver's of_match cover i.MX8MP.

     - clk_prepare_enable() AXI/disp_axi/pix at atomic_enable.  Linux
       runtime PM handles that via genpd; barebox has none, so the
       controller's MMIO writes silently no-op'd and frames never
       ticked.

     - VPL_GET_BUS_FORMAT abort no longer kills the enable path when
       the downstream panel doesn't carry a "bus-format" property
       (typical of panel-lvds DTs).  Default to RGB888_1X24 with a
       dev_warn instead.

 * Drop drivers/video/panel-lvds.c (Ahmad).  drivers/video/simple-panel.c
   already parses display-timings, enable-gpios and a backlight phandle
   from DT -- exactly what a Linux panel-lvds node provides.  v2 makes
   three small extensions:

     - Match "panel-lvds" in the of_id table.
     - Read modes from a "panel-timing" subnode as a fallback to the
       "display-timings" container (panel-lvds uses the singular form).
     - Switch power-supply to regulator_get_optional() so panels
       without "power-supply" bind.

 * Move the LCDIF write-combine drain from a dsb() to a readback of the
   WC region in fb_damage (Lucas).  dsb() doesn't actually drain WC;
   a load from the WC region does.

 * pmdomain: keep the ADB handshake propagation before the upstream
   clock enable in imx8mp_blk_ctrl_power_on; v1's refactor accidentally
   moved it after.  Route the HSIO-specific call through a new
   pre_power_on hook in struct imx8mp_blk_ctrl_data so the generic path
   remains HSIO-agnostic (Ahmad).

 * backlight-pwm: switch the power-supply lookup to
   regulator_get_optional() so a missing power-supply property surfaces
   as -ENODEV (the IS_ERR check never caught the NULL return),
   drop the now-redundant NULL guards around regulator_enable/_disable,
   use dev_errp_probe() for the PWM lookup, and add a Fixes: tag for
   the bogus "enable-gpios" gpiod descriptor name (gpiod_get_optional()
   appends -gpios itself) (Ahmad).

 * Pick up Ahmad's Reviewed-by on the 700 MHz VIDEO_PLL1 rate entry.

 * New patch: clk: imx8mp: add 1039.5 MHz and 519.75 MHz VIDEO_PLL1
   rate entries.  arch/arm64/boot/dts/freescale/imx8mp.dtsi pins
   VIDEO_PLL1 to 1039.5 MHz via media_blk_ctrl's assigned-clock-rates
   (the right value for 1080p60 LVDS), but the rate was missing from
   barebox's PLL14xx table.  Without it, media_blk_ctrl probe fails
   -EINVAL and breaks the clock tree below LCDIF2 before lcdif2's own
   assigned-clock-rates can rebind it.  Values taken from Linux's
   imx_pll1443x_tbl.

 * Split out three smaller stand-alone changes v1 had bundled with the
   new driver:

     - lcdif: 128B AXI bursts (avoids a right-edge gap on panels whose
       stride isn't a multiple of 256 bytes -- e.g. 800px at XRGB8888).
     - lcdif: register a simplefb fixup and call fb_enable() at probe,
       so a splash command can blit straight into a live framebuffer
       and Linux's DRM_SIMPLEDRM inherits the boot fb.
     - simple-panel: lazily resolve the backlight phandle without
       failing the panel-enable chain when the backlight hasn't probed
       yet.

Tested on i.MX8MP with a single-link LVDS 800x480@60Hz panel: boot
splash renders, Linux DRM_SIMPLEDRM inherits the framebuffer via the
simplefb DT fixup.

Assisted-by: Claude:claude-opus-4-7

Johannes Schneider (5):
  clk: imx8mp: add 1039.5 MHz and 519.75 MHz rate entries for VIDEO_PLL1
  video: lcdif: make functional on i.MX8MP
  video: lcdif: default to RGB888_1X24 on VPL_GET_BUS_FORMAT failure
  video: simple-panel: support panel-lvds DT bindings
  video: simple-panel: lazily resolve backlight without failing

Thomas Haemmerle (6):
  clk: imx8mp: add 700 MHz rate entry for VIDEO_PLL1
  pmdomain: imx8mp-blk-ctrl: add media blk-ctrl power domain support
  video: backlight-pwm: make power-supply and enable-gpio optional
  video: lcdif: use 128B AXI bursts to avoid right-edge gap
  video: lcdif: register simplefb fixup and enable framebuffer at probe
  video: lcdif: drain write-combine framebuffer in fb_damage

 drivers/clk/imx/clk-pll14xx.c          |  3 +
 drivers/pmdomain/imx/imx8mp-blk-ctrl.c | 91 ++++++++++++++++++++++++--
 drivers/video/Kconfig                  |  4 +-
 drivers/video/backlight-pwm.c          | 16 ++---
 drivers/video/backlight.c              |  2 +-
 drivers/video/fsl-ldb.c                |  2 +-
 drivers/video/lcdif_kms.c              | 47 +++++++++----
 drivers/video/simple-panel.c           | 31 ++++++---
 8 files changed, 155 insertions(+), 41 deletions(-)


base-commit: 651343da8af78d134d7ead4d2b36095d7ddc2d8f
--
2.43.0



             reply	other threads:[~2026-06-04  6:50 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-04  6:49 Johannes Schneider [this message]
2026-06-04  6:49 ` [PATCH v2 01/11] clk: imx8mp: add 700 MHz rate entry for VIDEO_PLL1 Johannes Schneider
2026-06-04  6:49 ` [PATCH v2 02/11] clk: imx8mp: add 1039.5 MHz and 519.75 MHz rate entries " Johannes Schneider
2026-06-04  6:49 ` [PATCH v2 03/11] pmdomain: imx8mp-blk-ctrl: add media blk-ctrl power domain support Johannes Schneider
2026-06-04  6:49 ` [PATCH v2 04/11] video: backlight-pwm: make power-supply and enable-gpio optional Johannes Schneider
2026-06-04  6:50 ` [PATCH v2 05/11] video: lcdif: make functional on i.MX8MP Johannes Schneider
2026-06-04  6:50 ` [PATCH v2 06/11] video: lcdif: use 128B AXI bursts to avoid right-edge gap Johannes Schneider
2026-06-04  6:50 ` [PATCH v2 07/11] video: lcdif: default to RGB888_1X24 on VPL_GET_BUS_FORMAT failure Johannes Schneider
2026-06-04  6:50 ` [PATCH v2 08/11] video: lcdif: register simplefb fixup and enable framebuffer at probe Johannes Schneider
2026-06-04  6:50 ` [PATCH v2 09/11] video: lcdif: drain write-combine framebuffer in fb_damage Johannes Schneider
2026-06-04  6:50 ` [PATCH v2 10/11] video: simple-panel: support panel-lvds DT bindings Johannes Schneider
2026-06-04  6:50 ` [PATCH v2 11/11] video: simple-panel: lazily resolve backlight without failing Johannes Schneider

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=20260604065006.2933142-1-johannes.schneider@leica-geosystems.com \
    --to=johannes.schneider@leica-geosystems.com \
    --cc=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=l.stach@pengutronix.de \
    --cc=mgr@kernel.org \
    --cc=thomas.haemmerle@leica-geosystems.com \
    /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