From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.groups.io with SMTP id smtpd.web11.4130.1681459384878906506 for ; Fri, 14 Apr 2023 01:03:05 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=N2lmmNmG; spf=pass (domain: redhat.com, ip: 170.10.129.124, mailfrom: kraxel@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1681459384; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=59L1YEjnM1DgOX/IJCHaDPjf9/B9bJyLWJasJiGuxk0=; b=N2lmmNmGqqWqyUNN8O7U/1DTR8qJtBdeUXYZxPyzV7vnSwi5qVIOQXbSyt2PXoxN60jni0 iR9toAMm1WMYFwAWoPyRHHb61M/mPKx4iwlIBIQI9cbIBPfG5mNAqqy3Bmb45h7Esmo8Xg RV+mo9HR8gjrSl+vlikObflXh0pzb1Q= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-665-qQ-VpR6TOkugqEs3c2szMw-1; Fri, 14 Apr 2023 04:03:03 -0400 X-MC-Unique: qQ-VpR6TOkugqEs3c2szMw-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 4E402185A78F; Fri, 14 Apr 2023 08:03:02 +0000 (UTC) Received: from sirius.home.kraxel.org (unknown [10.39.192.81]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 12E26C16028; Fri, 14 Apr 2023 08:03:02 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id B726A18003A8; Fri, 14 Apr 2023 10:02:50 +0200 (CEST) From: "Gerd Hoffmann" To: devel@edk2.groups.io Cc: Pawel Polawski , Dongyan Qian , Sunil V L , Baoqi Zhang , Chao Li , Rebecca Cran , Ard Biesheuvel , Zhiguang Liu , Liming Gao , Yuwei Chen , =?UTF-8?q?Marvin=20H=C3=A4user?= , Leif Lindholm , Michael D Kinney , Daniel Schaefer , Bob Feng , Oliver Steffen , Gerd Hoffmann Subject: [PATCH v4 06/10] MdePkg/PeImage.h: add bits from BaseTools version Date: Fri, 14 Apr 2023 10:02:46 +0200 Message-Id: <20230414080250.1357004-7-kraxel@redhat.com> In-Reply-To: <20230414080250.1357004-1-kraxel@redhat.com> References: <20230414080250.1357004-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.8 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true The BaseTools and MdePkg versions of PeImage.h diverged over time, add some missing bits to the MdePkg header file in preparation for removing the BaseTools version. Signed-off-by: Gerd Hoffmann --- MdePkg/Include/IndustryStandard/PeImage.h | 31 +++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/MdePkg/Include/IndustryStandard/PeImage.h b/MdePkg/Include/IndustryStandard/PeImage.h index 8646ff22b55f..47037049348c 100644 --- a/MdePkg/Include/IndustryStandard/PeImage.h +++ b/MdePkg/Include/IndustryStandard/PeImage.h @@ -101,6 +101,7 @@ typedef struct { #define EFI_IMAGE_FILE_EXECUTABLE_IMAGE BIT1 ///< 0x0002 File is executable (i.e. no unresolved externel references). #define EFI_IMAGE_FILE_LINE_NUMS_STRIPPED BIT2 ///< 0x0004 Line numbers stripped from file. #define EFI_IMAGE_FILE_LOCAL_SYMS_STRIPPED BIT3 ///< 0x0008 Local symbols stripped from file. +#define EFI_IMAGE_FILE_LARGE_ADDRESS_AWARE BIT5 ///< 0x0020 Supports addresses > 2-GB #define EFI_IMAGE_FILE_BYTES_REVERSED_LO BIT7 ///< 0x0080 Bytes of machine word are reversed. #define EFI_IMAGE_FILE_32BIT_MACHINE BIT8 ///< 0x0100 32 bit word machine. #define EFI_IMAGE_FILE_DEBUG_STRIPPED BIT9 ///< 0x0200 Debugging info stripped from file in .DBG file. @@ -577,6 +578,13 @@ typedef struct { UINT32 AddressOfNameOrdinals; } EFI_IMAGE_EXPORT_DIRECTORY; +// +// Based export types. +// +#define EFI_IMAGE_EXPORT_ORDINAL_BASE 1 +#define EFI_IMAGE_EXPORT_ADDR_SIZE 4 +#define EFI_IMAGE_EXPORT_ORDINAL_SIZE 2 + /// /// Hint/Name Table. /// @@ -670,6 +678,29 @@ typedef struct { // } EFI_IMAGE_DEBUG_CODEVIEW_MTOC_ENTRY; +// avoid conflict with windows header files +#ifndef RUNTIME_FUNCTION_INDIRECT + +// +// .pdata entries for X64 +// +typedef struct { + UINT32 FunctionStartAddress; + UINT32 FunctionEndAddress; + UINT32 UnwindInfoAddress; +} RUNTIME_FUNCTION; + +#endif + +typedef struct { + UINT8 Version : 3; + UINT8 Flags : 5; + UINT8 SizeOfProlog; + UINT8 CountOfUnwindCodes; + UINT8 FrameRegister : 4; + UINT8 FrameRegisterOffset : 4; +} UNWIND_INFO; + /// /// Extended DLL Characteristics /// -- 2.39.2