[U-Boot] [PATCH 3/6] arm: efi: Add a hello world test program

Leif Lindholm leif.lindholm at linaro.org
Mon Aug 15 14:23:29 CEST 2016


On Tue, Aug 09, 2016 at 10:55:31PM +0200, Alexander Graf wrote:
> 
> 
> > Am 09.08.2016 um 20:16 schrieb Simon Glass <sjg at chromium.org>:
> > 
> > Hi Bin,
> > 
> >> On 9 August 2016 at 00:50, Bin Meng <bmeng.cn at gmail.com> wrote:
> >> Hi Simon,
> >> 
> >>> On Sun, Aug 7, 2016 at 7:23 AM, Simon Glass <sjg at chromium.org> wrote:
> >>> It is useful to have a basic sanity check for EFI loader support. Add a
> >>> 'bootefi hello' command which loads HelloWord.efi and runs it under U-Boot.
> >>> 
> >>> Signed-off-by: Simon Glass <sjg at chromium.org>
> >>> ---
> >>> 
> >>> arch/arm/lib/HelloWorld32.efi  | Bin 0 -> 11712 bytes
> >>> arch/arm/lib/Makefile          |   6 ++++++
> >>> cmd/Kconfig                    |  10 ++++++++++
> >>> cmd/bootefi.c                  |  26 ++++++++++++++++++++------
> >>> include/asm-generic/sections.h |   2 ++
> >>> scripts/Makefile.lib           |  19 +++++++++++++++++++
> >>> 6 files changed, 57 insertions(+), 6 deletions(-)
> >>> create mode 100644 arch/arm/lib/HelloWorld32.efi
> >> 
> >> [snip]
> >> 
> >>> diff --git a/arch/arm/lib/Makefile b/arch/arm/lib/Makefile
> >>> index a8d1557..0f3ea0c 100644
> >>> --- a/arch/arm/lib/Makefile
> >>> +++ b/arch/arm/lib/Makefile
> >>> @@ -29,6 +29,12 @@ obj-$(CONFIG_OF_LIBFDT) += bootm-fdt.o
> >>> obj-$(CONFIG_CMD_BOOTM) += bootm.o
> >>> obj-$(CONFIG_CMD_BOOTM) += zimage.o
> >>> obj-$(CONFIG_SYS_L2_PL310) += cache-pl310.o
> >>> +ifdef CONFIG_ARM64
> >>> +# This option does not work for arm64, as there is no binary.
> >> 
> >> If so, can we just remove this for arm64?
> > 
> > Actually I was hoping that Alexander might have a suitable arm64
> > HelloWorld.efi lying around. When I tried building UEFI for arm64, for
> > some reason it did not create it.
> 
> Is it part of edk2? If so, Leif (CC'ed) might have one :). I usually
> use grub as my hello world application.

There is a hello world application in EDK2, but it does not get built
as part of a normal platform build.
Currently it also fails to build for ARM* on its own :|
See
http://patchew.org/EDK2/1471021908-3509-1-git-send-email-leif.lindholm%40linaro.org/
for a hack of how to build one before upstream is resolved.

If cross compiling, prepend GCC5_AARCH64_PREFIX=aarch64-linux-gnu- to
build command line.

/
    Leif


More information about the U-Boot mailing list