]> git.proxmox.com Git - mirror_edk2.git/blame - UefiCpuPkg/SecCore/Ia32/ResetVec.nasmb
UefiCpuPkg/CpuDxe: Enable protection for newly added page table
[mirror_edk2.git] / UefiCpuPkg / SecCore / Ia32 / ResetVec.nasmb
CommitLineData
1921695e
MK
1;------------------------------------------------------------------------------\r
2;\r
3; Copyright (c) 2014, Intel Corporation. All rights reserved.<BR>\r
4; This program and the accompanying materials\r
5; are licensed and made available under the terms and conditions of the BSD License\r
6; which accompanies this distribution. The full text of the license may be found at\r
7; http://opensource.org/licenses/bsd-license.php.\r
8;\r
9; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
10; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
11;\r
12; Module Name:\r
13;\r
14; ResetVec.nasmb\r
15;\r
16; Abstract:\r
17;\r
18; Reset Vector Data structure\r
19; This structure is located at 0xFFFFFFC0\r
20;\r
21;------------------------------------------------------------------------------\r
22\r
23; .stack 0x0\r
24; SECTION .text\r
25USE16\r
26\r
27;\r
28; The layout of this file is fixed. The build tool makes assumption of the layout.\r
29;\r
30\r
31 ORG 0h\r
32;\r
33; Reserved\r
34;\r
35ReservedData: DD 0eeeeeeeeh, 0eeeeeeeeh\r
36\r
37 TIMES 0x10-($-$$) DB 0\r
38;\r
39; This is located at 0xFFFFFFD0h\r
40;\r
41 mov di, "PA"\r
42 jmp ApStartup\r
43\r
44 TIMES 0x20-($-$$) DB 0\r
45;\r
46; Pointer to the entry point of the PEI core\r
47; It is located at 0xFFFFFFE0, and is fixed up by some build tool\r
48; So if the value 8..1 appears in the final FD image, tool failure occurs.\r
49;\r
50PeiCoreEntryPoint: DD 87654321h\r
51\r
52;\r
53; This is the handler for all kinds of exceptions. Since it's for debugging\r
54; purpose only, nothing except a dead loop would be done here. Developers could\r
55; analyze the cause of the exception if a debugger had been attached.\r
56;\r
57global ASM_PFX(InterruptHandler)\r
58ASM_PFX(InterruptHandler):\r
59 jmp $\r
60 iret\r
61\r
62 TIMES 0x30-($-$$) DB 0\r
63;\r
64; For IA32, the reset vector must be at 0xFFFFFFF0, i.e., 4G-16 byte\r
65; Execution starts here upon power-on/platform-reset.\r
66;\r
67ResetHandler:\r
68 nop\r
69 nop\r
70ApStartup:\r
71 ;\r
72 ; Jmp Rel16 instruction\r
73 ; Use machine code directly in case of the assembler optimization\r
74 ; SEC entry point relative address will be fixed up by some build tool.\r
75 ;\r
76 ; Typically, SEC entry point is the function _ModuleEntryPoint() defined in\r
77 ; SecEntry.asm\r
78 ;\r
79 DB 0e9h\r
80 DW -3\r
81\r
82\r
83 TIMES 0x38-($-$$) DB 0\r
84;\r
85; Ap reset vector segment address is at 0xFFFFFFF8\r
86; This will be fixed up by some build tool,\r
87; so if the value 1..8 appears in the final FD image,\r
88; tool failure occurs\r
89;\r
90ApSegAddress: dd 12345678h\r
91\r
92 TIMES 0x3c-($-$$) DB 0\r
93;\r
94; BFV Base is at 0xFFFFFFFC\r
95; This will be fixed up by some build tool,\r
96; so if the value 1..8 appears in the final FD image,\r
97; tool failure occurs.\r
98;\r
99BfvBase: DD 12345678h\r
100\r
101;\r
102; Nothing can go here, otherwise the layout of this file would change.\r
103;\r