844 Commits

Author SHA1 Message Date
Tom Rini
dac8d9c3cc Prepare v2026.01-rc5
-----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQTzzqh0PWDgGS+bTHor4qD1Cr/kCgUCaUnFqQAKCRAr4qD1Cr/k
 CrOEAQC3eaLxXYwOXMVFP1C6w7PfYTfUDKuSdgaRYqxF0ldPwQEA3eDTIIA/CPgg
 1M+K8q8ck+cKRK0P9CagbwyzNnvi4Qw=
 =0Z3i
 -----END PGP SIGNATURE-----

Merge tag 'v2026.01-rc5' into next

Prepare v2026.01-rc5
2025-12-22 16:31:21 -06:00
Tom Rini
d24f4ae654 test/py, buildman: Update filelock package version
The GitHub dependabot tool has reported a "medium" priority bug
CVE-2025-68146, with this package. Update to the patched version.

Reported-by: GitHub dependabot
Signed-off-by: Tom Rini <trini@konsulko.com>
2025-12-18 10:28:10 -06:00
Tom Rini
386f22e117 u-boot-dfu-next-20251211
Android:
 * Fix 8-byte alignment for newer versions of libfdt
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCgAdFiEELulCp7Yfar5TE60AGQ0dtGZOGTUFAmk6fJ0ACgkQGQ0dtGZO
 GTVOaAgAi9ZH9Wzbg1yAm1pxlD435270sMErJ+PcS1NmRvLRBvJZAcFPCRAvQI/r
 n6pi/u2LdJ4aL2WbtPXx7V49mqFi939mwtZyfLdIKPi6chG84bT5+/RrFQorZhBg
 FJrEN5o5Pc9TRQu9WCWyS36/NusvwkGu/hsJIBkz0EocK85/Qh8VKJ8gTpuQKPPr
 flfzlIBIFnWLmOywIdQHgx+QkaA5iwqhFPNDoBSgG5sOl4VLvxcwIOA9Nad6fyy+
 y0K8hssInxduHYseB8sYJJcf2xwEmGPWWTsbrPvYUNa4sUPwQ2bXsSBKT55BPFaD
 y9132+PC0rfISpklqkVEe2J7YsmJ2w==
 =oqXB
 -----END PGP SIGNATURE-----

Merge tag 'u-boot-dfu-next-20251211' of https://source.denx.de/u-boot/custodians/u-boot-dfu into next

u-boot-dfu-next-20251211:

CI: https://source.denx.de/u-boot/custodians/u-boot-dfu/-/pipelines/28724

Android:
* Fix 8-byte alignment for newer versions of libfdt
2025-12-11 07:52:55 -06:00
Tom Rini
17d1e039e1 Merge patch series "test/py: fit: Deduplicate the test"
This series from Marek Vasut <marek.vasut@mailbox.org> cleans up some of
the FIT pytests we have and then extends mkimage to support including
the TEE in FIT images when using "-f auto" to create the resulting FIT.

Link: https://lore.kernel.org/r/20251125154324.51940-1-marek.vasut@mailbox.org
2025-12-06 11:46:15 -06:00
Marek Vasut
22aa122eee mkimage: Add support for bundling TEE in mkimage -f auto
Introduce two new parameters to be used with mkimage -f auto to bundle
TEE image into fitImage, using auto-generated fitImage. Add -z to specify
TEE file name and -Z to specify TEE load and entry point address. This is
meant to be used with systems which boot all of TEE, Linux and its DT from
a single fitImage, all booted by U-Boot.

Example invocation:
"
$ mkimage -E -A arm -C none -e 0xc0008000 -a 0xc0008000 -f auto \
          -d arch/arm/boot/zImage \
          -b arch/arm/boot/dts/st/stm32mp135f-dhcor-dhsbc.dtb \
          -z ../optee_os/out/arm-plat-stm32mp1/core/tee-raw.bin \
	  -Z 0xde000000 \
          /path/to/output/fitImage
"

Documentation update and test are also included, the test validates
both positive and negative test cases, where fitImage does not include
TEE and does include TEE blobs.

