[PATCH V2 0/6] Add Support for RG353PS and Panel Auto Detection

Chris Morgan macroalpha82 at gmail.com
Mon May 15 18:00:26 CEST 2023


From: Chris Morgan <macromorgan at hotmail.com>

Add support for panel auto detection for the Anbernic RGxx3 series.
This requires us to probe the DSI and DSI-DPHY controllers so that
we may send a MIPI_DCS_GET_DISPLAY_ID command to the panel to find
out which panel we are running. This requires creating a kind of
"skeleton" driver for the panel so we have just enough information
about it to issue the necessary command.

Once the panel type is determined the panel type is saved as an
environment variable, and additionally the panel compatible string
is automatically fixed-up in the devicetree if it is found to be
incompatible. There is a table of panel IDs and compatible strings,
support for a new panel only requires knowing the ID and the string.

Additionally, the device auto detection was changed so that it
mimicks the panel auto detection, requiring only defining a few
new values to add support for a new compatible board. This is done
while also adding a new board, the RG353PS.

Tested the auto detection on an RG353P, RG353PS (2nd revision panel),
RG353V, RG353V (2nd revision panel), RG353M, and RG503. As long as
the correct devicetrees were located in ${boot}/rockchip/. U-Boot
was able to automatically detect the correct board and panel and
boot each device correctly.

Changes since V1:
 - Split into multiple patches to make it easier to digest.
 - Updated documentation to note panel detection is now working.

Chris Morgan (6):
  board: rockchip: Correct i2c2 pinctrl for RGxx3
  board: rockchip: add DSI and DSI-DPHY for Anbernic RGxx3
  board: rockchip: Add support for RG353PS to RGxx3
  board: rockchip: Add panel auto-detection for Anbernic RGxx3
  configs: Update anbernic-rgxx3_defconfig for panel detection
  doc: anbernic: Update RGxx3 Docs for panel detection

 .../arm/dts/rk3566-anbernic-rgxx3-u-boot.dtsi |  10 +
 board/anbernic/rgxx3_rk3566/rgxx3-rk3566.c    | 322 +++++++++++++++---
 configs/anbernic-rgxx3_defconfig              |  15 +
 doc/board/anbernic/rgxx3.rst                  |  31 +-
 4 files changed, 327 insertions(+), 51 deletions(-)

-- 
2.34.1



More information about the U-Boot mailing list