mbed library sources. Supersedes mbed-src.
Fork of mbed-dev by
targets/cmsis/TARGET_NUVOTON/TARGET_NUC472/TARGET_NUMAKER_PFM_NUC472/TOOLCHAIN_ARM_MICRO/sys.cpp@144:ef7eb2e8f9f7, 2016-09-02 (annotated)
- Committer:
- <>
- Date:
- Fri Sep 02 15:07:44 2016 +0100
- Revision:
- 144:ef7eb2e8f9f7
This updates the lib to the mbed lib v125
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
<> | 144:ef7eb2e8f9f7 | 1 | /* mbed Microcontroller Library - stackheap |
<> | 144:ef7eb2e8f9f7 | 2 | * Copyright (C) 2009-2011 ARM Limited. All rights reserved. |
<> | 144:ef7eb2e8f9f7 | 3 | * |
<> | 144:ef7eb2e8f9f7 | 4 | * Setup a fixed single stack/heap memory model, |
<> | 144:ef7eb2e8f9f7 | 5 | * between the top of the RW/ZI region and the stackpointer |
<> | 144:ef7eb2e8f9f7 | 6 | */ |
<> | 144:ef7eb2e8f9f7 | 7 | |
<> | 144:ef7eb2e8f9f7 | 8 | #ifdef __cplusplus |
<> | 144:ef7eb2e8f9f7 | 9 | extern "C" { |
<> | 144:ef7eb2e8f9f7 | 10 | #endif |
<> | 144:ef7eb2e8f9f7 | 11 | |
<> | 144:ef7eb2e8f9f7 | 12 | #include <rt_misc.h> |
<> | 144:ef7eb2e8f9f7 | 13 | #include <stdint.h> |
<> | 144:ef7eb2e8f9f7 | 14 | |
<> | 144:ef7eb2e8f9f7 | 15 | extern char Image$$ARM_LIB_STACK$$ZI$$Limit[]; |
<> | 144:ef7eb2e8f9f7 | 16 | extern char Image$$ARM_LIB_HEAP$$Base[]; |
<> | 144:ef7eb2e8f9f7 | 17 | extern char Image$$ARM_LIB_HEAP$$ZI$$Limit[]; |
<> | 144:ef7eb2e8f9f7 | 18 | extern __value_in_regs struct __initial_stackheap __user_setup_stackheap(uint32_t R0, uint32_t R1, uint32_t R2, uint32_t R3) { |
<> | 144:ef7eb2e8f9f7 | 19 | |
<> | 144:ef7eb2e8f9f7 | 20 | struct __initial_stackheap r; |
<> | 144:ef7eb2e8f9f7 | 21 | r.heap_base = (uint32_t)Image$$ARM_LIB_HEAP$$Base; |
<> | 144:ef7eb2e8f9f7 | 22 | r.heap_limit = (uint32_t)Image$$ARM_LIB_HEAP$$ZI$$Limit; |
<> | 144:ef7eb2e8f9f7 | 23 | return r; |
<> | 144:ef7eb2e8f9f7 | 24 | } |
<> | 144:ef7eb2e8f9f7 | 25 | |
<> | 144:ef7eb2e8f9f7 | 26 | #ifdef __cplusplus |
<> | 144:ef7eb2e8f9f7 | 27 | } |
<> | 144:ef7eb2e8f9f7 | 28 | #endif |