From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: distrokit@pengutronix.de
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>, mkl@pengutronix.de
Subject: [DistroKit] [PATCH 06/10] v8a: rockchip: use common environment
Date: Wed, 3 May 2023 15:53:23 +0200 [thread overview]
Message-ID: <20230503135327.4137066-7-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20230503135327.4137066-1-a.fatoum@pengutronix.de>
This effectively reverts commit 95014f4d8a50 ("v8a: rockchip: copy default
barebox env"). The common environment and the rockchip one are nearly
identical, except for a small section in the bootsource init script.
Let's make that section board-dependent and drop barebox-rock3a-defaultenv.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
.../barebox-common-defaultenv/init/bootsource | 12 +++++++++---
.../barebox-rock3a-defaultenv/init/bootsource | 14 --------------
.../nv/linux.bootargs.loglevel | 1 -
configs/platform-v8a/rules/barebox-rockchip.make | 2 +-
4 files changed, 10 insertions(+), 19 deletions(-)
delete mode 100644 configs/platform-v8a/barebox-rock3a-defaultenv/init/bootsource
delete mode 100644 configs/platform-v8a/barebox-rock3a-defaultenv/nv/linux.bootargs.loglevel
diff --git a/configs/platform-v8a/barebox-common-defaultenv/init/bootsource b/configs/platform-v8a/barebox-common-defaultenv/init/bootsource
index 8f00bced5df2..a45ebf51bec1 100644
--- a/configs/platform-v8a/barebox-common-defaultenv/init/bootsource
+++ b/configs/platform-v8a/barebox-common-defaultenv/init/bootsource
@@ -8,7 +8,13 @@ fi
if [ "$bootsource" = mmc ]; then
detect mmc$bootsource_instance
global.boot.default="mmc$bootsource_instance net"
-elif [ "$bootsource" = "spi-nor" ]; then
- usbgadget -A '/dev/mmc0(sd)'
- global.autoboot=abort
+fi
+
+if [ "${global.model}" = "Radxa ROCK3 Model A" ]; then
+ of_property -df mmc1 sd-uhs-sdr50
+
+ if [ "$bootsource" = "spi-nor" ]; then
+ usbgadget -A '/dev/mmc1(sd)'
+ global.autoboot=abort
+ fi
fi
diff --git a/configs/platform-v8a/barebox-rock3a-defaultenv/init/bootsource b/configs/platform-v8a/barebox-rock3a-defaultenv/init/bootsource
deleted file mode 100644
index d12f04949a5a..000000000000
--- a/configs/platform-v8a/barebox-rock3a-defaultenv/init/bootsource
+++ /dev/null
@@ -1,14 +0,0 @@
-#!/bin/sh
-
-if [ -n "${nv.boot.default}" ]; then
- exit
-fi
-
-if [ "$bootsource" = mmc ]; then
- detect mmc$bootsource_instance
- global.boot.default="mmc$bootsource_instance net"
- of_property -df mmc1 sd-uhs-sdr50
-elif [ "$bootsource" = "spi-nor" ]; then
- usbgadget -A '/dev/mmc1(sd)'
- global.autoboot=abort
-fi
diff --git a/configs/platform-v8a/barebox-rock3a-defaultenv/nv/linux.bootargs.loglevel b/configs/platform-v8a/barebox-rock3a-defaultenv/nv/linux.bootargs.loglevel
deleted file mode 100644
index 705752ca416d..000000000000
--- a/configs/platform-v8a/barebox-rock3a-defaultenv/nv/linux.bootargs.loglevel
+++ /dev/null
@@ -1 +0,0 @@
-loglevel=5 systemd.log_level=warning systemd.show_status=auto
diff --git a/configs/platform-v8a/rules/barebox-rockchip.make b/configs/platform-v8a/rules/barebox-rockchip.make
index fbab38419316..a04534418d84 100644
--- a/configs/platform-v8a/rules/barebox-rockchip.make
+++ b/configs/platform-v8a/rules/barebox-rockchip.make
@@ -69,7 +69,7 @@ $(BAREBOX_ROCKCHIP_CONFIG):
endif
BAREBOX_ROCKCHIP_EXTRA_ENV_PATH := $(foreach path, \
- $(call remove_quotes,"barebox-rock3a-defaultenv"), \
+ $(call remove_quotes,"barebox-common-defaultenv"), \
$(call ptx/in-platformconfigdir,$(path)))
BAREBOX_ROCKCHIP_EXTRA_ENV_DEPS := \
$(BAREBOX_ROCKCHIP_EXTRA_ENV_PATH) \
--
2.39.2
next prev parent reply other threads:[~2023-05-03 13:53 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-03 13:53 [DistroKit] [PATCH 00/10] v8a: barebox: update to use upstream PTXdist rule Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 01/10] v7a: barebox: version bump v2023.02.1 → v2023.04.0 Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 02/10] v8a: kernel: version bump v6.2 → v6.3.1 Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 03/10] v8a: barebox: version bump v2023.01.0 → v2023.04.0 Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 04/10] Revert "v8a: barebox: rockchip: disable CONFIG_MMCBLKDEV_ROOTARG" Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 05/10] platforms: drop no longer needed blspec-rpi4 Ahmad Fatoum
2023-05-03 13:53 ` Ahmad Fatoum [this message]
2023-05-03 13:53 ` [DistroKit] [PATCH 07/10] v8a: barebox: configure upstream barebox rule for both imx8m and rockchip Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 08/10] v8a: barebox: switch to upstream rule Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 09/10] v8a: barebox: remove left-over SoC-specific rules Ahmad Fatoum
2023-05-03 13:53 ` [DistroKit] [PATCH 10/10] v8a: barebox: enable fastboot over UDP Ahmad Fatoum
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230503135327.4137066-7-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=distrokit@pengutronix.de \
--cc=mkl@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox