# 1 "../src/start.S"
# 1 "/home/pullin/libmc1322x/tests//"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "../src/start.S"
# 29 "../src/start.S"
 .equ IRQ_DISABLE, 0x80
 .equ FIQ_DISABLE, 0x40

 .equ USR_MODE, 0x10
 .equ FIQ_MODE, 0x11
 .equ IRQ_MODE, 0x12
 .equ SVC_MODE, 0x13
 .equ ABT_MODE, 0x17
 .equ UND_MODE, 0x1B
 .equ SYS_MODE, 0x1F

 .equ usr_stack_size, 1024
 .equ irq_stack_size, 256
 .equ fiq_stack_size, 256
 .equ und_stack_size, 256
 .equ abt_stack_size, 16
 .equ sup_stack_size, 16
# 57 "../src/start.S"
.set base, .
.set _rom_data_init, 0x108d0


 .globl _start
_start: b _begin
 ldr pc, _undefined_instruction
 ldr pc, _software_interrupt
 ldr pc, _prefetch_abort
 ldr pc, _data_abort
 ldr pc, _not_used
 ldr pc, _irq
 ldr pc, _fiq



.org 0x20
.code 16
_RPTV_0_START:
 bx lr

.org 0x60
_RPTV_1_START:
 bx lr

.org 0xa0
_RPTV_2_START:
 bx lr

.org 0xe0
_RPTV_3_START:
 bx lr

.org 0x120
ROM_var_start: .word 0
.org 0x7ff
ROM_var_end: .word 0


.code 32
.align
_begin:

 msr CPSR_c, #(FIQ_MODE | IRQ_DISABLE | FIQ_DISABLE)
 ldr sp, =__fiq_stack_top__


 msr CPSR_c, #(IRQ_MODE | IRQ_DISABLE | FIQ_DISABLE)
 ldr sp, =__irq_stack_top__


 msr CPSR_c, #(SVC_MODE | IRQ_DISABLE | FIQ_DISABLE)
 ldr sp, =__svc_stack_top__


 msr CPSR_c, #(UND_MODE | IRQ_DISABLE | FIQ_DISABLE)
 ldr sp, =__und_stack_top__


 msr CPSR_c, #(ABT_MODE | IRQ_DISABLE | FIQ_DISABLE)
 ldr sp, =__abt_stack_top__


 msr CPSR_c, #(SYS_MODE | IRQ_DISABLE | FIQ_DISABLE)
 ldr sp, =__sys_stack_top__


 bl _rom_data_init+.-base

 msr CPSR_c, #(SYS_MODE)

 b main
# 159 "../src/start.S"
_undefined_instruction: .word undefined_instruction
_software_interrupt: .word software_interrupt
_prefetch_abort: .word prefetch_abort
_data_abort: .word data_abort
_not_used: .word not_used
_irq: .word irq
_fiq: .word fiq
 .balignl 16,0xdeadbeef
# 182 "../src/start.S"
_TEXT_BASE:
 .word

.globl _armboot_start
_armboot_start:
 .word _start




.globl _bss_start
_bss_start:
 .word __bss_start

.globl _bss_end
_bss_end:
 .word _end

_start_armboot: .word main

_system_stack:
 . = . + usr_stack_size + irq_stack_size + fiq_stack_size + und_stack_size + abt_stack_size + sup_stack_size
# 214 "../src/start.S"
cpu_init_crit:
 # actually do nothing for now!
 mov pc, lr





 .align 5
undefined_instruction:

 .align 5
software_interrupt:

 .align 5
prefetch_abort:
 nop
 .align 5
data_abort:

 .align 5
not_used:


 .align 5



fiq:

 .align 5

.globl reset_cpu
reset_cpu:
 mov pc, r0
