Re: [PATCH v6 00/28] Integrate MbedTLS v3.6 LTS with U-Boot

2024-09-06 Thread Ilias Apalodimas
Hi Tom On Wed, 4 Sept 2024 at 19:43, Tom Rini wrote: > > On Wed, Sep 04, 2024 at 01:48:43PM +0100, Peter Robinson wrote: > > Hi Simon, > > > > > I wonder if we could leave out the SHA stuff? The algorithms are > > > > One of the big advantages of the mbedtls when it comes to all things > > securi

[PATCH v2 0/2] fdtoverlay related changes

2024-09-06 Thread Prasad Kummari
Changes in v2: - Corrected commit description. Prasad Kummari (2): kbuild: cherry-pick kbuild fdtoverlay changes from linux arm64: zynqmp: Remove overlays and add new dtb entries for ZynqMP arch/arm/dts/Makefile | 78 +- scripts/Kbuild.include | 4 ++

[PATCH v2 1/2] kbuild: cherry-pick kbuild fdtoverlay changes from linux

2024-09-06 Thread Prasad Kummari
Linux commits: 15d16d6dadf6 kbuild: Add generic rule to apply fdtoverlay 44f87191d105 kbuild: parameterize the .o part of suffix-search The Linux commit 15d16d6dadf6 adds a generic rule in Makefile.lib to automatically apply fdtoverlay, so that each platform doesn't need to include a complex rule.

[PATCH v2 2/2] arm64: zynqmp: Remove overlays and add new dtb entries for ZynqMP

2024-09-06 Thread Prasad Kummari
Remove device tree overlay (DTBO) entries for the ZynqMP target from the Makefile. Add new device tree binaries (DTBs) for the zynqmp-sm-k24-revA and zynqmp-smk-k24-revA configurations. Signed-off-by: Michal Simek Signed-off-by: Prasad Kummari --- arch/arm/dts/Makefile | 21

Re: [PATCH v3 2/3] efi: Allow use of malloc() for the EFI pool

2024-09-06 Thread Ilias Apalodimas
Hi Simon, Apologies for the late reply, I was attending a conference. On Mon, 2 Sept 2024 at 01:23, Simon Glass wrote: > > This API call is intended for allocating small amounts of memory, > similar to malloc(). The current implementation rounds up to whole pages > which can waste large amounts

[PATCH v2 00/28] Implement ACPI on aarch64

2024-09-06 Thread Patrick Rudolph
Based on the existing work done by Simon Glass this series adds support for booting aarch64 devices using ACPI only. As first target QEMU SBSA support is added, which relies on ACPI only to boot an OS. As secondary target the Raspberry Pi4 was used, which is broadly available and allows easy testin

[PATCH v2 02/28] acpi: x86: Write FADT in common code

2024-09-06 Thread Patrick Rudolph
From: Maximilian Brune Write the FADT in common code since it's used on all architectures. Let the cpu code fill out the FADT body by introducing a new weak function acpi_fill_fadt(). Signed-off-by: Patrick Rudolph Cc: Simon Glass Cc: Bin Meng --- arch/x86/cpu/apollolake/acpi.c| 20 +++--

[PATCH v2 01/28] acpi: x86: Move SPCR and DBG2 into common code

2024-09-06 Thread Patrick Rudolph
From: Maximilian Brune This moves the SPCR and DBG2 table generation into common code, so that they can be used by architectures other than x86. Signed-off-by: Maximilian Brune Signed-off-by: Patrick Rudolph Cc: Simon Glass Cc: Bin Meng --- Changelog v2: - Do not add new features, just move

[PATCH v2 04/28] acpi: Fix typo

2024-09-06 Thread Patrick Rudolph
Rename ACPI tables MADR to MADT. Signed-off-by: Patrick Rudolph Reviewed-by: Simon Glass Cc: Simon Glass --- include/acpi/acpi_table.h | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/include/acpi/acpi_table.h b/include/acpi/acpi_table.h index 58630b3c4c..8a

[PATCH v2 03/28] acpi: x86: Move MADT to common code

2024-09-06 Thread Patrick Rudolph
Write MADT in common code and let the SoC fill out the body by calling acpi_fill_madt() which must be implemented at SoC level. Signed-off-by: Patrick Rudolph Cc: Simon Glass Cc: Bin Meng --- arch/sandbox/lib/Makefile | 9 +++--- arch/sandbox/lib/acpi_table.c | 7 + arch/x86/

[PATCH v2 05/28] serial: serial_pl01x: Implement .getinfo() for PL01

2024-09-06 Thread Patrick Rudolph
From: Maximilian Brune When ACPI is enabled on arm it will use the getinfo function to fill the SPCR ACPI table. Signed-off-by: Maximilian Brune Reviewed-by: Simon Glass Cc: Simon Glass Cc: Tom Rini --- boot/bootflow.c | 8 ++-- drivers/serial/serial_pl01x.c | 24

[PATCH v2 06/28] acpi: Add define for GTDT

2024-09-06 Thread Patrick Rudolph
Add the interrupt flag used in ACPI GTDT table as define. Signed-off-by: Patrick Rudolph Reviewed-by: Simon Glass Cc: Simon Glass --- include/acpi/acpi_table.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/acpi/acpi_table.h b/include/acpi/acpi_table.h index 8a25c76cf3..ac2dd0d6

[PATCH v2 07/28] arm: acpi: Add generic ACPI methods

2024-09-06 Thread Patrick Rudolph
Add generic ACPI code to generate - MADT GICC - MADT GICD - MADT GICR - MADT GIC ITS - PPTT processor - PPTT cache as commonly used on arm platforms. Signed-off-by: Patrick Rudolph Cc: Tom Rini Cc: Simon Glass --- Changelog v2: - Add full comments to exported functions --- arch/arm/include/a

[PATCH v2 08/28] acpi: Add fill_madt to acpi_ops

2024-09-06 Thread Patrick Rudolph
Add a new method to acpi_ops to let drivers fill out ACPI MADT. The code is unused for now until drivers implement the new ops. Signed-off-by: Patrick Rudolph Cc: Simon Glass --- drivers/core/acpi.c | 16 include/dm/acpi.h | 26 ++ lib/acpi/acpi_ta

[PATCH v2 09/28] acpi: acpi_table: Bump revisions

2024-09-06 Thread Patrick Rudolph
The FADT structure found in U-Boot represents FADT revision 6 and the GICC and GICD structures defined in U-Boot are based on ACPI revision 6.3. Bump the table revision to fix FWTS failures seen on aarch64. Signed-off-by: Patrick Rudolph Reviewed-by: Simon Glass Cc: Simon Glass Cc: Bin Meng -

[PATCH v2 10/28] acpi: Add ACPITAB for PPTT and GTDT

2024-09-06 Thread Patrick Rudolph
Return the ACPI table revision in acpi_get_table_revision() for PPTT and GTDT. Match both to ACPI 6.2. Signed-off-by: Patrick Rudolph Reviewed-by: Simon Glass Cc: Simon Glass --- include/acpi/acpi_table.h | 2 ++ lib/acpi/acpi_table.c | 4 2 files changed, 6 insertions(+) diff --git

[PATCH v2 11/28] acpi: acpi_table: Add IORT support

2024-09-06 Thread Patrick Rudolph
The SoC can implement acpi_fill_iort to update the IORT table. Add a helper function to fill out the NAMED_COMPONENT node. TEST=Run FWTS V24.03.00 on RPi4 and round no problems. Signed-off-by: Patrick Rudolph Cc: Simon Glass --- include/acpi/acpi_table.h | 213 +

[PATCH v2 12/28] acpi: Move function prototype

