diff options
Diffstat (limited to 'src/vendorcode/amd/agesa/f15')
-rw-r--r-- | src/vendorcode/amd/agesa/f15/Porting.h | 35 |
1 files changed, 14 insertions, 21 deletions
diff --git a/src/vendorcode/amd/agesa/f15/Porting.h b/src/vendorcode/amd/agesa/f15/Porting.h index 776cddced7..fc65cfc613 100644 --- a/src/vendorcode/amd/agesa/f15/Porting.h +++ b/src/vendorcode/amd/agesa/f15/Porting.h @@ -9,11 +9,11 @@ * @xrefitem bom "File Content Label" "Release Content" * @e project: AGESA * @e sub-project: Includes - * @e \$Revision: 44324 $ @e \$Date: 2010-12-22 02:16:51 -0700 (Wed, 22 Dec 2010) $ + * @e \$Revision: 44324 $ @e \$Date: 2010-12-22 03:16:51 -0600 (Wed, 22 Dec 2010) $ */ /***************************************************************************** * - * Copyright (C) 2012 Advanced Micro Devices, Inc. + * Copyright (c) 2008 - 2012, Advanced Micro Devices, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -38,7 +38,6 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * ***************************************************************************/ #ifndef _PORTING_H_ @@ -50,7 +49,7 @@ void _enable (void); #pragma warning(disable: 4103 4001 4733) #pragma intrinsic (_disable, _enable) -#pragma warning(push) + #pragma warning(push) // ----------------------------------------------------------------------- // Define a code_seg MACRO // @@ -59,7 +58,7 @@ #define CODE_GROUP(arg) __pragma (code_seg (MAKE_AS_A_STRING (.t##arg))) #define RDATA_GROUP(arg) __pragma (const_seg (MAKE_AS_A_STRING (.d##arg))) - + #define FUNC_ATTRIBUTE(arg) __declspec(arg) //#include <intrin.h> // MS has built-in functions #if _MSC_VER < 900 @@ -215,7 +214,6 @@ // ----------------------------------------------------------------------- // End of MS compiler versions - #elif defined __GNUC__ #define IN @@ -224,6 +222,7 @@ #define VOLATILE volatile #define TRUE 1 #define FALSE 0 +// #undef CONST #define CONST const #define ROMDATA #define CALLCONV @@ -232,35 +231,32 @@ typedef unsigned char BOOLEAN; typedef signed char INT8; typedef signed short INT16; - typedef signed int INT32; + typedef signed long INT32; typedef char CHAR8; typedef unsigned char UINT8; typedef unsigned short UINT16; - typedef unsigned int UINT32; - typedef unsigned int UINTN; + typedef unsigned long UINT32; + typedef unsigned long UINTN; typedef unsigned long long UINT64; + typedef long long INT64; typedef void VOID; //typedef unsigned long size_t; -//typedef unsigned int uintptr_t; -// Force tight packing of structures -// Note: Entire AGESA (Project / Solution) will be using pragma pack 1 + + //#include <intrin.h> // MingW-w64 library header #pragma pack(1) - #define CODE_GROUP(arg) - #define RDATA_GROUP(arg) +#define CODE_GROUP(arg) +#define RDATA_GROUP(arg) #define FUNC_ATTRIBUTE(arg) __attribute__((arg)) #define MAKE_AS_A_STRING(arg) #arg - -// ----------------------------------------------------------------------- -// Common definitions for all compilers -// #include <stddef.h> #include "gcc-intrin.h" #include <assert.h> #include <console/console.h> #include <console/loglevel.h> + #ifndef NULL #define NULL (void *)0 #endif @@ -272,8 +268,6 @@ #error "Unknown compiler in use" #endif - - // ----------------------------------------------------------------------- // Common definitions for all compilers // @@ -281,7 +275,6 @@ //Support forward reference construct #define AGESA_FORWARD_DECLARATION(x) typedef struct _##x x - // The following are use in conformance to the UEFI style guide #define IN #define OUT |