1126 Commits

Author SHA1 Message Date
Dario Binacchi
c14ce5346d boot/uboot: bump to version 2025.04
Release announcement:
https://lists.denx.de/pipermail/u-boot/2025-April/586033.html

Changelog:
https://github.com/u-boot/u-boot/compare/v2025.01...v2025.04

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-04-08 19:25:51 +02:00
Nayab Sayed
14ef1ed7d2 boot/optee-os: bump to 4.5.0
Update OP-TEE to its latest tag

Signed-off-by: Nayab Sayed <nayabbasha.sayed@microchip.com>
[Julien: move package archive hash to the "Locally computed" section]
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-04-06 11:22:44 +02:00
Luca Ceresoli
06dc0cc353 boot: move package options to a submenu
Change all Kconfig entries for packages in the "Bootloaders" menu to
submenus.

Currently many bootloaders and firmwares in this menu use a 'config'
keyword and thus menuconfig presents their sub-options as a flat list in
the same menu. This is not very convenient as some have a lot of
sub-options, and in (more and more common) configurations with multiple
such packages enabled the menuconfig screen becomes very crowded. Moreover
options of 'string' type don't have a visible indentation when their value
exceeds a few characters, thus making it visually hard to grasp which
package the various options belong to.

Non-bootloader packages having suboptions usually use a 'menuconfig'
keywork to have sub-options in a submenu. Do the same for packages in the
"Bootloaders" menu which have more than one sub-option.

Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Reviewed-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-03-19 21:16:00 +01:00
Luca Ceresoli
088808ccc7 boot/xilinx-embeddedsw: fix menuconfig visualization
Due to how menuconfig works, a 'comment' entry following a 'config' entry
prevents correct indentation of items depending on the 'config'
entry. xilinx-embeddedsw currently shows as:

  [*] xilinx-embeddedsw
      *** xilinx-embeddedsw needs a bare metal toolchain for tuple microblazeel-xilinx-elf ***
  (xilinx_v2024.2) xilinx-embeddedsw version (NEW)
  [ ] versal plm (NEW)
  [ ] versal psmfw (NEW)
  [ ] zynqmp pmufw (NEW)
  [ ] xilinx-prebuilt

So the 'versal *' and 'zynqmp pmufw' items are not indented even though
they should be.

Do like most other Config.in files which have the 'comment' before the
'config' entry, makeing it render as expected:

      *** xilinx-embeddedsw needs a bare metal toolchain for tuple microblazeel-xilinx-elf ***
  [*] xilinx-embeddedsw
  (xilinx_v2024.2) xilinx-embeddedsw version (NEW)
  [ ]   versal plm (NEW)
  [ ]   versal psmfw (NEW)
  [ ]   zynqmp pmufw (NEW)
  [ ] xilinx-prebuilt

Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Reviewed-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-03-19 21:15:56 +01:00
Peter Korsgaard
781987d67e Merge branch 'next' 2025-03-18 15:41:43 +01:00
Cherniaev Andrei
3fbc4e583f boot/grub2/readme.txt: typo
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-03-10 22:30:42 +01:00
Daniel Lang
f2498258d4 boot/optee-os: add CPE identifier
cpe:2.3:o:linaro:op-tee:4.3.0:*:*:*:*:*:*:* is a valid CPE ID.

See:
https://nvd.nist.gov/products/cpe/detail/2754E8CF-9BD5-448D-9F32-CFAC92278CD9

Note: this commit needs to set _CPE_ID_PREFIX because optee-os CPE
"part" needs to be set to "o" (OS), while the default Buildroot prefix
is "a" (Application).

Signed-off-by: Daniel Lang <dalang@gmx.at>
[Julien:
 - add extra info in commit log (and fix CVE to CPE)
 - add a new line after OPTEE_OS_CPE_ID_PRODUCT for readability
]
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-03-07 22:12:46 +01:00
Dario Binacchi
ad5445a347 boot/arm-trusted-firmware: add lts-v2.12.x selection
There is a new lts-v2.12.x branch. Add it to the selection

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-03-06 22:13:29 +01:00
Fabio Estevam
1ec956130d package/freescale-imx: Allow firmware installation on i.MX93
Currently, the LPDDR firmware binaries do not get installed into the
U-Boot mainline directory, causing U-Boot build to fail for i.MX93.

Fix this problem by expanding the BR2_PACKAGE_FIRMWARE_IMX_NEEDS_DDR_FW
checks to also take BR2_PACKAGE_FIRMWARE_IMX_NEEDS_DDR_FW_IMX9 into account.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-02-26 21:58:15 +01:00
Vincent Stehlé
bd41cccc7a boot/boot-wrapper-aarch64: bump version
Bump boot-wrapper to the latest version.

Signed-off-by: Vincent Stehlé <vincent.stehle@laposte.net>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-02-19 22:06:32 +01:00
Neal Frager
3761177a89 boot/xilinx-embeddedsw: change dependency
Now that BR2_TOOLCHAIN_BARE_METAL_BUILDROOT_ARCH can contain multiple tuples,
BR2_TARGET_XILINX_EMBEDDEDSW can no longer be dependent on:

depends on BR2_TOOLCHAIN_BARE_METAL_BUILDROOT_ARCH = "microblazeel-xilinx-elf"

A valid definition could have "microblazeel-xilinx-elf" as just one of many
tuples in the list.

For this reason, this patch changes the dependency to:

depends on BR2_TOOLCHAIN_BARE_METAL_BUILDROOT

One side effect of this is that the user comment will be displayed now when
using multiple tuples, even if one of them is the required tuple.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
2025-02-17 23:22:20 +01:00
Neal Frager
9f52cc8c0a boot/uboot: add qspi.bin file support
u-boot has introduced a new file called qspi.bin for users who boot from a
qspi flash device.  It combines the spl/boot.bin and u-boot.itb files into a
single binary that can be written to the qspi flash.

Here is an example of how binman generates the qspi.bin:
a4c9811910

At the moment, the qspi.bin is only used for the zynqmp platform, but other
platforms may adopt it, so the buildroot support has been made in a generic
way.

This patch adds the necessary support for buildroot to install this binary.

[Tested on Kria KV260 starter kit]
Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Signed-off-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2025-02-04 14:18:29 +01:00
Neal Frager
00039d7059 boot/uboot: support binman generated u-boot.itb
When using binman to generate u-boot images, there will no longer be a make
rule for generating files produced by binman.  However, these files will still
need to be installed to the output/images directory.

One such file is the u-boot.itb.  If the u-boot.itb is generated by binman,
then the file still needs to be copied, but without the make rule.

Here is an example of how binman generates the u-boot.itb:
a4c9811910

[Tested on Kria KV260 starter kit]
Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Signed-off-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2025-02-04 14:17:09 +01:00
Neal Frager
7dadbb6dcc boot/xilinx-prebuilt: remove xilinx_v2024.2 hash
Now that the versal defconfigs have been bumped to the new default version
xilinx_v2024.2_update1, the xilinx_v2024.2 hash can be removed.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
2025-02-03 16:15:13 +01:00
Neal Frager
a72537c763 boot/xilinx-prebuilt: bump default to xilinx_v2024.2_update1
This patch bumps the default version of xilinx-prebuilt to
xilinx_v2024.2_update1.  For some reason, the original xilinx_v2024.2
release tag was missing the kria boards.  There is no difference between
the xilinx_v2024.2 and the xilinx_v2024.2_update1 release tags other than
the fact that the kria boards are included.

Now that the release tag includes all the boards, it is possible to bump
the default version from xilinx_v2024.1 to xilinx_v2024.2_update1.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Reviewed-by: Brandon Maier <brandon.maier@gmail.com>
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
--
2025-02-03 16:10:05 +01:00
Neal Frager
4e99bc14eb boot/xilinx-prebuilt: merge hash files
There is actually no need to have two hash files for the xilinx-prebuilt
package.  As long as the boot/xilinx-prebuilt/xilinx-prebuilt.hash contains
the hash value for the default version as well as any version used by a
xilinx board defconfig, a single hash file is all that is needed.

In the future, when bumping the defconfig files independently of the
xilinx-prebuilt default version, all that has to be done is the following
process.

Patch Series:
1. Add new version hash to boot/xilinx-prebuilt/xilinx-prebuilt.hash.
2. Bump board defconfigs to new version.
3. Bump xilinx-prebuilt default version.

For this reason, this patch merges the two xilinx-prebuilt.hash files and
removes the board/xilinx xilinx-prebuilt.hash file.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
2025-02-03 16:09:53 +01:00
Neal Frager
92945909f1 boot/xilinx-prebuilt: add hash for LICENSE file
Add hash for xilinx-prebuilt LICENSE file.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-24 21:39:11 +01:00
Neal Frager
a5b360e53f boot/uboot.mk: new zynqmp pmufw embeddedsw option
The new BR2_TARGET_UBOOT_ZYNQMP_PMUFW_EMBEDDEDSW option will enable u-boot to
use the xilinx-embeddedsw package for building a pmufw.elf that gets included
in the generated boot.bin.

If the BR2_TARGET_UBOOT_ZYNQMP_PMUFW_EMBEDDEDSW option is enabled, then the
BR2_TARGET_UBOOT_ZYNQMP_PMUFW config for downloading a prebuilt pmufw from a
custom location will be ignored.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
[Luca: Tested on Kria KV260 starter kit]
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-24 19:24:52 +01:00
Neal Frager
1cbd222150 boot/xilinx-embeddedsw: new boot package
This patch adds a new boot package to Buildroot for building boot firmware
applications from the https://github.com/Xilinx/embeddedsw repo.

If a user chooses to build a boot firmware application, it will not be
installed by the xilinx-prebuilt package since it will come from the
xilinx-embeddedsw package.  In this way, users can mix and match applications
to be built by the xilinx-embeddedsw package and applications to be copied
from the xilinx-prebuilt package.  This is necessary for the versal platform
because the pdi file can only be built by AMD Vivado.

Support for additional applications in the https://github.com/Xilinx/embeddedsw
repo can always be added to this package as needed or requested.

The xilinx-embeddedsw package replaces previous solutions including
zynqmp-firmware, versal-firmware and xilinx-source.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
[Luca: Tested on Kria KV260 starter kit]
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-24 19:24:18 +01:00
Thomas Petazzoni
a311245ff7 boot/syslinux: add multiple patches fixing build issues with GCC >= 14
No autobuilder failures reported, but it fixes build issues that can
be reproduced with:

BR2_x86_64=y
BR2_x86_corei7=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_X86_64_CORE_I7_GLIBC_BLEEDING_EDGE=y
BR2_TARGET_SYSLINUX=y
BR2_TARGET_SYSLINUX_EFI=y

First patch is backported from upstream. Last 3 patches are not from
upstream, and they have not been submitted as upstream is basically
dead (last release 10 years ago, last commit 5 years ago).

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-19 11:36:10 +01:00
Akhilesh Nema
6ff1a66e20 boot/uboot: bump to version 2025.01
Release announcement:
https://lists.denx.de/pipermail/u-boot/2025-January/576668.html

Changelog:
https://github.com/u-boot/u-boot/compare/v2024.10...v2025.01

Signed-off-by: Akhilesh Nema <nemaakhilesh@gmail.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-17 19:26:07 +01:00
Vincent Stehlé
0f3791f25f boot/optee-os: add custom version option
Add custom version option, to enable easily specifying an official OP-TEE
version to use.
This is similar to what is done in other packages, such as linux, uboot or
arm-trusted-firmware.

Signed-off-by: Vincent Stehlé <vincent.stehle@arm.com>
Cc: Étienne Carrière <etienne.carriere@foss.st.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-08 21:51:17 +01:00
Vincent Stehlé
1220b505bc boot/uboot: add support for embedded TEE in binary format
We can embed a TEE in ELF format into U-Boot, but versions of OP-TEE since
3.8.0 must be embedded in binary format, as the tee.bin contains important
meta-data. [1]

Update the configuration menu and the Makefile to allow selecting to
embed either tee.elf or tee.bin.

By default, embed the TEE in ELF format to stay compatible with existing
configurations.

[1] https://github.com/OP-TEE/optee_os/issues/4542

Signed-off-by: Vincent Stehlé <vincent.stehle@arm.com>
Cc: Christoph Muellner <christoph.muellner@theobroma-systems.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-08 19:40:26 +01:00
Romain Naour
0919d98e83 boot/edk2: bump to version edk2-stable202411
Sync edk2-platforms with the last commit merged at the edk2 release
date (2024-11-22).

See:
https://github.com/tianocore/edk2/releases/tag/edk2-stable202411

Runtime tested with tests using EDK2 package: TestFwts, TestEdk2,
TestIso9660Grub2EFI, TestIso9660Grub2Hybrid, TestGrubi386EFI,
TestGrubX8664EFI, TestGrubAArch64EFI, TestGrubRiscV64EFI.

Runtime tested with defconfig using EDK2 package:
qemu_aarch64_sbsa_defconfig, qemu_riscv64_virt_efi_defconfig.

Cc: Julien Olivain <ju.o@free.fr>
Signed-off-by: Romain Naour <romain.naour@smile.fr>
Signed-off-by: Julien Olivain <ju.o@free.fr>
2025-01-04 21:32:03 +01:00
Bryan Brattlof
eb9bb65629 boot/ti-k3-r5-loader: add host-gnutls to dependencies
Newer versions of U-Boot (2024.10 and newer) will require the GnuTLS
library to be installed on the host machine to build the mkeficapsule
tool for U-Boot's image packaging phase to generate the final capsule
for all the boot images including the tiboot3.bin image.

Add host-gnutls to the list of dependencies.

Fixes:
https://gitlab.com/buildroot.org/buildroot/-/jobs/8723483578 (ti_am62x_sk_defconfig)

Signed-off-by: Bryan Brattlof <bb@ti.com>
Signed-off-by: Romain Naour <romain.naour@smile.fr>
2025-01-01 21:20:11 +01:00
Kilian Zinnecker
8d94747b33 boot/opensbi: bump version to 1.6
Release notes at:
https://github.com/riscv-software-src/opensbi/releases/tag/v1.6

From release notes:
"Overall, this release adds more ISA extensions, drivers, and other
improvements."

This OpenSBI version 1.6 can be tested in qemu with the commands:

    cat <<EOF >.config
    BR2_riscv=y
    BR2_LINUX_KERNEL=y
    BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y
    BR2_TARGET_ROOTFS_EXT2=y
    BR2_TARGET_OPENSBI=y
    BR2_TARGET_OPENSBI_PLAT="generic"
    BR2_TOOLCHAIN_EXTERNAL=y
    EOF
    make olddefconfig
    make

Then:

    qemu-system-riscv64 \
        -M virt \
        -bios output/images/fw_jump.bin \
        -kernel output/images/Image \
        -append "rootwait root=/dev/vda ro" \
        -drive file=output/images/rootfs.ext2,format=raw \
        -nographic

Note that in the previous qemu command line, the OpenSBI ".bin"
image is passed rather than the ".elf" image.

Loading the ".elf" image in qemu can now lead to the following
qemu error:

    qemu-system-riscv64: Some ROM regions are overlapping
    These ROM regions might have been loaded by direct user request or by default.
    They could be BIOS/firmware images, a guest kernel, initrd or some other file loaded into guest memory.
    Check whether you intended to load all this guest code, and whether it has been built to load to the correct addresses.

    The following two regions overlap (in the memory address space):
      fw_jump.elf ELF program header segment 1 (addresses 0x0000000000000000 - 0x00000000000271e0)
      mrom.reset (addresses 0x0000000000001000 - 0x0000000000001028)

See: https://github.com/riscv-software-src/opensbi/issues/372

Signed-off-by: Kilian Zinnecker <kilian.zinnecker@mail.de>
Tested-by: Julien Olivain <ju.o@free.fr>
[Julien: reworded the commit log about testing]
Signed-off-by: Julien Olivain <ju.o@free.fr>
2024-12-29 13:23:14 +01:00
Julien Olivain
c583befc8e boot/opensbi: bump to version 1.5
For release notes since version 1.3, see:
https://github.com/riscv-software-src/opensbi/releases/tag/v1.5
https://github.com/riscv-software-src/opensbi/releases/tag/v1.4

