Compiled in boot environment and dtbo files

Konstantin Kletschke konstantin.kletschke at inside-m2m.de
Fri Jun 18 06:15:32 PDT 2021



> In the end it goes down to putting an entry like this into
> loader/entries/foo.conf into your rootfs:

I will investigate this definitely carefully since this has nice advantages
controlling the boot from userspace, especially in order to gain a proper
failover environment.

Meanwhile I realized I most probably have no problem with barebox and
dtb/dtbo handling. At least it _is_ preparing “my” dtbo files and trying to 
handle them.

In my initial mail regarding this thread I mentioned how this works on my 
Beaglebones when I kept the delivered debian environment with u-boot.
The goal is to have the serial lines enabled as serial after bootup on the
pinheaders and there
this works with those dtbo files. Also I realized I can omit them and bitbang
in the GPIO multiplex mechanism below /sys/platform/... to gain the same
effect. Because the debian kernel setup (including the dtb file?) is enabling all
four serial lines at boot, regardless what I do:

[    0.952482] 44e09000.serial: ttyS0 at MMIO 0x44e09000 (irq = 30, base_baud = 3000000) is a 8250
[    1.713812] console [ttyS0] enabled
[    1.718482] 48022000.serial: ttyS1 at MMIO 0x48022000 (irq = 31, base_baud = 3000000) is a 8250
[    1.728498] 48024000.serial: ttyS2 at MMIO 0x48024000 (irq = 32, base_baud = 3000000) is a 8250
[    1.738387] 481a6000.serial: ttyS3 at MMIO 0x481a6000 (irq = 33, base_baud = 3000000) is a 8250
[    1.748351] 481a8000.serial: ttyS4 at MMIO 0x481a8000 (irq = 34, base_baud = 3000000) is a 8250
[    1.758188] 481aa000.serial: ttyS5 at MMIO 0x481aa000 (irq = 35, base_baud = 3000000) is a 8250

The dtbo files only do some GPIO multiplexing (I realized yesterday).

In my kernel setup only the first serial interface gets enabled:

[    0.734644] 44e09000.serial: ttyO0 at MMIO 0x44e09000 (irq = 29, base_baud = 3000000) is a OMAP UART0
[    1.303154] printk: console [ttyO0] enabled

Maybe the overlays are not working since there are referring to not enabled serial interfaces, 
like "target = <&uart1>;” for example? I am still investigating where differences between my 
rather vanilla setup and the debian changes are...


>> Loading ARM Linux zImage '/boot/uImage'
>> Loading devicetree from '/boot/am335x-boneblack.dtb'
>> ERROR: of_resolver: __symbols__ missing from base devicetree
>> WARNING: Failed to fixup node in of_overlay_fixup+0x1/0x4: Invalid argument
>> ERROR: of_resolver: __symbols__ missing from base devicetree
>> WARNING: Failed to fixup node in of_overlay_fixup+0x1/0x4: Invalid argument
> 
> You have to compile the device tree with -@ passed to dtc. If you are
> building the device tree in the Kernel this does the trick:
> 
> make dtbs DTC_FLAGS=-@

I prepared a kernel (usually I use yocto, I did not found where to apply flags for “make dtbs” so I
prepared a test setup) and dtbo files this way. The compile process spits many warnings and the 
resulting binary size increases, but the error “[…] Invalid argument" is identical.

As said, I have to figure this out further, I suppose the barebox is doing just fine!

Kind Regards
Konstantin


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4124 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/barebox/attachments/20210618/7a5b9e19/attachment-0001.p7s>


More information about the barebox mailing list