Placement between internal and external memory, and a two-buffer index. More...
#include "mmgr.h"Go to the source code of this file.
Data Structures | |
| struct | PingPong |
| A pair of buffers, one being filled while the other is drained. More... | |
| struct | ExternaCfg |
| Arguments for every exter call, where each call reads only the members it needs. More... | |
| struct | MemoriaExternaNs |
| Type of the exter dispatch table. More... | |
Enumerations | |
| enum | mmgr_place { PLACE_DRAM , PLACE_PSRAM , PLACE_FAIL } |
| Where a request should be placed. More... | |
Functions | |
| mmgr_place | mmgr_extern_place (const ExternaCfg *args) |
| Decides whether a request belongs in internal or external memory. | |
| void | mmgr_pingpong_init (const ExternaCfg *args) |
| Points the pair at buffer 0. | |
| uint8_t | mmgr_pingpong_fill_index (const ExternaCfg *args) |
| Returns the index of the buffer being filled. | |
| uint8_t | mmgr_pingpong_drain_index (const ExternaCfg *args) |
| Returns the index of the buffer being drained. | |
| uint8_t | mmgr_pingpong_swap (const ExternaCfg *args) |
| Swaps which buffer is filled and which is drained. | |
Variables | |
| static const MemoriaExternaNs | exter |
| Dispatch table instance named exter. | |
Placement between internal and external memory, and a two-buffer index.
Definition in file memoria_externa.h.
| enum mmgr_place |
Where a request should be placed.
| Enumerator | |
|---|---|
| PLACE_DRAM | Internal memory. |
| PLACE_PSRAM | External memory. |
| PLACE_FAIL | Neither will take it. |
Definition at line 32 of file memoria_externa.h.
| mmgr_place mmgr_extern_place | ( | const ExternaCfg * | args | ) |
Decides whether a request belongs in internal or external memory.
| [in] | args | Request size, the DMA requirement and both memory figures [BORROWS]. |
References mmgr_extern_place().
Referenced by mmgr_extern_place().
| void mmgr_pingpong_init | ( | const ExternaCfg * | args | ) |
Points the pair at buffer 0.
| [in,out] | args | Pair to reset, as args->pingpong [BORROWS]. |
| uint8_t mmgr_pingpong_fill_index | ( | const ExternaCfg * | args | ) |
Returns the index of the buffer being filled.
| [in] | args | Pair to read, as args->pingpong [BORROWS]. |
| uint8_t mmgr_pingpong_drain_index | ( | const ExternaCfg * | args | ) |
Returns the index of the buffer being drained.
| [in] | args | Pair to read, as args->pingpong [BORROWS]. |
| uint8_t mmgr_pingpong_swap | ( | const ExternaCfg * | args | ) |
Swaps which buffer is filled and which is drained.
| [in,out] | args | Pair to flip, as args->pingpong [BORROWS]. |
|
static |
Dispatch table instance named exter.
Definition at line 149 of file memoria_externa.h.