Acked-by: Quentin Schulz <quentin.schulz@cherry.de>
Signed-off-by: Marek Vasut <marek.vasut@mailbox.org>
2025-12-06 11:46:09 -06:00
Marek Vasut
23eb6c9ce1 test/py: fit: Deduplicate the test
Introduce generate_and_check_fit_image() and call it with various
parameters to test various configurations of the fitImage. This is
identical to the existing test, expect for the code duplication.

Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de>
Signed-off-by: Marek Vasut <marek.vasut@mailbox.org>
2025-12-06 11:46:09 -06:00
Marek Vasut
42ee514ed0 test/py: android: Point fdt command to aligned addresses
Newer versions of libfdt strictly check whether the FDT blob
passed to them is at 8-byte aligned offset, if it is not, then
the library fails checks with -FDT_ERR_ALIGNMENT . Currently,
'abootimg get dtb --index=1 addr size' may return non 8-byte
aligned FDT address which points directly into the abootimg.
Copy the result into temporary location before validation to
avoid FDT alignment check failure.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
Link: https://lore.kernel.org/r/20251119193311.127633-2-marek.vasut+renesas@mailbox.org
Signed-off-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
2025-12-05 17:21:47 +01:00
Tom Rini
b3835a812f Merge patch series "test: let UNIT_TEST imply CONSOLE_RECORD"
Heinrich Schuchardt <heinrich.schuchardt@canonical.com> says:

Many C unit tests are not executed if CONFIG_CONSOLE_RECORD is not set.
Hence Tom suggested to let UNIT_TEST imply CONSOLE_RECORD.

The first patch makes the skipped C unit tests visible.

The rest of the series deals with hidden bugs in our tests.

The 'fdt get value' command returned incorrect values on low-endian
systems. So this needed fixing too.

Link: https://lore.kernel.org/r/20251123225711.227016-1-heinrich.schuchardt@canonical.com
2025-12-05 08:55:19 -06:00
Heinrich Schuchardt
c448c933b9 test: Let pytest indicate skipped C unit tests
We invoke the ut command in test_ut.py. Currently we only check for
failures. Instead we should also indicate if sub-tests were skipped.

With this change we will get output like the following for skipped tests:

test/py/tests/test_ut.py ..sssss......ss..............s.sssss.s.s...
================================ short test summary info ================================
SKIPPED [1] test/py/tests/test_ut.py:597: Test addrmap addrmap_test_basic has 1 skipped sub-test(s).
SKIPPED [1] test/py/tests/test_ut.py:597: Test bdinfo bdinfo_test_eth has 4 skipped sub-test(s).

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2025-12-05 08:54:44 -06:00
Marek Vasut
f743530990 test/py: Use aligned address for overlays in 'extension' test
The 'extension' test would set 'extension_overlay_addr' variable to
decimal 4096 due to conversion in python. The 'extension_overlay_addr'
is however sampled using env_get_hex("extension_overlay_addr", 0);
which converts the 4096 to 0x4096 and uses that as DT overlay address,
which is unaligned. Fix this by setting extension_overlay_addr to 0x1000
as intended, which is aligned.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
2025-11-28 10:20:28 -06:00
Tom Rini
6d04828b45 dm: Remove pre-schema tag support
Support for using "u-boot,dm-..." rather than "bootph-..." has been
deprecated since February 2023. Any platforms using this have had a
console message saying to migrate by 2023.07. Go and remove all support
here now, for the v2026.01 release.

The results of this change that aren't clear from the above are that we
still have a checkpatch.pl error message, and document in
doc/develop/spl.rst that they have been migrated since 2023. We also
change the key2dtsi.py tool to use the correct bootph phase rather than
the legacy phase.

Signed-off-by: Tom Rini <trini@konsulko.com>
2025-11-10 11:30:56 -06:00
Tom Rini
20b822dd4f test/py: multiplexed_log.py: Clean up and correct RunAndLog()
The general python documentation for the subprocess class recommends
that run() be used in all cases that it can handle. What we do in
RunAndLog is simple enough that run() is easy to switch to. In fact,
looking at this exposed a problem we have today, which is that we had
combined stdout and stderr but then looked at both stdout and stderr as
if they were separate. Stop combining them.

Signed-off-by: Tom Rini <trini@konsulko.com>
2025-11-07 14:19:46 -06:00
Raymond Mao
f974e9b626 pytest: add test script to validate Firmware Handoff
Add test cases to validate FDT and TPM eventlog handoff from TF-A
and OP-TEE via bloblist.

For FDT, the nodes 'reserved-memory' and 'firmware' appended by
OP-TEE indicates a successful handoff.

For TPM eventlog, the events 'SECURE_RT_EL3', 'SECURE_RT_EL1_OPTEE'
and 'SECURE_RT_EL1_OPTEE_EXTRA1' created by TF-A indicates a
successful handoff.

Signed-off-by: Raymond Mao <raymond.mao@linaro.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2025-11-04 10:59:41 -06:00
Tom Rini
bf1d8c1fec test/py: Update to a newer pytest release
Our pytest package was pinned to a release from 2021. The minimum
compatible with labgrid v25.0.x is pytest 7.0.0. Update to the current
relase which is currently 8.4.2

Signed-off-by: Tom Rini <trini@konsulko.com>
2025-10-16 18:03:27 -06:00
Heinrich Schuchardt
ede1186f20 test: uninstall PK after secboot tests
The EFI secure boot tests install a security data base.
Other EFI tests assume that secure boot is not enabled.
Add the missing tear-down at the end of each secboot test sequence.

Reported-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Tested-by: Tom Rini <trini@konsulko.com>
2025-10-16 18:02:19 -06:00
Tom Rini
e482fdbbca Revert "Merge patch series "mkimage: Detect FIT image load address overlaps and fix related test/DTS issues""
This reverts commit 4d84fa1261eb27d57687f2e4c404a78b8653c183, reversing
changes made to b82a1fa7ddc7f3be2f3b75898d5dc44c34420bdd.

I had missed some feedback on this series from earlier, and we have
since had reports of regressions due to this as well. For now, revert
this.

Signed-off-by: Tom Rini <trini@konsulko.com>
2025-09-24 07:50:44 -06:00
Tom Rini
4d84fa1261 Merge patch series "mkimage: Detect FIT image load address overlaps and fix related test/DTS issues"
Aristo Chen <jj251510319013@gmail.com> says:

This patch series enhances FIT image robustness by adding **memory
region overlap detection** to `mkimage` and fixing existing overlaps
in DTS files and `binman` tests.

The primary goal is to prevent runtime memory corruption from
conflicting load addresses in FIT images.

Key Changes:

1.  `mkimage` Overlap Detection: A new validation in
    `tools/fit_image.c` checks for overlapping load addresses
    within FIT configurations. `mkimage` now errors out with
    detailed info on conflicts, preventing bad FIT image creation.

2.  New Test Case: A Python test verifies the new detection.
    It intentionally creates an overlap (kernel and FDT)
    to confirm correct error handling.

3.  Fixes for Existing Overlaps:
    * Board DTS (k3-am6xx): Adjusted load addresses for TI
      firmware stubs to prevent conflicts. This resolves
      previously undetected overlaps.
    * `binman` Tests: Fixed several tests. U-Boot load
      addresses were shifted to avoid ATF conflicts. A new
      linker script for TEE ELF sections ensures distinct
      memory layouts.

4.  Documentation: Added guidance for developers on how to
    determine ELF load addresses using readelf, linker scripts,
    and objdump when working with binman FIT images.

Impact:

This series improves FIT image reliability by catching overlaps
at build time, helping developers resolve issues before runtime
failures.

Link: https://lore.kernel.org/r/20250914110021.4103-1-aristo.chen@canonical.com
2025-09-23 13:41:16 -06:00
Aristo Chen
8f3d3510e3 test: Add test case for FIT image load address overlap detection
Add a new test case to verify that mkimage properly detects and reports
memory region overlaps in FIT image configurations.

The test creates a FIT image with kernel and FDT components that have
the same load address (0x40000), which should trigger the overlap
detection logic and cause mkimage to fail with an appropriate error
message.

Test verifies:
- mkimage returns non-zero exit code when overlap is detected
- Error message contains "Error: Overlap detected:"
- Error message identifies the specific overlapping components
  (kernel@1 and fdt@1)

This test ensures the overlap detection feature works correctly and
prevents deployment of FIT images with conflicting memory layouts
that could cause runtime failures.

Signed-off-by: Aristo Chen <aristo.chen@canonical.com>
2025-09-23 13:35:22 -06:00
Marek Vasut
6dfd14e122 mkimage: Add support for bundling TFA BL31 in mkimage -f auto
Introduce two new parameters to be used with mkimage -f auto to bundle
TFA BL31 image into fitImage, using auto-generated fitImage. Add -y to
specify TFA BL31 file name and -Y to specify TFA BL31 load and entry
point address. This is meant to be used with systems which boot all of
TFA BL31, Linux and its DT from a single fitImage, all booted by U-Boot.

Example invocation:
"
$ mkimage -E -A arm64 -C none -e 0x50200000 -a 0x50200000 -f auto \
          -d arch/arm64/boot/Image \
	  -b arch/arm64/boot/dts/renesas/r8a779g3-sparrow-hawk.dtb \
	  -y ../tfa/build/rcar_gen4/release/bl31.bin -Y 0x46400000 \
	  /path/to/output/fitImage
"

Documentation update and test are also included, the test validates
both positive and negative test cases, where fitImage does not include
TFA BL31 and does include TFA BL31 blobs.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2025-09-12 14:35:36 -06:00
Ilias Apalodimas
fc2686d2a8 test/py: Fix capsule update tests
Capsule updates tests have been skipped since
commit 659f97eb1fc3 ("scripts/Makefile.lib: EFI: Use capsule CRT instead of ESL file")

Remove that check since it's not needed anymore and re-enable the tests.

Fixes: 659f97eb1fc3 ("scripts/Makefile.lib: EFI: Use capsule CRT instead of ESL file")
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2025-08-18 16:42:04 -06:00
Ilias Apalodimas
fa2a2e20d0 test/py: Fix race conditions on EFI capsule tests
efi_capsule_data() is called in each of the EFI tests to create and
setup the files we need. However, it also recreates the spi.bin file
that holds the SPI flash contents we rely on for the test validation.

This leads to weird errors since reading from the flash returns 0,
instead of the expected value if the file has been recreated.

Always restart our sandbox instance if the files are recreated.

Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2025-08-18 16:42:04 -06:00
Ilias Apalodimas
5096f81bda test/py: Read from the correct offset when initializing capsules
The current code writes values to a flash offset defined by a function
argument. However, when reading it back we always read from a static
offset. Adjust the reads to use the correct offset.

Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2025-08-18 16:42:04 -06:00
Ilias Apalodimas
b0465eb88f test/py: Correctly restore the DT after capsule tests
Some capsule tests are changing the sandbox DT to test various features,
e.g authenticated capsule updates, versioning support etc. However, no one
restores the original DT and the CI pops errors looking like

/u-boot
Bloblist at 100 not found (err=-2)
Failed to find FDT file '/tmp/sandbox/persistent-data/scratch/EFI/CapsuleTestData/test_ver.dtb'
initcall_run_f(): initcall fdtdec_setup() failed

if sandbox is restarted.

So let's restore the proper DT after done with the capsule testing.

Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2025-08-18 16:42:04 -06:00
Tom Rini
12a94b894d test: py: test_fit_mkimage_validate: Only run either test on sandbox
Both of these tests are only valid for sandbox (and require dtc) so both
tests need the pytest annotations.

Fixes: 93d09d3bd8ea ("test: fit: add test case for invalid default configuration reference")
Signed-off-by: Tom Rini <trini@konsulko.com>
2025-08-04 18:23:13 -06:00
Aristo Chen
93d09d3bd8 test: fit: add test case for invalid default configuration reference
Recent changes to mkimage introduced a validation step to ensure that
the 'default' property under the /configurations node in a FIT image
references a valid configuration subnode. If the referenced node is
missing, mkimage will now return an error.

This patch adds a Python test case to verify that mkimage correctly
fails when the 'default' configuration does not exist. The test creates
a minimal ITS with an invalid default reference and checks that mkimage
produces the expected error message.

