Re: [PATCH v2 0/4] FAT file renaming

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:24:47AM +, Daniel Venzin wrote: > > Rework of v1 posted by Burak Gerz [1]. > > [1] https://lore.kernel.org/u-boot/20241212221427.GM1505244@bill-the-cat/ > > Changes in v2: > - Adapt variable names for better consistency > - Add missing rename hooks > - Use EFI_ACC

Re: [PATCH 21/32] efi: arm: Drop exception code when running as an EFI app

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:14AM -0700, Simon Glass wrote: > This code cannot be used since EFI is in charge of managing exceptions. > Drop it. > > Signed-off-by: Simon Glass > --- > > arch/arm/cpu/armv8/Makefile | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Why is SPL on in this

Re: [PATCH 14/32] efi: Rename ImageBase to image_base

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:07AM -0700, Simon Glass wrote: > It is confusing to have a camel-case indentifier in the link scripts. > Rename it to fit with U-Boot's snake-case style. > > Signed-off-by: Simon Glass This isn't the linker script, it's the crt0 file. Given that this is intended t

Re: [PATCH 09/32] efi: Allow board/efi Kconfig to be used outside x86

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:02AM -0700, Simon Glass wrote: > So far only x86 supports the EFI app. Sadly ARM is going the same way, > so allow these options to be enabled for ARM too. Please omit "Sadly", that's tone wording we don't need here. > Signed-off-by: Simon Glass Reviewed-by: Tom R

Re: [PATCH 15/32] efi: lmb: Avoid access to _start

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:08AM -0700, Simon Glass wrote: > The app does not have this symbol. Also the memory where the app is > loaded is not under U-Boot's control. Disable this reservation for > the EFI app. > > Signed-off-by: Simon Glass > --- > > lib/lmb.c | 3 ++- > 1 file changed, 2

Re: [PATCH 20/32] efi: arm: Omit the ARM start-up code in the EFI app

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:13AM -0700, Simon Glass wrote: > This code is not used with the EFI app, since it enters through a call > to efi_main(). Remove start.S and crt files from the build. > > Signed-off-by: Simon Glass Reviewed-by: Tom Rini -- Tom signature.asc Description: PGP sig

Re: [PATCH 11/32] efi: x86: Rework VENDOR_EFI option to permit other archs

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:04AM -0700, Simon Glass wrote: > At present only x86 supports the EFI app and (apart from Qualcomm) the > payload. In preparation for supporting ARM more generally, rename the > existing VENDOR_EFI option to VENDOR_EFI_X86, using that to define a > generic VENDOR_EFI

Re: [PATCH RFC v2 2/8] arm: dts: k3-j784s4-binman.dtsi: Clean up and templatize boot binaries

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 02:44:57PM -0600, Andrew Davis wrote: > On 1/6/25 3:34 AM, Manorit Chawdhry wrote: > > From: Neha Malcom Francis > > > > Clean up templatized boot binaries for j784s4 soc. This includes > > modifying the k3-j784s4-binman.dtsi to use SPL_BOARD_DTB, > > BOARD_DESCRIPTION and

Re: [PATCH 00/19] vbe: Series part G

2025-02-03 Thread Tom Rini
On Sun, Jan 26, 2025 at 11:43:10AM -0700, Simon Glass wrote: > This includes the VBE ABrec (A/B/recovery) implementation as well as a > number of patches needed to make it work: > > - marking some code as used by SPL_RELOC > - selection of images from a FIT based on the boot phase > - removal of

[PATCH RESEND] drivers: usb: gadget: composite: add checking for interface number

2025-02-03 Thread Vladimir Mitrofanov
Some proprietary protocols uses "w_index" field not by the rules. When we set "intf = w_index & 0xFF" variable without check it may exceed maximum number of interfaces. Not all code cases below check the range of this variable. In some protocols it is usefull to guaranty that "intf" not exceed MAX_

Re: [PATCH] net: Kconfig: Select DM_RNG for LWIP

2025-02-03 Thread Ilias Apalodimas
On Mon, 3 Feb 2025 at 17:23, Michal Simek wrote: > > > > On 2/3/25 16:13, Ilias Apalodimas wrote: > > Thanks Michal > > > > On Mon, 3 Feb 2025 at 17:03, Michal Simek wrote: > >> > >> LWIP wget.c/mbedtls_hardware_poll() is calling dm_rng_read() but dependency > >> is not recorded anywhere that's w

[PATCH] CI: Use different containers for concurrent runner

2025-02-03 Thread Simon Glass
When running multiple runners on the same machine, each should be in its own container to avoid them interfering with either other. Add a container name for this. Ensure it is removed after use. Signed-off-by: Simon Glass --- .gitlab-ci.yml | 4 1 file changed, 4 insertions(+) diff --git

[PATCH 2/4] u_boot_pylib: Add an exception-class for errors

2025-02-03 Thread Simon Glass
Throwing an Exception is not very friendly since it is the top-level class of all exceptions. Declare a new class instead. Signed-off-by: Simon Glass --- tools/patman/gitutil.py | 2 +- tools/u_boot_pylib/command.py | 20 ++-- 2 files changed, 19 insertions(+), 3 deletion

[PATCH 0/4] tools: Minor clean-ups for the command library

2025-02-03 Thread Simon Glass
This series adds comments and fixes pylint warnings in the command library. It also introduces a new, simpler way of running a single command. Simon Glass (4): u_boot_pylib: Correct case for test_result u_boot_pylib: Add an exception-class for errors u_boot_pylib: Fix pylint warnings in com

[PATCH 1/4] u_boot_pylib: Correct case for test_result

2025-02-03 Thread Simon Glass
This should be in capitals and defined at the start of the file. Update it. Signed-off-by: Simon Glass --- tools/binman/ftest.py | 14 +++--- tools/buildman/func_test.py | 10 +- tools/u_boot_pylib/command.py | 23 +++ 3 files changed, 23 insertions

[PATCH 4/4] u_boot_pylib: Add a function to run a single command

2025-02-03 Thread Simon Glass
Add a helper to avoid needing to use a list within a list for this simple case. Update existing users of runpipe() to use this where possible. Signed-off-by: Simon Glass --- tools/binman/ftest.py | 5 +-- tools/buildman/boards.py| 4 +-- tools/buildman/builder.py | 11

[PATCH 3/4] u_boot_pylib: Fix pylint warnings in command

2025-02-03 Thread Simon Glass
This file has a lot of warnings. Before adding any more features, fix those which are straightforward to resolve. Signed-off-by: Simon Glass --- tools/u_boot_pylib/command.py | 107 +- 1 file changed, 80 insertions(+), 27 deletions(-) diff --git a/tools/u_boot_p

[PATCH v2 3/3] mbedtls: refactor mbedtls build for XPL

2025-02-03 Thread Raymond Mao
Refactor the entire kconfig page for mbedtls, adapt mbedtls makefile and default config file using 'XPL_', in order to have independent mbedtls kconfig options in U-Boot Proper, SPL, TPL and VPL. User can choose legacy or mbedtls libraries for them independently. Set mbedtls native hashing librari

[PATCH v2 2/3] mbedtls: access mbedtls private members in mscode and pkcs7 parser

2025-02-03 Thread Raymond Mao
U-Boot requires to access x509_internal.h, mbedtls_sha256_context and mbedtls_sha1_context in the porting layer, and this requires to enable MBEDTLS_ALLOW_PRIVATE_ACCESS. Enable it to mscode and pkcs7_parser to fix a mbedtls internal building error when X509 is selected. Moreover, Move it to a se

[PATCH v2 1/3] mbedtls: fix incorrect kconfig dependencies on mbedtls

2025-02-03 Thread Raymond Mao
Fixed the building failures when WGET_HTTPS,NET_LWIP and MBEDTLS_LIB are selected due to a few incorrect kconfig dependencies. Signed-off-by: Raymond Mao --- Changes in v2: - Remove the renaming to patch 3/3 and update the commit message accordingly. cmd/Kconfig | 1 - lib/mbedtls/Kconf

Re: [PATCH 08/32] efi: Rename app and payload to include x86

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:01AM -0700, Simon Glass wrote: > Since we plan to support the EFI app and payload on ARM too, rename the > x86 target. > > Adjust the Kconfig rules to allow non-x86 builds to be added. > > Signed-off-by: Simon Glass Reviewed-by: Tom Rini -- Tom signature.asc

Re: [PATCH 03/32] video: Move vesa_setup_video_priv() into its own file

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:41:56AM -0700, Simon Glass wrote: > This helper is used by the EFI driver and we would like to use that on > ARM. Move the helper function into its own file, separate from PCI ROMs, > which are an x86 thing. > > Add a forward declaration for struct udevice so that the he

Re: [PATCH 01/32] Convert build-efi script to Python

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:41:54AM -0700, Simon Glass wrote: > Before this gets any longer, convert it to Python so it is easier to > maintain. > > Signed-off-by: Simon Glass > --- > > MAINTAINERS| 2 +- > doc/develop/uefi/u-boot_on_efi.rst | 4 +- > scripts/build-e

Re: [PATCH 10/32] efi: x86: Move EFI SDRAM-handling into a common file

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:03AM -0700, Simon Glass wrote: > This code is not actually x86-specific, so move it into the lib/efi dir > where other archs can use it. > > Drop inclusion of the unnecessary x86-specific header. > > Signed-off-by: Simon Glass Reviewed-by: Tom Rini -- Tom sig

Re: [PATCH 02/32] Makefile: Avoid using TEXT_BASE if not present

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:41:55AM -0700, Simon Glass wrote: > This value is only available if CONFIG_HAVE_TEXT_BASE is enabled. Add > conditions to avoid introducing errors in link scripts when it is not. > > Signed-off-by: Simon Glass > --- > > Makefile | 4 +++- > 1 file changed, 3 insertio

Re: [PATCH 05/32] lib: Provide fdtdec_get_pci_bar32() only with PCI enabled

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:41:58AM -0700, Simon Glass wrote: > This function calls dm_pci_read_bar32() which is only available if PCI > is enabled. Add this condition here too, so that the EFI app can build > without needing --gc-sections > > Signed-off-by: Simon Glass Reviewed-by: Tom Rini -