This commit also updates the package home page url and the
download _SITE to reflect the change of github account from "riscv"
to "riscv-software-src".

Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
2024-12-18 20:28:42 +01:00
Vincent Stehlé
24615d1502 boot/arm-trusted-firmware: bump to v2.12
For change log, see [1].

Update trusted-firmware-a version to v2.12 and add a hash file
accordingly.

Compared to v2.11, the license has changed with the additional mention
of files from the pydevicetree project under Apache 2.0 license.
As we only document the main license of TF-A, BSD-3-Clause, this change
has no impact for us.

[1] https://git.trustedfirmware.org/plugins/gitiles/TF-A/trusted-firmware-a.git/+/refs/tags/v2.12/docs/change-log.md

Signed-off-by: Vincent Stehlé <vincent.stehle@arm.com>
Cc: Dick Olsson <hi@senzilla.io>
Cc: Sergey Matyukevich <geomatsi@gmail.com>
[Julien:
  - add link to change log
  - remove v2.11 hash file
]
Signed-off-by: Julien Olivain <ju.o@free.fr>
2024-12-16 21:57:13 +01:00
Julien Olivain
51858c4a34 boot/grub2: update _SITE to use BR2_GNU_MIRROR
The grub2 package is distributed on the GNU project servers. See [1]
and [2]. Buildroot has the BR2_GNU_MIRROR configuration which can
be used for that purpose. See [3].

For consistency with all other GNU packages, this commit updates
the _SITE to use BR2_GNU_MIRROR.

Note: Commit [4] introduced the grub2 package using BR2_GNU_MIRROR.
Commit [5] changed it to use "http://ftp.gnu.org/gnu/grub" without
providing a justification for that change.

[1] https://www.gnu.org/software/grub/grub-download.html
[2] https://www.gnu.org/prep/ftp.html
[3] https://gitlab.com/buildroot.org/buildroot/-/blob/2024.08.2/Config.in#L286
[4] c24fdb3680
[5] 5ffafd2353

Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Romain Naour <romain.naour@smile.fr>
2024-12-11 15:03:20 +01:00
Bryce Johnson
f22d407637 boot/ti-k3-r5-loader: use BR2_PACKAGE_HOST_ARM_GNU_TOOLCHAIN_SUPPORTS
ti-k3-r5-loader can only be built on x86_64 or aarch64 hosts due
to ARM gnu toolchain dependency.

[Romain: improve commit log]
Signed-off-by: Bryce Johnson <bryce@redpinelabs.com>
Signed-off-by: Romain Naour <romain.naour@smile.fr>
2024-12-11 14:15:36 +01:00
Bryce Johnson
b948c25978 boot/arm-trusted-firmware: use BR2_PACKAGE_HOST_ARM_GNU_TOOLCHAIN_SUPPORTS
Allow to enable BR2_TARGET_ARM_TRUSTED_FIRMWARE_NEEDS_ARM32_TOOLCHAIN
option on aarch64 hosts using HOST_ARM_GNU_TOOLCHAIN_SUPPORTS, in order
to build an ATF firmwares that require a pre-built bare metal toolchain
(rockpro64_defconfig).

[Romain: improve commit log]
Signed-off-by: Bryce Johnson <bryce@redpinelabs.com>
Signed-off-by: Romain Naour <romain.naour@smile.fr>
2024-12-11 14:13:11 +01:00
Cherniaev Andrei
7dd56b6cd9 boot/grub2/readme.txt: don't specify /dev/loop0
losetup -f returns the next free loop device, which may not be
/dev/loop0.  If you blindly follow the readmy you may end up destroying
an existing device.

Make it more robust with a variable to store the loop device.

Signed-off-by: Cherniaev Andrei <dungeonlords789@naver.com>
[Arnout: keep the actual losetup atomic]
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
2024-12-04 22:17:09 +01:00
Romain Naour
cc0823c2d1 boot/edk2: bump to version edk2-stable202405
Release notes:

  https://github.com/tianocore/edk2/releases/tag/edk2-stable202405

