All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] Support board-selected raw partitions
@ 2026-09-11 12:05 Carlo Caione
  2026-09-11 12:05 ` [PATCH v2 1/2] spl: mmc: select the boot partition after device initialization Carlo Caione
  2026-09-11 12:05 ` [PATCH v2 2/2] spl: mmc: support dynamic selection in raw partition mode Carlo Caione
  0 siblings, 2 replies; 6+ messages in thread
From: Carlo Caione @ 2026-09-11 12:05 UTC (permalink / raw)
  To: u-boot, uboot-stm32
  Cc: Tom Rini, Peng Fan, Jaehoon Chung, Neil Armstrong,
	Bastien Curutchet, Alexey Charkov, Johan Jonker, Richard Genoud,
	João Marcos Costa, Miquel Raynal, David Lechner,
	Julien Stephan, Ilias Apalodimas, Patrick Delaunay,
	Patrice Chotard, Heinrich Schuchardt, Carlo Caione

Boards may need to read on-device metadata before choosing the raw MMC
partition containing the next boot stage. This series makes the existing
partition hook usable after MMC initialization and adds an explicit
runtime-selection option within raw partition mode.

The board hook owns hardware-area selection. A failed dynamic selection
stops the current MMC load attempt without filesystem fallback; other
configured boot devices may still be tried.

Out-of-tree spl_mmc_boot_partition() overrides must accept the added
struct mmc * argument; the in-tree STM32MP1 override is updated here.

Changes in v2:
- Reuse spl_mmc_boot_partition() instead of adding a second public hook.
- Pass the initialized MMC device and boot-device ID to the hook, and
  defer selection until after any raw Falcon boot attempt.
- Keep explicit partition loads independent of next-stage selection,
  without splitting the MMC loader into preparation and loading functions.
- Make dynamic selection an option within existing raw partition mode,
  select its partition library and hide the unused fixed partition number.
- Restrict STM32's fixed hook and MMC2 partition setting to fixed mode.
- Keep a weak default and diagnose nonpositive dynamic selections before
  filesystem fallback, while preserving fixed-mode behavior.
- Link to v1: https://patch.msgid.link/20260910-ccaione-upstream-part-dynamic-v1-1-381414ad9a34@baylibre.com

Signed-off-by: Carlo Caione <ccaione@baylibre.com>
---
Carlo Caione (2):
      spl: mmc: select the boot partition after device initialization
      spl: mmc: support dynamic selection in raw partition mode

 arch/arm/mach-stm32mp/Kconfig        |  1 +
 arch/arm/mach-stm32mp/stm32mp1/spl.c |  4 ++--
 common/spl/Kconfig                   |  9 +++++++++
 common/spl/spl_mmc.c                 | 22 ++++++++++++++++------
 include/spl.h                        | 21 ++++++++++++++-------
 5 files changed, 42 insertions(+), 15 deletions(-)
---
base-commit: 527115ef6783cec49e5610c523c124b399011361
change-id: 20260909-ccaione-upstream-part-dynamic-4c192e2d4bb6

Best regards,
--  
Carlo Caione <ccaione@baylibre.com>


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2026-09-12 14:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-11 12:05 [PATCH v2 0/2] Support board-selected raw partitions Carlo Caione
2026-09-11 12:05 ` [PATCH v2 1/2] spl: mmc: select the boot partition after device initialization Carlo Caione
2026-09-11 12:05 ` [PATCH v2 2/2] spl: mmc: support dynamic selection in raw partition mode Carlo Caione
2026-09-11 17:41   ` Tom Rini
2026-09-12 10:51     ` Carlo Caione
2026-09-12 14:41       ` Tom Rini

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.