Skip to content

Rebased nord changes - #143

Open
aswinm94 wants to merge 52 commits into
qualcomm-linux:nord-staging-qcom-nextfrom
aswinm94:nord-0909
Open

aswinm94 wants to merge 52 commits into
qualcomm-linux:nord-staging-qcom-nextfrom
aswinm94:nord-0909

Conversation

@aswinm94

@aswinm94 aswinm94 commented Sep 9, 2026

Copy link
Copy Markdown

Rebased nord changes for qup fw loading issue

aswinm94 and others added 30 commits September 9, 2026 19:06
Add the qcom,hwinfo U-Boot overlay node to nord-ride-u-boot.dtsi so
that the qcom_hwinfo driver can read the IMEM boot cookie and the TCSR
SOC_HW_VERSION register at boot.

Signed-off-by: Aswin Murugan <aswin.murugan@oss.qualcomm.com>
scsi_scan() removes existing SCSI block devices before rescanning,
which can invalidate existing references and requires callers to
avoid redundant scans.

Add scsi_scan_new() to scan only controllers without bound block
devices, making repeated scans safe and eliminating the need for
scan guards at individual call sites.

Signed-off-by: Aswin Murugan <aswin.murugan@oss.qualcomm.com>
Capsule update may miss newly attached SCSI storage when SCSI has
already been scanned earlier in boot.

Use scsi_scan_new() to detect newly added devices while avoiding
rescanning controllers that already have enumerated block devices.

