]> git.proxmox.com Git - mirror_edk2.git/blobdiff - UefiCpuPkg/ResetVector/Vtf0/Vtf0.nasmb
UefiCpuPkg: Support building VTF0 ResetVector during the EDK II build
[mirror_edk2.git] / UefiCpuPkg / ResetVector / Vtf0 / Vtf0.nasmb
diff --git a/UefiCpuPkg/ResetVector/Vtf0/Vtf0.nasmb b/UefiCpuPkg/ResetVector/Vtf0/Vtf0.nasmb
new file mode 100644 (file)
index 0000000..31ac06a
--- /dev/null
@@ -0,0 +1,66 @@
+;------------------------------------------------------------------------------\r
+; @file\r
+; This file includes all other code files to assemble the reset vector code\r
+;\r
+; Copyright (c) 2008 - 2013, Intel Corporation. All rights reserved.<BR>\r
+; This program and the accompanying materials\r
+; are licensed and made available under the terms and conditions of the BSD License\r
+; which accompanies this distribution.  The full text of the license may be found at\r
+; http://opensource.org/licenses/bsd-license.php\r
+;\r
+; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+;\r
+;------------------------------------------------------------------------------\r
+\r
+;\r
+; If neither ARCH_IA32 nor ARCH_X64 are defined, then try to include\r
+; Base.h to use the C pre-processor to determine the architecture.\r
+;\r
+%ifndef ARCH_IA32\r
+  %ifndef ARCH_X64\r
+    #include <Base.h>\r
+    #if defined (MDE_CPU_IA32)\r
+      %define ARCH_IA32\r
+    #elif defined (MDE_CPU_X64)\r
+      %define ARCH_X64\r
+    #endif\r
+  %endif\r
+%endif\r
+\r
+%ifdef ARCH_IA32\r
+  %ifdef ARCH_X64\r
+    %error "Only one of ARCH_IA32 or ARCH_X64 can be defined."\r
+  %endif\r
+%elifdef ARCH_X64\r
+%else\r
+  %error "Either ARCH_IA32 or ARCH_X64 must be defined."\r
+%endif\r
+\r
+%include "CommonMacros.inc"\r
+\r
+%include "PostCodes.inc"\r
+\r
+%ifdef DEBUG_PORT80\r
+  %include "Port80Debug.asm"\r
+%elifdef DEBUG_SERIAL\r
+  %include "SerialDebug.asm"\r
+%else\r
+  %include "DebugDisabled.asm"\r
+%endif\r
+\r
+%include "Ia32/SearchForBfvBase.asm"\r
+%include "Ia32/SearchForSecEntry.asm"\r
+\r
+%ifdef ARCH_X64\r
+%include "Ia32/Flat32ToFlat64.asm"\r
+%include "Ia32/PageTables64.asm"\r
+%endif\r
+\r
+%include "Ia16/Real16ToFlat32.asm"\r
+%include "Ia16/Init16.asm"\r
+\r
+%include "Main.asm"\r
+\r
+%include "Ia16/ResetVectorVtf0.asm"\r
+\r