From 40a52eb4864372029389ac34e9b026e2baa5008a Mon Sep 17 00:00:00 2001 From: Daniel DeGrasse Date: Wed, 5 Apr 2023 17:15:14 +0000 Subject: [PATCH] boards: add support for SMARTDMA when using RM67162 display shield Add support for using SMARTDMA when using RM67162 display shield with Zephyr, so that the DMA engine can be leveraged for improved performance when using the MIPI DSI in command mode. Signed-off-by: Daniel DeGrasse --- boards/arm/mimxrt595_evk/mimxrt595_evk_cm33.dts | 11 +++++++++++ boards/shields/g1120b0mipi/Kconfig.defconfig | 10 +++++++++- .../g1120b0mipi/boards/mimxrt595_evk_cm33.conf | 2 ++ 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 boards/shields/g1120b0mipi/boards/mimxrt595_evk_cm33.conf diff --git a/boards/arm/mimxrt595_evk/mimxrt595_evk_cm33.dts b/boards/arm/mimxrt595_evk/mimxrt595_evk_cm33.dts index f919ba00ea0..49dd4f424be 100644 --- a/boards/arm/mimxrt595_evk/mimxrt595_evk_cm33.dts +++ b/boards/arm/mimxrt595_evk/mimxrt595_evk_cm33.dts @@ -467,3 +467,14 @@ zephyr_udc0: &usbhs { &sram1 { status = "okay"; }; + +/* Enable smartDMA controller */ +&smartdma { + status = "okay"; +}; + +/* Add smartDMA to mipi DSI */ +&mipi_dsi { + dmas = <&smartdma>; + dma-names = "smartdma"; +}; diff --git a/boards/shields/g1120b0mipi/Kconfig.defconfig b/boards/shields/g1120b0mipi/Kconfig.defconfig index 807183c4742..64b784035e7 100644 --- a/boards/shields/g1120b0mipi/Kconfig.defconfig +++ b/boards/shields/g1120b0mipi/Kconfig.defconfig @@ -11,9 +11,17 @@ config INPUT config INPUT_FT5336_INTERRUPT default y +if MIPI_DSI_MCUX_2L +# Enable color swap in driver + +config MIPI_DSI_MCUX_2L_SWAP16 + default y + +endif # MIPI_DSI_MCUX_2L + # Swap 16 bit color setting for LVGL, to send high byte first config LV_COLOR_16_SWAP - default y + default y if !MIPI_DSI_MCUX_2L_SWAP16 config LV_Z_VDB_SIZE default 16 diff --git a/boards/shields/g1120b0mipi/boards/mimxrt595_evk_cm33.conf b/boards/shields/g1120b0mipi/boards/mimxrt595_evk_cm33.conf new file mode 100644 index 00000000000..ffe50a964ed --- /dev/null +++ b/boards/shields/g1120b0mipi/boards/mimxrt595_evk_cm33.conf @@ -0,0 +1,2 @@ +# Enable DMA, so that DSI MCUX will use SMARTDMA +CONFIG_DMA=y