All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Schultz <d.schultz@phytec.de>
To: <w.egorov@phytec.de>, <trini@konsulko.com>,
	<ggiordano@phytec.com>, <joe.hershberger@ni.com>,
	<u-boot@lists.denx.de>
Cc: <nm@ti.com>, <d-gole@ti.com>, <n-francis@ti.com>,
	<nmorrisson@phytec.com>,  <m.otto@phytec.de>, <bb@ti.com>,
	<upstream@lists.phytec.de>, Daniel Schultz <d.schultz@phytec.de>
Subject: [PATCH 08/10] include: env: phytec: k3_mmc: Add support for FIT boot
Date: Wed, 5 Feb 2025 00:01:44 -0800	[thread overview]
Message-ID: <20250205080146.1944928-9-d.schultz@phytec.de> (raw)
In-Reply-To: <20250205080146.1944928-1-d.schultz@phytec.de>

From: Nathan Morrisson <nmorrisson@phytec.com>

Our Secure Boot implementation uses a fitimage while our normal
boot flow doesn't. Load and boot a fitimage when
PHYTEC_K3_DOFITBOOT_DEFAULT is enabled. Otherwise, use our normal
k3 mmc boot flow.

Signed-off-by: Nathan Morrisson <nmorrisson@phytec.com>
Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
---
 include/env/phytec/k3_mmc.env | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/include/env/phytec/k3_mmc.env b/include/env/phytec/k3_mmc.env
index c4354fbb884..d90bf8277c8 100644
--- a/include/env/phytec/k3_mmc.env
+++ b/include/env/phytec/k3_mmc.env
@@ -15,6 +15,7 @@ doraucboot=1
 mmcargs=setenv bootargs console=${console} earlycon=${earlycon}
 	root=/dev/mmcblk${mmcdev}p${mmcroot} ${raucargs} rootwait rw
 mmcloadimage=load mmc ${mmcdev}:${mmcpart} ${kernel_addr_r} Image
+mmcloadfitimage=load mmc ${mmcdev}:${mmcpart} ${fit_addr_r} fitImage;
 mmcloadfdt=load mmc ${mmcdev}:${mmcpart} ${fdt_addr_r} ${fdtfile}
 mmcboot=
 #ifdef CONFIG_PHYTEC_K3_EMBED_RAUC_ENV
@@ -23,7 +24,12 @@ mmcboot=
 	run mmcargs;
 	mmc dev ${mmcdev};
 	mmc rescan;
+#ifdef CONFIG_PHYTEC_K3_DOFITBOOT_DEFAULT
+	run mmcloadfitimage;
+	bootm ${fit_addr_r};
+#else
 	run mmcloadimage;
 	run mmcloadfdt;
 	run mmc_apply_overlays;
 	booti ${kernel_addr_r} - ${fdt_addr_r}
+#endif
-- 
2.25.1


  parent reply	other threads:[~2025-02-05  8:03 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-05  8:01 [PATCH 00/10] phyCORE-AM62x/AM64x: Add RAUC and Secure Boot Daniel Schultz
2025-02-05  8:01 ` [PATCH 01/10] board: phytec: common: k3: Introduce Configs to Sign Images Daniel Schultz
2025-02-05  8:01 ` [PATCH 02/10] board: phytec: common: k3: Introduce PHYTEC_K3_EMBED_RAUC_ENV Daniel Schultz
2025-02-05  8:01 ` [PATCH 03/10] board: phytec: common: k3: Introduce PHYTEC_K3_DOFITBOOT_DEFAULT Daniel Schultz
2025-02-05  8:01 ` [PATCH 04/10] board: Phytec: phycore_am6*: Add k3 Kconfig to A53 Daniel Schultz
2025-02-05  8:01 ` [PATCH 05/10] arch: arm: dts: k3-am625-phycore-som-binman: Add custMpk and ti-degenerate keys with CONFIG entries Daniel Schultz
2025-02-05  8:01 ` [PATCH 06/10] arch: arm: dts: k3-am642-phycore-som-binman: " Daniel Schultz
2025-02-05  8:01 ` [PATCH 07/10] include: env: phytec: k3_mmc: Use PHYTEC_K3_EMBED_RAUC_ENV to enable RAUC Daniel Schultz
2025-02-05  8:01 ` Daniel Schultz [this message]
2025-02-05  8:01 ` [PATCH 09/10] board: phytec: phycore_am62x: Update environment for fitboot Daniel Schultz
2025-02-05  8:01 ` [PATCH 10/10] board: phytec: phycore_am64x: " Daniel Schultz
2025-02-05 14:51 ` [PATCH 00/10] phyCORE-AM62x/AM64x: Add RAUC and Secure Boot Tom Rini
2025-02-06 10:41   ` Daniel Schultz
2025-02-06 17:07     ` Tom Rini
2025-02-07  6:44       ` Daniel Schultz

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=20250205080146.1944928-9-d.schultz@phytec.de \
    --to=d.schultz@phytec.de \
    --cc=bb@ti.com \
    --cc=d-gole@ti.com \
    --cc=ggiordano@phytec.com \
    --cc=joe.hershberger@ni.com \
    --cc=m.otto@phytec.de \
    --cc=n-francis@ti.com \
    --cc=nm@ti.com \
    --cc=nmorrisson@phytec.com \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    --cc=upstream@lists.phytec.de \
    --cc=w.egorov@phytec.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.