-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathentry.S
40 lines (37 loc) · 840 Bytes
/
entry.S
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#include "assembly.h"
.arm
.pushsection .text.vectors
.align 12
b _vec_reset @ System reset
b _vec_undef @ Undefined instruction
b _vec_swi @ Software interrupt
b _vec_prefetch_abt @ Prefetch abort
b _vec_dabort @ Data abort
b _vec_reserved @ Reserved vector
b _vec_irq @ IRQ
b _vec_fiq @ FIQ
.popsection
VECTOR(undef)
ex_handler #4, do_undef, #CPSR_MODE_SVC
VECTOR(swi)
ex_handler #4, do_swi, #CPSR_MODE_SVC
VECTOR(prefetch_abt)
ex_handler #4, do_prefetch, #CPSR_MODE_SVC
VECTOR(dabort)
ex_handler #8, do_dabort, #CPSR_MODE_SVC
VECTOR(reserved)
ex_handler #8, do_reserved, #CPSR_MODE_SVC
VECTOR(irq)
ex_handler #4, do_irq, #CPSR_MODE_SVC
VECTOR(fiq)
ex_handler #4, do_fiq, #CPSR_MODE_SVC
VECTOR(reset)
ldr sp, stack_addr
bl start_kernel
stack_addr:
.word stack_top
stack:
.rept 1024
.word 0
.endr
stack_top: