950-0683-drm-vc4-dpi-Support-DPI-interface-in-mode3-for-RGB56.patch 1.1 KB

12345678910111213141516171819202122232425262728293031
  1. From 7ca1ee604c2269389ee00990dd8f7c375df3be06 Mon Sep 17 00:00:00 2001
  2. From: Chris Morgan <[email protected]>
  3. Date: Fri, 28 Jan 2022 17:39:54 -0600
  4. Subject: [PATCH] drm/vc4: dpi: Support DPI interface in mode3 for
  5. RGB565
  6. Add support for the VC4 DPI driver to utilize DPI mode 3. This is
  7. defined here as xxxRRRRRxxGGGGGGxxxBBBBB:
  8. https://www.raspberrypi.com/documentation/computers/raspberry-pi.html#parallel-display-interface-dpi
  9. This mode is required to use the Geekworm MZP280 DPI display.
  10. Signed-off-by: Chris Morgan <[email protected]>
  11. Reviewed-by: Dave Stevenson <[email protected]>
  12. ---
  13. drivers/gpu/drm/vc4/vc4_dpi.c | 4 ++++
  14. 1 file changed, 4 insertions(+)
  15. --- a/drivers/gpu/drm/vc4/vc4_dpi.c
  16. +++ b/drivers/gpu/drm/vc4/vc4_dpi.c
  17. @@ -189,6 +189,10 @@ static void vc4_dpi_encoder_enable(struc
  18. dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_1,
  19. DPI_FORMAT);
  20. break;
  21. + case MEDIA_BUS_FMT_RGB565_1X24_CPADHI:
  22. + dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_2,
  23. + DPI_FORMAT);
  24. + break;
  25. }
  26. } else {
  27. /* Default to 18bit if no connector found. */