openrisc: dts: or1ksim: Add stdout-path
Subsystems (2)
Stafford Horne
maintainerPATCH 1/1 openrisc: dts: or1ksim: Add stdout-path
During reviews of the OpenRISC SMP patch series it was suggested to add stdout-path to the SMP dts file. Add stdout-path to our other dts files to be a good example.
--- arch/openrisc/boot/dts/or1ksim.dts | 1 + 1 file changed, 1 insertion(+)
arch/openrisc/boot/dts/or1ksim.dts +1 -0
@@ -7,6 +7,7 @@ chosen { bootargs = "console=uart,mmio,0x90000000,115200"; + stdout-path = &serial0; }; memory@0 {
Signature · 6 lines
2.13.5 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Stafford,
Quoted 14 lines · Stafford Horne
During reviews of the OpenRISC SMP patch series it was suggested to add stdout-path to the SMP dts file. Add stdout-path to our other dts files to be a good example.
Signed-off-by Stafford Horne <[email protected]>--- arch/openrisc/boot/dts/or1ksim.dts | 1 + 1 file changed, 1 insertion(+)arch/openrisc/boot/dts/or1ksim.dts +0
-0
arch/openrisc/boot/dts/or1ksim.dts line 10
Quoted 4 lines
arch/openrisc/boot/dts/or1ksim.dts +1
-0@@ -7,6 +7,7 @@ chosen { bootargs = "console=uart,mmio,0x90000000,115200"; + stdout-path = &serial0;
I think that should be:
- bootargs = "console=uart,mmio,0x90000000,115200";
+ stdout-path = "serial0:115200";
If stdout-path is present, it will become the default console. All other UART parameters except for the serial speed are derived from the serial0 node (= serial@90000000) in DT.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Stafford Horne
maintainerHi Geert,
Quoted 27 lines · Geert Uytterhoeven
Hi Stafford,
Quoted 14 lines · Stafford Horne
During reviews of the OpenRISC SMP patch series it was suggested to add stdout-path to the SMP dts file. Add stdout-path to our other dts files to be a good example.
Signed-off-by Stafford Horne <[email protected]>--- arch/openrisc/boot/dts/or1ksim.dts | 1 + 1 file changed, 1 insertion(+)arch/openrisc/boot/dts/or1ksim.dts +0
-0arch/openrisc/boot/dts/or1ksim.dts line 10
Quoted 4 lines
arch/openrisc/boot/dts/or1ksim.dts +1
-0@@ -7,6 +7,7 @@ chosen { bootargs = "console=uart,mmio,0x90000000,115200"; + stdout-path = &serial0;I think that should be:
(quoted diff) +1
-1- bootargs = "console=uart,mmio,0x90000000,115200"; + stdout-path = "serial0:115200";
Quoted 3 lines
If stdout-path is present, it will become the default console. All other UART parameters except for the serial speed are derived from the serial0 node (= serial@90000000) in DT.
Thanks for the tip. I have seen examples using alias &serial0; and using the name directly `serio0:115200', but I guess I didnt really understand what was going on. I read through as much of the console initialization, of, earlycon and printk code as I needed to refresh my memory on this...
It seems there are a few other issues here:
- To use "serial0:115200" we will need an alias to the path (or specify the full path)
- It looks like we can't use console= and stdout-path at the same time
- We still need "earlycon" to define that we want to initialize early printk
I think updating to something like the below works, but its a few extra lines:
arch/openrisc/boot/dts/or1ksim.dts +6 -2
@@ -5,9 +5,13 @@ #size-cells = <1>; interrupt-parent = <&pic>; + aliases { + uart0 = &serial0; + }; + chosen { - bootargs = "console=uart,mmio,0x90000000,115200"; - stdout-path = &serial0; + bootargs = "earlycon"; + stdout-path = "uart0:115200"; }; memory@0 {
The boot prompt before showed:
Kernel command line: console=uart,mmio,0x90000000,115200
earlycon: uart0 at MMIO 0x90000000 (options '115200')
bootconsole [uart0] enabledNow it shows:
Kernel command line: earlycon
earlycon: ns16550a0 at MMIO 0x90000000 (options '115200')
bootconsole [ns16550a0] enabled-Stafford
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html