Signed-off-by: Aristo Chen <aristo.chen@canonical.com>
2025-07-23 13:12:16 -06:00
Michal Simek
43341fc021 cmd: Introduce CMD_HELP
Add option to disable help command in size constrained systems to save some
space. There is also no need to have ifdefs around CMDLINE because all
commands depends on it.
And also mark cmd_help dependency in test_help.py.

Reviewed-by: Peter Robinson <pbrobinson@gmail.com>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
Signed-off-by: Michal Simek <michal.simek@amd.com>
Link: https://lore.kernel.org/r/c17f825fb8a74e1d1912a3fd09a9a880c84a8bfd.1751286059.git.michal.simek@amd.com
2025-07-08 15:00:17 +02:00
Bryan Brattlof
b14b3de652 test/py/test_mmc: wrap multi-argument printf-style strings
Newer versions of python will emit a TypeError about not enough
arguments for a format string:

    FAILED ub/test/py/tests/test_mmc.py::test_mmc_dev - TypeError: not enough arguments for format string
    FAILED ub/test/py/tests/test_mmc.py::test_mmcinfo - TypeError: not enough arguments for format string
    FAILED ub/test/py/tests/test_mmc.py::test_mmc_info - TypeError: not enough arguments for format string
    FAILED ub/test/py/tests/test_mmc.py::test_mmc_rescan - TypeError: not enough arguments for format string
    FAILED ub/test/py/tests/test_mmc.py::test_mmc_part - TypeError: not enough arguments for format string

Add parentheses around all multi argument format strings so all
arguments will be passed to the format string

Signed-off-by: Bryan Brattlof <bb@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2025-06-27 10:02:19 -06:00
Tom Rini
f2220962f9 Merge patch series "sandbox: enable CONFIG_CMD_BOOTEFI_SELFTEST by default"
Heinrich Schuchardt <heinrich.schuchardt@canonical.com> says:

The sandbox is used for a lot of generic development, we should run the
UEFI tests there, too.

The TPM emulation on the sandbox is incomplete. Disable the TCG test on
sandbox.

Link: https://lore.kernel.org/r/20250617061945.9266-1-heinrich.schuchardt@canonical.com
2025-06-26 17:18:33 -06:00
Heinrich Schuchardt
615620479e test: disable TCG test on sandbox
The TPM emulation on the sandbox is incomplete.
Even basic tcg2 functionality like get_capability() fails:

    lib/efi_selftest/efi_selftest_tcg2.c(886):
    ERROR: get_manufacturer_id buffer too small failed

Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
2025-06-26 17:18:29 -06:00
Tom Rini
579d1a1bb7 Merge patch series "mkimage: validate image references in FIT configurations"
Aristo Chen <jj251510319013@gmail.com> says:

This series introduces a validation step in mkimage to ensure that all image
names referenced under the /configurations node of a FIT source (ITS) are
actually defined under the /images node.

### Motivation

When using mkimage to build FIT images, it's easy to mistakenly reference
nonexistent image nodes in configurations (e.g., referencing a missing `fdt` or
`firmware` node). Such issues are often not caught until runtime in U-Boot.

This series aims to catch these errors early during FIT image creation by
validating the configuration references in mkimage itself.

Link: https://lore.kernel.org/r/20250610074121.8308-1-aristo.chen@canonical.com
2025-06-26 08:33:42 -06:00
Aristo Chen
21f75eb7af test: py: add mkimage test for undefined image references in FIT configs
Add a test case to verify that mkimage correctly rejects a FIT source
that references a non-existent image from a configuration node.

This test introduces a minimal ITS that defines a valid kernel image
but references a missing "fdt" image under the /configurations section.
The test asserts that mkimage fails with a clear error message, as
introduced in the new validation logic.

This helps ensure the validation logic behaves correctly and prevents
regressions in future FIT enhancements.