Re: [PATCH RFC v2 2/8] arm: dts: k3-j784s4-binman.dtsi: Clean up and templatize boot binaries

2025-02-03 Thread Andrew Davis
On 1/6/25 3:34 AM, Manorit Chawdhry wrote: From: Neha Malcom Francis 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

Re: [GIT PULL] u-boot-riscv/master

2025-02-03 Thread Tom Rini
On Mon, 03 Feb 2025 16:17:45 +0800, Leo Liang wrote: > The following changes since commit 2b1c8d3b2da46ce0f7108f279f04bc66f1d8d09a: > > cmd: Fix Kconfig coding style (2025-01-31 11:29:05 -0600) > > are available in the Git repository at: > > https://source.denx.de/u-boot/custodians/u-boot-r

Re: [PATCH] dfu: Prevent set_dfu_alt_info() from overwriting a previous value

2025-02-03 Thread Jon Humphreys
Ilias Apalodimas writes: > Hi Jon, > > On Fri, 17 Jan 2025 at 00:02, Jon Humphreys wrote: >> >> Sughosh Ganu writes: >> >> > On Thu, 16 Jan 2025 at 14:07, Mattijs Korpershoek >> > wrote: >> >> >> >> Hi Jon, >> >> >> >> Sorry for the (very) late reply. I had some long holidays in between and >>

Re: [PATCH] scripts: Fix potential null-deref

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 07:50:08PM +0300, Maks Mishin wrote: > After having been compared to a NULL value at menu.c:799, > pointer 'sym' is dereferenced at menu.c:812. > > Signed-off-by: Maks Mishin > --- > scripts/kconfig/menu.c | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) >

Re: [PATCH v2 3/4] bloblist: add support for CONFIG_BLOBLIST_PASSAGE

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 12:28:25PM +, Harrison Mutai wrote: > On 31/01/2025 00:10, Tom Rini wrote: > > On Mon, Jan 27, 2025 at 12:42:30PM +, Harrison Mutai wrote: > > > Hi Tom, > > > > > > Thanks for the additional details, that helped! > > > > > > On 23/01/2025 17:12, Tom Rini wrote: > >

Re: [PATCH RFC v2 2/8] arm: dts: k3-j784s4-binman.dtsi: Clean up and templatize boot binaries

2025-02-03 Thread Manorit Chawdhry
Hi Andrew, On 14:44-20250203, Andrew Davis wrote: > On 1/6/25 3:34 AM, Manorit Chawdhry wrote: > > From: Neha Malcom Francis > > > > Clean up templatized boot binaries for j784s4 soc. This includes > > modifying the k3-j784s4-binman.dtsi to use SPL_BOARD_DTB

Re: [PATCH] cmd: ufetch: use 3-bit colour ANSI codes

