RTEMS 6.1-rc1
|
Items of this group should move to other groups. More...
Macros | |
#define | RTEMS_MICROSECONDS_TO_TICKS(_us) ( ( _us ) / rtems_configuration_get_microseconds_per_tick() ) |
Gets the number of clock ticks for the microseconds value. More... | |
#define | RTEMS_MILLISECONDS_TO_MICROSECONDS(_ms) ( ( _ms ) * 1000UL ) |
Gets the number of microseconds for the milliseconds value. More... | |
#define | RTEMS_MILLISECONDS_TO_TICKS(_ms) RTEMS_MICROSECONDS_TO_TICKS( RTEMS_MILLISECONDS_TO_MICROSECONDS( _ms ) ) |
Gets the number of clock ticks for the milliseconds value. More... | |
Functions | |
bool | rtems_workspace_allocate (size_t bytes, void **pointer) |
Allocates a memory area from the RTEMS Workspace. More... | |
bool | rtems_workspace_free (void *pointer) |
Frees the memory area allocated from the RTEMS Workspace. More... | |
bool | rtems_workspace_get_information (Heap_Information_block *the_info) |
Gets information about the RTEMS Workspace. More... | |
void * | rtems_workspace_greedy_allocate (const uintptr_t *block_sizes, size_t block_count) |
Greedy allocates that empties the RTEMS Workspace. More... | |
void * | rtems_workspace_greedy_allocate_all_except_largest (uintptr_t *allocatable_size) |
Greedy allocates all blocks of the RTEMS Workspace except the largest free block. More... | |
void | rtems_workspace_greedy_free (void *opaque) |
Frees space of a greedy allocation to the RTEMS Workspace. More... | |
Items of this group should move to other groups.
#define RTEMS_MICROSECONDS_TO_TICKS | ( | _us | ) | ( ( _us ) / rtems_configuration_get_microseconds_per_tick() ) |
Gets the number of clock ticks for the microseconds value.
_us | is the microseconds value to convert to clock ticks. |
The following constraints apply to this directive:
#define RTEMS_MILLISECONDS_TO_MICROSECONDS | ( | _ms | ) | ( ( _ms ) * 1000UL ) |
Gets the number of microseconds for the milliseconds value.
_ms | is the milliseconds value to convert to microseconds. |
The following constraints apply to this directive:
#define RTEMS_MILLISECONDS_TO_TICKS | ( | _ms | ) | RTEMS_MICROSECONDS_TO_TICKS( RTEMS_MILLISECONDS_TO_MICROSECONDS( _ms ) ) |
Gets the number of clock ticks for the milliseconds value.
_ms | is the milliseconds value to convert to clock ticks. |
The following constraints apply to this directive:
bool rtems_workspace_allocate | ( | size_t | bytes, |
void ** | pointer | ||
) |
Allocates a memory area from the RTEMS Workspace.
bytes | is the number of bytes to allocated. | |
[out] | pointer | is the pointer to a void pointer object. When the directive call is successful, the begin address of the allocated memory area will be stored in this object. |
The following constraints apply to this directive:
bool rtems_workspace_free | ( | void * | pointer | ) |
Frees the memory area allocated from the RTEMS Workspace.
pointer | is the begin address of the memory area to free. |
The following constraints apply to this directive:
bool rtems_workspace_get_information | ( | Heap_Information_block * | the_info | ) |
Gets information about the RTEMS Workspace.
[out] | the_info | is the pointer to a Heap_Information_block object. When the directive call is successful, the heap information will be stored in this object. |
The following constraints apply to this directive:
void * rtems_workspace_greedy_allocate | ( | const uintptr_t * | block_sizes, |
size_t | block_count | ||
) |
Greedy allocates that empties the RTEMS Workspace.
block_sizes | is the array of block sizes. |
block_count | is the block count. |
Afterwards the heap has at most block_count
allocatable blocks of sizes specified by block_sizes
. The block_sizes
must point to an array with block_count
members. All other blocks are used.
void * rtems_workspace_greedy_allocate_all_except_largest | ( | uintptr_t * | allocatable_size | ) |
Greedy allocates all blocks of the RTEMS Workspace except the largest free block.
allocatable_size | is the remaining allocatable size. |
Afterwards the heap has at most one allocatable block. This block is the largest free block if it exists. The allocatable size of this block is stored in allocatable_size
. All other blocks are used.
The following constraints apply to this directive:
void rtems_workspace_greedy_free | ( | void * | opaque | ) |
Frees space of a greedy allocation to the RTEMS Workspace.
opaque | is the pointer value returned by rtems_workspace_greedy_allocate() or rtems_workspace_greedy_allocate_all_except_largest(). |
The following constraints apply to this directive: