pandora-u-boot.git
2 months agoMerge branch 'next'
Tom Rini [Mon, 7 Apr 2025 22:40:02 +0000 (16:40 -0600)]
Merge branch 'next'

Note that this undoes the changes of commit cf6d4535cc4c ("x86:
emulation: Disable bloblist for now") as that was intended only for the
release due to time.

2 months agoRevert "Merge patch series "pxe: Precursor series for supporting read_all() in extlin...
Tom Rini [Mon, 7 Apr 2025 18:35:13 +0000 (12:35 -0600)]
Revert "Merge patch series "pxe: Precursor series for supporting read_all() in extlinux / PXE""

This reverts commit 8bc3542384e3a1219e5ffb62b79d16dddc1b1fb9, reversing
changes made to 698edd63eca090a2e299cd3facf90a0b97bed677.

There are still problems with this series to work out.

Link: https://lore.kernel.org/u-boot/CAFLszTjw_MJbK9tpzVYi3XKGazcv55auBAdgVzcAVUta7dRqcg@mail.gmail.com/
Signed-off-by: Tom Rini <trini@konsulko.com>
2 months agoPrepare v2025.04 v2025.04
Tom Rini [Mon, 7 Apr 2025 21:57:55 +0000 (15:57 -0600)]
Prepare v2025.04

Signed-off-by: Tom Rini <trini@konsulko.com>
2 months agobuildman: update PyYAML requirement
Heinrich Schuchardt [Mon, 7 Apr 2025 06:47:12 +0000 (08:47 +0200)]
buildman: update PyYAML requirement

On Ubuntu 25.04 installing the dependency pyyaml 6.0 fails with

    License classifiers are deprecated

Update PyYAML to the current release.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2 months agoefi_loader: stop network in EXIT_BOOT_SERVICES
Heinrich Schuchardt [Sat, 5 Apr 2025 06:58:12 +0000 (08:58 +0200)]
efi_loader: stop network in EXIT_BOOT_SERVICES

It has been reported that memory corruption can occurred because network
packages where received after EXIT_BOOT_SERVICES. See the thread
starting at [1].

We try to remove all drivers when EXIT_BOOT_SERVICES is called. But

* Some network drivers don't call their own stop method when removed.
* Some network drivers don't have a remove method.
* Some devices have CONFIG_DM_DEVICE_REMOVE=n.

Let's call eth_halt() in EXIT_BOOT_SERVICES explicitly.

[1]
https://lore.kernel.org/all/C101B675-EEE6-44CB-8A44-83F72182FBD6@kohlschutter.com/

Cc: Michael Brown <mcb30@ipxe.org>
Reported-by: Christian Kohlschütter <christian@kohlschutter.com>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Michael Brown <mcb30@ipxe.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Tested-by: Christian Kohlschütter <christian@kohlschutter.com>
2 months agoboot: call dhcp_run in pxe bootmethod
Heiko Stuebner [Wed, 2 Apr 2025 21:50:25 +0000 (23:50 +0200)]
boot: call dhcp_run in pxe bootmethod

A recent change tried to speed up EFI booting by not calling dhcp_run
from eth_bootdev_hunt() every time. PXE so far relied on that dhcp_run
call to get an IP address.

Fix that by adding a dhcp_run call to the pxe bootflow, with autoload
disabled to only get the ip address and nothing else.

Suggested-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Fixes: 1f68057e0320 ("net: eth_bootdev_hunt() should not run DHCP")
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
2 months agombedtls: remove incorrect attribute type checker
Raymond Mao [Fri, 4 Apr 2025 14:05:25 +0000 (07:05 -0700)]
mbedtls: remove incorrect attribute type checker

S/MIME Capabilities (OID: 1.2.840.113549.1.9.15) attributes are
expected to be algorithms but neither data nor MS Inderect Data,
thus the checker for data type is incorrect.

This patch fixes a capsule authentication failure with PKCS#7
message that contains S/MIME capabilities, which formed by the EDK2
GenerateCapsule tool.

S/MIME Capabilities are not common attributes in an EFI capsule,
thus this failure cannot be reproduced with the capsules generated
via mkeficapsule.

Fixes: 7de0d155cce7 ("mbedtls: add PKCS7 parser porting layer")
Reported-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Raymond Mao <raymond.mao@linaro.org>
2 months agox86: emulation: Disable bloblist for now
Tom Rini [Fri, 4 Apr 2025 16:36:17 +0000 (10:36 -0600)]
x86: emulation: Disable bloblist for now

As reported by Niklas Sombert, enabling bloblist on these platforms
means that we currently don't pass SMBIOS tables on to later stages. For
the v2025.04 release, disable bloblists as that is sufficient to restore
functionality and we will address the underlying problem for the next
release.

Link: https://lore.kernel.org/u-boot/c1dc7446-d1d0-4ef2-b201-09fc612aa8db@uni-duesseldorf.de
Reported-by: Niklas Sombert <niklas.sombert@uni-duesseldorf.de>
Signed-off-by: Tom Rini <trini@konsulko.com>
2 months agoMerge patch series "Enable MUX_MMIO at SPL stage"
Tom Rini [Sat, 5 Apr 2025 15:35:30 +0000 (09:35 -0600)]
Merge patch series "Enable MUX_MMIO at SPL stage"

Anurag Dutta <a-dutta@ti.com> says:

This series enables MUX_MMIO at SPL stage for j7200 and j721e
as it is required for successful hyperflash boot.

Test logs :
https://gist.github.com/anuragdutta731/b4c79ef8da56d8c50b38d953c9da4d45

Link: https://lore.kernel.org/r/20250320063004.1069653-1-a-dutta@ti.com
2 months agoarm: mach-k3: k3-ddr.h: Include spl.h
Neha Malcom Francis [Thu, 20 Mar 2025 06:27:33 +0000 (11:57 +0530)]
arm: mach-k3: k3-ddr.h: Include spl.h

Include spl.h to avoid definition errors in custom builds.

Fixes: commit bc07851897bd ("board: ti: Pull redundant DDR functions to a common location and Fixup DDR size when ECC is enabled")
Signed-off-by: Neha Malcom Francis <n-francis@ti.com>
2 months agoarm: mach-k3: j721e: Split out J7200 SoC support from J721e
Andrew Davis [Wed, 19 Mar 2025 18:54:58 +0000 (13:54 -0500)]
arm: mach-k3: j721e: Split out J7200 SoC support from J721e

Currently in j721e_init.c we check which firewalls to remove using
the board configuration (e.g CONFIG_TARGET_J721E_R5_EVM). We do this
as J721e and J7200 have different IP and firewalls but use the same
SoC definition (SOC_K3_J721E) even though they are different SoCs.

The idea was they would be similar enough that they both could use
the same SoC config to help with common code sharing. Board checks
would then be used differentiate.

This has grown far too messy to maintain any more, especially now
that there is more than one board using J721e (EVM, SK, Beagle AI64).
As differentiation is done based on board, every one of these boards
would have to have checks added for them. Instead let's split J7200
support out from J721e like how normal new SoC support is done.

This patch touches several subsystems and could not be split much better
as when we add SOC_K3_J7200 we want to make use of it in all spots that
once used the combined SOC_K3_J721E so we can turn off SOC_K3_J721E when
building for J7200 boards.

Signed-off-by: Andrew Davis <afd@ti.com>
2 months agoarm: dts: k3: Remove leftover file after OF_UPSTREAM
Andrew Davis [Wed, 19 Mar 2025 15:15:50 +0000 (10:15 -0500)]
arm: dts: k3: Remove leftover file after OF_UPSTREAM

The file k3-am62a7.dtsi is part of upstream DT and should
have been removed when migrating to OF_UPSTREAM but must
have been missed. Do this here.

Signed-off-by: Andrew Davis <afd@ti.com>
2 months agoconfigs: j721e_evm_a72_defconfig: Enable MUX_MMIO at SPL
Anurag Dutta [Thu, 20 Mar 2025 06:30:04 +0000 (12:00 +0530)]
configs: j721e_evm_a72_defconfig: Enable MUX_MMIO at SPL

MUX_MMIO is required in SPL stage in order to boot hyperflash
successfully. Add configs to enable MUX_MMIO in SPL stage.

Signed-off-by: Anurag Dutta <a-dutta@ti.com>
2 months agoconfigs: j7200_evm_a72_defconfig: Enable MUX_MMIO at SPL
Anurag Dutta [Thu, 20 Mar 2025 06:30:03 +0000 (12:00 +0530)]
configs: j7200_evm_a72_defconfig: Enable MUX_MMIO at SPL

MUX_MMIO is required in SPL stage in order to boot hyperflash
successfully. Add configs to enable MUX_MMIO in SPL stage.

Signed-off-by: Anurag Dutta <a-dutta@ti.com>
2 months agomux: Kconfig: Add Kconfig options for MUX_MMIO
Anurag Dutta [Thu, 20 Mar 2025 06:30:02 +0000 (12:00 +0530)]
mux: Kconfig: Add Kconfig options for MUX_MMIO

Add Kconfig options for MUX_MMIO so that it can be enabled
in SPL stage.

Signed-off-by: Anurag Dutta <a-dutta@ti.com>
2 months agoMerge patch series "64-bit U-Boot configuration without SPL"
Tom Rini [Fri, 4 Apr 2025 18:26:50 +0000 (12:26 -0600)]
Merge patch series "64-bit U-Boot configuration without SPL"

Jeremy Compostella <jeremy.compostella@intel.com> says:

Introduces a new configuration option X86_RUN_64BIT_NO_SPL to allow
building U-Boot as a 64-bit binary without using the SPL (Secondary
Program Loader). The motivation is to simplify the boot process for
specific x86-based platforms that do not require SPL, such as those
booting directly from a 64-bit coreboot firmware.

Link: https://lore.kernel.org/r/87bjtyutkp.fsf@jcompost-mobl.amr.corp.intel.com
2 months agoconfigs: Add coreboot64-no-spl_defconfig for 64-bit X86 without SPL
Jeremy Compostella [Tue, 18 Mar 2025 17:42:06 +0000 (10:42 -0700)]
configs: Add coreboot64-no-spl_defconfig for 64-bit X86 without SPL

Create a new defconfig file called `coreboot64-no-spl_defconfig`,
tailored specifically for 64-bit X86 architecture systems that operate
without the Secondary Program Loader (SPL). This configuration takes its
inspiration from `coreboot64_defconfig`..

Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2 months agoFix EFI boot file name definition for 64-bit x86
Jeremy Compostella [Tue, 18 Mar 2025 17:41:38 +0000 (10:41 -0700)]
Fix EFI boot file name definition for 64-bit x86

This change aligns the preprocessor directive with the standard
configuration flag used for detecting 64-bit x86 architecture.

Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2 months agoarch/x86/lib: Fix CONFIG_X86_64 usage in zimage.c
Jeremy Compostella [Tue, 18 Mar 2025 17:40:34 +0000 (10:40 -0700)]
arch/x86/lib: Fix CONFIG_X86_64 usage in zimage.c

Correct the preprocessor directive used to check for 64-bit kernel
support in the `zboot_go` function. The code previously checked for
`CONFIG_X86_RUN_64BIT`, which is not the correct configuration option
for determining if the kernel should run in 64-bit mode. The correct
option is `CONFIG_X86_64`.

Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2 months agoarch/x86/cpu: Call x86_cpu_reinit_f for 64-bits
Jeremy Compostella [Tue, 18 Mar 2025 17:40:03 +0000 (10:40 -0700)]
arch/x86/cpu: Call x86_cpu_reinit_f for 64-bits

As both CONFIG_X86_RUN_64BIT and X86_RUN_64BIT_NO_SPL cases run U-Boot
in 64-bit mode with the CPU fully initialized already.

Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2 months agoarch/x86: Add 64-bit U-Boot configuration without SPL
Jeremy Compostella [Tue, 18 Mar 2025 17:39:40 +0000 (10:39 -0700)]
arch/x86: Add 64-bit U-Boot configuration without SPL

This commit introduces a new configuration option X86_RUN_64BIT_NO_SPL
to allow building U-Boot as a 64-bit binary without using the SPL
(Secondary Program Loader). The motivation is to simplify the boot
process for certain x86-based platforms that do not require SPL, such as
those booting directly from a 64-bit coreboot firmware.

This update revises the `X86_RUN_64BIT` configuration to more accurately
describe its role as "32-bit SPL followed by 64-bit U-Boot." It
clarifies the sequence of operations during the boot process, where the
system transitions from a 32-bit SPL (Secondary Program Loader) to the
main 64-bit U-Boot.

Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2 months agoMerge patch series "cmd: fuse: Introduce fuse writebuff sub-system and clean up"
Tom Rini [Fri, 4 Apr 2025 18:25:11 +0000 (12:25 -0600)]
Merge patch series "cmd: fuse: Introduce fuse writebuff sub-system and clean up"

Harsha Vardhan V M <h-vm@ti.com> says:

This patch series introduces the fuse writebuff sub-system command and
makes improvements to the existing fuse implementation by removing the
custom string functions. The patches are required to be applied in
sequence.

The series consists of the following changes:
Patch 1 removes custom string functions and replaces them with standard
string functions.
Patch 2 introduces fuse.rst documentation for fuse commands.
Patch 3 introduces the fuse writebuff sub-system command, allowing to
write a structured buffer in memory to fuses, and implementing the
necessary function calls.
Patch 4 enables the fuse sub-system in the K3 platform.
Patch 5 updates the fuse.rst documentation to include details about the
new fuse writebuff command.

These changes aim to improve the fuse sub-system by the removal of
custom string functions and the addition of the fuse writebuff
command improves fuse programming workflows by allowing to write a
structured buffer in memory to efuses.

Link: https://lore.kernel.org/r/20250319084714.335777-1-h-vm@ti.com
2 months agodoc: cmd: Add fuse writebuff cmd documentation
Harsha Vardhan V M [Wed, 19 Mar 2025 08:47:14 +0000 (14:17 +0530)]
doc: cmd: Add fuse writebuff cmd documentation

Add fuse writebuff sub-system command documentation.

Signed-off-by: Harsha Vardhan V M <h-vm@ti.com>
2 months agodrivers: k3_fuse: Add fuse sub-system func calls
Harsha Vardhan V M [Wed, 19 Mar 2025 08:47:13 +0000 (14:17 +0530)]
drivers: k3_fuse: Add fuse sub-system func calls

Add K3_FUSE config option to add and enable fuse sub-system
implementation function calls.

Signed-off-by: Harsha Vardhan V M <h-vm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2 months agocmd: fuse: Add fuse writebuff sub-system command
Harsha Vardhan V M [Wed, 19 Mar 2025 08:47:12 +0000 (14:17 +0530)]
cmd: fuse: Add fuse writebuff sub-system command

Add CMD_FUSE_WRITEBUFF config option to add and enable fuse writebuff
sub-system command. Add fuse_writebuff function to be invoked on
writebuff command.

Signed-off-by: Harsha Vardhan V M <h-vm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2 months agodoc: cmd: Add documentation for fuse command
Harsha Vardhan V M [Wed, 19 Mar 2025 08:47:11 +0000 (14:17 +0530)]
doc: cmd: Add documentation for fuse command

Add documentation for the 'fuse' sub-system commands in
doc/usage/cmd/fuse.rst file.
Remove doc/README.fuse file.

Signed-off-by: Harsha Vardhan V M <h-vm@ti.com>
2 months agocmd: fuse: Remove custom string functions
Harsha Vardhan V M [Wed, 19 Mar 2025 08:47:10 +0000 (14:17 +0530)]
cmd: fuse: Remove custom string functions

Remove custom string functions and replace them with normal string
functions. Remove the custom strtou32 and replace it with
simple_strtoul.

Signed-off-by: Harsha Vardhan V M <h-vm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2 months agoarm64: Fix page permissions for platforms running at EL2
Ilias Apalodimas [Wed, 19 Mar 2025 07:22:02 +0000 (09:22 +0200)]
arm64: Fix page permissions for platforms running at EL2

We currently set both and print both PXN and UXN bits when removing
execution for pages. This happens even in the existing per platform
definitions of 'struct mm_region'.

That's not entirely correct though. For stage-1 translations, if a
platform runs on a translation regime with a single privilege level or the
the translation regime supports two privilege levels and we are not
in EL1&0 with HCR_EL2.{NV, NV1} = {1, 1} only BIT54 (XN) is needed
and BIT53(PXN) is reserved 0.

Currently we support Non-Secure EL2, Non-secure EL2&0 and Non-secure
EL1&0.

We already have get_effective_el() which returns 1 if we are
- Running in EL1 so we assume an EL1 translation regime but without
  checking HCR_EL2.{NV, NV1} != {1,1}
- Running in EL2 with HCR_EL2.E2H = 1

The only problem with the above is that if we are in EL1&0 and
HCR_EL2.{NV1, NV} == {1, 1}, then
- Bit[54] holds the PXN instead of the UXN
- The Effective value of UXN is 0
- Bit[53] is RES0

So let's re-use that function and set PXN only when we are in
and EL[2|1]&0 translation regime.

Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2 months agoMerge tag 'u-boot-amlogic-20250404' of https://source.denx.de/u-boot/custodians/u...
Tom Rini [Fri, 4 Apr 2025 15:02:37 +0000 (09:02 -0600)]
Merge tag 'u-boot-amlogic-20250404' of https://source.denx.de/u-boot/custodians/u-boot-amlogic

- Check interface before comparing it in set_dfu_alt_info() to avoid
  hard crash on capsule update

2 months agoboard: libre-computer: check interface before comparing it in set_dfu_alt_info()
Neil Armstrong [Thu, 3 Apr 2025 16:03:21 +0000 (18:03 +0200)]
board: libre-computer: check interface before comparing it in set_dfu_alt_info()

When set_dfu_alt_info() is called, interface can be NULL when called for
the EFI capsule, so check it before calling it with strcmp().

Fixes: 12ea40d29dc ("ARM: meson: add support for Libre Computer aml-s905d3-cc")
Fixes: 9e6e6b034b1 ("ARM: meson: add support for Libre Computer aml-a311d-cc")
Fixes: 75c87c6cbc0 ("board: libre-computer: aml-s805x-cc: Enable capsule updates")
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Link: https://lore.kernel.org/r/20250403-u-boot-fix-set-dfu-alt-info-interface-v1-1-1fdd12463186@linaro.org
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
2 months agoMerge patch series "membuff: Add tests and update to support a flag for empty/full"
Tom Rini [Thu, 3 Apr 2025 22:54:59 +0000 (16:54 -0600)]
Merge patch series "membuff: Add tests and update to support a flag for empty/full"

Simon Glass <sjg@chromium.org> says:

The membuff implementation curently has no tests. It also assumes that
head and tail can never correspond unless the buffer is empty.

This series provides a compile-time flag to support a 'full' flag. It
also adds some tests of the main routines.

The data structure is also renamed to membuf which fits better with
U-Boot.

There may be some cases in the code which could be optimised a little,
but the implementation is functional.

Link: https://lore.kernel.org/r/20250318152059.1464369-1-sjg@chromium.org
2 months agomembuf: Minor code-style improvements
Simon Glass [Tue, 18 Mar 2025 15:20:48 +0000 (16:20 +0100)]
membuf: Minor code-style improvements

Show the start in end in the comment. Comment a missing variable in
membuf_readline() and fix its line length.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agomembuf: Add some tests
Simon Glass [Tue, 18 Mar 2025 15:20:47 +0000 (16:20 +0100)]
membuf: Add some tests

Add tests for the membuf implementation.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agomembuf: Correct implementation of membuf_dispose()
Simon Glass [Tue, 18 Mar 2025 15:20:46 +0000 (16:20 +0100)]
membuf: Correct implementation of membuf_dispose()

This should free the pointer, not the address of the pointer. Fix it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agomembuf: Include stdbool
Simon Glass [Tue, 18 Mar 2025 15:20:45 +0000 (16:20 +0100)]
membuf: Include stdbool

This uses a bool type so include the required header.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agomembuf: Rename struct
Simon Glass [Tue, 18 Mar 2025 15:20:44 +0000 (16:20 +0100)]
membuf: Rename struct

Rename the struct to match the function prefix and filenames.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agomembuff: Rename the files to membuf
Simon Glass [Tue, 18 Mar 2025 15:20:43 +0000 (16:20 +0100)]
membuff: Rename the files to membuf

Rename the C and header files to use the membuf basename, to match the
functions.

Add a MAINTAINERS entry while we are here.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agomembuff: Rename functions to have membuf_ prefix
Simon Glass [Tue, 18 Mar 2025 15:20:42 +0000 (16:20 +0100)]
membuff: Rename functions to have membuf_ prefix

The double 'f' is not necessary and is a bit annoying as elsewhere in
U-Boot we use 'buf'. Rename all the functions before it is used more
widely.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agoMerge patch series "x86: Improve operation under QEMU"
Tom Rini [Thu, 3 Apr 2025 17:43:38 +0000 (11:43 -0600)]
Merge patch series "x86: Improve operation under QEMU"

Simon Glass <sjg@chromium.org> says:

U-Boot can start and boot an OS in both qemu-x86 and qemu-x86_64 but it
is not perfect.

With both builds, executing the VESA ROM causes an intermittent hang, at
least on some AMD CPUs.

With qemu-x86_64 kvm cannot be used since the move to long mode (64-bit)
is done in a way that works on real hardware but not with QEMU. This
means that performance is 4-5x slower than it could be, at least on my
CPU.

We can work around the first problem by using Bochs, which is anyway a
better choice than VESA for QEMU. The second can be addressed by using
the same descriptor across the jump to long mode.

With an MTRR fix this allows booting into Ubuntu on qemu-x86_64

In v3 some e820 patches are included to make booting reliable and avoid
ACPI tables being dropped. Also, several MTTR problems are addressed, to
support memory sizes above 4GB reliably.

Link: https://lore.kernel.org/all/20250315142643.2600605-1-sjg@chromium.org/
2 months agotest: Add a test for booting Ubuntu 24.04
Simon Glass [Sat, 15 Mar 2025 14:26:06 +0000 (14:26 +0000)]
test: Add a test for booting Ubuntu 24.04

Now that U-Boot can boot this quickly, using kvm, add a test that the
installer starts up correctly.

Use the qemu-x86_64 board in the SJG lab.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agoacpi: Support checking checksums
Simon Glass [Sat, 15 Mar 2025 14:26:05 +0000 (14:26 +0000)]
acpi: Support checking checksums

When the ACPI tables come from an earlier bootloader it is helpful to
see whether the checksums are correct or not. Add a -c flag to the
'acpi list' command to support that.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agotest: acpi: Correct memory leaks
Simon Glass [Sat, 15 Mar 2025 14:26:04 +0000 (14:26 +0000)]
test: acpi: Correct memory leaks

Free the memory used in tests to avoid a leak. Also unmap the addresses
for sandbox.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2 months agoacpi: Add a checksum to the DMAR table
Simon Glass [Sat, 15 Mar 2025 14:26:03 +0000 (14:26 +0000)]
acpi: Add a checksum to the DMAR table

This table lacks a correct checksum at present, so fix it.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2 months agosandbox: acpi: Correct mapping in FADT
Simon Glass [Sat, 15 Mar 2025 14:26:02 +0000 (14:26 +0000)]
sandbox: acpi: Correct mapping in FADT

The values in the FADT are pointers so should not go through sandbox's
normal addr<->pointer mapping. Fix this.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agosandbox: acpi: Avoid a warning about FADT
Simon Glass [Sat, 15 Mar 2025 14:26:01 +0000 (14:26 +0000)]
sandbox: acpi: Avoid a warning about FADT

Add a condition for sandbox, to match that of x86, to avoid the warning
"FADT not ACPI-hardware-reduced-compliant".

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agoboot: Support IO UARTs for earlycon and console
Simon Glass [Sat, 15 Mar 2025 14:26:00 +0000 (14:26 +0000)]
boot: Support IO UARTs for earlycon and console

Update the string to take account of UARTs which are connected on I/O
ports, as on x86.

Fix a typo in an error message in the same command, while we are here.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agoboot: Handle running out of labels
Simon Glass [Sat, 15 Mar 2025 14:25:59 +0000 (14:25 +0000)]
boot: Handle running out of labels

If only a single label is provided in the list, bootdev_next_label()
does not operate correctly and reads beyond the end of the pointer list.

Fix this by adding a new check. Also add a note to convert this array
to an alist

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agoboot: Consider non-bootable partitions
Simon Glass [Sat, 15 Mar 2025 14:25:58 +0000 (14:25 +0000)]
boot: Consider non-bootable partitions

Any 'bootable' flag in a DOS partition causes boostd to only scan
bootable partitions for that media. This can mean that extlinux.conf
files on the root disk are missed.

Put this logic behind a flag and update the documentation.

For now, the flag is enabled, to preserve the existing behaviour of
bootstd which is to ignore non-bootable partitions so long as there is
at least one bootable partition on the disk.  Future work may provide a
command (or some other mechanism) to control this.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agoacpi: Mark struct acpi_rsdp as packed
Simon Glass [Sat, 15 Mar 2025 14:25:57 +0000 (14:25 +0000)]
acpi: Mark struct acpi_rsdp as packed

At present the size of this struct is too large on 64-bit machines.
Annotate it with __packed to fix this.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Support a 64-bit ramdisk address
Simon Glass [Sat, 15 Mar 2025 14:25:56 +0000 (14:25 +0000)]
x86: Support a 64-bit ramdisk address

Add some missing pieces to bootparams so that a 64-bit ramdisk address
can be used. Tidy up the logging while we are here.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: emulation: Support BLOBLIST_TABLES properly
Simon Glass [Sat, 15 Mar 2025 14:25:55 +0000 (14:25 +0000)]
x86: emulation: Support BLOBLIST_TABLES properly

The existing QEMU implementation mostly ignored BLOBLIST_TABLES and
allocates the bulk of the tables with malloc(). Update it to place all
tables in the bloblist. Since QEMU declares a size of 128KB regardless
of the size of its tables, this requires a larger bloblist.

Fix up the e820 table to handle this, keeping the old code as an option
for now, to assist with any future bug-fixing.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: qemu: Use the new e820 API
Simon Glass [Sat, 15 Mar 2025 14:25:54 +0000 (14:25 +0000)]
x86: qemu: Use the new e820 API

Move over to use this API before making the code even more complicated.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Add a new API for e820
Simon Glass [Sat, 15 Mar 2025 14:25:53 +0000 (14:25 +0000)]
x86: Add a new API for e820

The existing mechanism is pretty painful as it requires manual
calculations for anything but a trivial setup.

Add a new API for adding e820 entries.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: e820: Add a function to dump the e820 table
Simon Glass [Sat, 15 Mar 2025 14:25:52 +0000 (14:25 +0000)]
x86: e820: Add a function to dump the e820 table

There is already code for this in zimage. Move it to the e820 file so
it can be used elsewhere.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agotest/py: Allow tests to be filtered by role
Simon Glass [Sat, 15 Mar 2025 14:25:51 +0000 (14:25 +0000)]
test/py: Allow tests to be filtered by role

Some test can only be run by a particular board in a lab, e.g. because
they are loaded with an OS image used by the test. Add a way to specify
this in tests.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agotest/py: Add a helper to send characters
Simon Glass [Sat, 15 Mar 2025 14:25:50 +0000 (14:25 +0000)]
test/py: Add a helper to send characters

The existing run_command() method is not great for sending things other
than U-Boot commands. Add a helper for sending arbitrary strings as well
as control characters.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2 months agotest/py: Correct sizing of created disks
Simon Glass [Sat, 15 Mar 2025 14:25:49 +0000 (14:25 +0000)]
test/py: Correct sizing of created disks

At present the disks end up being 1MB shorter than they should be,
since dd truncates by default.

Move the code into a function and update it to avoid truncation.

This resolves various warnings when running sandbox tests, of the form:

   mmc_bread() MMC: block number 0x9801 exceeds max(0x9800)

caused by the FAT partition being scanning.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: qemu: Support environment and cat command
Simon Glass [Sat, 15 Mar 2025 14:25:48 +0000 (14:25 +0000)]
x86: qemu: Support environment and cat command

Add support for an environment stored in the first partition of the
disk, which is assumed to hold a FAT filesystem.

Support the 'cat' command as it is useful for looking at extlinux.conf
files.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: emulation: Set an MTRR for the RAM
Simon Glass [Sat, 15 Mar 2025 14:25:47 +0000 (14:25 +0000)]
x86: emulation: Set an MTRR for the RAM

QEMU likes to have an MTRR set up, just like real machines. Add an MTRR
which covers the total RAM size.

This does nothing on machines without MTRRs.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Allow adding non-aligned size for MTRR
Simon Glass [Sat, 15 Mar 2025 14:25:46 +0000 (14:25 +0000)]
x86: Allow adding non-aligned size for MTRR

At present mtrr_add_request() requires that the size is a power of two.
This is too limiting for machines with 4GB (or more) of RAM, since they
often must take account of a memory hole at 3GB.

Update the function to automatically deal with an unaligned size, using
more MTRRs as required.

The algorithm is taken from coreboot commit 60bce10750

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Correct msr operation on amd64
Simon Glass [Sat, 15 Mar 2025 14:25:45 +0000 (14:25 +0000)]
x86: Correct msr operation on amd64

The CONFIG option is no-longer correct since we can have SPL and PPL
with different bitness.

Fix this and sync up with Linux 6.13 in this area, since this is where
the code came from many years ago.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Update cpuid_eax et al to work on amd64
Simon Glass [Sat, 15 Mar 2025 14:25:44 +0000 (14:25 +0000)]
x86: Update cpuid_eax et al to work on amd64

The existing functions work but the register clobbers are wrong, so
strange bugs results.

The original functions were taken from a very old version of Linux.
Update them from Linux 6.13

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Update mtrr command to support 64-bit values
Simon Glass [Sat, 15 Mar 2025 14:25:43 +0000 (14:25 +0000)]
x86: Update mtrr command to support 64-bit values

The MTRR registers have 64-bit values. Update the command to use 64-bit
values so that memory larger than 4GB can be handled.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Add functions to convert between mtrr size and mask
Simon Glass [Sat, 15 Mar 2025 14:25:42 +0000 (14:25 +0000)]
x86: Add functions to convert between mtrr size and mask

Rather than repeating the same code in several places, add some
functions which can do the conversion.

Use the cpu_phys_address_size() function to obtain the physical-address
size, since it is more reliable with kvm, where the host CPU may have a
different value from the emulation CPU.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Support CPU functions in long mode
Simon Glass [Sat, 15 Mar 2025 14:25:41 +0000 (14:25 +0000)]
x86: Support CPU functions in long mode

At present it is not possible to find out the physical-address size in
long mode, so a predefined value is used.

Update the macros to support this properly, since it is important when
programming MTRRs.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Rename the _D dirty flag
Simon Glass [Sat, 15 Mar 2025 14:25:40 +0000 (14:25 +0000)]
x86: Rename the _D dirty flag

This value happens to be used by ctype.h so chose a different name.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Use a simple jump into long mode
Simon Glass [Sat, 15 Mar 2025 14:25:39 +0000 (14:25 +0000)]
x86: Use a simple jump into long mode

With the 64-bit descriptor we can use a jump instruction, rather than
pushing things on the stack.

Since the processor is in 64-bit mode by this point, pop a 64-bit value
from the stack, containing the target address.

This simplifies the code slightly, in particular its use of the stack.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Use the same GDT when jumping to long mode
Simon Glass [Sat, 15 Mar 2025 14:25:38 +0000 (14:25 +0000)]
x86: Use the same GDT when jumping to long mode

Make use the existing GDT which now includes entries for 64-bit code.
Leave the interrupt descriptors alone. They can be tidied up once U-Boot
starts up.

With this, kvm mode works with QEMU.

Signed-off-by: Simon Glass <sjg@chromium.org>
Fixes: https://source.denx.de/u-boot/custodians/u-boot-dm/-/issues/31

2 months agox86: Disable paging before changing to long mode
Simon Glass [Sat, 15 Mar 2025 14:25:37 +0000 (14:25 +0000)]
x86: Disable paging before changing to long mode

This is required as part of the procedure. The existing code works
because it changes the GDT at the same time, but this makes kvm
unhappy.

Update the algorithm to disable and then re-enable paging.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Tidy up the GDT size in start/16.S
Simon Glass [Sat, 15 Mar 2025 14:25:36 +0000 (14:25 +0000)]
x86: Tidy up the GDT size in start/16.S

Use a symbol to select the size of the GDT, rather than hard-coding a
value. This matches how it is done in start64

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Include stdbool.h in interrupt header
Simon Glass [Sat, 15 Mar 2025 14:25:35 +0000 (14:25 +0000)]
x86: Include stdbool.h in interrupt header

This makes use of a 'bool' type, so include the required header.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Drop the message about features missing in 64-bit
Simon Glass [Sat, 15 Mar 2025 14:25:34 +0000 (14:25 +0000)]
x86: Drop the message about features missing in 64-bit

This functions normally and has done for a while, so drop this scary
message.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: spl: Drop duplicate CPU init
Simon Glass [Sat, 15 Mar 2025 14:25:33 +0000 (14:25 +0000)]
x86: spl: Drop duplicate CPU init

x86_cpu_init_f() is called by arch_cpu_init() a few lines below this
code. Drop the duplicate call.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Use defines for the cache flags
Simon Glass [Sat, 15 Mar 2025 14:25:32 +0000 (14:25 +0000)]
x86: Use defines for the cache flags

Use some named flags when setting up the cache, so it is easier to see
what is going on.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Add 64-bit entries to the GDT
Simon Glass [Sat, 15 Mar 2025 14:25:31 +0000 (14:25 +0000)]
x86: Add 64-bit entries to the GDT

At present it is not possible to execution 64-bit code without
installing an entire new Global Descriptor Table. This is inconvenient
since kvm does not seem to like switching into long mode with a new
table.

It isn't actually necessary, since we can just extend the existing
table. Add some new entries to this effect.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Avoid clearing the VESA display
Simon Glass [Sat, 15 Mar 2025 14:25:30 +0000 (14:25 +0000)]
x86: Avoid clearing the VESA display

U-Boot clears the display when it starts up, so there is no need to ask
the VESA driver to do this. Fix this and add a comment explaining the
flags.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Drop use of CONFIG_REALMODE_DEBUG
Simon Glass [Sat, 15 Mar 2025 14:25:29 +0000 (14:25 +0000)]
x86: Drop use of CONFIG_REALMODE_DEBUG

This option is not actually defined in Kconfig anymore. Use a normal
debug print instead, which has a similar effect.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2 months agox86: Add some log categories
Simon Glass [Sat, 15 Mar 2025 14:25:28 +0000 (14:25 +0000)]
x86: Add some log categories

Add categories for i8259 and bios files, so that log statements have the
right category.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: Drop mpspec from the SPL build
Simon Glass [Sat, 15 Mar 2025 14:25:27 +0000 (14:25 +0000)]
x86: Drop mpspec from the SPL build

This is not needed in SPL, so drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: qemu: Avoid accessing BSS too early
Simon Glass [Sat, 15 Mar 2025 14:25:26 +0000 (14:25 +0000)]
x86: qemu: Avoid accessing BSS too early

BSS is placed in DRAM which is actually available early with QEMU. But
it is cleared by the init sequence, so values stored there are lost.

Move the system-type flag into a function, instead.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: qemu: Enable dhrystone
Simon Glass [Sat, 15 Mar 2025 14:25:25 +0000 (14:25 +0000)]
x86: qemu: Enable dhrystone

Provide the 'dhry' command, which helps to check that kvm is being used
properly with QEMU.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agox86: qemu: Switch to bochs display
Simon Glass [Sat, 15 Mar 2025 14:25:24 +0000 (14:25 +0000)]
x86: qemu: Switch to bochs display

The vesa display is widely used on hardware, but it is a bit of a pain
with QEMU. It requires executing option ROMs, which either doesn't work
with kvm, or is difficult to do in a kvm/QEMU-friendly way.

THe bochs display is probably better anyway, so switch to that. It works
fine with kvm as it doesn't need an option ROM.

Signed-off-by: Simon Glass <sjg@chromium.org>
Fixes: https://source.denx.de/u-boot/custodians/u-boot-dm/-/issues/31

2 months agox86: Expand x86_64 early memory
Simon Glass [Sat, 15 Mar 2025 14:25:23 +0000 (14:25 +0000)]
x86: Expand x86_64 early memory

The SPL and pre-reloc malloc()-space is not large enough to start up
with a display. Expand it.

Switch the order of SPL_SYS_MALLOC_F_LEN and SPL_TEXT_BASE since this
matches what 'savedefconfig' gives us.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agosandbox: Correct a typo in mapmem
Simon Glass [Sat, 15 Mar 2025 14:25:22 +0000 (14:25 +0000)]
sandbox: Correct a typo in mapmem

This should say 'cast', not 'case', so fix it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2 months agoMerge patch series "acpi_table: Fix IORT RC node"
Tom Rini [Thu, 3 Apr 2025 17:38:22 +0000 (11:38 -0600)]
Merge patch series "acpi_table: Fix IORT RC node"

This series from Patrick Rudolph <patrick.rudolph@9elements.com> brings
in an assortment of ACPI related fixes.

Link: https://lore.kernel.org/r/20250316083300.2692377-1-patrick.rudolph@9elements.com
2 months agotest: acpi: Add IORT tests
Patrick Rudolph [Sun, 16 Mar 2025 08:32:56 +0000 (09:32 +0100)]
test: acpi: Add IORT tests

Add tests for IORT table generation:
- SMMU_V3 node
- RC node

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2 months agoacpi: Conditionally set mapping_offset in IORT
Patrick Rudolph [Sun, 16 Mar 2025 08:32:55 +0000 (09:32 +0100)]
acpi: Conditionally set mapping_offset in IORT

The spec recommends to set the mapping_offset only when there are
ID mappings as indicated by the mapping_count field.

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2 months agoacpi: Clear reserved bits in IORT
Patrick Rudolph [Sun, 16 Mar 2025 08:32:54 +0000 (09:32 +0100)]
acpi: Clear reserved bits in IORT

The IORT spec says that reserved bits must be set to zero, thus clear
all fields of the struct before starting to fill out non-reserved
fields.

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2 months agoacpi_table: Add asserts in IORT
Patrick Rudolph [Sun, 16 Mar 2025 08:32:53 +0000 (09:32 +0100)]
acpi_table: Add asserts in IORT

Check that the provided offsets are really pointing to a node
that have been previously written and are of the correct type.

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2 months agoacpi_table: Fix IORT RC node
Patrick Rudolph [Sun, 16 Mar 2025 08:32:52 +0000 (09:32 +0100)]
acpi_table: Fix IORT RC node

Even though the RC node has the correct size and the ID mappings
are written to the end of the node, the ID 'mapping offset' and
'mapping count' are not written in the IORT RC node header, thus it
looks like that the RC node has no ID mappings.
The Linux kernel doesn't complain about the invalid IORT RC node,
even though the spec says that each RC node must have an ID mapping.
The kernel will fail to use MSI IRQs and fall back to a legacy IRQ
mechanism that's not working either.
Finally it will show strange behaviour around PCI interrupts, making it
hard to trace back to an invalid IORT RC nodes.

Add the missing ID mapping count and mapping offset.

TEST: Fixes IRQ usage of PCI devices on qemu/sbsa-ref.
Fixes: bf5d37662da5 "acpi: acpi_table: Add IORT support"

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2 months agoMerge patch series "Introduce J742S2 SoC and EVM"
Tom Rini [Thu, 3 Apr 2025 17:37:57 +0000 (11:37 -0600)]
Merge patch series "Introduce J742S2 SoC and EVM"

Manorit Chawdhry <m-chawdhry@ti.com> says:

The series adds support for J742S2 family of SoCs. Also adds J742S2 EVM
Support and re-uses most of the stuff from the superset device J784s4.

This device is a subset of J784S4 and shares the same memory map and
thus the code is being reused from J784S4 to avoid duplication.

It initially cleans up the J784s4 and AM69 files so that they can be
re-usable for j742s2 and then it introduces J742S2.

The DT for the following SoC will be coming to U-boot during 6.13 Sync
so the series is kept as RFC till then.

Here are some of the salient features of the J742S2 automotive grade
application processor:

The J742S2 SoC belongs to the K3 Multicore SoC architecture platform,
providing advanced system integration in automotive, ADAS and industrial
applications requiring AI at the network edge. This SoC extends the K3
Jacinto 7 family of SoCs with focus on raising performance and
integration while providing interfaces, memory architecture and compute
performance for multi-sensor, high concurrency applications.

Some changes that this devices has from J784S4 are:
* 4x Cortex-A72 vs 8x Cortex-A72
* 3x C7x DSP vs 4x C7x DSP
* 4 port ethernet switch vs 8 port ethernet switch
* 2 DDR controller vs 4 DDR controller

Test logs:
https://gist.github.com/manorit2001/f7df0e8cca1e9973b4361f0559c6f53d

Link: https://lore.kernel.org/r/20250317-b4-upstream-j742s2-v4-0-4ba88bfd357a@ti.com
2 months agoconfigs: Introduce configs for J742S2
Manorit Chawdhry [Mon, 17 Mar 2025 04:54:27 +0000 (10:24 +0530)]
configs: Introduce configs for J742S2

Based off j784s4 configs with delta changes for J742S2

[ Add AVS support for J742S2 ]

Signed-off-by: Keerthy <j-keerthy@ti.com>
Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2 months agoarm: dts: Introduce J742S2 U-boot DTS files
Manorit Chawdhry [Mon, 17 Mar 2025 04:54:26 +0000 (10:24 +0530)]
arm: dts: Introduce J742S2 U-boot DTS files

Include the U-boot device tree files needed to boot the board.

[ DDR config ]

Signed-off-by: Neha Malcom Francis <n-francis@ti.com>
Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2 months agoboard: ti: Introduce basic board files for the J742S2 family
Manorit Chawdhry [Mon, 17 Mar 2025 04:54:25 +0000 (10:24 +0530)]
board: ti: Introduce basic board files for the J742S2 family

Introduce the basic files needed to support the TI J742S2 family of SoCs.

Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2 months agoarm: mach-k3: j742s2: Introduce clock and device files for J742S2 SoC
Manorit Chawdhry [Mon, 17 Mar 2025 04:54:24 +0000 (10:24 +0530)]
arm: mach-k3: j742s2: Introduce clock and device files for J742S2 SoC

Re-use j784s4 clocks and power domains for j742s2 family of device.

Reviewed-by: Udit Kumar <u-kumar1@ti.com>
Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2 months agosoc: Add information to identify the J742S2 SoC family
Manorit Chawdhry [Mon, 17 Mar 2025 04:54:23 +0000 (10:24 +0530)]
soc: Add information to identify the J742S2 SoC family

J742S2 has the same part number as J784S4 but JTAG_DEVICE_ID has a
PKG bit that tells about J742S2.

Add support for reading JTAG_DEVICE_ID and set family as J742S2 based
on that.

Link: https://www.ti.com/lit/pdf/spruje3
Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2 months agoarm: dts: k3-j784s4-ddr: Refactor J784s4 ddr file to a common file
Manorit Chawdhry [Mon, 17 Mar 2025 04:54:22 +0000 (10:24 +0530)]
arm: dts: k3-j784s4-ddr: Refactor J784s4 ddr file to a common file

Refactor J784s4 ddr file to a common file which uses the
superset device to allow reuse in j742s2-evm which uses the subset part.

Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2 months agoarm: dts: k3-j784s4-binman.dtsi: Clean up and templatize boot binaries
Neha Malcom Francis [Mon, 17 Mar 2025 04:54:21 +0000 (10:24 +0530)]
arm: dts: k3-j784s4-binman.dtsi: Clean up and templatize boot binaries

Clean up templatized boot binaries for j784s4 soc. This includes
modifying the k3-j784s4-binman.dtsi to use SPL_BOARD_DTB,
BOARD_DESCRIPTION and UBOOT_BOARD_DESCRIPTION from the files that
include it to further reuse code.

k3-j784s4-binman.dtsi will contain only templates. Only required boot
binaries can be built from the templates in the boards' respective
-u-boot.dtsi file (or k3-<board>-binman.dtsi if it exists). This allows
clear distinction between the SoC common stuff vs. what is additionally
needed to boot up a specific board.

Signed-off-by: Neha Malcom Francis <n-francis@ti.com>
[ Do it only for j784s4 ]
Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
2 months agotools: binman: control.py: Delete template nodes after parsing
Neha Malcom Francis [Mon, 17 Mar 2025 04:54:20 +0000 (10:24 +0530)]
tools: binman: control.py: Delete template nodes after parsing

Dynamically going through the subnode array and deleting leads to
templates being skipped from deletion when templates are consecutive in
the subnode list. Prevent this from happening by first parsing the DT
and then deleting the nodes. Add a testcase as well for this cornercase.

Signed-off-by: Neha Malcom Francis <n-francis@ti.com>
2 months agoMerge tag 'efi-2025-04-rc6' of https://source.denx.de/u-boot/custodians/u-boot-efi
Tom Rini [Thu, 3 Apr 2025 13:31:28 +0000 (07:31 -0600)]
Merge tag 'efi-2025-04-rc6' of https://source.denx.de/u-boot/custodians/u-boot-efi

Pull request efi-2025-04-rc6

CI:

* https://source.denx.de/u-boot/custodians/u-boot-efi/-/pipelines/25491

Documentation:

* correct references to overlay-fdt-boot.txt
* build: docker: Fix code highlighting syntax
* build: docker: Use code-block for syntax highlighting
* Fix typo bootfloe to bootflow

UEFI:

* Correct the size of the AcpiReclaimMemory region for ACPI tables
  when using QFW