Re: Compiled in boot environment and dtbo files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 16, 2021 at 05:57:09PM +0200, Konstantin Kletschke wrote:
> 
> > defaultenv/defaultenv-2-base/boot is the generic place used for all
> > boards. As you are using the beaglebone you should rather manipulate
> > arch/arm/boards/beaglebone/defaultenv-beaglebone/. This directory is
> > added with defaultenv_append_directory(defaultenv_beaglebone) to the
> > environment once we actually know we are running on the beaglebone.
> 
> I moved my customisations to the board specific part of the tree, works
> like a charm. Thanks for the clarification about its role.
> 
> > https://systemd.io/BOOT_LOADER_SPECIFICATION/. With that you can put
> > Kernel and device tree into the rootfs and start the whole thing with
> > "boot emmc".
> 
> Well, I am rather open minded to do that, even if I can configure the kernel and
> device tree from rootfs. But I need to investigate on how this is done properly…

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

title      brand new stuff
version    5.13-rc6
machine-id 6a9857a393724b7a981ebb5b8495b9ea
linux      /boot/sha-linux-phyFLEX-i.MX6
devicetree /boot/sha-oftree-phyFLEX-i.MX6
linux-appendroot true

Linux and device tree paths are relative to the top of the rootfs.
The good thing about it is that now you can exchange Kernel and device
tree as part of your rootfs or even with your distros package
management. The linux-appendroot property is barebox specific. When this
is found then barebox will add a suitable root= option to the Kernel
commandline, so you don't have to care about that anymore.

> 
> In both cases I get an error+warning:
> 
> Booting entry 'insidem2m'
> mounted /dev/mmc1.1 on /mnt/mmc1.1
> 
> 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=-@

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox




[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux