summaryrefslogtreecommitdiffstats
path: root/MdePkg/Include/AArch64
diff options
context:
space:
mode:
authorPete Batard <pete@akeo.ie>2018-02-23 17:50:00 +0800
committerLiming Gao <liming.gao@intel.com>2018-03-19 17:05:34 +0800
commit903365297913dacb2296a46e8c00c37aa3ca716a (patch)
tree5d28b174ccbf3771858f71bc0b9c93ff87178fe2 /MdePkg/Include/AArch64
parent909762d0785676613dc29d833c0fe0ebe73a4835 (diff)
downloadedk2-903365297913dacb2296a46e8c00c37aa3ca716a.tar.gz
edk2-903365297913dacb2296a46e8c00c37aa3ca716a.tar.bz2
edk2-903365297913dacb2296a46e8c00c37aa3ca716a.zip
MdePkg: Disable some Level 4 warnings for VS2017/ARM64
We disable the exact same warnings as IA32 and X64. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Pete Batard <pete@akeo.ie> Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'MdePkg/Include/AArch64')
-rw-r--r--MdePkg/Include/AArch64/ProcessorBind.h53
1 files changed, 51 insertions, 2 deletions
diff --git a/MdePkg/Include/AArch64/ProcessorBind.h b/MdePkg/Include/AArch64/ProcessorBind.h
index bc473562f9..968c18f915 100644
--- a/MdePkg/Include/AArch64/ProcessorBind.h
+++ b/MdePkg/Include/AArch64/ProcessorBind.h
@@ -1,7 +1,7 @@
/** @file
Processor or Compiler specific defines and types for AArch64.
- Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
Portions copyright (c) 2011 - 2013, ARM Ltd. All rights reserved.<BR>
@@ -30,7 +30,53 @@
#pragma pack()
#endif
-#if _MSC_EXTENSIONS
+#if defined(_MSC_EXTENSIONS)
+
+//
+// Disable some level 4 compilation warnings (same as IA32 and X64)
+//
+
+//
+// Disabling bitfield type checking warnings.
+//
+#pragma warning ( disable : 4214 )
+
+//
+// Disabling the unreferenced formal parameter warnings.
+//
+#pragma warning ( disable : 4100 )
+
+//
+// Disable slightly different base types warning as CHAR8 * can not be set
+// to a constant string.
+//
+#pragma warning ( disable : 4057 )
+
+//
+// ASSERT(FALSE) or while (TRUE) are legal constructs so suppress this warning
+//
+#pragma warning ( disable : 4127 )
+
+//
+// This warning is caused by functions defined but not used. For precompiled header only.
+//
+#pragma warning ( disable : 4505 )
+
+//
+// This warning is caused by empty (after preprocessing) source file. For precompiled header only.
+//
+#pragma warning ( disable : 4206 )
+
+//
+// Disable 'potentially uninitialized local variable X used' warnings
+//
+#pragma warning ( disable : 4701 )
+
+//
+// Disable 'potentially uninitialized local pointer variable X used' warnings
+//
+#pragma warning ( disable : 4703 )
+
//
// use Microsoft* C compiler dependent integer width types
//
@@ -45,7 +91,9 @@
typedef unsigned char UINT8;
typedef char CHAR8;
typedef signed char INT8;
+
#else
+
//
// Assume standard AARCH64 alignment.
//
@@ -60,6 +108,7 @@
typedef unsigned char UINT8;
typedef char CHAR8;
typedef signed char INT8;
+
#endif
///