Jump to main content

##

# TCPIP_STACK_HEAP_POOL_ENTRY Structure

## C

    typedef struct {
    uint16_t entrySize;
    uint16_t nBlocks;
    uint8_t nExpBlks;
    } TCPIP_STACK_HEAP_POOL_ENTRY;

## Description

Internal pool configuration data.

This data type defines the data required to initialize the TCP/IP stack internal memory pool.

## Preconditions

None.

## Members

Members | Description
--- | ---
entrySize | Size of the blocks in this pool entry.
nBlocks | Number of blocks to create for this entry.
nExpBlks | Number of blocks to expand/allocate when an allocation in this entry failed.

## Remarks

Pool entries should follow these 2 rules:

- They should have distincy block sizes: entrySize. Multiple entries having the same entrySize is not supported.
- Pool entries should have a non-zero block size. Entries with 0 block size are not supported.

If these conditions are not observed, the heap creation will fail. To expand/dynamically allocate at run time the expansionHeapSize needs to be != 0; If nExpBlks == 0, then no allocation will be tried for this particular entry.