Does IMX8MM support WQHD?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Does IMX8MM support WQHD?

Jump to solution
2,274 Views
Takashi_Kashiwagi
Senior Contributor I

Hi Community.

I set a 2400x480 display to panel-simple.c with IMX8MM, I am getting the following error.

[ 0.000000] Kernel command line: console=ttymxc0,115200 earlycon=ec_imx6q,0x30860000,115200 root=/dev/mmcblk2p1 rootwait rw uio_pdrv_genirq.of_id=generic-uio drm.debug=0x06
[ 0.871554] [drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
[ 0.876879] [drm] No driver support for vblank timestamp query.
[ 0.881567] imx-drm display-subsystem: bound imx-lcdif-crtc.0 (ops lcdif_crtc_ops)
[ 0.909589] imx-drm display-subsystem: bound 32e10000.mipi_dsi (ops imx_sec_dsim_ops)
[ 0.916149] [drm:drm_setup_crtcs]
[ 0.916158] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:33:DSI-1]
[ 0.916167] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:33:DSI-1] status updated from unknown to connected
[ 0.916187] [drm:drm_mode_debug_printmodeline] Modeline 34:"2400x480" 60 99000 2400 2520 2664 2784 480 493 496 525 0x48 0x5
[ 0.916193] [drm:drm_mode_prune_invalid] Not using 2400x480 mode: VIRTUAL_X
[ 0.916200] [drm:drm_setup_crtcs] No connectors reported connected with modes
[ 0.916205] [drm:drm_setup_crtcs] connector 33 enabled? yes
[ 0.916211] [drm:drm_setup_crtcs] looking for cmdline mode on connector 33
[ 0.916216] [drm:drm_setup_crtcs] looking for preferred mode on connector 33 0
[ 0.916220] [drm:drm_setup_crtcs] found mode none
[ 0.916224] [drm:drm_setup_crtcs] picking CRTCs for 1920x1920 config
[ 0.916229] [drm] Cannot find any crtc or sizes
[ 0.919749] [drm] Initialized imx-drm 1.0.0 20120507 for display-subsystem on minor 0

The RM says WQHD support, but is the configuration incorrect? Should I reduce the bandwidth?

pastedImage_5.png

panel-simple.c is as follows.

static const struct drm_display_mode test_2400x480_mode = {
.clock = 33000*3,
.hdisplay = 800*3,
.hsync_start = (800 + 40)*3,
.hsync_end = (800 + 40 + 48)*3,
.htotal = (800 + 40 + 48 + 40)*3,
.vdisplay = 480*1,
.vsync_start = (480 + 13)*1,
.vsync_end = (480 + 13 + 3)*1,
.vtotal = (480 + 13 + 3 + 29)*1,
.vrefresh = 60,
.flags = DRM_MODE_FLAG_PVSYNC | DRM_MODE_FLAG_PHSYNC,
};

