|
WS63 SDK 文档 7021f4f@fbb_ws63
ws63 和 ws63e 解决方案的 SDK 文档
|

结构体 | |
| struct | LOS_MEMBOX_INFO |
宏定义 | |
| #define | LOS_MEMBOX_ALLIGNED(memAddr) (((UINTPTR)(memAddr) + sizeof(UINTPTR) - 1) & (~(sizeof(UINTPTR) - 1))) |
| Align the input parameter. | |
函数 | |
| UINT32 | LOS_MemboxInit (void *pool, UINT32 poolSize, UINT32 blkSize) |
| Initialize a static memory pool. | |
| void * | LOS_MemboxAlloc (void *pool) |
| Request a static memory block. | |
| UINT32 | LOS_MemboxFree (void *pool, void *box) |
| Free a static memory block. | |
| void | LOS_MemboxClr (void *pool, void *box) |
| Clear a static memory block. | |
| void | LOS_ShowBox (void *pool) |
| show static memory pool information. | |
| UINT32 | LOS_MemboxStatisticsGet (const void *boxMem, UINT32 *maxBlk, UINT32 *blkCnt, UINT32 *blkSize) |
| Obtain the static memory pool information. | |
| #define LOS_MEMBOX_ALLIGNED | ( | memAddr | ) | (((UINTPTR)(memAddr) + sizeof(UINTPTR) - 1) & (~(sizeof(UINTPTR) - 1))) |
Align the input parameter.
| memAddr | [IN] The variable that need to be aligned. Usually memAddr is an unsigned integer or an unsigned long integer on 64-bit platform. |
| The | memAddr value after alignment. |
|
extern |
Request a static memory block.
| pool | [IN] Memory pool address. |
| #VOID* | This API will return a memory block address, if the request is accepted successfully. |
| NULL | The request fails. |
|
extern |
Clear a static memory block.
| pool | [IN] Memory pool address. The memory block need to clear is requested from this memory pool. |
| box | [IN] The pointer to the memory block to clear. |
| None. |
|
extern |
Free a static memory block.
| pool | [IN] Memory pool address. The memory block need to release is requested from this memory pool. |
| box | [IN] The pointer to the memory block to be released. |
Initialize a static memory pool.
| pool | [IN] Memory pool address. |
| poolSize | [IN] The total size of the static memory pool. |
| blkSize | [IN] The memory block size of the static memory pool. |
| LOS_NOK | The memory pool fails to be initialized. |
| LOS_OK | The memory pool is successfully initialized. |
|
extern |
Obtain the static memory pool information.
| boxMem | [IN] Type VOID* Pointer to the static memory pool. |
| maxBlk | [OUT] Type UINT32* The total memory block number is outputted to this parameter. |
| blkCnt | [OUT] Type UINT32* The allocated memory block number is outputted to this parameter. |
| blkSize | [OUT] Type UINT32* The memory block size is outputted to this parameter. |
| LOS_OK | Obtain the static memory pool information successfully. |
| LOS_NOK | Failed to obtain the static memory pool information, check whether the parameters is NULL or not. |
|
extern |
show static memory pool information.
| pool | [IN] Memory pool address. |
| None. |