From 13d9ee291bab2db27246befc8f1c426713edf8a6 Mon Sep 17 00:00:00 2001 From: chrysn Date: Thu, 15 Jan 2015 11:44:36 +0100 Subject: [PATCH] provide lwip memory resources for more coap_malloc_type --- lwippools.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lwippools.h b/lwippools.h index 4c9c8e36..f6df921a 100644 --- a/lwippools.h +++ b/lwippools.h @@ -12,6 +12,15 @@ #define MEMP_NUM_COAPCONTEXT 1 #endif +#ifndef MEMP_NUM_COAPENDPOINT +#define MEMP_NUM_COAPENDPOINT 1 +#endif + +/* 1 is sufficient as this is very short-lived */ +#ifndef MEMP_NUM_COAPPACKET +#define MEMP_NUM_COAPPACKET 1 +#endif + #ifndef MEMP_NUM_COAPNODE #define MEMP_NUM_COAPNODE 4 #endif @@ -29,6 +38,8 @@ #endif LWIP_MEMPOOL(COAP_CONTEXT, MEMP_NUM_COAPCONTEXT, sizeof(coap_context_t), "COAP_CONTEXT") +LWIP_MEMPOOL(COAP_ENDPOINT, MEMP_NUM_COAPENDPOINT, sizeof(coap_endpoint_t), "COAP_ENDPOINT") +LWIP_MEMPOOL(COAP_PACKET, MEMP_NUM_COAPPACKET, sizeof(coap_packet_t), "COAP_PACKET") LWIP_MEMPOOL(COAP_NODE, MEMP_NUM_COAPNODE, sizeof(coap_queue_t), "COAP_NODE") LWIP_MEMPOOL(COAP_subscription, MEMP_NUM_COAP_SUBSCRIPTION, sizeof(coap_subscription_t), "COAP_subscription") LWIP_MEMPOOL(COAP_RESOURCE, MEMP_NUM_COAPRESOURCE, sizeof(coap_resource_t), "COAP_RESOURCE")