public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [RFC PATCH v1 0/3] efi_loader: Introduce platform hook for FDT selection
@ 2026-01-06 12:21 Aswin Murugan
  2026-01-06 12:21 ` [PATCH v1 1/3] efi_loader: Add platform hook for FDT loading Aswin Murugan
                   ` (4 more replies)
  0 siblings, 5 replies; 13+ messages in thread
From: Aswin Murugan @ 2026-01-06 12:21 UTC (permalink / raw)
  To: trini, casey.connolly, neil.armstrong, sumit.garg, xypron.glpk,
	ilias.apalodimas, varadarajan.narayanan, aswin.murugan, adrianox,
	paul.liu, sjg, wolfgang.wallner, javier.tia, u-boot-qcom, u-boot

This RFC patch series introduces a weak function hook to allow platforms to
provide custom device tree selection logic while keeping common EFI
loader code generic.

Background:
Currently, EFI loader supports loading a single DTB file.
Qualcomm platforms require special multi-DTB selection logic that:
- Reads hardware information from SMEM (Shared Memory)
- Selects the appropriate device tree from a combined DTB file based on:
  * Platform ID (SoC variant)
  * Board variant and subtype
  * PMIC configuration
  * SoC revision.

Solution:
Introduce `efi_load_platform_fdt()` as a weak function:
- Weak implementation in lib/efi_loader/efi_fdt.c (defaults to no-op)
- Called from efi_bootmgr_run() after efi_load_distro_fdt()
- Qualcomm override in arch/arm/mach-snapdragon/efi_fdt_qcom.c

Aswin Murugan (3):
  efi_loader: Add platform hook for FDT loading
  soc: qcom: smem: Added socinfo header file
  mach-snapdragon: Implement Qualcomm multi-DTB selection

 arch/arm/mach-snapdragon/Makefile       |   1 +
 arch/arm/mach-snapdragon/efi_fdt_qcom.c | 339 ++++++++++++++++++++++++
 include/soc/qcom/socinfo.h              | 114 ++++++++
 lib/efi_loader/efi_fdt.c                |  34 +++
 4 files changed, 488 insertions(+)
 create mode 100644 arch/arm/mach-snapdragon/efi_fdt_qcom.c
 create mode 100644 include/soc/qcom/socinfo.h

-- 
2.34.1


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

end of thread, other threads:[~2026-01-15  6:52 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-06 12:21 [RFC PATCH v1 0/3] efi_loader: Introduce platform hook for FDT selection Aswin Murugan
2026-01-06 12:21 ` [PATCH v1 1/3] efi_loader: Add platform hook for FDT loading Aswin Murugan
2026-01-06 16:22   ` Simon Glass
2026-01-07 15:00   ` Ilias Apalodimas
2026-01-07 18:44   ` Heinrich Schuchardt
2026-01-06 12:21 ` [PATCH v1 2/3] soc: qcom: smem: Added socinfo header file Aswin Murugan
2026-01-06 12:21 ` [PATCH v1 3/3] mach-snapdragon: Implement Qualcomm multi-DTB selection Aswin Murugan
2026-01-08 12:10 ` [RFC PATCH v1 0/3] efi_loader: Introduce platform hook for FDT selection Sumit Garg
2026-01-10  8:30 ` Aswin Murugan
2026-01-12  8:10   ` Heinrich Schuchardt
2026-01-12 13:48   ` Casey Connolly
2026-01-15  6:51     ` Sumit Garg
2026-01-15  6:50   ` Sumit Garg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox