CMSIS-RTX  
Keil RTX5 Real-Time Operating System
 
Loading...
Searching...
No Matches
Memory Pool Functions

Events generated by memory pool functions. More...

Functions

void EvrRtxMemoryPoolError (osMemoryPoolId_t mp_id, int32_t status)
 Event on memory pool error (Error)
 
void EvrRtxMemoryPoolNew (uint32_t block_count, uint32_t block_size, const osMemoryPoolAttr_t *attr)
 Event on memory pool create and initialize (API)
 
void EvrRtxMemoryPoolCreated (osMemoryPoolId_t mp_id, const char *name)
 Event on successful memory pool create (Op)
 
void EvrRtxMemoryPoolGetName (osMemoryPoolId_t mp_id, const char *name)
 Event on memory pool name retrieve (API)
 
void EvrRtxMemoryPoolAlloc (osMemoryPoolId_t mp_id, uint32_t timeout)
 Event on memory pool allocation (API)
 
void EvrRtxMemoryPoolAllocPending (osMemoryPoolId_t mp_id, uint32_t timeout)
 Event on pending memory pool allocation (Op)
 
void EvrRtxMemoryPoolAllocTimeout (osMemoryPoolId_t mp_id)
 Event on memory pool allocation timeout (Op)
 
void EvrRtxMemoryPoolAllocated (osMemoryPoolId_t mp_id, void *block)
 Event on successful memory pool allocation (Op)
 
void EvrRtxMemoryPoolAllocFailed (osMemoryPoolId_t mp_id)
 Event on unsuccessful memory pool allocation (Op)
 
void EvrRtxMemoryPoolFree (osMemoryPoolId_t mp_id, void *block)
 Event on memory pool free (API)
 
void EvrRtxMemoryPoolDeallocated (osMemoryPoolId_t mp_id, void *block)
 Event on successful memory pool free (Op)
 
void EvrRtxMemoryPoolFreeFailed (osMemoryPoolId_t mp_id, void *block)
 Event on unsuccessful memory pool free (Op)
 
void EvrRtxMemoryPoolGetCapacity (osMemoryPoolId_t mp_id, uint32_t capacity)
 Event on memory pool capacity retrieve (API)
 
void EvrRtxMemoryPoolGetBlockSize (osMemoryPoolId_t mp_id, uint32_t block_size)
 Event on memory pool block size retrieve (API)
 
void EvrRtxMemoryPoolGetCount (osMemoryPoolId_t mp_id, uint32_t count)
 Event on used memory pool blocks retrieve (API)
 
void EvrRtxMemoryPoolGetSpace (osMemoryPoolId_t mp_id, uint32_t space)
 Event on available memory pool blocks retrieve (API)
 
void EvrRtxMemoryPoolDelete (osMemoryPoolId_t mp_id)
 Event on memory pool delete (API)
 
void EvrRtxMemoryPoolDestroyed (osMemoryPoolId_t mp_id)
 Event on successful memory pool delete (Op)
 

Description

Events generated by memory pool functions.

Function Documentation

◆ EvrRtxMemoryPoolError()

void EvrRtxMemoryPoolError ( osMemoryPoolId_t  mp_id,
int32_t  status 
)

Event on memory pool error (Error)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew or NULL when ID is unknown.
[in]statusextended execution status.

The event MemoryPoolError is generated when Memory Pool routines complete their execution due to an error.

The status parameter indicates the execution status and can be one of the osStatus_t codes or one of the extended execution status codes which are summarized in the table below.

Extended Status Code Description
osRtxErrorKernelNotReady Kernel scheduler is not in Ready state.
osRtxErrorKernelNotRunning Kernel scheduler is not executing - there is no running thread.
osRtxErrorInvalidControlBlock Object control block with invalid alignment or size was specified.
osRtxErrorInvalidDataMemory Object data memory with invalid alignment or size was specified.
osRtxErrorInvalidThreadStack Thread stack memory with invalid alignment or size was specified.
osRtxErrorInvalidPriority Invalid thread priority was specified.
osRtxErrorInvalidPrivilegedMode Privileged thread cannot be created - kernel protect privileged is active.
osRtxErrorThreadNotJoinable Specified thread is not joinable.
osRtxErrorMutexNotOwned Specified mutex is not owned by the current running thread.
osRtxErrorMutexNotLocked Specified mutex is not locked.
osRtxErrorMutexLockLimit Maximum number of recursive mutex locks reached.
osRtxErrorSemaphoreCountLimit Semaphore count limit reached.
osRtxErrorTZ_InitContext_S Secure context memory system initialization failed.
osRtxErrorTZ_AllocContext_S Secure context memory allocation failed.
osRtxErrorTZ_FreeContext_S Secure context memory deallocation failed.
osRtxErrorTZ_LoadContext_S Secure context load failed.
osRtxErrorTZ_SaveContext_S Secure context save failed.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • status : execution status code.

◆ EvrRtxMemoryPoolNew()

void EvrRtxMemoryPoolNew ( uint32_t  block_count,
uint32_t  block_size,
const osMemoryPoolAttr_t attr 
)

Event on memory pool create and initialize (API)

Parameters
[in]block_countmaximum number of memory blocks in memory pool.
[in]block_sizememory block size in bytes.
[in]attrmemory pool attributes; NULL: default values.

The event MemoryPoolNew is generated when the function osMemoryPoolNew is called.

Value in the Event Recorder shows:

  • block_count : maximum number of memory blocks in memory pool.
  • block_size : memory block size in bytes.
  • attr : memory address of Memory Pool attributes or 0 when they are not specified.

◆ EvrRtxMemoryPoolCreated()

void EvrRtxMemoryPoolCreated ( osMemoryPoolId_t  mp_id,
const char *  name 
)

Event on successful memory pool create (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]namepointer to memory pool object name.

The event MemoryPoolCreated is generated when the function osMemoryPoolNew successfully creates a memory pool object.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.

◆ EvrRtxMemoryPoolGetName()

void EvrRtxMemoryPoolGetName ( osMemoryPoolId_t  mp_id,
const char *  name 
)

Event on memory pool name retrieve (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]namepointer to memory pool object name.

The event MemoryPoolGetName is generated when the function osMemoryPoolGetName is called and its execution result is known.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • name : retrieved memory address of name string (0 in case of a failure).

◆ EvrRtxMemoryPoolAlloc()

void EvrRtxMemoryPoolAlloc ( osMemoryPoolId_t  mp_id,
uint32_t  timeout 
)

Event on memory pool allocation (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]timeoutTimeout Value or 0 in case of no time-out.

The event MemoryPoolAlloc is generated when the function osMemoryPoolAlloc is called.

Value in the Event Recorder shows:

◆ EvrRtxMemoryPoolAllocPending()

void EvrRtxMemoryPoolAllocPending ( osMemoryPoolId_t  mp_id,
uint32_t  timeout 
)

Event on pending memory pool allocation (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]timeoutTimeout Value or 0 in case of no time-out.

The event MemoryPoolAllocPending is generated when the function osMemoryPoolAlloc blocks current running thread and waits for memory block to become available.

Value in the Event Recorder shows:

◆ EvrRtxMemoryPoolAllocTimeout()

void EvrRtxMemoryPoolAllocTimeout ( osMemoryPoolId_t  mp_id)

Event on memory pool allocation timeout (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.

The event MemoryPoolAllocTimeout is generated when wait for memory pool to become available is aborted due to expired wait timeout.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.

◆ EvrRtxMemoryPoolAllocated()

void EvrRtxMemoryPoolAllocated ( osMemoryPoolId_t  mp_id,
void *  block 
)

Event on successful memory pool allocation (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]blockaddress of the allocated memory block.

The event MemoryPoolAllocated is generated when the function osMemoryPoolAlloc successfully allocates the memory block.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • block : memory address of the allocated memory block.

◆ EvrRtxMemoryPoolAllocFailed()

void EvrRtxMemoryPoolAllocFailed ( osMemoryPoolId_t  mp_id)

Event on unsuccessful memory pool allocation (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.

The event MemoryPoolAllocFailed is generated when the function osMemoryPoolAlloc fails to allocate the memory block due to out of available memory.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.

◆ EvrRtxMemoryPoolFree()

void EvrRtxMemoryPoolFree ( osMemoryPoolId_t  mp_id,
void *  block 
)

Event on memory pool free (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]blockaddress of the allocated memory block to be returned to the memory pool.

The event MemoryPoolFree is generated when the function osMemoryPoolFree is called.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • block : memory address of the memory block to be returned to the memory pool.

◆ EvrRtxMemoryPoolDeallocated()

void EvrRtxMemoryPoolDeallocated ( osMemoryPoolId_t  mp_id,
void *  block 
)

Event on successful memory pool free (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]blockaddress of the allocated memory block to be returned to the memory pool.

The event MemoryPoolDeallocated is generated when the function osMemoryPoolFree successfully deallocates the memory block.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • block : memory address of the memory block returned to the memory pool.

◆ EvrRtxMemoryPoolFreeFailed()

void EvrRtxMemoryPoolFreeFailed ( osMemoryPoolId_t  mp_id,
void *  block 
)

Event on unsuccessful memory pool free (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]blockaddress of the allocated memory block to be returned to the memory pool.

The event MemoryPoolFreeFailed is generated when the function osMemoryPoolFree fails to deallocate the memory block.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • block : memory address of the memory block to be returned to the memory pool.

◆ EvrRtxMemoryPoolGetCapacity()

void EvrRtxMemoryPoolGetCapacity ( osMemoryPoolId_t  mp_id,
uint32_t  capacity 
)

Event on memory pool capacity retrieve (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]capacitymaximum number of memory blocks.

The event MemoryPoolGetCapacity is generated when the function osMemoryPoolGetCapacity is called and its execution result is known.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • capacity : retrieved maximum number of memory blocks (0 in case of a failure).

◆ EvrRtxMemoryPoolGetBlockSize()

void EvrRtxMemoryPoolGetBlockSize ( osMemoryPoolId_t  mp_id,
uint32_t  block_size 
)

Event on memory pool block size retrieve (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]block_sizememory block size in bytes.

The event MemoryPoolGetBlockSize is generated when the function osMemoryPoolGetBlockSize is called and its execution result is known.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • block_size : retrieved memory block size in bytes (0 in case of a failure).

◆ EvrRtxMemoryPoolGetCount()

void EvrRtxMemoryPoolGetCount ( osMemoryPoolId_t  mp_id,
uint32_t  count 
)

Event on used memory pool blocks retrieve (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]countnumber of memory blocks used.

The event MemoryPoolGetCount is generated when the function osMemoryPoolGetCount is called and its execution result is known.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • count : retrieved number of memory block used (0 in case of a failure).

◆ EvrRtxMemoryPoolGetSpace()

void EvrRtxMemoryPoolGetSpace ( osMemoryPoolId_t  mp_id,
uint32_t  space 
)

Event on available memory pool blocks retrieve (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.
[in]spacenumber of memory blocks available.

The event MemoryPoolGetSpace is generated when the function osMemoryPoolGetSpace is called and its execution result is known.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.
  • space : retrieved number of memory blocks available (0 in case of a failure).

◆ EvrRtxMemoryPoolDelete()

void EvrRtxMemoryPoolDelete ( osMemoryPoolId_t  mp_id)

Event on memory pool delete (API)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.

The event MemoryPoolDelete is generated when the function osMemoryPoolDelete is called.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.

◆ EvrRtxMemoryPoolDestroyed()

void EvrRtxMemoryPoolDestroyed ( osMemoryPoolId_t  mp_id)

Event on successful memory pool delete (Op)

Parameters
[in]mp_idmemory pool ID obtained by osMemoryPoolNew.

The event MemoryPoolDestroyed is generated when the function osMemoryPoolDelete successfully deletes the memory pool object.

Value in the Event Recorder shows:

  • mp_id : memory pool ID.