Signed-off-by: Aristo Chen <aristo.chen@canonical.com>
2025-06-26 08:12:54 -06:00
Tom Rini
184e7d0bb2 Prepare v2025.07-rc5
-----BEGIN PGP SIGNATURE-----
 
 iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmhZtLAACgkQFHw5/5Y0
 tyyl/gv+LLsF/PdBp93gXaUVFQwh3lrAWltjK6n+gKDpIazlX8Ajiu2tFBzYgBdP
 JNp3PsHJ8ER/GpU4nG/13KfWg8c4CGvAqY0zLxKufMckBdZAE5EwztvSNzZKZA6f
 5FQCecidpwlWBNZRWVbxAAtl83nGBwUmgPAoxDBv4I7DQBJD7mJfzxVnWZuwSioP
 ix3aingjRSIUpldHR5IAQfEmnPPfv7IS6EYb2lOoV22WtTfnF6bpteR/2OUxnW6z
 YxXHaZrDkIfE+gXYOQu5Tau8R0ca4l+ws8GaocTD9VVCDem8JU7b0GCfoXg+ry2Q
 dLYuROREeiXEi14I6arZznpPQM8iIAeDOy0w5b3qXbav0+GWB4rmJKLMniD5JT2r
 r8Kle/QeagILMVPOaUVgjmkEnft4thD14ipvr8kUCurUh1VtFYWTGzKVS47yHaxY
 I1zQaz1NNdtyQNWO/Nwbs+88C7v8q7DeLIIjUt2/J01Bu8ouf2WyfG04iBeZOitt
 CxBZ++2z
 =e4ez
 -----END PGP SIGNATURE-----

Merge tag 'v2025.07-rc5' into next

Prepare v2025.07-rc5

With this merge, tighten up the LTO_FLAGS removal we added to not
trigger on ARMv7 (which is Thumb-2 and should be fine).
2025-06-23 16:15:23 -06:00
Patrick Delaunay
7a598e633a test/py: tests: gpt: add test_gpt_write_part_type
Add sandbox test on gpt command with partition type for known type.

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2025-06-17 17:21:36 -06:00
Tom Rini
4d23c8aeaa u-boot-dfu-20250616
Usb gadget:
 - Fix ti_musb driver in gadget mode (with DM_USB_GADGET)
 
 DFU:
 - mmc/scsi backends when using 10 or more partitions
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCgAdFiEELulCp7Yfar5TE60AGQ0dtGZOGTUFAmhP4ZEACgkQGQ0dtGZO
 GTXihAgA4FwT0FZ7JQmWEVQvYWlv6MkGoewBd6n/e9jRZQvvS9UzE/+lkRnbUCqm
 9INq9u5H3JEeMSEZviufdHe69Z5WrdHQWtbM9sx3fAevOe+u5IJThMTKl1lnYLv0
 fVkxJi4CTgoQj3kt07L5yuv38uATYgl1tBH1inSe6d1+782UlOhc4/gp3T22wM6D
 ySsbsPVUC77GQ1bQmAka2jE/G9Yno+KTnhHFtvh6X2Wj+eYHtWz3v4XItLf+5mka
 8vu579DaecOY3JGIHE2gbv7JwR5+wWckTcl3z0iP9dsRVDLzaKDseB0h35miwjpq
 nVP9QkGmgKjBPABz03OpLiVy/3UPZg==
 =dUh0
 -----END PGP SIGNATURE-----

Merge tag 'u-boot-dfu-next-20250616' of https://source.denx.de/u-boot/custodians/u-boot-dfu into next

u-boot-dfu-next-20250616

CI: https://source.denx.de/u-boot/custodians/u-boot-dfu/-/pipelines/26704

Usb gadget:
- Fix ti_musb driver in gadget mode (with DM_USB_GADGET)

DFU:
- mmc/scsi backends when using 10 or more partitions
2025-06-16 09:39:31 -06:00
Simon Glass
2ab10ed239 test/py: Correct handling of exceptions
If an Unexpected exception is thrown in a test, an undefined variable
error is reported. Fix this.

Signed-off-by: Simon Glass <sjg@chromium.org>
Fixes: 85d7dae377a ("test: Detect dead connections")
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
2025-06-12 11:32:29 -06:00
Simon Glass
ef82e45c2e test/py: Use the correct fixture name in exception handler
If a BootFail exception is thrown in a test, it is not handled
correctly. Use the correct fixture variable 'ubman_fix' to resolve this.

