
On 05/29/2017 02:26 PM, Tom Rini wrote:
On Mon, May 29, 2017 at 02:18:48PM +0200, Jorge Ramirez wrote:
On 05/29/2017 01:57 PM, Tom Rini wrote:
The issue is actually with serial-uclass.c when the kernel dts contains a chosen node that contains the stdout-path. chosen { stdout-path = "serial0:115200n8"; };
Disabling uart0 (ie serial0) in u-boot.dtsi loses the console instead of probing the pl01x for the platform_data.
is there a pre-defined way to work around this?
Provide a new stdout-path in the -u-boot.dtsi too? Any changes you
yes I obviously tried that but are you sure that that is allowed with "chosen" it being kind of a special type of node? the compiler just cant find the label when added to u-boot.dtsi hence why I was asking (sorry, I should have raised it upfront) ie:
/*
- U-Boot addition to:
- use platform data for the console
- provide support for the generic-ehci USB driver currently not
available
in the linux kernel (8/May/2017).
- (C) Copyright 2017 Jorge Ramirez-Ortiz jorge.ramirez-ortiz@linaro.org
- SPDX-License-Identifier: GPL-2.0+
*/
&soc { usb2: ehci@9890000 { compatible = "generic-ehci"; reg = <0x9890000 0x100>; status = "okay"; }; };
&uart0 { status = "disabled"; };
&chosen { stdout-path = &uart0;
};
leads to
LD u-boot OBJCOPY u-boot.srec OBJCOPY u-boot-nodtb.bin SYM u-boot.sym start=$(aarch64-linux-gnu-nm u-boot | grep __rel_dyn_start | cut -f 1 -d ' '); end=$(aarch64-linux-gnu-nm u-boot | grep __rel_dyn_end | cut -f 1 -d ' '); tools/relocate-rela u-boot-nodtb.bin 0x37000000 $start $end DTC arch/arm/dts/hi3798cv200-poplar.dtb Error: ./arch/arm/dts/hi3798cv200-u-boot.dtsi:27.2-3 label or path, 'chosen', not found FATAL ERROR: Syntax error parsing input tree scripts/Makefile.lib:322: recipe for target 'arch/arm/dts/hi3798cv200-poplar.dtb' failed make[2]: *** [arch/arm/dts/hi3798cv200-poplar.dtb] Error 1 dts/Makefile:32: recipe for target 'arch/arm/dts/hi3798cv200-poplar.dtb' failed make[1]: *** [arch/arm/dts/hi3798cv200-poplar.dtb] Error 2 Makefile:865: recipe for target 'dts/dt.dtb' failed make: *** [dts/dt.dtb] Error 2
Well, lets see. Pantelis has been telling me that what we're doing here is going to lead to problems like what you see here in some cases. Any suggestions?
sorry Tom, this is the right syntax for "chosen" hi3798cv200-u-boot.dtsi uart0 is now initialized and functional via platform data
&soc { usb2: ehci@9890000 { compatible = "generic-ehci"; reg = <0x9890000 0x100>; status = "okay"; }; };
&uart0 { status = "disabled"; };
/{ chosen { stdout-path = ""; }; };