From 555e76f83f0ccf60434d3c72720f0a79f5ff4639 Mon Sep 17 00:00:00 2001 From: xli24 Date: Tue, 18 Nov 2008 07:01:14 +0000 Subject: [PATCH] Refine MdeModulePkg to pass GCC build. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6575 6f19259b-4bc3-4df7-8a09-765794883524 --- .../Universal/BdsDxe/BootMaint/BootMaint.c | 12 +++++--- .../Universal/BdsDxe/BootMaint/Data.c | 28 +++++++++---------- MdeModulePkg/Universal/BdsDxe/FrontPage.h | 2 +- MdeModulePkg/Universal/BdsDxe/String.c | 2 +- .../GraphicsConsoleDxe/GraphicsConsole.c | 2 +- .../Universal/DriverSampleDxe/NVDataStruc.h | 4 +-- .../Network/UefiPxeBcDxe/PxeBcImpl.c | 8 +++--- .../PlatOverMngr/PlatOverMngr.h | 2 +- 8 files changed, 32 insertions(+), 28 deletions(-) diff --git a/MdeModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c b/MdeModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c index 709720c200..48f750d444 100644 --- a/MdeModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c +++ b/MdeModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c @@ -18,10 +18,14 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include "FrontPage.h" EFI_DEVICE_PATH_PROTOCOL EndDevicePath[] = { - END_DEVICE_PATH_TYPE, - END_ENTIRE_DEVICE_PATH_SUBTYPE, - END_DEVICE_PATH_LENGTH, - 0 + { + END_DEVICE_PATH_TYPE, + END_ENTIRE_DEVICE_PATH_SUBTYPE, + { + END_DEVICE_PATH_LENGTH, + 0 + } + } }; diff --git a/MdeModulePkg/Universal/BdsDxe/BootMaint/Data.c b/MdeModulePkg/Universal/BdsDxe/BootMaint/Data.c index 00ef410229..5a22e77a9a 100644 --- a/MdeModulePkg/Universal/BdsDxe/BootMaint/Data.c +++ b/MdeModulePkg/Universal/BdsDxe/BootMaint/Data.c @@ -38,7 +38,7 @@ UINT16 TerminalType[] = { /// BM_MENU_OPTION FsOptionMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -47,7 +47,7 @@ BM_MENU_OPTION FsOptionMenu = { /// BM_MENU_OPTION ConsoleInpMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -56,7 +56,7 @@ BM_MENU_OPTION ConsoleInpMenu = { /// BM_MENU_OPTION ConsoleOutMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -65,7 +65,7 @@ BM_MENU_OPTION ConsoleOutMenu = { /// BM_MENU_OPTION ConsoleErrMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -74,7 +74,7 @@ BM_MENU_OPTION ConsoleErrMenu = { /// BM_MENU_OPTION BootOptionMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -83,7 +83,7 @@ BM_MENU_OPTION BootOptionMenu = { /// BM_MENU_OPTION DriverOptionMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -92,7 +92,7 @@ BM_MENU_OPTION DriverOptionMenu = { /// BM_MENU_OPTION LegacyFDMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -101,7 +101,7 @@ BM_MENU_OPTION LegacyFDMenu = { /// BM_MENU_OPTION LegacyHDMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -110,7 +110,7 @@ BM_MENU_OPTION LegacyHDMenu = { /// BM_MENU_OPTION LegacyCDMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -119,7 +119,7 @@ BM_MENU_OPTION LegacyCDMenu = { /// BM_MENU_OPTION LegacyNETMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -128,7 +128,7 @@ BM_MENU_OPTION LegacyNETMenu = { /// BM_MENU_OPTION LegacyBEVMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -137,7 +137,7 @@ BM_MENU_OPTION LegacyBEVMenu = { /// BM_MENU_OPTION DirectoryMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; @@ -146,13 +146,13 @@ BM_MENU_OPTION DirectoryMenu = { /// BM_MENU_OPTION DriverMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; BM_MENU_OPTION TerminalMenu = { BM_MENU_OPTION_SIGNATURE, - NULL, + {NULL}, 0 }; diff --git a/MdeModulePkg/Universal/BdsDxe/FrontPage.h b/MdeModulePkg/Universal/BdsDxe/FrontPage.h index f774351d4c..aaefbd565a 100644 --- a/MdeModulePkg/Universal/BdsDxe/FrontPage.h +++ b/MdeModulePkg/Universal/BdsDxe/FrontPage.h @@ -43,7 +43,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #define FRONT_PAGE_FORMSET_GUID \ { \ - 0x9e0c30bc, 0x3f06, 0x4ba6, 0x82, 0x88, 0x9, 0x17, 0x9b, 0x85, 0x5d, 0xbe \ + 0x9e0c30bc, 0x3f06, 0x4ba6, {0x82, 0x88, 0x9, 0x17, 0x9b, 0x85, 0x5d, 0xbe} \ } #define FRONT_PAGE_CALLBACK_DATA_SIGNATURE EFI_SIGNATURE_32 ('F', 'P', 'C', 'B') diff --git a/MdeModulePkg/Universal/BdsDxe/String.c b/MdeModulePkg/Universal/BdsDxe/String.c index b78b22f97e..d1c6651977 100644 --- a/MdeModulePkg/Universal/BdsDxe/String.c +++ b/MdeModulePkg/Universal/BdsDxe/String.c @@ -19,7 +19,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. EFI_HII_HANDLE gStringPackHandle; EFI_GUID mBdsStringPackGuid = { - 0x7bac95d3, 0xddf, 0x42f3, 0x9e, 0x24, 0x7c, 0x64, 0x49, 0x40, 0x37, 0x9a + 0x7bac95d3, 0xddf, 0x42f3, {0x9e, 0x24, 0x7c, 0x64, 0x49, 0x40, 0x37, 0x9a} }; /** diff --git a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c index 6a0aad5716..ada795b99c 100644 --- a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c +++ b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c @@ -132,7 +132,7 @@ EFI_HII_DATABASE_PROTOCOL *mHiiDatabase; EFI_HII_FONT_PROTOCOL *mHiiFont; BOOLEAN mFirstAccessFlag = TRUE; -EFI_GUID mFontPackageListGuid = {0xf5f219d3, 0x7006, 0x4648, 0xac, 0x8d, 0xd6, 0x1d, 0xfb, 0x7b, 0xc6, 0xad}; +EFI_GUID mFontPackageListGuid = {0xf5f219d3, 0x7006, 0x4648, {0xac, 0x8d, 0xd6, 0x1d, 0xfb, 0x7b, 0xc6, 0xad}}; CHAR16 mCrLfString[3] = { CHAR_CARRIAGE_RETURN, CHAR_LINEFEED, CHAR_NULL }; diff --git a/MdeModulePkg/Universal/DriverSampleDxe/NVDataStruc.h b/MdeModulePkg/Universal/DriverSampleDxe/NVDataStruc.h index 171d3baf08..453e474b67 100644 --- a/MdeModulePkg/Universal/DriverSampleDxe/NVDataStruc.h +++ b/MdeModulePkg/Universal/DriverSampleDxe/NVDataStruc.h @@ -27,12 +27,12 @@ Revision History: #define FORMSET_GUID \ { \ - 0xA04A27f4, 0xDF00, 0x4D42, 0xB5, 0x52, 0x39, 0x51, 0x13, 0x02, 0x11, 0x3D \ + 0xA04A27f4, 0xDF00, 0x4D42, {0xB5, 0x52, 0x39, 0x51, 0x13, 0x02, 0x11, 0x3D} \ } #define INVENTORY_GUID \ { \ - 0xb3f56470, 0x6141, 0x4621, 0x8f, 0x19, 0x70, 0x4e, 0x57, 0x7a, 0xa9, 0xe8 \ + 0xb3f56470, 0x6141, 0x4621, {0x8f, 0x19, 0x70, 0x4e, 0x57, 0x7a, 0xa9, 0xe8} \ } #define CONFIGURATION_VARSTORE_ID 0x1234 diff --git a/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c b/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c index 841ea09a01..40f7277a67 100644 --- a/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c +++ b/MdeModulePkg/Universal/Network/UefiPxeBcDxe/PxeBcImpl.c @@ -1909,13 +1909,13 @@ EfiPxeBcSetStationIP ( } if (NewStationIp != NULL) { - Mode->StationIp = *NewStationIp; - Private->StationIp = *NewStationIp; + CopyMem (&Mode->StationIp, NewStationIp, sizeof (EFI_IP_ADDRESS)); + CopyMem (&Private->StationIp, NewStationIp, sizeof (EFI_IP_ADDRESS)); } if (NewSubnetMask != NULL) { - Mode->SubnetMask = *NewSubnetMask; - Private->SubnetMask = *NewSubnetMask; + CopyMem (&Mode->SubnetMask, NewSubnetMask, sizeof (EFI_IP_ADDRESS)); + CopyMem (&Private->SubnetMask ,NewSubnetMask, sizeof (EFI_IP_ADDRESS)); } Private->AddressIsOk = TRUE; diff --git a/MdeModulePkg/Universal/PlatformDriverOverride/PlatOverMngr/PlatOverMngr.h b/MdeModulePkg/Universal/PlatformDriverOverride/PlatOverMngr/PlatOverMngr.h index 5ac780c8bf..f1f4e1c801 100644 --- a/MdeModulePkg/Universal/PlatformDriverOverride/PlatOverMngr/PlatOverMngr.h +++ b/MdeModulePkg/Universal/PlatformDriverOverride/PlatOverMngr/PlatOverMngr.h @@ -70,7 +70,7 @@ extern UINT8 PlatOverMngrStrings[]; // #define PLAT_OVER_MNGR_GUID \ { \ - 0x8614567d, 0x35be, 0x4415, 0x8d, 0x88, 0xbd, 0x7d, 0xc, 0x9c, 0x70, 0xc0 \ + 0x8614567d, 0x35be, 0x4415, {0x8d, 0x88, 0xbd, 0x7d, 0xc, 0x9c, 0x70, 0xc0} \ } typedef struct {