Update bootloader

This commit is contained in:
Pascal Vizeli 2018-03-22 18:49:56 +01:00
parent 4cacbdd303
commit 264c62d38d
11 changed files with 50 additions and 3 deletions

View File

@ -0,0 +1,32 @@
#!/bin/sh
export PATH=/env/bin
global autoboot_timeout
global boot.default
global linux.bootargs.base
global linux.bootargs.console
#linux.bootargs.dyn.* will be cleared at the beginning of boot
global linux.bootargs.dyn.root
global editcmd
[ -z "${global.autoboot_timeout}" ] && global.autoboot_timeout=3
magicvar -a global.autoboot_timeout "timeout in seconds before automatic booting"
[ -z "${global.boot.default}" ] && global.boot.default="system0"
[ -z "${global.editcmd}" ] && global.editcmd=sedit
[ -e /env/config-board ] && /env/config-board
# Autostart
for i in /env/init/*; do
. $i
done
echo -e -n "\nHit any key to stop autoboot: "
timeout -a $global.autoboot_timeout
autoboot="$?"
if [ "$autoboot" = 0 ]; then
boot
fi

View File

@ -0,0 +1,9 @@
#!/bin/sh
global bootchooser.targets
global bootchooser.system0.boot
global bootchooser.system1.boot
[ -z "${global.bootchooser.targets}" ] && global.bootchooser.targets="system0 system1"
[ -z "${global.bootchooser.system0.boot}" ] && global.bootchooser.system0.boot="system0"
[ -z "${global.bootchooser.system1.boot}" ] && global.bootchooser.system1.boot="system1"

View File

@ -0,0 +1 @@
2

View File

@ -0,0 +1 @@
bootchooser

View File

@ -0,0 +1 @@
system0

View File

@ -0,0 +1 @@
10

View File

@ -0,0 +1 @@
system1

View File

@ -0,0 +1 @@
20

View File

@ -0,0 +1 @@
system0 system1

View File

@ -13,7 +13,7 @@ CONFIG_FLEXIBLE_BOOTARGS=y
CONFIG_PARTITION_DISK_EFI=y
# CONFIG_PARTITION_DISK_EFI_GPT_NO_FORCE is not set
# CONFIG_PARTITION_DISK_EFI_GPT_COMPARE is not set
CONFIG_DEFAULT_ENVIRONMENT_PATH="/build/buildroot-external/board/ova/barebox-env"
CONFIG_DEFAULT_ENVIRONMENT_PATH="/build/buildroot-external/board/ova/barebox-env /build/buildroot-external/barebox-env"
CONFIG_STATE=y
CONFIG_BOOTCHOOSER=y
CONFIG_CMD_BOOT=y
@ -40,7 +40,6 @@ CONFIG_USB_HOST=y
CONFIG_VIDEO=y
CONFIG_DRIVER_VIDEO_EFI_GOP=y
CONFIG_CLOCKSOURCE_EFI=y
CONFIG_FS_EXT4=y
CONFIG_FS_EFI=y
CONFIG_FS_EFIVARFS=y
CONFIG_FS_FAT=y

View File

@ -53,7 +53,7 @@ BR2_TARGET_ROOTFS_SQUASHFS4_LZ4=y
BR2_TARGET_BAREBOX=y
BR2_TARGET_BAREBOX_USE_CUSTOM_CONFIG=y
BR2_TARGET_BAREBOX_CUSTOM_CONFIG_FILE="$(BR2_EXTERNAL_HASSIO_PATH)/board/ova/barebox.config"
BR2_TARGET_BAREBOX_CUSTOM_EMBEDDED_ENV_PATH="$(BR2_EXTERNAL_HASSIO_PATH)/board/ova/barebox-env"
BR2_TARGET_BAREBOX_CUSTOM_EMBEDDED_ENV_PATH="$(BR2_EXTERNAL_HASSIO_PATH)/board/ova/barebox-env $(BR2_EXTERNAL_HASSIO_PATH)/barebox-env"
BR2_PACKAGE_HOST_DOSFSTOOLS=y
BR2_PACKAGE_HOST_E2FSPROGS=y
BR2_PACKAGE_HOST_GENIMAGE=y