4.104.115
Last change
on this file since 12838f75 was
12838f75,
checked in by Joel Sherrill <joel.sherrill@…>, on 10/02/08 at 19:12:59
|
2008-10-02 Joel Sherrill <joel.sherrill@…>
- startup/bspgetworkarea.c: Change size_t to ssize_t on
bsp_get_work_area(). On 16-bit architectures, size_t can be 16-bits
which would limit the work area to 64K.
|
-
Property mode set to
100644
|
File size:
818 bytes
|
Line | |
---|
1 | /* |
---|
2 | * The license and distribution terms for this file may be |
---|
3 | * found in the file LICENSE in this distribution or at |
---|
4 | * http://www.rtems.com/license/LICENSE. |
---|
5 | * |
---|
6 | * $Id$ |
---|
7 | */ |
---|
8 | |
---|
9 | #include <bsp.h> |
---|
10 | #include <bsp/bootcard.h> |
---|
11 | #include <stdint.h> |
---|
12 | |
---|
13 | /* |
---|
14 | * These are from the linker script. |
---|
15 | */ |
---|
16 | extern void * _end; |
---|
17 | extern void *__ewram_end; |
---|
18 | |
---|
19 | /* |
---|
20 | * This method returns the base address and size of the area which |
---|
21 | * is to be allocated between the RTEMS Workspace and the C Program |
---|
22 | * Heap. |
---|
23 | */ |
---|
24 | void bsp_get_work_area( |
---|
25 | void **work_area_start, |
---|
26 | ssize_t *work_area_size, |
---|
27 | void **heap_start, |
---|
28 | ssize_t *heap_size |
---|
29 | ) |
---|
30 | { |
---|
31 | *work_area_start = &_end; |
---|
32 | *work_area_size = (void *)&__ewram_end - (void *)&_end; |
---|
33 | *heap_start = BSP_BOOTCARD_HEAP_USES_WORK_AREA; |
---|
34 | *heap_size = BSP_BOOTCARD_HEAP_SIZE_DEFAULT; |
---|
35 | } |
---|
36 | |
---|
Note: See
TracBrowser
for help on using the repository browser.