DistroKit Mailinglist
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: distrokit@pengutronix.de
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [DistroKit] [PATCH 2/2] v7a: images: stm32mp: generate eMMC boot partition image as well
Date: Wed, 13 Dec 2023 17:50:16 +0100	[thread overview]
Message-ID: <20231213165014.1279779-2-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20231213165014.1279779-1-a.fatoum@pengutronix.de>

The DistroKit image is capable of booting both from SD-Card and eMMC
user area. For boot from eMMC boot partition, we can keep reusing the
same image for the user area, but need to place the boot firmware into
the boot partition as well. Add an extra image that does just that.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 .../platform-v7a/config/images/stm32mp.config | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/configs/platform-v7a/config/images/stm32mp.config b/configs/platform-v7a/config/images/stm32mp.config
index 58b9232d84a6..f75d6adc054a 100644
--- a/configs/platform-v7a/config/images/stm32mp.config
+++ b/configs/platform-v7a/config/images/stm32mp.config
@@ -4,6 +4,8 @@ image @IMAGE@ {
 		partition-table-type = gpt
 		gpt-no-backup = true
 	}
+
+	/* below three partitions are unused when booting from eMMC boot partition */
 	partition fsbl1 {
 		image = "stm32mp1-tf-a-@STM32MP_BOARD@.stm32"
 		size = 256K
@@ -16,6 +18,7 @@ image @IMAGE@ {
 		image = "@STM32MP_BOARD@.fip"
 		size = 1M
 	}
+
 	partition barebox-environment {
 		size = 1M
 	}
@@ -29,6 +32,22 @@ image @IMAGE@ {
 	}
 }
 
+image @STM32MP_BOARD@-emmcboot.img {
+	hdimage {
+		partition-table = false
+	}
+
+	partition fsbl {
+		image = "stm32mp1-tf-a-@STM32MP_BOARD@.stm32"
+		size = 256K
+	}
+
+	partition fip {
+		image = "@STM32MP_BOARD@.fip"
+		offset = 256K
+	}
+}
+
 image @STM32MP_BOARD@.fip {
 	fip {
 		fw-config = "stm32mp1-@STM32MP_BOARD@-fw-config.dtb"
-- 
2.39.2




  reply	other threads:[~2023-12-13 16:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-13 16:50 [DistroKit] [PATCH 1/2] v7a: stm32mp: tf-a: enable boot from eMMC boot partition Ahmad Fatoum
2023-12-13 16:50 ` Ahmad Fatoum [this message]
2023-12-13 17:23 ` Robert Schwebel

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=20231213165014.1279779-2-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=distrokit@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