]> rtime.felk.cvut.cz Git - l4.git/blob - l4/pkg/l4re-core/l4util/include/ARCH-arm/stack_impl.h
Update
[l4.git] / l4 / pkg / l4re-core / l4util / include / ARCH-arm / stack_impl.h
1 /**
2  * \file
3  * \brief Stack utilities, arm version
4  */
5 /*
6  * (c) 2008-2009 Adam Lackorzynski <adam@os.inf.tu-dresden.de>
7  *     economic rights: Technische Universität Dresden (Germany)
8  * This file is part of TUD:OS and distributed under the terms of the
9  * GNU Lesser General Public License 2.1.
10  * Please see the COPYING-LGPL-2.1 file for details.
11  */
12 #ifndef __L4UTIL__INCLUDE__ARCH_ARM__STACK_IMPL_H__
13 #define __L4UTIL__INCLUDE__ARCH_ARM__STACK_IMPL_H__
14
15 #include <l4/sys/compiler.h>
16
17 EXTERN_C_BEGIN
18
19 #ifndef _L4UTIL_STACK_H
20 #error Do not include stack_impl.h directly, use stack.h instead
21 #endif
22
23 L4_INLINE l4_addr_t l4util_stack_get_sp(void)
24 {
25   register l4_addr_t sp asm ("sp");
26   return sp;
27 }
28
29 EXTERN_C_END
30
31 #endif /* ! __L4UTIL__INCLUDE__ARCH_ARM__STACK_IMPL_H__ */