From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Tue, 05 Dec 2023 10:59:54 +0100 Received: from metis.whiteo.stw.pengutronix.de ([2a0a:edc0:2:b01:1d::104]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1rASDa-0041zF-0R for lore@lore.pengutronix.de; Tue, 05 Dec 2023 10:59:54 +0100 Received: from localhost ([127.0.0.1] helo=metis.whiteo.stw.pengutronix.de) by metis.whiteo.stw.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1rASDa-0006Zy-9m; Tue, 05 Dec 2023 10:59:54 +0100 Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rASDQ-0006Vy-Gf; Tue, 05 Dec 2023 10:59:44 +0100 Received: from [2a0a:edc0:0:1101:1d::54] (helo=dude05.red.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rASDQ-00DiGZ-43; Tue, 05 Dec 2023 10:59:44 +0100 Received: from localhost ([::1] helo=dude05.red.stw.pengutronix.de) by dude05.red.stw.pengutronix.de with esmtp (Exim 4.96) (envelope-from ) id 1rASDQ-00EYdG-07; Tue, 05 Dec 2023 10:59:44 +0100 From: Ahmad Fatoum To: distrokit@pengutronix.de Date: Tue, 5 Dec 2023 10:59:30 +0100 Message-Id: <20231205095929.3469672-3-a.fatoum@pengutronix.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231205095929.3469672-1-a.fatoum@pengutronix.de> References: <20231205095929.3469672-1-a.fatoum@pengutronix.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [DistroKit] [PATCH 2/2] v8a: barebox: env: fix boot for i.MX8M EVKs X-BeenThere: distrokit@pengutronix.de X-Mailman-Version: 2.1.29 Precedence: list List-Id: DistroKit Mailinglist List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ahmad Fatoum Sender: "DistroKit" X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: distrokit-bounces@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false Rockchip RK35* and i.MX8M* share the same barebox environment, but RAUC and bootchooser were only configured for the Rockchip boards, rendering the i.MX boards unbootable. Fix this by adding bootchooser as boot target only for the radxa,rock3a. While at it, we switch to using the new of_compatible command. This is likey more stable than the Model string and allows easy extension in future by additional compatibles. Signed-off-by: Ahmad Fatoum --- .../platform-v8a/barebox-common-defaultenv/init/bootsource | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/configs/platform-v8a/barebox-common-defaultenv/init/bootsource b/configs/platform-v8a/barebox-common-defaultenv/init/bootsource index fe63bbbe099b..af47c82c1001 100644 --- a/configs/platform-v8a/barebox-common-defaultenv/init/bootsource +++ b/configs/platform-v8a/barebox-common-defaultenv/init/bootsource @@ -7,10 +7,11 @@ fi if [ "$bootsource" = mmc ]; then detect mmc$bootsource_instance - global.boot.default="bootchooser net" + global.boot.default="mmc$bootsource_instance net" fi -if [ "${global.model}" = "Radxa ROCK3 Model A" ]; then +if of_compatible -k radxa,rock3a; then + global.boot.default="bootchooser net" global bootchooser.state_prefix="state.bootstate" global bootchooser.targets="system0 system1" global bootchooser.system0.boot="mmc1.root-A" -- 2.39.2