static const struct panel_desc_dsi test_2400x480_lcd = {
.desc = {
.modes = &test_2400x480_mode,
.num_modes = 1,
.bpc = 8,
.size = {
.width = 1547*3,
.height = 841*1,
},
.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
},
.flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE | MIPI_DSI_MODE_VIDEO_HSE, // MIPI_DSI_CLOCK_NON_CONTINUOUS
.format = MIPI_DSI_FMT_RGB888,
.

Best Regards.

T.Kashiwagi

0 Kudos
1 Solution
2,082 Views
igorpadykov
NXP Employee
NXP Employee

Hi Kashiwagi

driver limits resolutions as described below:

pastedImage_1.jpg

So width = 2400 is not supported,

Note, 2400 violates capabilities described in Reference Manual (1920x1080)

pastedImage_1.jpg

Best regards
igor

View solution in original post

0 Kudos
10 Replies
2,082 Views
igorpadykov
NXP Employee
NXP Employee

Hi Kashiwagi

from log: " imx-lcdif-crtc.. picking CRTCs for 1920x1920 config"

seems there is limitation in  imx-lcdif-crtc driver ( function lcdif_crtc_bind() )

lcdif-crtc.c\lcdif\imx\drm\gpu\drivers - linux-imx - i.MX Linux kernel 

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
2,082 Views
Takashi_Kashiwagi
Senior Contributor I

Hi igorpadykov‌ san.

I applied following patch.

---
drivers/gpu/drm/imx/lcdif/lcdif-crtc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/imx/lcdif/lcdif-crtc.c b/drivers/gpu/drm/imx/lcdif/lcdif-crtc.c
index 9c7642e4a997..eb1eca3d2d3b 100644
--- a/drivers/gpu/drm/imx/lcdif/lcdif-crtc.c
+++ b/drivers/gpu/drm/imx/lcdif/lcdif-crtc.c
@@ -330,8 +330,8 @@ static int lcdif_crtc_bind(struct device *dev, struct device *master,
drm->mode_config.helper_private = &lcdif_drm_mode_config_helpers;

/* limit the max width and height */
- drm->mode_config.max_width = 1920;
- drm->mode_config.max_height = 1920;
+ drm->mode_config.max_width = 2560;//1920;
+ drm->mode_config.max_height = 1440;//1920;

dev_set_drvdata(dev, lcdif_crtc);

--

Then DRM Init has been passed and Pixel Clock is correct(49.5MHz). But Pixel Data does not output.(The screen is white.)

The FrameBuffer is all 0. Is this wrong? Where should I look up?

root@imx8mm-var-dart:~# hexdump /dev/fb
0000000 0000 0000 0000 0000 0000 0000 0000 0000
*
0465000
root@imx8mm-var-dart:~#

dmesg and weston.log are as follows.

root@imx8mm-var-dart:~# dmesg | grep drm
[ 0.953637] [drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
[ 0.958964] [drm] No driver support for vblank timestamp query.
[ 0.963649] imx-drm display-subsystem: bound imx-lcdif-crtc.0 (ops lcdif_crtc_ops)
[ 0.991639] imx-drm display-subsystem: bound 32e10000.mipi_dsi (ops imx_sec_dsim_ops)
[ 0.998199] [drm:drm_setup_crtcs]
[ 1.000304] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:33:DSI-1]
[ 1.006235] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:33:DSI-1] status updated from unknown to connected
[ 1.015752] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:33:DSI-1] probed modes :
[ 1.022988] [drm:drm_mode_debug_printmodeline] Modeline 34:"2400x480" 30 49500 2400 2520 2664 2784 480 493 496 525 0x48 0x5
[ 1.032821] [drm:drm_setup_crtcs] connector 33 enabled? yes
[ 1.037098] [drm:drm_setup_crtcs] looking for cmdline mode on connector 33
[ 1.042676] [drm:drm_setup_crtcs] looking for preferred mode on connector 33 0
[ 1.048601] [drm:drm_setup_crtcs] found mode 2400x480
[ 1.052355] [drm:drm_setup_crtcs] picking CRTCs for 2560x1440 config
[ 1.057415] [drm:drm_setup_crtcs] desired mode 2400x480 set on crtc 31 (0,0)
[ 1.063172] [drm:drm_fb_helper_generic_probe] surface width(2400), height(480) and bpp(32)
[ 1.072395] [drm:drm_mode_addfb2] [FB:36]
[ 1.108204] imx-drm display-subsystem: fb0: DRM emulated frame buffer device
[ 1.114263] [drm] Initialized imx-drm 1.0.0 20120507 for display-subsystem on minor 0
[ 6.325558] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:33:DSI-1]
[ 6.331642] [drm:drm_helper_probe_single_connector_modes] [CONNECTOR:33:DSI-1] probed modes :
[ 6.338923] [drm:drm_mode_debug_printmodeline] Modeline 34:"2400x480" 30 49500 2400 2520 2664 2784 480 493 496 525 0x48 0x5
[ 6.351982] [drm:drm_mode_addfb2] [FB:38]
[ 6.359150] [drm:drm_mode_addfb2] [FB:39]
root@imx8mm-var-dart:~#

root@imx8mm-var-dart:~# cat /var/log/weston.log
Date: 2020-06-24 JST
[14:40:23.675] weston 6.0.0
https://wayland.freedesktop.org
Bug reports to: https://gitlab.freedesktop.org/wayland/weston/issues/
Build: 6.0.0-33-g81b11811-dirty compositor-drm: Bypass the check of the libinput (2019-06-06 17:54:16 +0800)
[14:40:23.675] Command line: /usr/bin/weston --log=/var/log/weston.log
[14:40:23.675] OS: Linux, 4.19.85-imx8mm+ge4452f4458e4, #1 SMP PREEMPT Wed Jun 24 05:24:54 UTC 2020, aarch64
[14:40:23.676] Using config file '/etc/xdg/weston/weston.ini'
[14:40:23.676] Output repaint window is 16 ms maximum.
[14:40:23.677] Loading module '/usr/lib/libweston-6/drm-backend.so'
[14:40:23.681] initializing drm backend
[14:40:23.688] logind: session control granted
[14:40:23.692] using /dev/dri/card0
[14:40:23.692] DRM: supports universal planes
[14:40:23.692] DRM: supports atomic modesetting
[14:40:23.692] DRM: supports picture aspect ratio
[14:40:23.692] Loading module '/usr/lib/libweston-6/g2d-renderer.so'
[14:40:23.733] event0 - 30370000.snvs:snvs-powerkey: is tagged by udev as: Keyboard
[14:40:23.733] event0 - 30370000.snvs:snvs-powerkey: device is a keyboard
[14:40:23.760] event3 - bu21025: is tagged by udev as: Touchscreen
[14:40:23.760] event3 - bu21025: device is a touch device
[14:40:23.817] event1: opening input device '/dev/input/event1' failed (No such device).
[14:40:23.817] event1 - failed to create input device '/dev/input/event1'
[14:40:23.843] event2 - bu21025: is tagged by udev as: Touchscreen
[14:40:23.844] event2 - bu21025: device is a touch device
[14:40:23.875] libinput: configuring device "30370000.snvs:snvs-powerkey".
[14:40:23.875] Touchscreen - bu21025 - /sys/devices/platform/30a50000.i2c/i2c-3/3-0048/input/input3/event3
[14:40:23.875] libinput: configuring device "bu21025".
[14:40:23.875] input device event3 has no enabled output associated (none named), skipping calibration for now.
[14:40:23.875] Touchscreen - bu21025 - /sys/devices/platform/30a50000.i2c/i2c-3/3-004b/input/input2/event2
[14:40:23.875] libinput: configuring device "bu21025".
[14:40:23.875] input device event2 has no enabled output associated (none named), skipping calibration for now.
[14:40:23.899] DRM: head 'DSI-1' found, connector 33 is connected, EDID make 'unknown', model 'unknown', serial 'unknown'
[14:40:23.899] Registered plugin API 'weston_drm_output_api_v1' of size 24
[14:40:23.899] Registered plugin API 'weston_drm_virtual_output_api_v1' of size 48
[14:40:23.910] Output DSI-1 (crtc 31) video modes:
2400x480@33.9, preferred, current, 49.5 MHz
[14:40:23.910] associating input device event0 with output DSI-1 (none by udev)
[14:40:23.910] associating input device event3 with output DSI-1 (none by udev)
[14:40:23.911] associating input device event2 with output DSI-1 (none by udev)
[14:40:23.911] Output 'DSI-1' enabled with head(s) DSI-1
[14:40:23.911] Compositor capabilities:
arbitrary surface rotation: yes
screen capture uses y-flip: yes
presentation clock: CLOCK_MONOTONIC, id 1
presentation clock resolution: 0.000000001 s
[14:40:23.912] Loading module '/usr/lib/weston/desktop-shell.so'
[14:40:23.915] launching '/usr/libexec/weston-keyboard'
[14:40:23.917] launching '/usr/libexec/weston-desktop-shell'
root@imx8mm-var-dart:~#


root@imx8mm-var-dart:~#

Best Regards,

T.Kashiwagi

0 Kudos
2,082 Views
igorpadykov
NXP Employee
NXP Employee

Hi Kashiwagi

>The FrameBuffer is all 0. Is this wrong? Where should I look up?

sorry such configuration is not supported as described in driver sources

imx-lcdif-crtc driver ( function lcdif_crtc_bind() ).

Best regards
igor

0 Kudos
2,082 Views
Takashi_Kashiwagi
Senior Contributor I

Hi Igor-san.

Thank you for reply.

Is width = 2400 bad? Or is it possible by changing other settings?

Best Regards,

T.Kashiwagi

0 Kudos
2,083 Views
igorpadykov
NXP Employee
NXP Employee

Hi Kashiwagi

driver limits resolutions as described below:

pastedImage_1.jpg

So width = 2400 is not supported,

Note, 2400 violates capabilities described in Reference Manual (1920x1080)

pastedImage_1.jpg

Best regards
igor

0 Kudos
2,082 Views
Takashi_Kashiwagi
Senior Contributor I

HI Igor-san

Thank you for reply.

Note, 2400 violates capabilities described in Reference Manual (1920x1080)

OK..... I will review the HW design....

Best Regards,

T.Kashiwagi

0 Kudos
2,082 Views
Takashi_Kashiwagi
Senior Contributor I

Hi Community.

The polarity of LCD_EN in the DTS file was reversed........

Although the resolution is not supported, screen output was possible even with 2400x480@30.

Best Regards,

T.Kashiwagi

0 Kudos
2,082 Views
pascalenz
Contributor I

Hi Takashi,

sorry for hijacking this thread.

I've planned to use a 1920x1200 DSI display on either imx8mm or imx8mn.

So can you confirm that this can be achived?

Just have to overwrite the limitations in driver?

So it's clear, that I cannot achieve 60fps. But 30fps should be possible?

Thanks in advance

0 Kudos
2,082 Views
Takashi_Kashiwagi
Senior Contributor I

Hi pascalenz san

> So can you confirm that this can be achived?

No I can not. I don't have 1920x1200 display.

> Just have to overwrite the limitations in driver?

> So it's clear, that I cannot achieve 60fps. But 30fps should be possible?

Maybe it works, but I'm not sure if it's within support.

Best Regrads,

T.Kashiwagi

0 Kudos
2,082 Views
Takashi_Kashiwagi
Senior Contributor I

Hi Igor-san

Thank you for reply.

I understand. I'll check lcdif_crtc_bind.

Best Regards,

T.Kashiwagi

0 Kudos