cancel
Showing results for 
Search instead for 
Did you mean: 

modetest error on stm32mp257f-ev1

mteaching
Associate III

I aim TO drive a mipi display screen on STM32MP257F-EV1, so I have to understand the DRM framework.

After flash the new firmware, I found that the modetset always shows errors, so I want to confirm whether the support in this aspect is OK? But watching your previous video, it can drive LVDS screen, so I feel very strange, is there anything else I need to pay attention to?

 

STM32_Programmer_CLI -c port=usb1 -w ./flashlayout_st-image-weston/optee/FlashLayout_sdcard_stm32mp257f-ev1-ca35tdcid-ostl-m33-examples-optee.tsv

 

 

 

root@stm32mp2:~#  modetest -M stm
failed to open device 'stm': No such file or directory

 

as you can see, all are failed.

 

root@stm32mp2:~#  modetest
trying to open device 'i915'...failed
trying to open device 'amdgpu'...failed
trying to open device 'radeon'...failed
trying to open device 'nouveau'...failed
trying to open device 'vmwgfx'...failed
trying to open device 'omapdrm'...failed
trying to open device 'exynos'...failed
trying to open device 'tilcdc'...failed
trying to open device 'msm'...failed
trying to open device 'sti'...failed
trying to open device 'tegra'...failed
trying to open device 'imx-drm'...failed
trying to open device 'rockchip'...failed
trying to open device 'atmel-hlcdc'...failed
trying to open device 'fsl-dcu-drm'...failed
trying to open device 'vc4'...failed
trying to open device 'virtio_gpu'...failed
trying to open device 'mediatek'...failed
trying to open device 'meson'...failed
trying to open device 'pl111'...failed
trying to open device 'stm'...failed
trying to open device 'sun4i-drm'...failed
trying to open device 'armada-drm'...failed
trying to open device 'komeda'...failed
trying to open device 'imx-dcss'...failed
trying to open device 'mxsfb-drm'...failed
trying to open device 'simpledrm'...failed
trying to open device 'imx-lcdif'...failed
no device found

 

by the way,

https://wiki.stmicroelectronics.cn/stm32mpu/wiki/Getting_started/STM32MP2_boards/STM32MP257x-EV1/Develop_on_Arm%C2%AE_Cortex%C2%AE-A35/Modify,_rebuild_and_reload_the_Linux%C2%AE_kernel

 

the part

Modify a built-in Linux® kernel device driver

the added log never success for me.

 

static int stm_drm_platform_probe(struct platform_device *pdev)
{
	struct device *dev = &pdev->dev;
	struct drm_device *ddev;
	int ret;
	[...]

	DRM_INFO("Simple example - %s\n", __func__);

	return 0;
	[...]
}

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Hello, Erwan:

Thanks, I have solved this problem, it was because I used the wrong device tree configuration, now I upload my device tree and panel-ilitek-ili9881c.c so that others can see it in the future.

 

I don't connect a real panel, so it is always timeout.

the hardware design is in progress.

mteaching_0-1728393572506.pngmteaching_1-1728393602252.png

 

View solution in original post

4 REPLIES 4
Erwan SZYMANSKI
ST Employee

Hello @mteaching ,
Can you explain me a little bit more your current setup ? I understand you have the STM32MP257F-EV kit, but you try to use a specific display right ? Do you have the reference of this last one ? 

By default, the software delivered for the STM32MP257F-EV1 board is set to be used with a specific LVDS panel. You can see its configuration in the kernel board device tree : stm32mp257f-ev1.dts

In this device tree, you can see 2 nodes that can interest you :

  • lvds node : status = "okay"
  • dsi node : status = "disabled"

The thing is that the DRM driver will be able to load if the complete graphic drivers chain is able to probe. In your case, if you use a MIPI DSI panel, but the driver is not configured or probed, you will fall on a such issue.

In summary :

  1. Check that your device tree enable the DSI node, with a correct configuration for your panel.
  2. Check that your panel driver (specific or generic driver) is well probed.
  3. Check the new status

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

Hello,Erwan:

The thing is that the DRM driver will be able to load if the complete graphic drivers chain is able to probe.

This is something I didn't expect, so it means that if the kernel wants to print this sentence,it must have your LVDS display.

 

But I don't know if DSI or LVDS can automatically detect whether a display screen is connected? It is amazing.

 

static int stm_drm_platform_probe(struct platform_device *pdev)
{
	struct device *dev = &pdev->dev;
	struct drm_device *ddev;
	int ret;
	[...]

	DRM_INFO("Simple example - %s\n", __func__);

	return 0;
	[...]
}

 

So now back to my question, I think this function should run here when kernel trying to mount the display module, but in reality it does not, so how the kernel can reach here(ili9881c_dsi_probe)? I think there is no problem with the device tree, and this display can also be found in the kernel log.

mteaching_0-1728222423665.png

 

mteaching_1-1728222704429.png

 

 

CONFIG_DRM_PANEL_ILITEK_ILI9881C=y

 

 

 

root@stm32mp2:~# dmesg | grep ili98
[    0.315353] platform 48000000.dsi: Fixed dependency cycle(s) with /soc@0/rifsc@42080000/dsi@48000000/ports/panel-ili9881c@0
root@stm32mp2:~# ls /dev/dri/ -a
.  ..

 

 

Hello @mteaching ,
What I wanted to say is that the modetest command will work only if the complete graphic driver chain is well probed, with our panel or with your own one anyway.

In your case, I think you have probe issue for your panel that you need to solve first.

Can you share your complete boot logs here (dmesg) here ? 

By the way, you can also activate drm dynamic debug to get some additional information. To do it, you need to add the following in your kernel bootcmd : loglevel=8 drm.debug=0x1ff

Kind regards,
Erwan.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

Hello, Erwan:

Thanks, I have solved this problem, it was because I used the wrong device tree configuration, now I upload my device tree and panel-ilitek-ili9881c.c so that others can see it in the future.

 

I don't connect a real panel, so it is always timeout.

the hardware design is in progress.

mteaching_0-1728393572506.pngmteaching_1-1728393602252.png