[PATCH 10/15] efi: payload: x86: enable the possibility to efi stub bootm for x86.

2025-09-19 Thread Chali Anis
this permits to select one of efi stub bootm or efi handover protocol tested on dell latitude and qemu. Signed-off-by: Chali Anis --- efi/payload/Kconfig | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/efi/payload/Kconfig b/efi/payload/Kconfig index 8f76b00744e7453ddde4a

[PATCH 13/15] efi: payload: earlymem: allocate only the barebox needs in term of memory.

2025-09-19 Thread Chali Anis
Since an EFI malloc callback is available to provide additional memory on demand, limit early allocations to what barebox strictly requires. This ensures more deterministic behavior and reduces the risk of OOM conditions. Signed-off-by: Chali Anis --- efi/payload/early-mem.c| 18

[PATCH 11/15] malloc: tlsf: efi: add a fallback for allocate more memory when we are in efi.

2025-09-19 Thread Chali Anis
this will fix the OOM issues for when barebox is running on top of efi. the OOM were unpredictble since we can't determine the size required in advance for initrd or kernel. with this patch we don't need anymore to increase memory in efi early mem, we allocate only what barebox needs to relocate it

[PATCH 02/15] efi: payload: add support for efi stub boot

2025-09-19 Thread chalianis1
From: Ahmad Fatoum This patch has more stock, between implementing EFI STUB boot, refactor to reuse the code and finaly support the fit image format. This code is tested on many qemu EFI compilations comming from ovmf ubuntu package, tianocore efi for qemu, local edk2 build, and also tested on RP

[PATCH 00/15] Implement efi loader to run barebox as efi payload app and then load efi stubed application/kernels.

2025-09-19 Thread chalianis1
+ include/efi/efi-payload.h | 5 +- include/filetype.h| 6 + include/malloc.h | 19 ++ 25 files changed, 1352 insertions(+), 246 deletions(-) --- base-commit: 3366e9e04a284b7fed71c4b8729fe331b6547d6b change-id: 20250919-efi-loader-cdff44ad2d40 Best regards

[PATCH 15/15] efi: payload: bootm: remove redundant reallocations in image loader

2025-09-19 Thread Chali Anis
The EFI payload loader used to copy OS images, initrds and FDTs into freshly allocated EFI pages before handing them to LoadImage() or installing configuration tables. This resulted in unnecessary memory moves, extra allocations and longer boot times. Rework the loader to: - pass buffers from re

[PATCH 09/15] efi: payload: bootm: add x86 efi stub boot support.

2025-09-19 Thread Chali Anis
implement the efi stub boot on x86, this code is tested on qemu, and dell latitude 7490. the EFI_ALLOCATE_MAX_PAGES cause an xfuncs issue on real hardware so I transformed it to allocate any pages. Signed-off-by: Chali Anis --- efi/payload/bootm.c | 139 ++

[PATCH 07/15] common: filetype: add x86 linux filetype.

2025-09-19 Thread Chali Anis
add x86 linux filetype to be used to boot with efi stub bootm image handler. Signed-off-by: Chali Anis --- common/filetype.c | 4 include/filetype.h | 6 ++ 2 files changed, 10 insertions(+) diff --git a/common/filetype.c b/common/filetype.c index eb397a175cb63df06e4426d2b99e4fde360c

[PATCH 14/15] ARM: cpu: allow selecting CPU_V7/CPU_V8 directly

2025-09-19 Thread chalianis1
From: Ahmad Fatoum We currently lack a way to build a barebox EFI payload on ARM without enabling some other subarchitecture. As CONFIG_EFI_PAYLOAD has a global effect and adds EFI stubs to all enabled board, an EFI subarchitecture doesn't fit into our current model. Instead, let's make it possi

[PATCH 05/15] arm: efi: add a generic defconfig for v8 efi payload,

2025-09-19 Thread Chali Anis
Signed-off-by: Chali Anis --- arch/arm/configs/efi_v8_defconfig | 266 ++ 1 file changed, 266 insertions(+) diff --git a/arch/arm/configs/efi_v8_defconfig b/arch/arm/configs/efi_v8_defconfig new file mode 100644 index

[PATCH 01/15] efi: payload: split image handling from legacy handover boot support

2025-09-19 Thread chalianis1
From: Ahmad Fatoum Signed-off-by: Ahmad Fatoum Signed-off-by: Chali Anis --- efi/Kconfig| 4 + efi/payload/Kconfig| 4 + efi/payload/Makefile | 2 + efi/payload/handover.c | 195 ++ efi/payload/image.c| 228 ++-

[PATCH 06/15] efi: payload: initrd: implement efi initrd media protocol.

2025-09-19 Thread Chali Anis
Add the ability to install an initrd media protocol from an initrd file or a fitImage, support both the initrd media protocol or installing the initramfs directly to efi like what linux do. Signed-off-by: Chali Anis --- efi/guid.c| 7 +++ efi/payload/efi-initrd.c | 123 +++

[PATCH 04/15] efi: payload: make selectable without COMPILE_TEST

2025-09-19 Thread chalianis1
From: Ahmad Fatoum Signed-off-by: Ahmad Fatoum Signed-off-by: Chali Anis --- efi/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/efi/Kconfig b/efi/Kconfig index 5f4c6713d539abc88e3244f7ff3933274a8c4ebb..5ae7ec92e5f8d12f72842c5c97bc9ed924b6dff9 100644 --- a/efi/Kco

[PATCH 08/15] efi: payload: early-mem: helps to correctly boot x86 linux.

2025-09-19 Thread Chali Anis
remove the allocate EFI_ALLOCATE_MAX_ADDRESSES and use a different memsize for x86 since the initrd could be bigger that those used in arm. it might be refactored in the future with a more generic allocation strategy (i.e barebox malloc memory vs an allocator for the boot loader data) something lik

[PATCH 03/15] efi: payload: add support for fit image

2025-09-19 Thread chalianis1
From: Ahmad Fatoum This patch has more stock, between implementing EFI STUB boot, refactor to reuse the code and finaly support the fit image format. This code is tested on many qemu EFI compilations comming from ovmf ubuntu package, tianocore efi for qemu, local edk2 build, and also tested on RP

Re: [PATCH] drivers: dma: refactor: rename dma_ops to dma_device_ops.

2025-09-19 Thread Sascha Hauer
On Mon, Sep 15, 2025 at 11:02:12AM +0200, Ahmad Fatoum wrote: > Hi, > > On 9/14/25 9:32 PM, chalian...@gmail.com wrote: > > From: Chali Anis > > > > This patch is an esthetic cleanup, rename the dma_ops to dma_device_ops > > to be sure that the struct in drivers/dma is different from one used in

[PATCH] ARM: am62l: fix mdio clock id

2025-09-19 Thread Sascha Hauer
Based on this commit found in the TI downstream repository: | commit 20778f6c125dc24e62767dc4837d793a0f18c319 | Author: Siddharth Vadapalli | Date: Wed Jun 4 15:41:53 2025 +0530 | |PENDING: arm64: dts: ti: k3-am62l-main: Fix MDIO clock | |Based on the Clock ID documentation for AM62L [0