- memory pool area flags simplified

This commit is contained in:
Wiesner András 2023-02-15 14:00:04 +01:00
parent c3e76236a6
commit 704fef911f
2 changed files with 4 additions and 3 deletions

View File

@ -2,9 +2,9 @@
#include "global_state.h" #include "global_state.h"
#include "utils.h" #include "utils.h"
#if !defined(ETHLIB_MEMORY_POOL_ATTRIBUTES) || (ETHLIB_MEMORY_POOL_ATTRIBUTES == none) #if !defined(ETHLIB_MEMORY_POOL_ATTRIBUTES)
static uint8_t sDynMemPool[ETHLIB_MEMORY_POOL_TOTAL_SIZE]; static uint8_t sDynMemPool[ETHLIB_MEMORY_POOL_TOTAL_SIZE];
#elif #else
static uint8_t sDynMemPool[ETHLIB_MEMORY_POOL_TOTAL_SIZE] __attribute__((ETHLIB_MEMORY_POOL_ATTRIBUTES)); static uint8_t sDynMemPool[ETHLIB_MEMORY_POOL_TOTAL_SIZE] __attribute__((ETHLIB_MEMORY_POOL_ATTRIBUTES));
#endif #endif
@ -19,4 +19,4 @@ void * dynmem_alloc_(uint32_t size) {
void dynmem_free_(void * ptr) { void dynmem_free_(void * ptr) {
mp_free(E.mp, ptr); mp_free(E.mp, ptr);
} }

View File

@ -1,6 +1,7 @@
#ifndef ETHERLIB_MSG_QUEUE_H #ifndef ETHERLIB_MSG_QUEUE_H
#define ETHERLIB_MSG_QUEUE_H #define ETHERLIB_MSG_QUEUE_H
#include <stdbool.h>
#include <stdint.h> #include <stdint.h>
#include "packet.h" #include "packet.h"