summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems/score/heap.h
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2008-11-20 20:01:13 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2008-11-20 20:01:13 +0000
commit7ff6115b8b913d848b8fe76daf72ca0b4bbf2548 (patch)
tree35545452de162753f8c608a400f2b0bd97d42807 /cpukit/score/include/rtems/score/heap.h
parent2008-11-20 Joel Sherrill <joel.sherrill@oarcorp.com> (diff)
downloadrtems-7ff6115b8b913d848b8fe76daf72ca0b4bbf2548.tar.bz2
2008-11-20 Joel Sherrill <joel.sherrill@oarcorp.com>
* 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: Revert use of ssize_t. This type is not guaranteed to be able to represent a positive number greater than the size of a single allocatable object. We needed a type that is able to represent the size of a pool of multiple allocatable objects or potentially nearly all memory.
Diffstat (limited to '')
-rw-r--r--cpukit/score/include/rtems/score/heap.h18
1 files changed, 8 insertions, 10 deletions
diff --git a/cpukit/score/include/rtems/score/heap.h b/cpukit/score/include/rtems/score/heap.h
index 78c15522fd..0587852d78 100644
--- a/cpukit/score/include/rtems/score/heap.h
+++ b/cpukit/score/include/rtems/score/heap.h
@@ -31,8 +31,6 @@
#ifndef _RTEMS_SCORE_HEAP_H
#define _RTEMS_SCORE_HEAP_H
-#include <sys/types.h>
-
/**
* @defgroup ScoreHeap Heap Handler
*
@@ -264,7 +262,7 @@ typedef struct {
uint32_t _Heap_Initialize(
Heap_Control *the_heap,
void *starting_address,
- ssize_t size,
+ size_t size,
uint32_t page_size
);
@@ -283,7 +281,7 @@ uint32_t _Heap_Initialize(
Heap_Extend_status _Heap_Extend(
Heap_Control *the_heap,
void *starting_address,
- ssize_t size,
+ size_t size,
uint32_t *amount_extended
);
@@ -298,7 +296,7 @@ Heap_Extend_status _Heap_Extend(
*/
void *_Heap_Allocate(
Heap_Control *the_heap,
- ssize_t size
+ size_t size
);
/**
@@ -317,7 +315,7 @@ void *_Heap_Allocate(
*/
void *_Heap_Allocate_aligned(
Heap_Control *the_heap,
- ssize_t size,
+ size_t size,
uint32_t alignment
);
@@ -338,7 +336,7 @@ void *_Heap_Allocate_aligned(
bool _Heap_Size_of_user_area(
Heap_Control *the_heap,
void *starting_address,
- ssize_t *size
+ size_t *size
);
/**
@@ -366,7 +364,7 @@ bool _Heap_Size_of_user_area(
Heap_Resize_status _Heap_Resize_block(
Heap_Control *the_heap,
void *starting_address,
- ssize_t size,
+ size_t size,
uint32_t *old_mem_size,
uint32_t *avail_mem_size
);
@@ -451,8 +449,8 @@ void _Heap_Get_free_information(
*
* @return This method returns block size on success, 0 if overflow occured.
*/
-extern ssize_t _Heap_Calc_block_size(
- ssize_t size,
+extern size_t _Heap_Calc_block_size(
+ size_t size,
uint32_t page_size,
uint32_t min_size
);