]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fix build breaks from comment clean up checkin
authormdkinney <mdkinney@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 4 Jun 2009 18:57:44 +0000 (18:57 +0000)
committermdkinney <mdkinney@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 4 Jun 2009 18:57:44 +0000 (18:57 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8468 6f19259b-4bc3-4df7-8a09-765794883524

MdePkg/Include/Base.h
MdePkg/Include/Ia32/ProcessorBind.h
MdePkg/Include/Ipf/ProcessorBind.h
MdePkg/Include/Library/DxeServicesLib.h
MdePkg/Include/Library/UefiUsbLib.h
MdePkg/Include/X64/ProcessorBind.h

index 287c193a3ea03710514d36fe6e05d542ad27dcc3..4eedffde0b8ed1bb150530c7b758fbd92072fc93 100644 (file)
@@ -333,6 +333,15 @@ struct _LIST_ENTRY {
 //  }\r
 //\r
 \r
+/**\r
+  Return the size of argument that has been aligned to sizeof (UINTN).\r
+\r
+  @param  n    The parameter size is to be aligned.\r
+\r
+  @return The aligned size\r
+**/\r
+#define _INT_SIZE_OF(n) ((sizeof (n) + sizeof (UINTN) - 1) &~(sizeof (UINTN) - 1))\r
+\r
 #if defined(__GNUC__)\r
 //\r
 // Use GCC built-in macros for variable argument lists.\r
@@ -346,15 +355,6 @@ typedef __builtin_va_list VA_LIST;
 #define VA_END(Marker)               __builtin_va_end (Marker)\r
 \r
 #else\r
-/**\r
-  Return the size of argument that has been aligned to sizeof (UINTN).\r
-\r
-  @param  n    The parameter size to be aligned.\r
-\r
-  @return The aligned size\r
-**/\r
-#define _INT_SIZE_OF(n) ((sizeof (n) + sizeof (UINTN) - 1) &~(sizeof (UINTN) - 1))\r
-\r
 ///\r
 /// Pointer to the start of a variable argument list. Same as CHAR8 *.\r
 ///\r
@@ -409,6 +409,29 @@ typedef CHAR8 *VA_LIST;
 \r
 #endif\r
 \r
+///\r
+/// Pointer to the start of a variable argument list stored in a memory buffer. Same as UINT8 *.\r
+///\r
+typedef UINTN  *BASE_LIST;\r
+\r
+/**\r
+  Returns an argument of a specified type from a variable argument list and updates \r
+  the pointer to the variable argument list to point to the next argument. \r
+\r
+  This function returns an argument of the type specified by TYPE from the beginning \r
+  of the variable argument list specified by Marker.  Marker is then updated to point \r
+  to the next argument in the variable argument list.  The method for computing the \r
+  pointer to the next argument in the argument list is CPU specific following the EFIAPI ABI.\r
+\r
+  @param   Marker   Pointer to the beginning of a variable argument list.\r
+  @param   TYPE     The type of argument to retrieve from the beginning \r
+                    of the variable argument list.\r
+  \r
+  @return  An argument of the type specified by TYPE.\r
+\r
+**/\r
+#define BASE_ARG(Marker, TYPE) (*(TYPE *)((UINT8 *)(Marker = (BASE_LIST)((UINT8 *)Marker + _INT_SIZE_OF (TYPE))) - _INT_SIZE_OF (TYPE)))\r
+\r
 /**\r
   Macro that returns the byte offset of a field in a data structure. \r
 \r
index edf881b7ee5f13be57cc88583fdd9bf1c67406fb..4f24c67077d9254923834ee1457e572e0e0301bc 100644 (file)
@@ -341,6 +341,11 @@ typedef INT32   INTN;
   #else\r
     #define ASM_PFX(name) _##name\r
   #endif \r
+  ///\r
+  /// For GNU assembly code, .global or .globl can declare global symbols.\r
+  /// Define this macro to unify the usage.\r
+  ///\r
+  #define ASM_GLOBAL .globl\r
 #endif\r
 \r
 /**\r
index b8fca5e0142e9db63a8b856c3a765bbf04c55897..c58588214f6a3c59ecf8ac015b55f88b38eecc9e 100644 (file)
@@ -392,6 +392,12 @@ typedef INT64   INTN;
   #define GLOBAL_REMOVE_IF_UNREFERENCED\r
 #endif\r
 \r
+///\r
+/// For GNU assembly code, .global or .globl can declare global symbols.\r
+/// Define this macro to unify the usage.\r
+///\r
+#define ASM_GLOBAL .globl\r
+\r
 ///\r
 /// A pointer to a function in IPF points to a plabel.\r
 ///\r
index 23a8bed3f26c145993803f46bc358140edb0de83..898793398f07766401d6e2d391021ded5417f5ef 100644 (file)
 \r
 **/\r
 \r
-#ifndef __PI_LIB_H__\r
-#define __PI_LIB_H__\r
-\r
-#include <Pi/PiFirmwareFile.h>\r
-\r
+#ifndef __DXE_SERVICES_LIB_H__\r
+#define __DXE_SERVICES_LIB_H__\r
 \r
 /**\r
   Searches all the available firmware volumes and returns the first matching FFS section. \r
index 9d15579053f9e8f5ad53274ececd4c06bad8b476..455cb7b06e478f6c0d2bd42dafb935e4a5a12783 100644 (file)
@@ -18,7 +18,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #define __USB_DXE_LIB_H__\r
 \r
 #include <Protocol/UsbIo.h>\r
-#include <IndustryStandard/Usb.h>\r
 \r
 /**\r
   Get the descriptor of the specified USB HID interface.\r
index 5ebc58d8c2fa27048ffcf1202a9312daef55e59e..363a2dca350da4da803d33ded7a832c268395278 100644 (file)
@@ -404,7 +404,12 @@ typedef INT64   INTN;
     #define ASM_PFX(name) name\r
   #else\r
     #define ASM_PFX(name) _##name\r
-  #endif  \r
+  #endif\r
+  ///\r
+  /// For GNU assembly code, .global or .globl can declare global symbols.\r
+  /// Define this macro to unify the usage.\r
+  ///\r
+  #define ASM_GLOBAL .globl\r
 #endif\r
 \r
 /**\r