cmd: bootelf: executing ELF files requires variable autostart
Johannes Krottmayer
krotti83 at proton.me
Sun Jun 14 16:32:36 CEST 2026
Hello U-Boot list members!
I have a question about the 'bootelf' command. Use U-Boot
as loader for my bare-metal projects, but noticed maybe an
issue when trying to execute an ELF binary.
I'm not really sure whether this is intentional or this is
an issue. Wasted a lot of time for trying to run a simple
'Hello World" program on RISC-V (both QEMU and real
hardware). Then I looked into the source code from
the command and noticed that currently the environment
variable 'autostart' must be set, if not the command
simple returns without any error or warning message:
Source: lib/elf.c:bootelf():
---
if (!flags.autostart)
return 0;
---
Please can somebody clarify why 'autostart' must
be set to successful use the command 'bootelf'?
Thanks in advance!
--
Kind regards,
Johannes K.
More information about the U-Boot
mailing list