From 1ee162281710650d444c554f9fdbbd404abd9677 Mon Sep 17 00:00:00 2001 From: Jose Marinho Date: Fri, 29 Oct 2021 17:48:26 +0100 Subject: Basetools/GenFw: Allow AARCH64 builds to use the --prm flag The GenFw invocation with the --prm flag was previously reserved for X64. AArch64 platforms, built with GCC5, can also deploy PRM modules, hence the --prm flag is also applicable in builds targeting the AARCH64 architecture. This commit enables the --prm flag to be used for EDK2 builds targeting AARCH64. Signed-off-by: Jose Marinho Signed-off-by: Sami Mujawar Reviewed-by: Michael Kubacki Reviewed-by: Ard Biesheuvel --- BaseTools/Source/C/GenFw/Elf64Convert.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'BaseTools') diff --git a/BaseTools/Source/C/GenFw/Elf64Convert.c b/BaseTools/Source/C/GenFw/Elf64Convert.c index 2aa9bfc..35e96dd 100644 --- a/BaseTools/Source/C/GenFw/Elf64Convert.c +++ b/BaseTools/Source/C/GenFw/Elf64Convert.c @@ -2,7 +2,7 @@ Elf64 convert solution Copyright (c) 2010 - 2021, Intel Corporation. All rights reserved.
-Portions copyright (c) 2013-2014, ARM Ltd. All rights reserved.
+Portions copyright (c) 2013-2022, ARM Ltd. All rights reserved.
Portions Copyright (c) 2020, Hewlett Packard Enterprise Development LP. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent @@ -186,8 +186,8 @@ InitializeElf64 ( } if (mExportFlag) { - if (mEhdr->e_machine != EM_X86_64) { - Error (NULL, 0, 3000, "Unsupported", "--prm option currently only supports X64 arch."); + if ((mEhdr->e_machine != EM_X86_64) && (mEhdr->e_machine != EM_AARCH64)) { + Error (NULL, 0, 3000, "Unsupported", "--prm option currently only supports X64 and AArch64 archs."); return FALSE; } } -- cgit v1.1