We can't bump to edk2-stable202408 yet due to a runtime issue while
testing qemu_aarch64_sbsa_defconfig following the switch generic
ArmPsciResetSystemLib [1]

  ERROR:   sbsa_sip_smc_handler: unhandled SMC (0xc20000ca) (function id: 202)

Qemu 9.0/9.1 is using a slightly older edk2 firmware based on
edk2-stable202405 release [2] that contains a commit [3] fixing a
bootloader crash produced with qemu_aarch64_sbsa_defconfig [4] since
Qemu 9.0.

From [5]:
"The version of the sbsa-ref EDK2 firmware we used to use in this test
had a bug where it might make an unaligned access to the framebuffer,
which causes a guest crash on newer versions of QEMU where we enforce
the architectural requirement that unaligned accesses to Device memory
should take an exception."

This commit [5] is backported to edk2-stable202405.

For the same reason, we have to update edk2-platforms to a specific
version [6]:

"QemuSbsa: enable WriteCombine for the FrameBuffer
QEMU no longer permits misaligned access to device memory, which breaks
QemuVideoDxe on SbsaQemu.

c1d1910be6e04a8b1a73090cf2881fb698947a6e commit in EDK2 fixed it by
enabling WriteCombine for Framebuffer memory. This change enables that
fix."

As a side note, the edk2-non-osi package does not need to be updated, so
it is left untouched.

Finally, this EDK2 version requires a recent Qemu version. The version
included in the reference Docker image (5.2.0) is too old and will not
allow to start this EDK2 version. Therefore, this bump is known to be
incompatible with runtime tests which are using EDK2 on Aarch64
architecture. At the authoring time of this commit, broken tests are:
- tests.boot.test_edk2
- tests.boot.test_grub.TestGrubAArch64EFI
- tests.package.test_fwts

Note that the EDK2/Qemu incompatibility is only affecting Aarch64
tests. Other tests using EDK2 on i386 or x86_64 are not affected.

To prevent this commit introducing broken runtime tests, those have
been disabled in a previous commit.

[1] 2d0668d399
[2] 24a7cd6a7c
[3] c1d1910be6
[4] https://gitlab.com/buildroot.org/buildroot/-/jobs/7764483764
[5] 6c84daac58
[6] 3f08401365

Fixes:
https://gitlab.com/buildroot.org/buildroot/-/jobs/7764483764

Signed-off-by: Romain Naour <romain.naour@smile.fr>
Cc: Waldemar Brodkorb <wbx@openadk.org>
[Julien: add comments in commit log]
Signed-off-by: Julien Olivain <ju.o@free.fr>
2024-11-04 23:03:44 +01:00
Bryan Brattlof
06a1cf4854 boot/ti-k3-r5-loader: bump to v2024.10
A new version of U-Boot has been released. Update to this latest version
to pull in the latest features and bug fixes

Signed-off-by: Bryan Brattlof <bb@ti.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2024-10-22 22:53:04 +02:00
Bryan Brattlof
164d9f0546 boot/uboot: update link to the U-Boot docs
The denx.de/wiki/U-Boot link now redirects to docs.u-boot.org/en/latest
Replace the link to the new location for the U-Boot documentation

Signed-off-by: Bryan Brattlof <bb@ti.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2024-10-22 22:52:32 +02:00
Dario Binacchi
fe295d94e9 boot/uboot: bump to version 2024.10
Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2024-10-11 08:39:22 +02:00
Julien Olivain
8a71fda371 boot/grub2: replace host-python3 with BR2_PYTHON3_HOST_DEPENDENCY
Commit 86bb1b236 "boot/grub2: needs host-python3" [1] introduced a
dependency on host-python3.

Since grub does not have any specific requirements on host Python
modules, or recent host Python version, this commit replaces the
host-python3 dependency with BR2_PYTHON3_HOST_DEPENDENCY. This will
skip the host-python3 compilation if a sufficient version (3.4 or
greater at the time of this commit) is already present on host. This
will save build time.

This optimization was suggested by Peter, in [2].

Note 1: this commit was checked to ensure that grub is building with
Python 3.4.

Note 2: BR2_PYTHON3_HOST_DEPENDENCY was introduced in commit b60729784
"support/dependencies: add a check for python3" [3].

[1] 86bb1b2360
[2] https://lists.buildroot.org/pipermail/buildroot/2024-September/763967.html
[3] b60729784a

Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2024-10-03 11:30:21 +02:00
Ben Wolsieffer
ceff8dbaa5 boot/uboot: pass -mno-fdpic if FDPIC is enabled
If the FDPIC ABI is enabled by default in the toolchain, it must be
explicitly disabled when building U-Boot.

Signed-off-by: Ben Wolsieffer <Ben.Wolsieffer@hefring.com>
Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2024-10-02 22:34:38 +02:00
Peter Korsgaard
ab34bdcb38 boot/uboot: fix typos
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-21 20:39:49 +02:00
Peter Korsgaard
6dc6a747fd boot/shim/shim.mk: fix 'deactivate' typo
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-21 20:39:47 +02:00
Peter Korsgaard
7bd00d5506 boot/optee-os/optee-os.mk: fix 'PLATFORM' typo
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-21 20:39:46 +02:00
Peter Korsgaard
0fa6bd5a96 boot/grub2/Config.in: fix 'targeting' typo
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-21 20:39:45 +02:00
Peter Korsgaard
a52fd38060 boot/edk2/edk2.mk: fix 'release' typo
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-21 20:39:43 +02:00
Peter Korsgaard
9e3fdb87f0 boot/barebox/barebox.mk: fix 'allows' typo
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-21 20:39:42 +02:00
Peter Korsgaard
2e3c0ab1b7 boot/arm-trusted-firmware/Config.in: fix 'platform' typo
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-21 20:39:40 +02:00
Yu Chien Peter Lin
7c5b6c1e9f boot: optee-os: enable RISC-V (64-bit) architecture
OP-TEE OS and TAs can run on RISC-V (64-bit) machines, so allow
optee-os to be compiled for the new architecture.

Signed-off-by: Yu Chien Peter Lin <peterlin@andestech.com>
[Arnout:
 - set CROSS_COMPILE_ta_rv64 even on arm builds;
 - ARCH=arm for aarch64.
]
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
2024-09-14 17:56:44 +02:00
Julien Olivain
86bb1b2360 boot/grub2: needs host-python3
When the build host does not have a Python interpreter installed,
host-grub2 is failing to configure due to this missing interpreter.
Note that host-grub2 is the first package to fail because it is a
dependency of grub2. The grub2 target package has the same dependency
requirement.

The issue can be quickly reproduced on a host without Python with the
commands:

    cat <<EOF >.config
    BR2_aarch64=y
    BR2_TARGET_GRUB2=y
    BR2_TOOLCHAIN_EXTERNAL=y
    EOF
    make olddefconfig
    make grub2

grub2 autotools configure.ac search for a Python interpreter since
upstream commit [1] 8b467844e "python: Use AM_PATH_PYTHON to determine
interpreter for gentpl.py", first included in grub v2.04 released
on 2019-07-04. For reference, grub2 has been updated to that version
in commit [2] ea7ec41c "boot/grub2: bump to verson 2.04".

This commit fixes the issue by adding the host-python3 dependency to
host-grub2 and grub2.

Fixes:

    checking for a Python interpreter with version >= 2.6... none
    configure: error: no suitable Python interpreter found

[1] https://git.savannah.gnu.org/gitweb/?p=grub.git;a=commitdiff;h=8b467844e11170077c8ca727c39d2bd36eeb5f08
[2] ea7ec41cf6

Reported-by: Vincent Stehlé <vincent.stehle@arm.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-14 16:36:03 +02:00
Julien Olivain
248c2d045e boot/arm-trusted-firmware: add -no-pie to LDFLAGS
Arm Trusted Firmware (TF-A) v2.11 fails to build in some situations
with the error message:

    ld: build/qemu/release/bl1/bl1.elf: error: PHDR segment not covered by LOAD segment

This error can be reproduced with the commands:

    make qemu_aarch64_ebbr_defconfig
    utils/config --set-str BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE v2.11
    make olddefconfig
    make

This issue was reported in [1].

This error is coming from a check that was made more strict since
binutils ld 2.34. This error message is normally related to dynamic
linker, so it should normally not apply to a package like TF-A.

When BR2_SHARED_LIBS=y (shared libraries only) and BR2_PIC_PIE=y
(Build code with PIC/PIE), the Buildroot toolchain-wrapper will try
to enable position-independent code/executables. See [2]. This
configuration is a common default.

Arm Trusted Firmware (TF-A) build system, on its side, tries to detect
if the toolchain enables PIE automatically. It does so by checking if
--enable-default-pie is in the output of "$(CC) -v". If found, the TF-A
build system tries to disable PIE globally (it can be explicitly
enabled again with the ENABLE_PIE=1 build variable, in some specific
configurations). This detection mechanism is not working with the
Buildroot toolchain wrapper which is enabling PIE silently. See [3].

Commit 1061ed6c "boot/arm-trusted-firmware: add -fno-PIE to CFLAGS"
added the option -fno-PIE in CFLAGS for that reason. See [4].
TF-A >= v2.11 now needs the same treatment for LDFLAGS. This is
because TF-A switched the default linker from "ld" to "gcc", in
upstream commit [5]. This change makes the Buildroot toolchain wrapper
to enable PIE at link, without passing the "--no-dynamic-linker" option
that would normally avoids this ld error.

Also, even if there is no defconfigs using the
BR2_TARGET_ARM_TRUSTED_FIRMWARE_LATEST_VERSION config directive, it is
worth mentioning that the Buildroot TF-A "latest version" was updated
to v2.11 in commit 9c50759cd "boot/arm-trusted-firmware: bump to
v2.11". See [6]. This latest version is the default choice. So
Buildroot is subject to generate this build failure. This can be
reproduced with the commands:

    cat <<EOF >.config
    BR2_aarch64=y
    BR2_TARGET_ARM_TRUSTED_FIRMWARE=y
    BR2_TARGET_ARM_TRUSTED_FIRMWARE_PLATFORM="qemu"
    BR2_TOOLCHAIN_EXTERNAL=y
    EOF
    make olddefconfig
    make arm-trusted-firmware

This commit fixes the issue by adding the option "-no-pie" in LDFLAGS.
This will prevent the Buildroot toolchain wrapper to enable PIE, for
versions using "gcc" as a linker. This change should also remain
compatible with older TF-A < 2.11 using "ld" as a linker, since
"-no-pie" is also a valid ld option.

Fixes:

    ld: build/qemu/release/bl1/bl1.elf: error: PHDR segment not covered by LOAD segment

[1] https://github.com/TrustedFirmware-A/trusted-firmware-a/issues/26
[2] https://gitlab.com/buildroot.org/buildroot/-/blob/2024.08-rc3/toolchain/toolchain-wrapper.c?ref_type=tags#L403
[3] https://git.trustedfirmware.org/plugins/gitiles/TF-A/trusted-firmware-a.git/+/refs/tags/v2.11.0/Makefile#711
[4] 1061ed6c62
[5] 2f1c5e7eb1%5E%21/
[6] 9c50759cd1

Reported-by: Vincent Stehlé <vincent.stehle@arm.com>
Tested-by: Vincent Stehlé <vincent.stehle@arm.com>
Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2024-09-03 23:58:40 +02:00
Thomas Petazzoni
e2f46ed03d boot/grub2: ignore CVE-2023-4001
This vulnerability is irrelevant to Buildroot, as it affects only some
downstream changes from Redhat.

See:

  https://security-tracker.debian.org/tracker/CVE-2023-4001
  https://www.openwall.com/lists/oss-security/2024/01/15/3

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2024-08-23 16:27:30 +02:00
Thomas Petazzoni
2495630383 boot/grub2: ignore CVE-2024-1048
As explained in:

  https://security-tracker.debian.org/tracker/CVE-2024-1048
  https://www.openwall.com/lists/oss-security/2024/02/06/3

CVE-2024-1048 is related to a tool called grub-set-bootflag which only
exists in the Redhat fork of Grub, and which we don't use in
Buildroot, so this CVE should be ignored.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2024-08-23 16:27:28 +02:00