diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2008-10-02 20:56:55 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2008-10-02 20:56:55 +0000 |
commit | 4c09f4b3fefc7ba5c5868a97ad00c1ee14a06677 (patch) | |
tree | 30ce362448a1d4d367e6532beac8b428315be09d /cpukit/score/src/heap.c | |
parent | 3d0e458723d51bfd92757685ead0ea2171c2e091 (diff) |
2008-10-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* libcsupport/src/malloc_statistics_helpers.c,
libcsupport/src/realloc.c, rtems/include/rtems/rtems/region.h,
rtems/include/rtems/rtems/support.h,
rtems/src/regiongetsegmentsize.c, rtems/src/regionresizesegment.c,
rtems/src/workspace.c, sapi/include/confdefs.h,
score/include/rtems/score/heap.h,
score/include/rtems/score/protectedheap.h,
score/include/rtems/score/wkspace.h, score/src/heap.c,
score/src/heapallocate.c, score/src/heapallocatealigned.c,
score/src/heapextend.c, score/src/heapresizeblock.c,
score/src/heapsizeofuserarea.c, score/src/pheapgetblocksize.c,
score/src/wkspace.c: Change size_t to ssize_t on all Heap, Workspace
and Region calls. On 16-bit architectures, size_t can be 16-bits
which would limit sizes to 64K.
Diffstat (limited to 'cpukit/score/src/heap.c')
-rw-r--r-- | cpukit/score/src/heap.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/cpukit/score/src/heap.c b/cpukit/score/src/heap.c index 042dc6d604..8c55b06ecd 100644 --- a/cpukit/score/src/heap.c +++ b/cpukit/score/src/heap.c @@ -111,11 +111,10 @@ static uint32_t instance = 0; * +--------------------------------+ <- end = begin + size * */ - uint32_t _Heap_Initialize( Heap_Control *the_heap, void *starting_address, - size_t size, + ssize_t size, uint32_t page_size ) { @@ -207,10 +206,10 @@ uint32_t _Heap_Initialize( * Convert user requested 'size' of memory block to the block size. * Return block size on success, 0 if overflow occured */ -size_t _Heap_Calc_block_size( - size_t size, - uint32_t page_size, - uint32_t min_size) +ssize_t _Heap_Calc_block_size( + ssize_t size, + uint32_t page_size, + uint32_t min_size) { uint32_t block_size = size + HEAP_BLOCK_USED_OVERHEAD; _Heap_Align_up(&block_size, page_size); |