Specify console in device tree chosen/stdout-path

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

Specify console in device tree chosen/stdout-path

3,648 Views
craigmcqueenir
Contributor IV

I have an imx8mm based system. I'm using Yocto dunfell with meta-freescale providing kernel 5.4.107.

I am trying to simplify the kernel command line, and remove kernel-specific parameters that would better be specified in the device tree. The main items are (a) console; (b) earlycon; and (c) root. It would be better if these were defined in the device tree, rather than in U-Boot environment variables which are not so easily changed with a kernel upgrade.

Currently the kernel command line for my board includes

console=ttymxc2,115200 earlycon=ec_imx6q,0x30880000,115200

and that works. But it would be better if the console were defined in the device tree.

The device tree specifies the console in node chosen/stdout-path. I had it set to

 

    stdout-path = &uart3;

 

 

But that doesn't work (when console=... is removed from kernel command line). After reading the docs, I changed it to:

 

    stdout-path = "serial2:115200n8";

 

 

That also doesn't work. Looking at /proc/consoles, the console gets set to ttymxc0 instead of ttymxc2.

 

I found these, but they are not recent, and I haven't worked out if they're still relevant:

 

0 Kudos
Reply
3 Replies

1,611 Views
gigli_korg
Contributor II

Hi everybody,
@craigmcqueenir: have you solved in this way?

0 Kudos
Reply

1,586 Views
craigmcqueenir
Contributor IV

No, I haven't found a solution.

3,637 Views
jamesbone
NXP TechSupport
NXP TechSupport

 

You can take a look into our Linux Porting Guide.  sect.1.4 Debugging, please check uboot/drivers/serial/serial_mxc.c

 

0 Kudos
Reply