2025-02-03 Thread Alexey Minnekhanov
t;\033[0m" static const char * const logo_lines[] = { --- base-commit: 2b1c8d3b2da46ce0f7108f279f04bc66f1d8d09a change-id: 20250203-ufetch-vidconsole-colours-0e6a9ebe2475 Best regards, I can see colors on my framebuffer now, thanks! Tested-by: Alexey Minnekhanov

Re: [PATCH] Add Kconfig option for altbootcmd when using CONFIG_BOOTCOUNT_LIMIT

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 03:56:18PM +, Tomáš Peterka wrote: > Hello Tom, > > sorry for the formatting of the first email. As you might have figured > out, the it was not send using git send-email. I tried to do better > later and I had to use different SMTP server and account > (athei...@se

Re: [PATCH 32/32] efi: arm: Add an EFI app for arm64

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:25AM -0700, Simon Glass wrote: > Introduce an EFI app for arm64 and update the documentation. > > Provide a value for LOAD_ADDR to avoid a link error. What's the link error? [snip] > diff --git a/board/efi/Kconfig b/board/efi/Kconfig > index 33bc364861a..75d272d241

Re: [PATCH 11/32] efi: x86: Rework VENDOR_EFI option to permit other archs

2025-02-03 Thread Simon Glass
Hi Tom, On Mon, 3 Feb 2025 at 13:08, Tom Rini wrote: > > On Mon, Feb 03, 2025 at 10:42:04AM -0700, Simon Glass wrote: > > > At present only x86 supports the EFI app and (apart from Qualcomm) the > > payload. In preparation for supporting ARM more generally, rename the > > existing VENDOR_EFI opti

Re: [PATCH 15/32] efi: lmb: Avoid access to _start

2025-02-03 Thread Simon Glass
Hi Tom, On Mon, 3 Feb 2025 at 13:09, Tom Rini wrote: > > On Mon, Feb 03, 2025 at 10:42:08AM -0700, Simon Glass wrote: > > > The app does not have this symbol. Also the memory where the app is > > loaded is not under U-Boot's control. Disable this reservation for > > the EFI app. > > > > Signed-of

Re: [PATCH] zynqmp: Save "bootseq" environment variable in dec format

2025-02-03 Thread Simon Glass
Hi Benjamin, On Mon, 3 Feb 2025 at 09:33, wrote: > > From: Benjamin Szőke > > Save "bootseq" environment variable in decimal format. > > Signed-off-by: Benjamin Szőke > --- > board/xilinx/zynqmp/zynqmp.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/board/xilinx/zynq

Re: [PATCH 21/32] efi: arm: Drop exception code when running as an EFI app

2025-02-03 Thread Simon Glass
Hi Tom, On Mon, 3 Feb 2025 at 13:09, Tom Rini wrote: > > On Mon, Feb 03, 2025 at 10:42:14AM -0700, Simon Glass wrote: > > > This code cannot be used since EFI is in charge of managing exceptions. > > Drop it. > > > > Signed-off-by: Simon Glass > > --- > > > > arch/arm/cpu/armv8/Makefile | 2 +-

Re: [PATCH 31/32] efi: arm: Simplify the crt0 file and update link script

2025-02-03 Thread Simon Glass
Hi Tom, On Mon, 3 Feb 2025 at 13:10, Tom Rini wrote: > > On Mon, Feb 03, 2025 at 10:42:24AM -0700, Simon Glass wrote: > > We don't need to manually add the PE header, since binutils has support > > for this now. Remove it to simplify the file. > > > > Set the link-target to efi-app-aarch64 so tha

Re: [PATCH] zynqmp: Save "bootseq" environment variable in dec format

2025-02-03 Thread Szőke Benjamin
2025. 02. 04. 1:38 keltezéssel, Simon Glass írta: Hi Benjamin, On Mon, 3 Feb 2025 at 09:33, wrote: From: Benjamin Szőke Save "bootseq" environment variable in decimal format. Signed-off-by: Benjamin Szőke --- board/xilinx/zynqmp/zynqmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deleti

Re: [PATCH 28/32] efi: Generate the app as a shared library

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:21AM -0700, Simon Glass wrote: > The app should be built as a shared library, with position-independent > code and the -shared flags. Update the Makefile to handle this. > > Signed-off-by: Simon Glass > --- > > Makefile | 4 > 1 file changed, 4 insertions(+) >

Re: [PATCH 30/32] efi: arm: Use EFI flags for all compilation with the app

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:23AM -0700, Simon Glass wrote: > As opposed to the payload, which is built normally with just an EFI > stub, the app is build homogenously using EFI flags. Update > PLATFORM_CPPFLAGS to enable this. > > Signed-off-by: Simon Glass > --- > > arch/arm/cpu/armv8/confi

Re: [PATCH 25/32] efi: arm: Adjust how the monitor length is calculated

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:18AM -0700, Simon Glass wrote: > Adjust the conditions to support the EFI app when running on ARM. > > Signed-off-by: Simon Glass > --- > > common/board_f.c | 4 ++-- > common/board_r.c | 4 +++- > 2 files changed, 5 insertions(+), 3 deletions(-) > > diff --git a

Re: [PATCH 23/32] efi: arm: Disable --gc-sections for the app

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:16AM -0700, Simon Glass wrote: > This option cannot be used with a shared library, since it results in > everything being removed. Disable it. > > Signed-off-by: Simon Glass Reviewed-by: Tom Rini -- Tom signature.asc Description: PGP signature

Re: [PATCH 24/32] efi: arm: Drop startup code from the app

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:17AM -0700, Simon Glass wrote: > The EFI app uses different startup and relocation code and the existing > code uses symbols not present in the app. Drop it. > > Signed-off-by: Simon Glass Reviewed-by: Tom Rini -- Tom signature.asc Description: PGP signature

Re: [PATCH 26/32] efi: arm: Select the EFI linker script for the app

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:19AM -0700, Simon Glass wrote: > The app needs a special linker script, so select that for the app. > > Signed-off-by: Simon Glass > --- > > arch/arm/cpu/armv8/config.mk | 4 > 1 file changed, 4 insertions(+) > > diff --git a/arch/arm/cpu/armv8/config.mk b/a

Re: [PATCH 27/32] efi: arm: Provide startup and relocation code

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:20AM -0700, Simon Glass wrote: > Build in the EFI-app startup code as well as the code to relocate U-Boot > to the loaded position, since this is under the control of the previous > firmware. > > Signed-off-by: Simon Glass Reviewed-by: Tom Rini -- Tom signatur

Re: [PATCH 31/32] efi: arm: Simplify the crt0 file and update link script

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:24AM -0700, Simon Glass wrote: > We don't need to manually add the PE header, since binutils has support > for this now. Remove it to simplify the file. > > Set the link-target to efi-app-aarch64 so that binutils knows what to > do. Add rules to pick up the arm64 file

Re: [PATCH 16/32] efi: arm: Don't do the EL2 switch when running under EFI

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 10:42:09AM -0700, Simon Glass wrote: > The previous bootloader has likely done this already, so avoid trying to > do it again. This fixes a crash in QEMU when booting from EDK2 > > Signed-off-by: Simon Glass > --- > > arch/arm/lib/bootm.c | 7 +-- > 1 file changed,

Re: [PATCH 21/32] efi: arm: Drop exception code when running as an EFI app

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 05:38:52PM -0700, Simon Glass wrote: > Hi Tom, > > On Mon, 3 Feb 2025 at 13:09, Tom Rini wrote: > > > > On Mon, Feb 03, 2025 at 10:42:14AM -0700, Simon Glass wrote: > > > > > This code cannot be used since EFI is in charge of managing exceptions. > > > Drop it. > > > > > >

Re: [PATCH 11/32] efi: x86: Rework VENDOR_EFI option to permit other archs

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 05:38:27PM -0700, Simon Glass wrote: > Hi Tom, > > On Mon, 3 Feb 2025 at 13:08, Tom Rini wrote: > > > > On Mon, Feb 03, 2025 at 10:42:04AM -0700, Simon Glass wrote: > > > > > At present only x86 supports the EFI app and (apart from Qualcomm) the > > > payload. In preparati

Re: [PATCH 15/32] efi: lmb: Avoid access to _start

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 05:38:44PM -0700, Simon Glass wrote: > Hi Tom, > > On Mon, 3 Feb 2025 at 13:09, Tom Rini wrote: > > > > On Mon, Feb 03, 2025 at 10:42:08AM -0700, Simon Glass wrote: > > > > > The app does not have this symbol. Also the memory where the app is > > > loaded is not under U-Bo

Re: [PATCH 31/32] efi: arm: Simplify the crt0 file and update link script

2025-02-03 Thread Tom Rini
On Mon, Feb 03, 2025 at 05:38:16PM -0700, Simon Glass wrote: > Hi Tom, > > On Mon, 3 Feb 2025 at 13:10, Tom Rini wrote: > > > > On Mon, Feb 03, 2025 at 10:42:24AM -0700, Simon Glass wrote: > > > We don't need to manually add the PE header, since binutils has support > > > for this now. Remove it

[PATCH 1/2] efi_firmware: set EFI capsule dfu_alt_info env explicitly

2025-02-03 Thread Jonathan Humphreys
The current implementation of EFI capsule update uses set_dfu_alt_info() to set the dfu_alt_info environment variable with the settings it requires. However, set_dfu_alt_info() is doing this for all DFU operations, even those unrelated to capsule update. Thus other uses of DFU, such as DFU boot wh

[PATCH 2/2] board: remove capsule update support in set_dfu_alt_info()

2025-02-03 Thread Jonathan Humphreys
Now that capsule update sets the dfu_alt_info environment variable explicitly, there is no need to support it in the set_dfu_alt_info() function. Decouple SET_DFU_ALT_INFO from EFI_CAPSULE_FIRMWARE_FIT and EFI_CAPSULE_FIRMWARE_RAW. For many boards, this was the only use of set_dfu_alt_info() so rem

[PATCH 0/2] EFI Capsule update explicitly sets dfu_alt_info

2025-02-03 Thread Jonathan Humphreys
For capsule update, explicitly set the dfu_alt_info environment variable before the DFU operation, and then restore it to the original value. Previously, the dfu_alt_info environment variable was set with the set_dfu_alt_info() function. The problem with setting the capsule update's dfu_alt_info s

Re: [PATCH 3/3] configs: phycore_am64x_r5_defconfig: Enable PHYTEC_SOM_DETECTION

2025-02-03 Thread Daniel Schultz
On 27.01.25 05:16, Wadim Egorov wrote: > Enable configs required for detecting and fixing up for different RAM > variants. > Also resync after savedefconfig. > > Signed-off-by: Wadim Egorov Tested-by: Daniel Schultz > --- > configs/phycore_am64x_r5_defconfig | 4 +++- > 1 file changed, 3 ins

Re: [PATCH 1/3] arch: arm: dts: phyboard-electra-uboot.dtsi: Add bootph props to i2c

2025-02-03 Thread Daniel Schultz
On 27.01.25 05:16, Wadim Egorov wrote: > Add bootph-all properties to I2C0 nodes to ensure the bus and EEPROM > are accessible across all stages. This enables reading the SoM > configuration at any point during the boot process. > > Signed-off-by: Wadim Egorov Tested-by: Daniel Schultz > --- >

Re: [PATCH 2/3] board: phytec: phycore_am64x: Add support for 1 GB RAM variant and ECC

2025-02-03 Thread Daniel Schultz
On 27.01.25 05:16, Wadim Egorov wrote: > Detect RAM size via EEPROM and adjust DDR size and banks accordingly. > Include necessary fixups to handle ECC-enabled configurations. > > Signed-off-by: Wadim Egorov Tested-by: Daniel Schultz > --- > board/phytec/phycore_am64x/Kconfig | 25 +++

[PATCH v4 2/5] efi_loader: add a function to remove memory from the EFI map

2025-02-03 Thread Sughosh Ganu
From: Ilias Apalodimas With upcoming changes supporting pmem nodes, we need to remove the pmem area from the EFI memory map. Add a function to do that. Signed-off-by: Ilias Apalodimas Reviewed-by: Heinrich Schuchardt Signed-off-by: Sughosh Ganu --- Changes since V3: None include/efi_loader.

[PATCH v4 3/5] efi_loader: preserve installer images in pmem

2025-02-03 Thread Sughosh Ganu
From: Ilias Apalodimas One of the problems OS installers face, when running in EFI, is that the mounted ISO after calling ExitBootServices goes away. For some distros this is a problem since they rely on finding some core packages before continuing the installation. Distros have works around this

[PATCH v4 0/5] Add pmem node for preserving distro ISO's

2025-02-03 Thread Sughosh Ganu
When installing a distro via EFI HTTP boot some OS installers expect the .iso image to be preserved and treat it as a "CDROM" to install packages. This is problematic in EFI, since U-Boot mounts the image, starts the installer, and eventually calls ExitBootServices. At that point the image U-Boo

[PATCH v4 1/5] fdt: add support for adding pmem nodes

2025-02-03 Thread Sughosh Ganu
From: Masahisa Kojima One of the problems OS installers face, when running in EFI, is that the mounted ISO after calling ExitBootServices goes away. For some distros this is a problem since they rely on finding some core packages before continuing the installation. Distros have works around this

[PATCH v4 4/5] blkmap: store type of blkmap slice in corresponding structure

2025-02-03 Thread Sughosh Ganu
Add information about the type of blkmap slice in the corresponding slice structure. Put information in the blkmap slice structure to identify if it is associated with a memory or linear mapped device. Which can then be used to take specific action based on the type of the blkmap slice. Signed-off

[PATCH v4 5/5] blkmap: add pmem nodes for blkmap memory mapped slices

2025-02-03 Thread Sughosh Ganu
The EFI HTTP boot puts the ISO installer image at some location in memory which needs to be added to the devicetree as persistent memory (pmem) node. The OS installer then gets information about the presence of this ISO image through the pmem node and proceeds with the installation. In U-Boot, thi

Re: [PATCH v2 1/1] cmd/setexpr: support concatenation of direct strings

2025-02-03 Thread Heinrich Schuchardt
On 2/2/25 16:00, Tom Rini wrote: On Sun, Feb 02, 2025 at 01:01:00PM +0100, Heinrich Schuchardt wrote: On 1/20/25 21:52, Tom Rini wrote: On Sun, Jan 05, 2025 at 11:46:14AM +0100, Heinrich Schuchardt wrote: The setexpr.s command allows to concatenate two strings. According to the description i

Re: [PATCH v2] zynqmp: Dynamic setting mmcdev and mmcroot

2025-02-03 Thread Michal Simek
Hi, On 2/1/25 15:06, egyszer...@freemail.hu wrote: From: Benjamin Szőke Dynamic setting mmcdev and mmcroot. Then when boot linux, we can have correct "root=/dev/mmcblk[x]p2" This is source of the problem. That root partition is second is only your choice and doesn't need to be choice for ot

[GIT PULL] u-boot-riscv/master

2025-02-03 Thread Leo Liang
Hi Tom, The following changes since commit 2b1c8d3b2da46ce0f7108f279f04bc66f1d8d09a: cmd: Fix Kconfig coding style (2025-01-31 11:29:05 -0600) are available in the Git repository at: https://source.denx.de/u-boot/custodians/u-boot-riscv.git for you to fetch changes up to faf237d1b43c3221e

Re: [PATCH v2 1/4] net: lwip: tftp: fix find_option()

2025-02-03 Thread Jerome Forissier
Hi Heinrich, On 2/1/25 07:22, Heinrich Schuchardt wrote: > Find_option() is used to retrieve the block size value in an option > acknowledgment in response to a request containing a block size option > according to RFC2348. > > The format of an OACK response is described in RFC2347 as > > +-

[PATCH] configs: versal: update initial stack pointer

2025-02-03 Thread Padmarao Begari
The mini u-boot is hanging because of an initial stack pointer address is used at half of the memory, when mini u-boot is called reloc_fdt() function and doing memcpy() for the fdt before relocation, and there is no sufficient memory for the stack pointer. To fix, set an initial stack pointer addre

Re: [PATCH] xilinx: Remove SYS_MALLOC_F_LEN setup via board Kconfig

2025-02-03 Thread Michal Simek
On 1/20/25 14:33, Michal Simek wrote: The commit e05689242238 ("Kconfig: Change SYS_MALLOC_F_LEN default to 0x2000") already setup default values from board Kconfigs that's why no reason to duplicate it again. Fixes: e05689242238 ("Kconfig: Change SYS_MALLOC_F_LEN default to 0x2000") Signed-o

Re: [PATCH] arm64: zynqmp: enable u-boot itb generation via binman if SPL is enabled

2025-02-03 Thread Michal Simek
On 1/21/25 13:24, Michal Simek wrote: From: Prasad Kummari Output images are generated via Binman only if SPL is enabled, as there is no consumer for them otherwise. An #ifdef check ensures that when SPL is enabled, Binman generates the U-Boot ITB. If SPL is disabled, ITB generation is skipp

Re: [PATCH] arm64: zynqmp: Describe ethernet controllers via aliases on SOM

2025-02-03 Thread Michal Simek
On 1/21/25 14:41, Michal Simek wrote: Add ethernet aliases to CC (Carrier card) description to create a connection which is used by fdt_fixup_ethernet() for updating local-mac-address in DT. On Kria SOM MAC address is read from i2c eeprom at start and based on it environment variables are crea

[PATCH v3 1/4] net: lwip: tftp: fix find_option()

2025-02-03 Thread Heinrich Schuchardt
Find_option() is used to retrieve the block size value in an option acknowledgment in response to a request containing a block size option according to RFC2348. The format of an OACK response is described in RFC2347 as +---+---~~---+---+---~~---+---+---~~---+---+---~~---+---+ | opc | opt1

[PATCH v3 4/4] net: use strnstr() for lwip_strnstr()

2025-02-03 Thread Heinrich Schuchardt
Using strstr() instead of strnstr() creates a security concern. Fixes: 1c41a7afaa15 ("net: lwip: build lwIP") Signed-off-by: Heinrich Schuchardt Reviewed-by: Jerome Forissier --- v3: no change v2: no change --- lib/lwip/u-boot/arch/cc.h | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH v3 3/4] test: unit tests for strstr() and strnstr()

2025-02-03 Thread Heinrich Schuchardt
Add unit tests for the library functions. Signed-off-by: Heinrich Schuchardt Acked-by: Ilias Apalodimas --- v3: no change v2: no change --- lib/string.c | 2 +- test/lib/string.c | 40 2 files changed, 41 insertions(+), 1 deletion(-

[PATCH v3 2/4] lib: implement strnstr()

2025-02-03 Thread Heinrich Schuchardt
Implement library function strnstr(). Implement strstr() using strnstr(). Sort the includes. Signed-off-by: Heinrich Schuchardt --- v3: no change v2: no change --- include/linux/string.h | 3 +++ lib/string.c | 49 +- 2 files cha

[PATCH v3 0/4] net: use strnstr() for lwip_strnstr()

2025-02-03 Thread Heinrich Schuchardt
Using strstr() instead of strnstr() creates a security concern. * Implement missing library function strnstr() and add unit tests. * Use it for lwIP. * Fix function find_option() which is used to find the TFTP blocksize. v3: rename variable match to diff in find_option() v2: New p

Re: [PATCH v2 2/7] ARM: dts: at91: sam9x60: Define pinctrl node with its label

2025-02-03 Thread Manikandan.M
Hi Eugen, On 31/01/25 12:10 am, Eugen Hristev wrote: > EXTERNAL EMAIL: Do not click links or open attachments unless you know the > content is safe > > On 1/30/25 05:51, Manikandan Muralidharan wrote: >> From: Balamanikandan Gunasundar >> >> Define the pinctrl nodes with its label to align with

[PATCH] rtc: emul_rtc: Make emul_rtc_probe() static

2025-02-03 Thread Michal Simek
emul_rtc_probe() is not called from anywhere else that's why make it static. Issue is reported by build with W=1. Signed-off-by: Michal Simek --- drivers/rtc/emul_rtc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/emul_rtc.c b/drivers/rtc/emul_rtc.c index 97a8

Re: [PATCH] fpga: Avoid ignored-qualifiers warning

2025-02-03 Thread Michal Simek
On 1/21/25 17:22, Alexander Dahl wrote: Fixes annoying warnings of the following type when built with W=1 (for each file including fpga.h): CC drivers/fpga/fpga.o In file included from /mnt/data/adahl/src/u-boot/include/xilinx.h:7, from /mnt/data/adahl/s

Re: [PATCH] env: fat: Avoid writing to read-only location

2025-02-03 Thread Ilias Apalodimas
Thanks Andre, On Thu, 30 Jan 2025 at 15:37, Andre Przywara wrote: > > The env_fat_get_dev_part() function mostly returns a fixed string, set > via some Kconfig variable. However when the first character is a colon, > that means that the boot device number is determined at runtime, and > patched

Re: [PATCH v2] zynqmp: Dynamic setting mmcdev and mmcroot

2025-02-03 Thread Michal Simek
On 2/3/25 13:19, Szőke Benjamin wrote: 2025. 02. 03. 9:01 keltezéssel, Michal Simek írta: Hi, On 2/1/25 15:06, egyszer...@freemail.hu wrote: From: Benjamin Szőke Dynamic setting mmcdev and mmcroot. Then when boot linux, we can have correct "root=/dev/mmcblk[x]p2" This is source of the p

Re: [PATCH] Add Kconfig option for altbootcmd when using CONFIG_BOOTCOUNT_LIMIT

2025-02-03 Thread Tomáš Peterka
Hello Tom, sorry for the formatting of the first email. As you might have figured out, the it was not send using git send-email. I tried to do better later and I had to use different SMTP server and account (athei...@seznam.cz) because our company email provider is too much ahead in the future

[PATCH] tools: image-host: Fix potential memory leaks

2025-02-03 Thread Maks Mishin
For a variable `info.name` memory is allocated when calling the `fit_image_setup_sig` function and is lost when the error code is returned. The situation is similar for the `region_prop` variable, the memory for which is allocated by calling the function `fit_config_get_regions`. Signed-off-by

[PATCH] scripts: Fix potential null-deref

2025-02-03 Thread Maks Mishin
After having been compared to a NULL value at menu.c:799, pointer 'sym' is dereferenced at menu.c:812. Signed-off-by: Maks Mishin --- scripts/kconfig/menu.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/kconfig/menu.c b/scripts/kconfig/menu.c index 0fe7f3255a

Re: [PATCH RFC 00/14] efi: implement EFISTUB support for ARM64 and Qualcomm

2025-02-03 Thread Simon Glass
Hi again, On Mon, 3 Feb 2025 at 05:54, Simon Glass wrote: > > Hi Caleb, > > On Sun, 24 Nov 2024 at 13:27, Caleb Connolly > wrote: > > > > This series implements support for launching U-Boot as an EFI payload on > > ARM64 devices that already have an EFI capable bootloader. > > > > Patches 9 thr

[PATCH 01/32] Convert build-efi script to Python

2025-02-03 Thread Simon Glass
Before this gets any longer, convert it to Python so it is easier to maintain. Signed-off-by: Simon Glass --- MAINTAINERS| 2 +- doc/develop/uefi/u-boot_on_efi.rst | 4 +- scripts/build-efi.py | 258 + scripts/build-efi.sh

[PATCH 03/32] video: Move vesa_setup_video_priv() into its own file

2025-02-03 Thread Simon Glass
This helper is used by the EFI driver and we would like to use that on ARM. Move the helper function into its own file, separate from PCI ROMs, which are an x86 thing. Add a forward declaration for struct udevice so that the header can be included directly. Signed-off-by: Simon Glass --- drive

[PATCH 02/32] Makefile: Avoid using TEXT_BASE if not present

2025-02-03 Thread Simon Glass
This value is only available if CONFIG_HAVE_TEXT_BASE is enabled. Add conditions to avoid introducing errors in link scripts when it is not. Signed-off-by: Simon Glass --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 2f7614191a1..3958

[PATCH 04/32] video: Use a local mode_info struct in the EFI driver

2025-02-03 Thread Simon Glass
There is no need to use the global struct provided by PCI. Declare a local structure instead, so this can be used on ARM without including support for PCI ROMs. Signed-off-by: Simon Glass --- drivers/video/efi.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/video/efi.c b/drivers/v

[PATCH 05/32] lib: Provide fdtdec_get_pci_bar32() only with PCI enabled

2025-02-03 Thread Simon Glass
This function calls dm_pci_read_bar32() which is only available if PCI is enabled. Add this condition here too, so that the EFI app can build without needing --gc-sections Signed-off-by: Simon Glass --- lib/fdtdec.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/fdtdec.c b/lib/fdtdec

[PATCH 06/32] scripts: Update build-efi to support building U-Boot

2025-02-03 Thread Simon Glass
Build U-Boot by default, so we can select the correct board and make the process of trying different boards less error-prone. Signed-off-by: Simon Glass --- scripts/build-efi.py | 14 ++ 1 file changed, 14 insertions(+) diff --git a/scripts/build-efi.py b/scripts/build-efi.py index

[PATCH 12/32] efi: x86: Allow setting the global_data pointer with EFI

2025-02-03 Thread Simon Glass
Provide a function which sets this pointer, for use in the EFI app. Signed-off-by: Simon Glass --- arch/x86/include/asm/global_data.h | 7 +++ 1 file changed, 7 insertions(+) diff --git a/arch/x86/include/asm/global_data.h b/arch/x86/include/asm/global_data.h index 06bd80ccc13..1bd1fa9207

[PATCH 13/32] efi: Tidy up setup of global_data

2025-02-03 Thread Simon Glass
Use the available functions for setting and getting the global_data pointer so that EFI-startup can operate on ARM as well as x86. Signed-off-by: Simon Glass --- lib/efi/efi_app.c | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/lib/efi/efi_app.c b/lib/efi/efi_a

[PATCH 14/32] efi: Rename ImageBase to image_base

2025-02-03 Thread Simon Glass
It is confusing to have a camel-case indentifier in the link scripts. Rename it to fit with U-Boot's snake-case style. Signed-off-by: Simon Glass --- arch/arm/lib/crt0_aarch64_efi.S | 26 +- arch/riscv/lib/crt0_riscv_efi.S | 28 ++-- include/asm-g

[PATCH 07/32] scripts: Update build-efi to support arm64

2025-02-03 Thread Simon Glass
Provide a -A flag to select ARM instead of x86. For now, only the app is supported and only for 64-bit ARM. Signed-off-by: Simon Glass --- scripts/build-efi.py | 49 +++- 1 file changed, 35 insertions(+), 14 deletions(-) diff --git a/scripts/build-efi.py

[PATCH 08/32] efi: Rename app and payload to include x86

2025-02-03 Thread Simon Glass
Since we plan to support the EFI app and payload on ARM too, rename the x86 target. Adjust the Kconfig rules to allow non-x86 builds to be added. Signed-off-by: Simon Glass --- board/efi/Kconfig | 12 board/efi/efi-x86_payload/Kconfig | 2 +- configs/efi-x86_a

[PATCH 11/32] efi: x86: Rework VENDOR_EFI option to permit other archs

2025-02-03 Thread Simon Glass
At present only x86 supports the EFI app and (apart from Qualcomm) the payload. In preparation for supporting ARM more generally, rename the existing VENDOR_EFI option to VENDOR_EFI_X86, using that to define a generic VENDOR_EFI which will be enabled for all architectures. Signed-off-by: Simon Gla

  1   2   >