mbox series

[0/5] drm/bridge: simple-bridge: Add DPI color encoder support

Message ID 20250304101530.969920-1-victor.liu@nxp.com (mailing list archive)
Headers show
Series drm/bridge: simple-bridge: Add DPI color encoder support | expand

Message

Liu Ying March 4, 2025, 10:15 a.m. UTC
Hi,

This patch series aims to add DPI color encoder support as a simple DRM
bridge.  A DPI color encoder simply converts input DPI color coding to
output DPI color coding, like Adafruit Kippah DPI hat[1] which converts
input 18-bit pixel data to 24-bit pixel data(with 2 low padding bits in
every color component though).  A real use case is that NXP i.MX93 11x11
EVK[2] and i.MX93 9x9 QSB[3] boards may connect a 24-bit DPI panel through
the Adafruit Kippah DPI hat.  The display pipeline is

i.MX93 LCDIF display controller(RGB888) ->
i.MX93 parallel display format configuration(RGB666) ->
on-board Raspiberry Pi compatible interface(RPi)(RGB666) ->
Adafruit Kippah DPI hat(RGB888 with 2 low padding bits in color components) ->
24-bit "ontat,kd50g21-40nt-a1" DPI panel

[1] https://learn.adafruit.com/adafruit-dpi-display-kippah-ttl-tft/downloads
[2] https://www.nxp.com/design/design-center/development-boards-and-designs/i.MX93EVK
[3] https://www.nxp.com/design/design-center/development-boards-and-designs/IMX93QSB

Liu Ying (5):
  dt-bindings: display: Document DPI color codings
  drm/of: Add drm_of_dpi_get_color_coding()
  dt-bindings: display: simple-bridge: Document DPI color encoder
  drm/bridge: simple-bridge: Add DPI color encoder support
  drm/bridge: simple-bridge: Add next panel support

 .../display/bridge/simple-bridge.yaml         |  89 +++++++++++-
 .../bindings/display/dpi-color-coding.yaml    |  90 ++++++++++++
 drivers/gpu/drm/bridge/Kconfig                |   1 +
 drivers/gpu/drm/bridge/simple-bridge.c        | 132 ++++++++++++++++--
 drivers/gpu/drm/drm_of.c                      |  43 ++++++
 include/drm/drm_of.h                          |   7 +
 6 files changed, 348 insertions(+), 14 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/display/dpi-color-coding.yaml

Comments

Alexander Stein March 4, 2025, 3 p.m. UTC | #1
Hi,

Am Dienstag, 4. März 2025, 11:15:25 CET schrieb Liu Ying:
> Hi,
> 
> This patch series aims to add DPI color encoder support as a simple DRM
> bridge.  A DPI color encoder simply converts input DPI color coding to
> output DPI color coding, like Adafruit Kippah DPI hat[1] which converts
> input 18-bit pixel data to 24-bit pixel data(with 2 low padding bits in
> every color component though).  A real use case is that NXP i.MX93 11x11
> EVK[2] and i.MX93 9x9 QSB[3] boards may connect a 24-bit DPI panel through
> the Adafruit Kippah DPI hat.  The display pipeline is
> 
> i.MX93 LCDIF display controller(RGB888) ->
> i.MX93 parallel display format configuration(RGB666) ->
> on-board Raspiberry Pi compatible interface(RPi)(RGB666) ->
> Adafruit Kippah DPI hat(RGB888 with 2 low padding bits in color components) ->
> 24-bit "ontat,kd50g21-40nt-a1" DPI panel
> 
> [1] https://learn.adafruit.com/adafruit-dpi-display-kippah-ttl-tft/downloads
> [2] https://www.nxp.com/design/design-center/development-boards-and-designs/i.MX93EVK
> [3] https://www.nxp.com/design/design-center/development-boards-and-designs/IMX93QSB

Thanks for this series.
Actually I was about to create a similar (dumb) bridge. My use case is wrong
wiring on hardware for DPI displays. The current workaround was to use a
"new" display compatible with bus_format changes from
MEDIA_BUS_FMT_RGB666_1X18 -> MEDIA_BUS_FMT_RGB888_1X24.

I added this new bridge and changed my DT and it works flawlessly.

Best regards
Alexander

> Liu Ying (5):
>   dt-bindings: display: Document DPI color codings
>   drm/of: Add drm_of_dpi_get_color_coding()
>   dt-bindings: display: simple-bridge: Document DPI color encoder
>   drm/bridge: simple-bridge: Add DPI color encoder support
>   drm/bridge: simple-bridge: Add next panel support
> 
>  .../display/bridge/simple-bridge.yaml         |  89 +++++++++++-
>  .../bindings/display/dpi-color-coding.yaml    |  90 ++++++++++++
>  drivers/gpu/drm/bridge/Kconfig                |   1 +
>  drivers/gpu/drm/bridge/simple-bridge.c        | 132 ++++++++++++++++--
>  drivers/gpu/drm/drm_of.c                      |  43 ++++++
>  include/drm/drm_of.h                          |   7 +
>  6 files changed, 348 insertions(+), 14 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/display/dpi-color-coding.yaml
> 
>