Signed-off-by: Aswin Murugan <aswin.murugan@oss.qualcomm.com>
Revert the SPL Lemans fixes merged via qualcomm-linux/u-boot PR qualcomm-linux#85
(qualcomm-linux#85).

This reverts the following qcom-next commits:
  5f0cc1d configs: lemans_spl: Remove TEXT_BASE and REMAKE_ELF configs
  530ecc7 arm: dts: lemans-evk: Remove hardcoded memory node
  bede6f8 misc: qcom-spmi-sdam: Add PHASE_ prefix support

Signed-off-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
…mm-linux#79)

Revert the Lemans EVK SPL support merged via qualcomm-linux/u-boot PR qualcomm-linux#79
(qualcomm-linux#79).

This reverts the following qcom-next commits:
  4c09f12 qcom_lemans_spl: disable SPL_QCOM_BOOT_FROM_PBL for XBL boot
  1d68746 mach-snapdragon: spl: add SPL_QCOM_BOOT_FROM_PBL Kconfig option
  c910816 configs: qcom: Add qcom_lemans_spl_defconfig for Lemans EVK
  ad30037 arm: dts: qcom: Add Lemans EVK U-Boot DTS overlay for SPL

Signed-off-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
…ualcomm-linux#77)

Revert the initial SPL support for Qualcomm Snapdragon SoCs (IPQ5210 and
core SPL infrastructure) merged via qualcomm-linux/u-boot PR qualcomm-linux#77
(qualcomm-linux#77).

This reverts the following qcom-next commits:
  976563d doc: board/qualcomm: Update RDP build instructions
  9fa2f27 configs: add qcom_ipq5210_mmc_defconfig
  2bd29d6 mach-snapdragon: Add commands to create wrapper ELF
  18e16ee mach-snapdragon: spl: Update SMEM with boot details
  60b1477 mach-snapdragon: Add initial support for QCOM SPL
  e3003d1 spl: Include SMEM driver in SPL
  3635906 mach-snapdragon: Add PBL shared data defines
  16c3f92 misc: qcom_geni: Add minicore support
  f460d84 pinctrl: qcom: Add ipq5210 pinctrl driver
  945097f clk/qcom: add initial clock driver for ipq5210
  316563b dts: ipq5210-rdp504-u-boot: add override dtsi
  3034e84 binman: qcom: Add type definitions for Qualcomm binaries
  eb026ca binman: Ignore noload segments for image numbering

Signed-off-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Currently only board/vendor/$(BOARD)/config.mk is supported, add the
additional usecase of having a vendor generic config.mk for adding
functionality like platform-specific build targets.

Additionally, fix the ifdef to correctly check for $(BOARDDIR) rather
than $(BOARD) since that's what is actually used in the include path.

Reviewed-by: Tom Rini <trini@konsulko.com>
Link: https://patch.msgid.link/20260511-b4-qcom-tooling-improvements-v7-1-0c06346e79a9@linaro.org
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
This is a fork of qtestsign[1] with modifications to integrate with the
U-Boot build system. It is pulled from

f3df53a5f0e3 ("Rename "fw" to "mbn"")

New Qualcomm dev boards flash U-Boot to the "uefi" partition, the format
is a standard ELF file with custom program headers containing Qualcomm
signatures, hashes and other metadata. Currently this is accomplished
with qtestsign manually, let's instead import it so we can integrate it
into the build process.

This library will be used by a new mkmbn.py tool to create MBN files
which can be directly flashed to the board.

[1]: https://github.com/msm8916-mainline/qtestsign

Link: https://patch.msgid.link/20260511-b4-qcom-tooling-improvements-v7-2-0c06346e79a9@linaro.org
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Adjust the elf class to support creating ELF files from scratch so that
mkmbn can build an MBN file from the U-Boot binary image and fix some
imports to work correctly in the U-Boot build system.

The new tool inspects the DTB embedded in u-boot.bin and uses a lookup
table to determine the appropriate configuration based on the root
compatible property, effectively encoding the info that was previously
kept in documentation.

Link: https://patch.msgid.link/20260511-b4-qcom-tooling-improvements-v7-3-0c06346e79a9@linaro.org
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Update the build docs to describe building the u-boot.mbn target
explicitly for some boards. Additionally add a new "signing" page to
describe the purpose of mkmbn and the MBN format.

Link: https://patch.msgid.link/20260511-b4-qcom-tooling-improvements-v7-4-0c06346e79a9@linaro.org
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Add a qualcomm specific Makefile fragment to make u-boot.mbn a build
target and introduce a kconfig option to build it by default on relevant
platforms via CONFIG_BUILD_TARGET.

Link: https://patch.msgid.link/20260511-b4-qcom-tooling-improvements-v7-5-0c06346e79a9@linaro.org
[casey: minor kconfig fix]
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
With mkmbn integrated we now no longer need CONFIG_REMAKE_ELF to then
run qtestsign and can instead just enable QCOM_GENERATE_MBN to have
mkmbn emit an MBN file directly.

While we're here, finally rename the db410c and 820c defconfigs to have
the qcom_ prefix.

Tested on qcs6490 and sm8550.

Tested-by: Stephan Gerhold <stephan.gerhold@linaro.org> # db410c
Link: https://patch.msgid.link/20260511-b4-qcom-tooling-improvements-v7-6-0c06346e79a9@linaro.org
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Some platforms (e.g. at least Qualcomm) use the ELF format in creative
ways, including in the bootrom. Make SPL_REMAKE_ELF use a linker script
specified in SPL_REMAKE_ELF_LDSCRIPT (with the previously hardcoded path
as the default).

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-1-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Add CONFIG_SPL_OF_LIVE and if set, initialize of_live in spl.c

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-2-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Only Makefile and Kconfig changes necessary.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-3-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Prepare for supporting alternative boot0.h per-SoC by splitting out
the existing msm8916-specific code.

There is now a selection mechanism to choose a specific boot0.h
in the Kconfig. BOOT0_MSM8916_PSCI_WORKAROUND is the only option
right now, but more can be added. The toplevel boot0.h additionally
enables conditionally performing the include only in u-boot proper,
or only in SPL.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-4-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
This custom linker script is required to produce a bootable ELF
for the sdm845 SoC. An xbl_sec.elf must be provided, which will
be put in a section in the ELF as required by the boot rom.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-5-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-6-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Select SUPPORT_SPL so SPL build can be enabled, disable SYSRESET_PSCI in SPL.
(SPL runs in EL3, so if SPL itself doesn't provide PSCI, nothing else will.)

Also select (SPL_)OF_LIVE and (SPL_)EVENT, which are needed to fix up
upstream dt to make usb work, and in general don't make sense to
disable in SPL as long as we're not running out of SRAM.

Mirror u-boot proper selections like GPIO and pinctrl to ensure consistent
behavior, and select SPL_SPRINTF, SPL_LIBCOMMON_SUPPORT etc for similar
reasons.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-7-c108ebe8ff4e@seznam.cz
[casey: kconfig fix missing "if SPL"]
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
On sdm845, running u-boot SPL in EL3 requires escalting by using
an unintentional feature in old builds of xbl_sec.elf. We do this
in boot0.h so the rest of U-Boot can stay blissfully unaware
of XBL_SEC. If we are already in EL3 for whatever reason, the
code is skipped.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-8-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
This function is currently only really needed on db410c,
move it to the board-specific .c file ahead of introducing
board_spl.c to simplify things. If db410c is to ever be
converted to not use board-spefific funtions, the generic
solution replacing this function should probably not be
Qualcomm-specific anyway.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-9-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
Code in board.c will now only be compiled into U-Boot proper,
and the new board_spl.c will only be built into SPL.
Code in mem_map.c is common to both phases since it seems to not cause
issues in SPL. The existing dram.c is also common to both phases with
similar reasoning.
In the future memory map related code should probably behave differenly
in SPL, especially if dram initialization is supported.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-10-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
The defconfig should in principle be board-agnostic. Environment
simply contains a dfu env specifying where to load u-boot proper
(TEXT_BASE - 64).

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-11-c108ebe8ff4e@seznam.cz
[casey: add missing default devicetree]
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
The board .dtsi just includes the SoC-specific .dtsi, which
adds bootph-all markings to upstream dts nodes which are
needed in SPL.

Signed-off-by: Michael Srba <Michael.Srba@seznam.cz>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Casey Connolly <casey.connolly@linaro.org>
Link: https://patch.msgid.link/20260521-qcom_spl-v9-12-c108ebe8ff4e@seznam.cz
Signed-off-by: Casey Connolly <casey.connolly@linaro.org>
The qcom_geni driver reads an ELF from storage and configures a set of
registers and programs the firmware to the GENI Serial Engine (GENI-SE)
wrapper device for the expected functionality.

Unlike the GENI-SE wrapper found in MSM SoCs, the IPQ5210's GENI-SE
wrapper is pre-configured for one of the functions defined in 'enum
geni_se_protocol_type'. Hence, the firmware download is not needed.
Only the register configuration part is needed.

Earlier, the boot stages before U-Boot would configure the GENI-SE (to
access UART/SPI etc). Since for IPQ5210 U-Boot SPL, the previous stage
(i.e. boot ROM) doesn't do that modify the driver to do the register
configuration part alone without reading an ELF from the storage.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
The commit d38787bb5dafa ("mach-snapdragon: Kconfig: changes / additions to
support SPL") auto selects options that may not be applicable to all
platforms. This results in warning messages during make xxx_defconfig
and/or waiting for user input for on/off or values for certain configs.
So auto select options based on the enabled configs in xxx_defconfig.

Fixes: d38787bb5dafa ("mach-snapdragon: Kconfig: changes / additions to support SPL")

Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Add structure and enum definitions to be able to parse the information
that is passed from PBL. This will be used to identify the boot medium.

Since the PBL shared data defines are private, move spl_boot_device() from
board_spl.c to pbl-shared-data.c to parse the shared data and identify the
boot medium

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Update the SMEM with the boot device information got from the boot rom.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Add routines to enable U-Boot SPL to be able to proceed with the boot from
MMC partitions.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
varada-qcom and others added 22 commits September 9, 2026 19:17
The boot rom expects the secondary boot loader in MBN format followed by
the TME executable. Add rules to board/qualcomm/config.mk to create
u-boot-spl.mbn and u-boot-spl.melf.

u-boot-spl.melf is the combined multi-elf file that has u-boot-spl.mbn
followed by the TME executable.

Additionally, this patch adds a config option to specify the path
of the TME executable to be used to create u-boot-spl.melf.

Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Identify the boot media loader driver and load the FIT image that has the
binaries to initialize the DDR, U-Boot proper etc.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
The U-Boot SPL loads the next stage FIT image into internal SRAM. The
binaries are 'external' in this FIT image. The SPL has to load the DDR init
binary, i.e. qclib and the DDR parameters i.e. qcconfig used by qclib and
invoke the qclib. SPL and qclib exchange information using the interface
table described in doc/board/qualcomm/interface-table.rst.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Add functions that handle loading the FIT image nodes having the Qclib
executable and executing it. Also provides 'weak' hooks that can be
overridden by SoC specific implementations.

Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
* Add initial support for the IPQ5210 MMC based RDP platforms.
* Define memory layout statically.
* Mark the nodes that would be needed for SPL.

Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Sumit Garg <sumit.garg@oss.qualcomm.com>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Add clocks and resets for enabling U-Boot on ipq5210 based RDP platforms.

Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Add pinctrl driver for the TLMM block found in the ipq5210 SoC.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
This patch adds the basic board init routines that invoke the common and
mach-snapdragon specific SPL frameworks to proceed with the hand over from
boot rom to the next stage i.e. U-Boot proper. This also provides the
linker script to generate the SPL image in the format expected by the boot
rom.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Introduce a defconfig for the Qualcomm IPQ5210 SoC based RDPs.
Presently supports eMMC.

Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Add details about the SPL & U-Boot proper build steps, converting to
flashable images, source URLs for the needed binaries and scripts.

Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Enable the missing SPL IPQ5210 pinctrl and GENI options. Disable MBN
generation, which is unsupported for this platform.

Only register the MSM SDHCI tuning callback when MMC tuning is enabled,
avoiding an SPL reference to mmc_send_tuning().

Signed-off-by: abhilash.v <abhilash.v@oss.qualcomm.com>
…ELF options

Add two Kconfig options needed by boards whose SPL is not loaded
directly by PBL:

- SPL_QCOM_BOOT_FROM_PBL: gates whether spl_boot_device() trusts the
  pbl_shared_data structure passed via r0. Boards loaded by an
  intermediate bootloader (e.g. PBL->XBL->U-Boot SPL) don't get valid
  PBL shared data in r0 and must rely on a board-specific
  spl_boot_device() override instead. Defaults to y to preserve
  existing behavior for boards loaded directly by PBL.

- SPL_WRAPPER_ELF: enables wrapping the U-Boot SPL binary in a
  wrapper ELF for boards whose boot ROM / signing tool expects the
  SPL image embedded as an ELF segment.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
…COM_BOOT_FROM_PBL

spl_boot_device() currently assumes the pbl_shared_data structure
passed via r0 is always valid, which only holds when U-Boot SPL is
loaded directly by PBL. On boards where SPL is loaded by an
intermediate bootloader, r0 does not contain valid PBL shared data,
so this parsing must be skipped in favor of a board-specific
spl_boot_device() override.

Wrap the existing boot-media detection logic in a check for
CONFIG_SPL_QCOM_BOOT_FROM_PBL so it only runs when applicable.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
Add the SPL variant of PINCTRL_QCOM_NORD so the Nord pinctrl/GPIO
driver can be built into SPL, needed for Nord-Ride SPL to configure
pins (e.g. for UFS) before DDR/full driver model bring-up.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
Add the SPL defconfig for Nord-Ride dev boards using the "Linux
Embedded" partition layout (dedicated "uefi" partition for edk2/
U-Boot). SPL loads a FIT image containing TF-A, OP-TEE and U-Boot
proper from the "uefi_a" UFS raw partition and hands off to TF-A via
CONFIG_SPL_ATF.

SPL's memory region (0xbc180000-0xbc280000) lays out TEXT, the FIT
load buffer, stack, and malloc/fastboot pool bottom-to-top with
explicit gaps, validated on nord-ride hardware. UFS boot parameters
(devnum 4, partition "uefi_a"/1) come from the target's confirmed
partition table. CONFIG_SPL_QCOM_BOOT_FROM_PBL is left disabled since
nord-ride boots via UFS raw partition rather than PBL, and
CONFIG_SPL_WRAPPER_ELF/the 4K-aligned wrap-elf build is used to meet
the board's boot ROM signing requirements.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
Add the board-specific SPL bring-up for Nord-Ride:

- spl-nord.c: nord-ride always boots the SPL FIT image from a fixed
  UFS raw partition rather than via PBL, so spl_boot_device() is
  hard-coded to BOOT_DEVICE_UFS instead of relying on pbl_shared_data
  (see SPL_QCOM_BOOT_FROM_PBL). Also provides board_init_f() to clear
  BSS, set up malloc, run early init and console, then hand off to
  board_init_r().

- nord-spl-wrap-elf.lds: linker script for the SPL_WRAPPER_ELF build,
  wrapping the SPL binary in a single 4K-aligned PT_LOAD segment as
  required by nord-ride's boot ROM / image-signing tool.

- include/configs/nord.h: board config header (CONFIG_SYS_CONFIG_NAME
  target), currently empty aside from the include guard.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
Some SPL FIT images carry an optional "toc_fdt" image node intended
for BL32 (OP-TEE), used to locate the TOC FDT that OP-TEE consumes.
This node is loaded into memory by the generic FIT loadables path
regardless of QCOM_BOOT_FROM_PBL, but its load address was never
communicated to BL32.

Add qcom_spl_get_toc_fdt_address() to look up the "toc_fdt" node's
load address from the FIT at CONFIG_SPL_LOAD_FIT_ADDRESS, and call it
from bl2_plat_get_bl31_params_v2() so the address can be passed to
BL32 via arg0. The node is optional: boards whose FIT carries no
"toc_fdt" node are unaffected and BL32 receives arg0=0.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
Nord-Ride boots the SPL FIT image from UFS, not MMC. Explicitly
disable CONFIG_SPL_MMC so the MMC boot path is not built into SPL.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
Print which image is being loaded from the FIT (spl_load_simple_fit's
load_simple_fit()) and the BL31 entry address just before jumping
(spl_invoke_atf's bl31_entry()). These give visibility into SPL's
boot progress on platforms without more detailed boot logging, e.g.
"Loading image: tfa" / "Loading image: uboot" / "Loading image: optee"
and "Jumping to BL31 at 0x...".

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
nord-ride's SPL FDT is trimmed to only the nodes tagged bootph-all.
Tag the root clock inputs (xo_board_clk, sleep_clk), the negcc clock
controller, tlmm (pinctrl, needed for UFS reset-gpios), ufs_mem_phy,
ufs_mem_hc, the debug UART and its parent qupv3_0 wrapper, smem, and
its reserved-memory carveout, so all of these survive into the SPL
FDT instead of being trimmed away.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
nord-ride's boot ROM / image-signing tool requires the wrapper ELF's
single PT_LOAD segment to be 4K-aligned. Guard the added linker flags
behind QCOM_SPL_SOC == nord so this only affects nord's wrap-elf
build and does not regress lemans/shikra/ipq5210, which also use the
wrap-elf mechanism but don't need this alignment.

Signed-off-by: smadhesu <smadhesu@qti.qualcomm.com>
qcom_geni_fw_initialise() was unconditionally registered on
EVT_LAST_STAGE_INIT for non-SPL builds. Add CONFIG_QCOM_GENI_FW_LOAD
to make this optional, and disable it by default in qcom_defconfig
for boards that don't need GENI firmware loading.

Signed-off-by: Aswin Murugan <aswin.murugan@oss.qualcomm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants