barebox environment raw partition on beaglebone black
Lars Pedersen
lapeddk at gmail.com
Thu Feb 15 05:01:09 PST 2024
Hi.
I'm trying to create a barebox environment by using af emmc a raw
partition offset on the beaglebone black.
For testing I appended the following into am33x-boneblack.dts.
/ {
chosen {
environment {
compatible = "barebox,environment";
device-path = &environment_emmc;
};
};
aliases {
state = &state_emmc;
};
state_emmc: state {
#address-cells = <1>;
#size-cells = <1>;
compatible = "barebox,state";
magic = <0x4b414d31>;
backend-type = "raw";
backend = <&backend_state_emmc>;
backend-stridesize = <0x200>;
bootstate {
#address-cells = <1>;
#size-cells = <1>;
system0 {
#address-cells = <1>;
#size-cells = <1>;
remaining_attempts at 0 {
reg = <0x0 0x4>;
type = "uint32";
default = <10>;
};
priority at 4 {
reg = <0x4 0x4>;
type = "uint32";
default = <21>;
};
};
system1 {
#address-cells = <1>;
#size-cells = <1>;
remaining_attempts at 8 {
reg = <0x8 0x4>;
type = "uint32";
default = <0>;
};
priority at c {
reg = <0xc 0x4>;
type = "uint32";
default = <20>;
};
};
last_chosen at 10 {
reg = <0x10 0x4>;
type = "uint32";
};
};
};
};
/* eMMC */
&mmc2 {
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
environment_emmc: partition at 100000 {
label = "barebox-environment";
reg = <0x100000 0x100000>;
};
backend_state_emmc: partition at 200000 {
label = "barebox-state";
reg = <0x200000 0x100000>;
};
};
};
Afterwards I get the following console output:
-------------------------------------------------
barebox 2024.01.0 #1 2024-01-01T00:00:00+00:00
Board: TI AM335x BeagleBone black
detected 'BeagleBone Black'
cpsw-mdio 4a101000.mdio at 1000.of: detected phy mask 0x1
mdio_bus: miibus0: probed
eth0: got preset MAC address: 18:2c:65:2a:81:1d
i2c-omap 44e0b000.i2c at 0.of: bus 0 rev0.11 at 400 kHz
i2c-omap 4819c000.i2c at 0.of: bus 1 rev0.11 at 100 kHz
omap-hsmmc 48060000.mmc at 0.of: registered as mmc0
omap-hsmmc 481d8000.mmc at 0.of: registered as mmc1
mmc1: detected MMC card version 5.0
mmc1: registered mmc1
state: New state registered 'state'
state state.of: Fresh state detected, continuing with defaults
omap_wdt 44e35000.wdt at 0.of: OMAP Watchdog Timer Rev 0x01
netconsole: registered as netconsole-1
malloc space: 0x8fefe3c0 -> 0x9fdfc77f (size 255 MiB)
am335x-phy-driver 47401b00.usb-phy at 1b00.of: am_usbphy 8fff21a4 enabled
am335x-phy-driver 47401300.usb-phy at 1300.of: am_usbphy 8fff225c enabled
musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, bulk combine, bulk
split, HB-ISO Rx, HB-ISO Tx, SoftConn)
musb-hdrc: MHDRC RTL version 2.0
musb-hdrc: setup fifo_mode 4
musb-hdrc: 28/31 max ep, 16384/16384 memory
musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, bulk combine, bulk
split, HB-ISO Rx, HB-ISO Tx, SoftConn)
musb-hdrc: MHDRC RTL version 2.0
musb-hdrc: setup fifo_mode 4
musb-hdrc: 28/31 max ep, 16384/16384 memory
environment load /mnt/mmc1.0/barebox.env: No such file or directory
Maybe you have to create the partition.
changing USB current limit to 1300 mA... done
Hit m for menu or any to stop autoboot: 1
---------------------------------------------------
Why does it try to read the env on a partition on
/mnt/mmc1.0/barebox.env? Is it because barebox.bin also is read from
this partition?
Thanks.
/Lars
More information about the barebox
mailing list