2024-09-06 Thread Patrick Rudolph
Allow other architectures to use acpi_create_mcfg_mmconfig as well by moving the function prototype to common code. Signed-off-by: Patrick Rudolph Cc: Simon Glass --- arch/x86/include/asm/acpi_table.h | 2 -- include/acpi/acpi_table.h | 13 + 2 files changed, 13 insertions(

[PATCH v2 13/28] acpi: acpi_table: Support ACPI 2.0 platforms

2024-09-06 Thread Patrick Rudolph
On platforms that do not have usable DRAM below 4GiB, like QEMU sbsa, the RSDT cannot be used. Allow both RSDT and XSDT to be null and only fill those tables that are present in acpi_add_table(). Fixes a crash on QEMU sbsa. Signed-off-by: Patrick Rudolph Cc: Simon Glass Cc: Tom Rini --- lib/a

[PATCH v2 14/28] efi_loader: Install ACPI tables

2024-09-06 Thread Patrick Rudolph
Install ACPI tables inside the efi_loader similar to SMBIOS tables. When ACPI is enabled and wasn't installed in other places, install the ACPI table in EFI. Since EFI is necessary to pass the ACPI table location when FDT isn't used, there's no need to install it separately. When CONFIG_BLOBLIST_T

[PATCH v2 15/28] acpi: Add processor device

2024-09-06 Thread Patrick Rudolph
Add a new method to write the processor device identified by _HID ACPI0007, that is preferred over the Processor OpCode since ACPI 6.0. Fixes booting arm using ACPI only since the Processor OpCode isn't found valid by the Linux kernel. Signed-off-by: Patrick Rudolph Cc: Simon Glass --- include

[PATCH v2 16/28] drivers: usb: Add generic XHCI

2024-09-06 Thread Patrick Rudolph
Add support for the generic XHCI driver that contains no SoC specific code. It can be used on platforms that simply work out of the box, like on emulated platforms. TEST: Booted on QEMU sbsa machine using the generic xhci driver. Signed-off-by: Patrick Rudolph Cc: Tom Rini --- drivers/usb/host

[PATCH v2 18/28] drivers/cpu: Add generic armv8 cpu driver

2024-09-06 Thread Patrick Rudolph
Add a generic driver that binds to armv8 CPU nodes. TEST: Booted on QEMU sbsa and verify the driver binds to CPU nodes. Confirmed with FWTS that all ACPI processor devices are present. Signed-off-by: Patrick Rudolph Cc: Tom Rini --- drivers/cpu/Kconfig | 6 +++ drivers/cpu/Makefile

[PATCH v2 19/28] common: Enable BLOBLIST_TABLES on arm

2024-09-06 Thread Patrick Rudolph
Allow to use BLOBLIST_TABLES on arm to store ACPI or other tables. Signed-off-by: Patrick Rudolph Cc: Tom Rini --- common/Kconfig | 1 + lib/Kconfig| 15 +-- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/common/Kconfig b/common/Kconfig index 83c81edac2..a864e2

[PATCH v2 17/28] drivers: ata: Rename ahci_mvebu

2024-09-06 Thread Patrick Rudolph
Rename 'ahci_mvebu' to 'ahci_generic' and select it by default. The AHCI driver contains no SoC specific code and only expects the base address to be passed, thus rename it to ahci_generic and add the DT compatible string "generic-ahci". Update existing defconfigs to use the new Kconfig name as we

[PATCH v2 21/28] arm: mach-bcm283x: Map the ARM local MMIO as well

2024-09-06 Thread Patrick Rudolph
Cover the "ARM local MMIO" range as well in the default MMU mapping in order to allow future code to access the GIC-400 without crashing. For now the GIC is not touched in u-boot, thus this change is a noop. See [1](BCM2711 ARM Peripherals) for reference. TEST: Enabled CONFIG_GICV2 and accessed t

[PATCH v2 22/28] arm: mach-bcm283x: Bring in some header files from tianocore

2024-09-06 Thread Patrick Rudolph
From: Simon Glass These header files presumably duplicate things already in the U-Boot devicetree. For now, bring them in to get the ASL code and ACPI table code to compile. Signed-off-by: Simon Glass Signed-off-by: Patrick Rudolph Cc: Matthias Brugger Cc: Peter Robinson Cc: Tom Rini --- .

[PATCH v2 23/28] arm: bcm283x: Generate ACPI tables

2024-09-06 Thread Patrick Rudolph
Generate SoC specific ACPI tables for BCM2711: - MADT - FADT - PPTT - GTDT Board specific tables like DSDT and SSDT are added in a separate patch. When ACPI is enabled for a different SoC compliation will fail by design, indicating the required functions that needs to be implemented. When ACPI is

[PATCH v2 20/28] board: emulation: Add QEMU sbsa support

2024-09-06 Thread Patrick Rudolph
Add support for Arm sbsa [1] v0.3+ that is supported by QEMU [2]. Unlike other Arm based platforms the machine only provides a minimal FDT that contains number of CPUs, ammount of memory and machine-version. The boot firmware has to provide ACPI tables to the OS. Add a minimal amount of devicetre

[PATCH v2 25/28] arm: cpu: Add ACPI parking protocol support

2024-09-06 Thread Patrick Rudolph
On Arm platforms that use ACPI they cannot rely on the "spin-table" CPU bringup usually defined in the FDT. Thus implement the 'ACPI Multi-processor Startup for ARM Platforms', also referred to as 'ACPI parking protocol'. The ACPI parking protocol works similar to the spin-table mechanism, but the

[PATCH v2 24/28] board: raspberrypi: Add ASL files from tianocore

2024-09-06 Thread Patrick Rudolph
From: Simon Glass Add the necessary DSDT files copied from tianocore to boot the RPi4. In addition generate a board specific SSDT to dynamically enable/disable ACPI devices based on FDT. This is required to support the various variants and boot options. It also allows to test the code on QEMU 9.0

[PATCH v2 26/28] arm: mach-bcm283x: Add ARMV8_MULTIENTRY support

2024-09-06 Thread Patrick Rudolph
When ACPI is enabled over FDT the APs cannot be brought out of reset by the OS using the "FDT spin-table" mechanism, as no FDT is provided to the OS. The APs must be released out of reset in u-boot and then brought up in an ACPI compliant fashion. When ARMV8_MULTIENTRY is specified the APs are rel

[PATCH v2 27/28] arm: mach-bcm283x: Enable ARMV8_MULTIENTRY

2024-09-06 Thread Patrick Rudolph
On FDT platforms the APs are brought out of reset using the spin-table as defined in the DT. On ACPI enabled platforms there's no FDT, thus enable the ARMV8_MULTIENTRY to use the ACPI parking protocol instead. TEST: - APs enter Linux when run on qemu-system-aarch64 -machine raspi4b - APs on

[PATCH v2 28/28] configs: Add RPI4 ACPI defconfig

2024-09-06 Thread Patrick Rudolph
Allows to build the RPi4 with ACPI enabled. TEST: - Boots on qemu-system-aarch64 -machine raspi4b - Boots on real hardware with arm_64bit=1 in config.txt Signed-off-by: Patrick Rudolph Cc: Simon Glass Cc: Matthias Brugger Cc: Peter Robinson --- configs/rpi_4_acpi_defconfig | 72 +++

Re: [PATCH v6 07/28] hash: integrate hash on mbedtls

2024-09-06 Thread Ilias Apalodimas
Hi Raymond, On Tue, 3 Sept 2024 at 18:54, Raymond Mao wrote: > > Hi Ilias, > > On Fri, 30 Aug 2024 at 05:37, Ilias Apalodimas > wrote: >> >> Hi Simon, >> >> On Thu, 29 Aug 2024 at 18:01, Simon Glass wrote: >> > >> > Hi Raymond, >> > >> > On Fri, 16 Aug 2024 at 15:47, Raymond Mao wrote: >> > >

Re: [Binman] Question regarding SPL symbol offsets generation

2024-09-06 Thread Lukasz Majewski
Hi Simon, > Hi Lukasz, > > On Thu, 5 Sept 2024 at 07:54, Lukasz Majewski wrote: > > > > Hi Adam, > > > > > On Wed, Aug 28, 2024 at 3:04 AM Lukasz Majewski > > > wrote: > > > > > > > > Hi Simon, > > > > > > > > > Hi, > > > > > > > > > > On Tue, 27 Aug 2024 at 12:47, Fabio Estevam > > > > >

Re: [PATCH v6 06/28] mbedtls: add digest shim layer for MbedTLS

2024-09-06 Thread Ilias Apalodimas
[...] On Tue, 3 Sept 2024 at 18:28, Raymond Mao wrote >> > +void sha256_starts(sha256_context *ctx) >> > +{ >> > + mbedtls_sha256_init(ctx); >> > + mbedtls_sha256_starts(ctx, 0); >> > +} >> > + >> > +void >> > +sha256_update(sha256_context *ctx, const uint8_t *input, uint32_t length) >> >

Re: [PATCH v4 2/9] phy: starfive: Add Starfive JH7110 USB 2.0 PHY driver

2024-09-06 Thread Minda Chen
> > On 8/29/24 3:30 AM, Minda Chen wrote: > > [...] > > > +menu "Starfive PHY driver" > > + > > +config PHY_STARFIVE_JH7110_USB2 > > + bool "Starfive JH7110 USB 2.0 PHY driver" > > + select PHY > > Can this PHY_STARFIVE_JH7110_USB2 symbol be selected if CONFIG_PHY is not > set ? I think i

Re: [PATCH v6 00/28] Integrate MbedTLS v3.6 LTS with U-Boot

2024-09-06 Thread Peter Robinson
On Fri, 6 Sept 2024 at 01:44, Simon Glass wrote: > > Hi, > > On Wed, 4 Sept 2024 at 06:48, Peter Robinson wrote: > > > > Hi Simon, > > > > > I wonder if we could leave out the SHA stuff? The algorithms are > > > > One of the big advantages of the mbedtls when it comes to all things > > security i

Re: [PATCH] cmd: fdt: use U-Boot's FDT by default

2024-09-06 Thread Caleb Connolly
On 03/09/2024 20:29, Tom Rini wrote: On Mon, Sep 02, 2024 at 03:07:44PM +0200, Caleb Connolly wrote: Hi Simon, On 01/09/2024 21:10, Simon Glass wrote: Hi Caleb, On Sun, 1 Sept 2024 at 08:21, Caleb Connolly wrote: Hi, On 31/08/2024 23:22, E Shattow wrote: Hi Caleb, the problem here is

Re: [PATCH] cmd: fdt: use U-Boot's FDT by default

2024-09-06 Thread Caleb Connolly
On 03/09/2024 20:14, Tom Rini wrote: On Sat, Aug 31, 2024 at 05:46:19PM +0100, Caleb Connolly wrote: When using the FDT command to inspect an arbitrary FDT in memory, it will always be necessary to explicitly set the FDT address. However it is also quite likely that the command is being used

Re: [PATCH 0/6] Miscellaneous FWU fixes

2024-09-06 Thread Sughosh Ganu
On Fri, 6 Sept 2024 at 12:05, Michal Simek wrote: > > > > On 9/5/24 11:17, Sughosh Ganu wrote: > > On Thu, 5 Sept 2024 at 14:07, Michal Simek wrote: > >> > >> > >> > >> On 9/5/24 10:12, Sughosh Ganu wrote: > >>> On Thu, 5 Sept 2024 at 13:20, Michal Simek wrote: > > > > On 9/5

Re: [PATCH v2 0/2] arm: zynqmp: Initialize some registers at boot

2024-09-06 Thread Michal Simek
On 9/5/24 19:18, Sean Anderson wrote: CAUTION: This message has originated from an External Source. Please use proper judgment and caution when opening attachments, clicking links, or responding to this email. These patches are independent in intent, but they modify adjacent lines so I hav

Re: [PATCH v2 14/28] efi_loader: Install ACPI tables

2024-09-06 Thread Ilias Apalodimas
Hi Patrick, On Fri, Sep 06, 2024 at 09:22:16AM +0200, Patrick Rudolph wrote: > Install ACPI tables inside the efi_loader similar to SMBIOS tables. > When ACPI is enabled and wasn't installed in other places, install > the ACPI table in EFI. Since EFI is necessary to pass the ACPI > table location

Re: [PATCH v2 14/28] efi_loader: Install ACPI tables

2024-09-06 Thread Ilias Apalodimas
Apologies for the noise +cc Heinrich On Fri, 6 Sept 2024 at 13:15, Ilias Apalodimas wrote: > > Hi Patrick, > > On Fri, Sep 06, 2024 at 09:22:16AM +0200, Patrick Rudolph wrote: > > Install ACPI tables inside the efi_loader similar to SMBIOS tables. > > When ACPI is enabled and wasn't installed in

Re: [PATCH v2 14/28] efi_loader: Install ACPI tables

2024-09-06 Thread Heinrich Schuchardt
On 9/6/24 09:22, Patrick Rudolph wrote: Install ACPI tables inside the efi_loader similar to SMBIOS tables. When ACPI is enabled and wasn't installed in other places, install the ACPI table in EFI. Since EFI is necessary to pass the ACPI table location when FDT isn't used, there's no need to inst

Re: [PATCH v9 20/37] net-lwip: add DHCP support and dhcp commmand

2024-09-06 Thread Jerome Forissier
On 9/4/24 18:09, Tom Rini wrote: > On Wed, Sep 04, 2024 at 09:54:15AM +0200, Jerome Forissier wrote: >> Hi Simon, >> >> On 8/29/24 16:05, Simon Glass wrote: >>> Hi Jerome, >>> >>> On Fri, 23 Aug 2024 at 07:49, Jerome Forissier >>> wrote: Add what it takes to enable NETDEVICES with NET

[PATCH v10 00/25] Introduce the lwIP network stack

2024-09-06 Thread Jerome Forissier
This is a rework of a patch series by Maxim Uvarov: "net/lwip: add lwip library for the network stack" [1]. The goal is to introduce the lwIP TCP/IP stack [2] [3] as an alternative to the current implementation in net/, selectable with Kconfig, and ultimately keep only lwIP if possible. Some reason

[PATCH v10 04/25] net: split include/net.h into net{, -common, -legacy, -lwip}.h

2024-09-06 Thread Jerome Forissier
Make net.h a wrapper which includes net-common.h and either net-legacy.h or net-lwip.h based on NET_LWIP. Signed-off-by: Jerome Forissier --- Makefile | 4 +- include/net-common.h | 485 ++ include/net-legacy.h | 560 + include/net-lwip.h

[PATCH v10 05/25] net: move copy_filename() to new file net/net-common.c

2024-09-06 Thread Jerome Forissier
copy_filename() can be useful when NET_LWIP is enabled, therefore move it out of net/net.c which is built only when networking choice is NET. Signed-off-by: Jerome Forissier --- net/Makefile | 2 ++ net/net-common.c | 13 + net/net.c| 12 3 files changed, 15

[PATCH v10 06/25] net: eth-uclass: add function eth_start_udev()

2024-09-06 Thread Jerome Forissier
Add a function to start a given network device, and update eth_init() to use it. Signed-off-by: Jerome Forissier --- include/net-common.h | 1 + net/eth-uclass.c | 38 +- 2 files changed, 26 insertions(+), 13 deletions(-) diff --git a/include/net-common.

[PATCH v10 07/25] net-lwip: build lwIP

2024-09-06 Thread Jerome Forissier
Build the lwIP library when NET_LWIP is enabled. The following files are adaptation layers written specially for U-Boot: lib/lwip/u-boot/arch/cc.h lib/lwip/u-boot/arch/sys_arch.h (empty) lib/lwip/u-boot/limits.h (empty) lib/lwip/u-boot/lwipopts.h They were initially contributed by Maxim in a

[PATCH v10 09/25] net-lwip: add TFTP support and tftpboot command

2024-09-06 Thread Jerome Forissier
Implement do_tftpb(). This implementation of the tftp command supports an optional port number. For example: tftp 192.168.0.30:9069:file.bin It also supports taking the server IP from ${tftpserverip} if defined, before falling back to ${serverip}. Signed-off-by: Jerome Forissier --- cmd/Kconf

[PATCH v10 10/25] net-lwip: add ping command

2024-09-06 Thread Jerome Forissier
Add support for the the ping command with NET_LWIP. The implementation is derived from lwIP's contrib/apps/ping/ping.c. Signed-off-by: Jerome Forissier --- cmd/Kconfig| 11 +-- cmd/net-lwip.c | 8 ++ include/net-lwip.h | 1 + net/lwip/Makefile | 1 + net/lwip/ping.c| 177

[PATCH v10 11/25] net-lwip: add dns command

2024-09-06 Thread Jerome Forissier
Add CMD_DNS when NET_LWIP is enabled to provide the dns command using lwIP. Signed-off-by: Jerome Forissier --- cmd/Kconfig| 11 ++-- cmd/net-lwip.c | 8 +++ include/net-lwip.h | 1 + net/lwip/Makefile | 1 + net/lwip/dns.c | 127 ++

[PATCH v10 12/25] net: split cmd/net.c into cmd/net.c and cmd/net-common.c

2024-09-06 Thread Jerome Forissier
Extract some code from cmd/net.c that will be useful in a subsequent commit to implement wget with NET_LWIP. Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas --- cmd/Makefile | 5 ++- cmd/net-common.c | 109 cmd/net.c| 115

[PATCH v10 13/25] net-lwip: add wget command

2024-09-06 Thread Jerome Forissier
Add support for the wget command with NET_LWIP. The command normally expects a URL: wget [loadaddr] url, but it also accepts the legacy syntax: wget [loadaddr] [server:]file. The server IP may alternatively be supplied via ${httpserverip} which has higher priority than ${serverip}. Based on code i

[PATCH v10 14/25] net-lwip: lwIP wget supports user defined port in the uri, so allow it.

2024-09-06 Thread Jerome Forissier
From: Jonathan Humphreys Signed-off-by: Jonathan Humphreys Signed-off-by: Jerome Forissier --- net/lwip/wget.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/net/lwip/wget.c b/net/lwip/wget.c index e8768fc2acd..b495ebd1aa9 100644 --- a/net/lwip/wget.c +++ b/net/lwip/wget.c @@ -349,12

[PATCH v10 15/25] cmd: bdinfo: enable -e when CONFIG_CMD_NET_LWIP=y

2024-09-06 Thread Jerome Forissier
Support "bdinfo -e" when lwIP is selected. Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas Reviewed-by: Tom Rini --- cmd/bdinfo.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cmd/bdinfo.c b/cmd/bdinfo.c index f6e534dd5bb..4c0e2adabc3 100644 --- a/cmd/b

[PATCH v10 16/25] configs: add qemu_arm64_lwip_defconfig

2024-09-06 Thread Jerome Forissier
Add qemu_arm64_lwip_defconfig which #include's qemu_arm64_defconfig and selects NET_LWIP instead of NET. This config has all the supported net commands enabled. Signed-off-by: Jerome Forissier --- configs/qemu_arm64_lwip_defconfig | 10 ++ 1 file changed, 10 insertions(+) create mode 10

[PATCH v10 17/25] lwip: tftp: add support of blksize option to client

2024-09-06 Thread Jerome Forissier
The TFTP protocol uses a default block size of 512 bytes. This value is sub-optimal for ethernet devices, which have a MTU (Maximum Transmission Unit) of 1500 bytes. When taking into acount the overhead of the IP and UDP layers, this leaves 1468 bytes for the TFTP payload. This patch introduces a

[PATCH v10 18/25] net-lwip: add TFTP_BLOCKSIZE

2024-09-06 Thread Jerome Forissier
Add support for setting the TFTP block size. The default value (1468) is fine for Ethernet and allows a better throughput than the TFTP default (512), if the server supports the blksize option of course. I tested this change with qemu_arm64_lwip_defconfig. The throughput is now 875 KiB/s vs. 313 K

[PATCH v10 19/25] CI: add qemu_arm64_lwip to the test matrix

2024-09-06 Thread Jerome Forissier
Build and run qemu_arm64_lwip_defconfig in CI. This tests the lightweight IP (lwIP) implementation of the dhcp, tftpboot and ping commands. Signed-off-by: Jerome Forissier --- .azure-pipelines.yml | 7 +++ 1 file changed, 7 insertions(+) diff --git a/.azure-pipelines.yml b/.azure-pipelines.

[PATCH v10 20/25] MAINTAINERS: net-lwip: add myself as a maintainer

2024-09-06 Thread Jerome Forissier
Add myself as a maintainer for the lwIP network stack integration code and network commands. The library code itself (i.e., most files under lib/lwip/ except README, Makefile and integration files in u-boot) is unmodified from upstream and therefore does not need a maintainer. Signed-off-by: Jerom

[PATCH v10 21/25] Kconfig: fix undefined symbols (g_dnl*) when NET_LWIP is default enabled

2024-09-06 Thread Jerome Forissier
Fix for link errors on am62px_evm_a53and other platforms when NET_LWIP is enabled: common/dfu.c:34:(.text.run_usb_dnl_gadget+0x68): undefined reference to `g_dnl_clear_detach [...] common/spl/spl_dfu.c:29:(.text.spl_dfu_cmd+0xb0): undefined reference to `run_usb_dnl_gadget' - DFU_OVER_USB co

[PATCH v10 22/25] configs: use syntax CONFIG_FOO=n in tools-only_defconfig

2024-09-06 Thread Jerome Forissier
The tools-only defconfig causes troubles on MacOSX due to the default C compiler being Clang (LLVM) rather than GCC and more specifically due to [1]. Therefore replace "# CONFIG_FOO is not set" with the equivalent "CONFIG_FOO=n" using the following command: $ sed -i -e 's/# \(CONFIG_[^ ]*\) is no

[PATCH v10 23/25] [TESTING] configs: set CONFIG_NET=y for FTGMAC100

2024-09-06 Thread Jerome Forissier
FTGMAC100 is not compatible with NET_LWIP which was enabled as the default stack in a previous commit. So enable NET in the defconfig. Signed-off-by: Jerome Forissier Reviewed-by: Chia-Wei Wang --- configs/evb-ast2500_defconfig | 1 + configs/evb-ast2600_defconfig | 1 + 2 files changed, 2 inse

[PATCH v10 25/25] [TESTING] Kconfig: enable NET_LWIP by default except for SANDBOX

2024-09-06 Thread Jerome Forissier
Enable NET_LWIP by default for testing purposes. SANDBOX doesn't support NET_LWIP so default to NET in this case. Signed-off-by: Jerome Forissier --- Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/Kconfig b/Kconfig index 35e34e16789..e3796e397a1 100644 --- a/Kconfig +++ b/Kconfig @@

Re: [PATCH v3 2/3] efi: Allow use of malloc() for the EFI pool

2024-09-06 Thread Simon Glass
Hi Sughosh, On Fri, 6 Sept 2024 at 00:23, Sughosh Ganu wrote: > > On Mon, 2 Sept 2024 at 03:53, Simon Glass wrote: > > > > This API call is intended for allocating small amounts of memory, > > similar to malloc(). The current implementation rounds up to whole pages > > which can waste large amou

Re: [PATCH v3 2/3] efi: Allow use of malloc() for the EFI pool

2024-09-06 Thread Simon Glass
Hi Ilias, On Fri, 6 Sept 2024 at 01:13, Ilias Apalodimas wrote: > > Hi Simon, > > Apologies for the late reply, I was attending a conference. > > On Mon, 2 Sept 2024 at 01:23, Simon Glass wrote: > > > > This API call is intended for allocating small amounts of memory, > > similar to malloc(). Th

[PATCH v10 02/25] net: introduce alternative implementation as net-lwip/

2024-09-06 Thread Jerome Forissier
Prepare the introduction of the lwIP (lightweight IP) TCP/IP stack by adding a new net/lwip/ directory and the NET_LWIP symbol. Network support is either NO_NET, NET (legacy stack) or NET_LWIP. Subsequent commits will introduce the lwIP code, re-work the NETDEVICE integration and port some of the N

[PATCH v10 01/25] Miscellaneous fixes

2024-09-06 Thread Jerome Forissier
Squashed commit of patches posted separately [1][2][3]. cmd: pxe: CMD_PXE implies CMD_TFTPBOOT common: update: UPDATE_COMMON implies CMD_TFTPBOOT test/py: test_efi_loader: add HTTP (wget) test for the EFI loader test/py: test_efi_loader: add missing dependency on cmd_tftpboot t

[PATCH v10 03/25] configs: replace '# CONFIG_NET is not set' with CONFIG_NO_NET=y

2024-09-06 Thread Jerome Forissier
The parent patch has made the networking stack a choice between NO_NET, NET and NET_LWIP. Therefore '# CONFIG_NET is not set' is now 'CONFIG_NO_NET=y'. Adjust the defconfigs accordingly. Note that this patch is intended to be folded in but is kept separate separate for now to make review easier. S

[PATCH v10 08/25] net-lwip: add DHCP support and dhcp commmand

2024-09-06 Thread Jerome Forissier
Add what it takes to enable NETDEVICES with NET_LWIP and enable DHCP as well as the dhcp command. CMD_TFTPBOOT is selected by BOOTMETH_EFI due to this code having an implicit dependency on do_tftpb(). Signed-off-by: Jerome Forissier --- board/engicam/imx8mp/icore_mx8mp.c| 2 +- ...

[PATCH v10 24/25] [TESTING] configs: set CONFIG_NET=y when PXE is enabled

2024-09-06 Thread Jerome Forissier
Many platforms won't build when NET_LWIP is the default choice in Kconfig: include/config_distro_bootcmd.h:443:9: error: expected '}' before 'BOOT_TARGET_DEVICES_references_PXE_without_CONFIG_CMD_DHCP_or_PXE' [...] Set the legacy stack (CONFIG_NET=y) for these platforms. Signed-off-by: Jerome

