|
|
The memory management descriptor is a representation of the memory model in the client front end. It defines how memory blocks are allocated/deallocated and how allocation failure is handled. Other aspects of the memory model, such as the grouping of memory blocks in pools and buffers, are not addressed directly in the descriptor. To allow such extensions, the memory management descriptor contains a reference to private model data which can be used by the model-specific interface. The memory management descriptor is a handle defined as:
typedef void * DmiMemDsc_t;Effectively this handle references the following structure which defines the memory model:
typedef struct DmiMemMgmt { DmiNodeAlloc_t * nodeAlloc; DmiNodeFree_t * nodeFree; DmiAllocFail_t * allocFail; void * mgmtData; } DmiMemMgmt_t;This definition can be found in /usr/include/dmi/dmi2mem.h The members are:
nodeAlloc
nodeFree
allocFail
mgmtData
allocFail
pointer is NULL
then no handler is called in the case of failure.
See also: