From a36b832687fa4ecbe891e78b8834d9b7746ac355 Mon Sep 17 00:00:00 2001 From: Roland Hieber Date: Tue, 15 Sep 2020 20:59:13 +0200 Subject: rpi: barebox: migrate defaultenv from /env/config to nv variables All upstream defaultenvs were converted in barebox 2015.01.0 [2] to use nv variables instead of /env/config, and /env/config is no longer sourced by the init script since barebox 2019.06.0 [1]. The default defaultenv already contains our variable definitions for allow_color, user, and autoboot_timeout, and the information in linux.bootargs.base is detected automatically as linux.bootargs.console from the port name given by the serial driver and CONFIG_BAUDRATE in the barebox config, so we don't have to convert those. This leaves boot.default, and converting this variable should also fix the issue of barebox trying to boot from net (instead of SD card) by default. [1]: 2019-02-25, Sascha Hauer: "defaultenv: Convert init script to C", https://git.pengutronix.de/cgit/barebox/commit/?id=90df2a955e3c66fee2c5 [2]: 2014-11-06, Sascha Hauer: "defaultenv-2: Make use of nonvolatile variables", https://git.pengutronix.de/cgit/barebox/commit/?id=7962e7a0b423a5dfba25 Signed-off-by: Roland Hieber --- configs/platform-rpi/barebox-defaultenv/config | 19 ------------------- .../platform-rpi/barebox-defaultenv/nv/boot.default | 1 + 2 files changed, 1 insertion(+), 19 deletions(-) delete mode 100644 configs/platform-rpi/barebox-defaultenv/config create mode 100644 configs/platform-rpi/barebox-defaultenv/nv/boot.default diff --git a/configs/platform-rpi/barebox-defaultenv/config b/configs/platform-rpi/barebox-defaultenv/config deleted file mode 100644 index 411e054..0000000 --- a/configs/platform-rpi/barebox-defaultenv/config +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh - -# change network settings in /env/network/eth0 -# change mtd partition settings and automountpoints in /env/init/* - -# set to false if you do not want to have colors -global.allow_color=true - -# user (used for network filenames) -global.user=none - -# timeout in seconds before the default boot entry is started -global.autoboot_timeout=3 - -# default boot entry (one of /env/boot/*) -global.boot.default=sd - -# base bootargs -global.linux.bootargs.base="console=ttyAMA0,115200" diff --git a/configs/platform-rpi/barebox-defaultenv/nv/boot.default b/configs/platform-rpi/barebox-defaultenv/nv/boot.default new file mode 100644 index 0000000..e1476cf --- /dev/null +++ b/configs/platform-rpi/barebox-defaultenv/nv/boot.default @@ -0,0 +1 @@ +sd -- cgit v1.2.3