Re: [PATCH v6 07/28] hash: integrate hash on mbedtls

2024-09-06 Thread Raymond Mao
Hi Ilias, On Fri, 6 Sept 2024 at 03:36, Ilias Apalodimas wrote: > Hi Raymond, > > On Tue, 3 Sept 2024 at 18:54, Raymond Mao wrote: > > > > Hi Ilias, > > > > On Fri, 30 Aug 2024 at 05:37, Ilias Apalodimas < > ilias.apalodi...@linaro.org> wrote: > >> > >> Hi Simon, > >> > >> On Thu, 29 Aug 2024 a

Re: [PATCH v6 07/28] hash: integrate hash on mbedtls

2024-09-06 Thread Ilias Apalodimas
Hi Raymond, On Fri, 6 Sept 2024 at 17:00, Raymond Mao wrote: > > Hi Ilias, > > On Fri, 6 Sept 2024 at 03:36, Ilias Apalodimas > wrote: >> >> Hi Raymond, >> >> On Tue, 3 Sept 2024 at 18:54, Raymond Mao wrote: >> > >> > Hi Ilias, >> > >> > On Fri, 30 Aug 2024 at 05:37, Ilias Apalodimas >> > wr

RE: [PATCH 3/3] tpm_tcg2: hash algo optimization

2024-09-06 Thread Benjamin BARATTE
Hi Ilas, > -Original Message- > From: Ilias Apalodimas > Sent: Tuesday, August 27, 2024 10:05 AM > To: Benjamin BARATTE > Cc: u-boot@lists.denx.de; akashi.tk...@gmail.com; > abdellatif.elkhl...@arm.com; eaja...@linux.ibm.com; xypron.g...@gmx.de; > kojima.masah...@socionext.com; s...@chro

RE: [PATCH 1/3] tpm: update tpm hash algorithm according to tpm2.0 spec 1.59

2024-09-06 Thread Benjamin BARATTE
Hi Ilas, Could you comment my last mail on this topic ? Thanks, Benjamin > -Original Message- > From: Benjamin BARATTE > Sent: Friday, August 23, 2024 2:25 PM > To: 'Ilias Apalodimas' > Cc: u-boot@lists.denx.de; eaja...@linux.ibm.com; s...@chromium.org; > thar...@gateworks.com; tr...@k

Re: [PATCH v6 00/28] Integrate MbedTLS v3.6 LTS with U-Boot

2024-09-06 Thread Raymond Mao
Hi Simon, On Thu, 5 Sept 2024 at 20:43, Simon Glass wrote: > Hi Raymond, > > On Tue, 3 Sept 2024 at 08:59, Raymond Mao wrote: > > > > Hi Simon, > > > > On Sat, 17 Aug 2024 at 11:58, Simon Glass wrote: > >> > >> Hi Raymond, > >> > >> On Fri, 16 Aug 2024 at 15:44, Raymond Mao > wrote: > >> > >

Re: [PATCH] cmd: fdt: use U-Boot's FDT by default

2024-09-06 Thread Simon Glass
Hi Caleb, On Fri, 6 Sept 2024 at 03:31, Caleb Connolly wrote: > > > > On 03/09/2024 20:14, Tom Rini wrote: > > On Sat, Aug 31, 2024 at 05:46:19PM +0100, Caleb Connolly wrote: > > > >> When using the FDT command to inspect an arbitrary FDT in memory, it > >> will always be necessary to explicitly

Re: [PATCH v3 01/16] Makefile: detect HOST_ARCH properly when CROSS_COMPILE is multi-word

2024-09-06 Thread Simon Glass
Hi Jerome, On Tue, 3 Sept 2024 at 02:38, Jerome Forissier wrote: > > When CROSS_COMPILE contains multiple words, HOST_ARCH is not properly > detected and the sandbox build fail. It typically happens when using > ccache. For example: > > $ make sandbox_defconfig > $ make CROSS_COMPILE="ccache x8

Re: [PATCH 0/6] Miscellaneous FWU fixes

2024-09-06 Thread Michal Simek
On 9/6/24 11:47, Sughosh Ganu wrote: On Fri, 6 Sept 2024 at 12:05, Michal Simek wrote: On 9/5/24 11:17, Sughosh Ganu wrote: On Thu, 5 Sept 2024 at 14:07, Michal Simek wrote: On 9/5/24 10:12, Sughosh Ganu wrote: On Thu, 5 Sept 2024 at 13:20, Michal Simek wrote: On 9/5/24 09:43,

