]> git.proxmox.com Git - mirror_edk2.git/blame - ArmPlatformPkg/PrePeiCore/Arm/Exception.S
BaseTools/Capsule: Do not support -o with --dump-info
[mirror_edk2.git] / ArmPlatformPkg / PrePeiCore / Arm / Exception.S
CommitLineData
a6caee65 1//\r
2// Copyright (c) 2011, ARM Limited. All rights reserved.\r
3402aac7
RC
3//\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
a6caee65 7# http://opensource.org/licenses/bsd-license.php\r
8#\r
3402aac7
RC
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
a6caee65 11#\r
12#\r
13\r
14#include <AsmMacroIoLib.h>\r
15#include <Base.h>\r
16#include <AutoGen.h>\r
17\r
18#start of the code section\r
19.text\r
1d5d0ae9 20.align 5\r
21\r
a6caee65 22# IMPORT\r
23GCC_ASM_IMPORT(PeiCommonExceptionEntry)\r
24\r
25# EXPORT\r
26GCC_ASM_EXPORT(PeiVectorTable)\r
27\r
28//============================================================\r
29//Default Exception Handlers\r
30//============================================================\r
3402aac7
RC
31\r
32\r
a6caee65 33ASM_PFX(PeiVectorTable):\r
34 b _DefaultResetHandler\r
35 b _DefaultUndefined\r
36 b _DefaultSWI\r
37 b _DefaultPrefetchAbort\r
38 b _DefaultDataAbort\r
39 b _DefaultReserved\r
40 b _DefaultIrq\r
41 b _DefaultFiq\r
42\r
43//\r
44// Default Exception handlers: There is no plan to return from any of these exceptions.\r
45// No context saving at all.\r
46//\r
47_DefaultResetHandler:\r
48 mov r1, lr\r
49 # Switch to SVC for common stack\r
50 cps #0x13\r
51 mov r0, #0\r
52 blx ASM_PFX(PeiCommonExceptionEntry)\r
53\r
54_DefaultUndefined:\r
55 sub r1, LR, #4\r
56 # Switch to SVC for common stack\r
57 cps #0x13\r
58 mov r0, #1\r
59 blx ASM_PFX(PeiCommonExceptionEntry)\r
60\r
61_DefaultSWI:\r
62 sub r1, LR, #4\r
63 # Switch to SVC for common stack\r
64 cps #0x13\r
65 mov r0, #2\r
66 blx ASM_PFX(PeiCommonExceptionEntry)\r
67\r
68_DefaultPrefetchAbort:\r
69 sub r1, LR, #4\r
70 # Switch to SVC for common stack\r
71 cps #0x13\r
72 mov r0, #3\r
73 blx ASM_PFX(PeiCommonExceptionEntry)\r
74\r
75_DefaultDataAbort:\r
76 sub r1, LR, #8\r
77 # Switch to SVC for common stack\r
78 cps #0x13\r
79 mov r0, #4\r
80 blx ASM_PFX(PeiCommonExceptionEntry)\r
81\r
82_DefaultReserved:\r
83 mov r1, lr\r
84 # Switch to SVC for common stack\r
85 cps #0x13\r
86 mov r0, #5\r
87 blx ASM_PFX(PeiCommonExceptionEntry)\r
88\r
89_DefaultIrq:\r
90 sub r1, LR, #4\r
91 # Switch to SVC for common stack\r
92 cps #0x13\r
93 mov r0, #6\r
94 blx ASM_PFX(PeiCommonExceptionEntry)\r
1d5d0ae9 95\r
a6caee65 96_DefaultFiq:\r
97 sub r1, LR, #4\r
98 # Switch to SVC for common stack\r
99 cps #0x13\r
100 mov r0, #7\r
101 blx ASM_PFX(PeiCommonExceptionEntry)\r
1d5d0ae9 102\r