Signed-off-by: Simon Glass <sjg@chromium.org>
Fixes: d9ed4b75add ("test/py: Drop u_boot_ prefix on test files")
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
2025-06-12 11:32:29 -06:00
Simon Glass
693b7a738d test: tpm: Skip failing tests on coral
These tests have been failing for some months. Disable them so that a CI
run can pass on coral. Further work will be needed to see how to make
them pass.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2025-06-10 19:35:58 +03:00
Simon Glass
343f74b4e6 tpm: Drop unwanted special cases for sandbox
These don't seem to be needed.

Add a few notes about what to do next. Also mention parallel tests in
at the top of thefile.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2025-06-10 19:35:58 +03:00
Simon Glass
edc4bfd2e3 tpm: Convert sandbox-focussed tests to C
Some of the Python tests are a pain because they don't reset the TPM
state before each test. Driver model tests do this, so convert the
tests to C.

This means that these tests won't run on real hardware, but we have
tests which do TPM init, so there is still enough coverage.

Rename and update the Python tpm_init test to use 'tpm autostart',
since this fully initializes the TPM and performs the self tests.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2025-06-10 19:35:26 +03:00
Heinrich Schuchardt
22abd882c3 test: allow testing with NET_LWIP=y
Adjust network tests to run with CONFIG_NET_LWIP=y.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
2025-05-18 09:16:55 +02:00
Heinrich Schuchardt
2bac578c5a test: allow multiple config options in buildconfigspec
In some cases we have alternative configuration options that supply the
same functionality, e.g CONFIG_NET and CONFIG_NET_LWIP.

Allow to specify all of them as arguments for buildconfigspec() and execute
the text if any of these is fulfilled, e.g.

    @pytest.mark.buildconfigspec('net', 'net_lwip')

Update the documentation.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-18 09:16:51 +02:00
Adriano Cordova
8fdb8740b3 test/py/test_efi_fit: test fdt and initrd
Add tests to check initrd and dtb loading

Signed-off-by: Adriano Cordova <adriano.cordova@canonical.com>
2025-05-11 13:30:36 +02:00
Tom Rini
02e5d344a0 doc: pytest: Document the test_button test
Add this test to the documentation. No changes to the test itself were
required.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:57 +02:00
Tom Rini
e1076c6619 doc: pytest: Document the test_bootmenu test
Add this test to the documentation. There was already a function comment
that included the argument, so convert it to the right style to be
rendered correctly in output.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:57 +02:00
Tom Rini
4964cc9caa doc: pytest: Document the test_bind test
Add this test to the documentation. None of the functions had comments,
so attempt to explain what each does.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:56 +02:00
Tom Rini
6c3c08c478 doc: pytest: Document the test_efi_loader test
Add this test to the documentation. We need to add a code-block
annotation to the example and indent it correctly. We also need to
document the do_test_efi_helloworld_net function and that in turn means
changing the documentation to test_efi_helloworld_net_http and
test_efi_helloworld_net_tftp to reflect what is and isn't done in those
functions themselves now.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:56 +02:00
Tom Rini
58b2f0895b doc: pytest: Document the test_bootstage test
Add this test to the documentation. We need to move the import to follow
the main comment so that it renders correctly, and add a code-block
annotation to the example and indent it correctly. Next, neither of the
functions had comments themselves, so document them now.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:56 +02:00
Tom Rini
45d325ba09 doc: pytest: Document the test_net test
Add this test to the documentation. While the diff appears large at
first, the only changes within the test are to move the imports to
follow the pydoc comment and then to code-block and indent the example
configuration.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:56 +02:00
Tom Rini
9e56248584 test: test_net_boot: Add more comments
Some of the functions were missing pydoc comments. Add them so they will
be included in the documentation.

Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:56 +02:00
Tom Rini
8f8f0f0ed9 doc: pytest: Document the test_net_boot test
Add the test_net_boot.py test to the generated documentation. While most
of this was already commented correctly for inclusion the biggest
problem was examples of code without a code-block notation. This in turn
broke parsing. Add the missing notations. We also must have the comment
prior to any import lines or it will not be seen as a comment on the
overall file and thus not included.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2025-05-11 12:52:56 +02:00