Re: [PATCH v3 01/16] Makefile: detect HOST_ARCH properly when CROSS_COMPILE is multi-word

2024-09-06 Thread Jerome Forissier
Hello Simon, On 9/6/24 17:02, Simon Glass wrote: > Hi Jerome, > > On Tue, 3 Sept 2024 at 02:38, Jerome Forissier > wrote: >> >> When CROSS_COMPILE contains multiple words, HOST_ARCH is not properly >> detected and the sandbox build fail. It typically happens when using >> ccache. For example: >>

Re: [PATCH v6 00/28] Integrate MbedTLS v3.6 LTS with U-Boot

2024-09-06 Thread Tom Rini
On Fri, Sep 06, 2024 at 10:50:15AM -0400, Raymond Mao wrote: > Hi Simon, > > On Thu, 5 Sept 2024 at 20:43, Simon Glass wrote: > > > Hi Raymond, > > > > On Tue, 3 Sept 2024 at 08:59, Raymond Mao wrote: > > > > > > Hi Simon, > > > > > > On Sat, 17 Aug 2024 at 11:58, Simon Glass wrote: > > >> > >

Re: [PATCH] cmd: fdt: use U-Boot's FDT by default

2024-09-06 Thread Tom Rini
On Fri, Sep 06, 2024 at 09:02:25AM -0600, Simon Glass wrote: > Hi Caleb, > > On Fri, 6 Sept 2024 at 03:31, Caleb Connolly > wrote: > > > > > > > > On 03/09/2024 20:14, Tom Rini wrote: > > > On Sat, Aug 31, 2024 at 05:46:19PM +0100, Caleb Connolly wrote: > > > > > >> When using the FDT command to

Re: [PATCH v2 16/28] drivers: usb: Add generic XHCI

2024-09-06 Thread Tom Rini
On Fri, Sep 06, 2024 at 09:22:18AM +0200, Patrick Rudolph wrote: > Add support for the generic XHCI driver that contains no SoC > specific code. It can be used on platforms that simply work out > of the box, like on emulated platforms. > > TEST: Booted on QEMU sbsa machine using the generic xhci

Re: [PATCH] power: regulator: tps6287x: Add driver for TPS6287x step down convertors

2024-09-06 Thread Tom Rini
On Fri, 31 May 2024 11:20:41 +0530, Keerthy wrote: > Add driver for TPS6287x step down convertors > > Data sheet: https://www.ti.com/lit/ds/slvsgc5a/slvsgc5a.pdf > > Applied to u-boot/next, thanks! -- Tom

Re: [PATCH] regulator: fixed: fix regulator-fixed-clock

2024-09-06 Thread Tom Rini
On Tue, 09 Jul 2024 10:24:54 +0100, John Keeping wrote: > For regulator-fixed-clock, the device's private data is never set so in > fixed_clock_regulator_set_enable() is null and the function cannot > complete successfully. > > Rename the _plat structure to _priv to better represent its role and

fit signing without access to private key

2024-09-06 Thread Mikael Pahmp
Hi. We want to sign fitImages but our company policies does not allow access to the private signing key from our build machines. Is there a way using e.g. mkimage to 1. Generate the hash of a fitImage configuration section? We will then request a signature for the hash from our enterprise PK

Re: [PATCH v9 20/37] net-lwip: add DHCP support and dhcp commmand

2024-09-06 Thread Tom Rini
On Fri, Sep 06, 2024 at 02:09:28PM +0200, Jerome Forissier wrote: > > > On 9/4/24 18:09, Tom Rini wrote: > > On Wed, Sep 04, 2024 at 09:54:15AM +0200, Jerome Forissier wrote: > >> Hi Simon, > >> > >> On 8/29/24 16:05, Simon Glass wrote: > >>> Hi Jerome, > >>> > >>> On Fri, 23 Aug 2024 at 07:49, J

Assistance Required: U-Boot Access Issues on Amlogic A113X SoC

2024-09-06 Thread Mike
Dear U-Boot Community, I am working on a project involving the Amlogic A113X SoC and have encountered an issue with U-Boot during the boot process over UART. While I am able to connect via UART and observe the boot log, the system does not allow any interaction or command input. It seems that the

[PATCH v6] mmc: Poll CD in case cyclic framework is enabled

2024-09-06 Thread Marek Vasut
In case the cyclic framework is enabled, poll the card detect of already initialized cards and deinitialize them in case they are removed. Since the card initialization is a longer process and card initialization is done on first access to an uninitialized card anyway, avoid initializing newly dete

[PATCH] cmd: osd: Depend on OSD

2024-09-06 Thread Marek Vasut
The OSD command calls functions from video_osd-uclass.o , which is built only when CONFIG_OSD is enabled. Add the missing dependency into Kconfig. Signed-off-by: Marek Vasut --- Cc: Simon Glass Cc: Tom Rini Cc: u-boot@lists.denx.de --- cmd/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --

Re: [PATCH v6 00/28] Integrate MbedTLS v3.6 LTS with U-Boot

2024-09-06 Thread Raymond Mao
Hi Tom, On Fri, 6 Sept 2024 at 11:27, Tom Rini wrote: > On Fri, Sep 06, 2024 at 10:50:15AM -0400, Raymond Mao wrote: > > Hi Simon, > > > > On Thu, 5 Sept 2024 at 20:43, Simon Glass wrote: > > > > > Hi Raymond, > > > > > > On Tue, 3 Sept 2024 at 08:59, Raymond Mao > wrote: > > > > > > > > Hi Si

Re: [PATCH v10 00/25] Introduce the lwIP network stack

2024-09-06 Thread Tom Rini
On Fri, Sep 06, 2024 at 02:33:16PM +0200, Jerome Forissier wrote: > This is a rework of a patch series by Maxim Uvarov: "net/lwip: add lwip > library for the network stack" [1]. The goal is to introduce the lwIP TCP/IP > stack [2] [3] as an alternative to the current implementation in net/, > sele

Re: [PATCH v2 1/2] kbuild: cherry-pick kbuild fdtoverlay changes from linux

2024-09-06 Thread Tom Rini
On Fri, Sep 06, 2024 at 12:38:07PM +0530, Prasad Kummari wrote: > Linux commits: > 15d16d6dadf6 kbuild: Add generic rule to apply fdtoverlay > 44f87191d105 kbuild: parameterize the .o part of suffix-search > > The Linux commit 15d16d6dadf6 adds a generic rule in Makefile.lib > to automatically ap

Re: [PATCH v4 2/9] phy: starfive: Add Starfive JH7110 USB 2.0 PHY driver

2024-09-06 Thread Marek Vasut
On 9/6/24 10:08 AM, Minda Chen wrote: On 8/29/24 3:30 AM, Minda Chen wrote: [...] +menu "Starfive PHY driver" + +config PHY_STARFIVE_JH7110_USB2 + bool "Starfive JH7110 USB 2.0 PHY driver" + select PHY Can this PHY_STARFIVE_JH7110_USB2 symbol be selected if CONFIG_PHY is not

Re: [PATCH v5] mmc: Poll CD in case cyclic framework is enabled

2024-09-06 Thread Marek Vasut
On 9/6/24 12:02 AM, Tom Rini wrote: On Sun, Jun 16, 2024 at 04:58:49PM +0200, Marek Vasut wrote: In case the cyclic framework is enabled, poll the card detect of already initialized cards and deinitialize them in case they are removed. Since the card initialization is a longer process and card

Re: [PATCH] video: Add parentheses around VNBYTES() macro

2024-09-06 Thread Tom Rini
On Mon, Sep 02, 2024 at 10:17:59AM +0200, Miquel Raynal wrote: > Hello, > > tr...@konsulko.com wrote on Tue, 19 Sep 2023 11:14:56 -0400: > > > On Mon, Sep 18, 2023 at 07:04:41PM -0600, Simon Glass wrote: > > > Hi Tom, Dan, > > > > > > On Tue, 8 Aug 2023 at 19:39, Tom Rini wrote: > > > > > > >

  1   2   >