Add macro SECTION_SIZE(SectionHeader) in MdePkg.
authoryshang1 <yshang1@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 4 Jul 2007 08:23:26 +0000 (08:23 +0000)
committeryshang1 <yshang1@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 4 Jul 2007 08:23:26 +0000 (08:23 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@3030 6f19259b-4bc3-4df7-8a09-765794883524

MdePkg/Include/Pi/PiFirmwareFile.h

index b84e982..3f2b8b1 100644 (file)
@@ -236,5 +236,10 @@ typedef struct {
   CHAR16                      VersionString[1];\r
 } EFI_VERSION_SECTION;\r
 \r
+\r
+#define SECTION_SIZE(SectionHeaderPtr) \\r
+    ((UINT32) (*((UINT32 *) ((EFI_COMMON_SECTION_HEADER *) SectionHeaderPtr)->Size) & 0x00ffffff))\r
+\r
+\r
 #endif\r
 \r