From f2d60f6257cf1d4999f4e77a467087dff2c30874 Mon Sep 17 00:00:00 2001 From: Heinrich Schuchardt Date: Thu, 1 Dec 2022 19:07:57 +0100 Subject: efi_loader: add an EFI binary to print boot hart ID Provide an EFI binary that prints the boot hart ID as found in the device-tree as /chosen/boot-hartid property and as provided by the RISCV_EFI_BOOT_PROTOCOL. Signed-off-by: Heinrich Schuchardt --- lib/efi_loader/Makefile | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'lib/efi_loader/Makefile') diff --git a/lib/efi_loader/Makefile b/lib/efi_loader/Makefile index 8738757dd2c..13a35eae6c0 100644 --- a/lib/efi_loader/Makefile +++ b/lib/efi_loader/Makefile @@ -12,6 +12,8 @@ ccflags-y += -DHOST_ARCH="$(HOST_ARCH)" CFLAGS_efi_boottime.o += \ -DFW_VERSION="0x$(VERSION)" \ -DFW_PATCHLEVEL="0x$(PATCHLEVEL)" +CFLAGS_boothart.o := $(CFLAGS_EFI) -Os -ffreestanding +CFLAGS_REMOVE_boothart.o := $(CFLAGS_NON_EFI) CFLAGS_helloworld.o := $(CFLAGS_EFI) -Os -ffreestanding CFLAGS_REMOVE_helloworld.o := $(CFLAGS_NON_EFI) CFLAGS_dtbdump.o := $(CFLAGS_EFI) -Os -ffreestanding @@ -19,6 +21,10 @@ CFLAGS_REMOVE_dtbdump.o := $(CFLAGS_NON_EFI) CFLAGS_initrddump.o := $(CFLAGS_EFI) -Os -ffreestanding CFLAGS_REMOVE_initrddump.o := $(CFLAGS_NON_EFI) +ifdef CONFIG_RISCV +always += boothart.efi +endif + ifneq ($(CONFIG_CMD_BOOTEFI_HELLO_COMPILE),) always += helloworld.efi targets += helloworld.o -- cgit v1.3.1