view gsm-fw/lldbg/entry.S @ 992:a7b0b426f9ca

target-utils: boot ROM UART autodetection revamped The new implementation should work with both the familiar Calypso C035 boot ROM version found in our regular targets as well as the older Calypso F741979B version found on the vintage D-Sample board.
author Mychaela Falconia <falcon@ivan.Harhan.ORG>
date Wed, 30 Dec 2015 21:28:41 +0000
parents f5affe83ba2d
children
line wrap: on
line source

	.section "ext.ram","aw",%nobits
	.balign  4
	.globl	lldbg_stack
lldbg_stack:
	.space	2048
lldbg_init_sp:

	.text
	.code	32
	.globl	lldbg_entry
lldbg_entry:
	stmfd	sp!, {r0-r12,lr}
	mrs	r0, CPSR
	mov	r1, sp
	/* supervisor mode, disable all interrupts */
	msr	CPSR_c, #0xd3
	ldr	sp, =lldbg_init_sp
	/* save entry SP and CPSR */
	ldr	r2, =lldbg_entry_cpsr
	str	r0, [r2]
	ldr	r2, =lldbg_entry_sp
	str	r1, [r2]
	b	lldbg_main