1/**
2 * \file
3 * \brief	Startup code
4 *
5 * \date	06/03/2003
6 * \author	Frank Mehnert <fm3@os.inf.tu-dresden.de> */
7
8/*
9 * (c) 2003-2009 Author(s)
10 *     economic rights: Technische Universität Dresden (Germany)
11 *
12 * This file is part of TUD:OS and distributed under the terms of the
13 * GNU General Public License 2.
14 * Please see the COPYING-GPL-2 file for details.
15 */
16
17#define __ASSEMBLY__
18#include <l4/sys/compiler.h>
19
20/*--- .text (program code) -------------------------*/
21	.text
22
23	.globl	_real_start
24_real_start:
25	ldr 	x9, .LCstack
26	mov 	sp, x9
27	b	_start
28
29/* Mind the argc that is popped off the stack! */
30.LCstack: .8byte _stack_top-16
31
32/* This is not a normal function and must not clobber any register.
33 * This is a special syscall stub -- do not add any code! */
34.global __l4_sys_syscall
35.type __l4_sys_syscall, @function
36__l4_sys_syscall:
37#ifdef CONFIG_KERNEL_CPU_VIRT
38	hvc #0
39#else
40	svc #0
41#endif
42	ret
43.size __l4_sys_syscall, . - __l4_sys_syscall
44
45
46/*--- my stack -------------------------------------*/
47	.bss
48	.align 4
49_stack_bottom:
50	.space 0x4000
51_stack_top:
52