mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-01-06 09:56:38 +00:00
Make SYS_LIGHTWEIGHT_PROT==1 the default since it's more often used like that and it's more safe as default; improved some option's comments
This commit is contained in:
parent
f98c3dd4b5
commit
6e6ce4fb78
@ -52,17 +52,21 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* SYS_LIGHTWEIGHT_PROT==1: if you want inter-task protection for certain
|
* SYS_LIGHTWEIGHT_PROT==1: enable inter-task protection (and task-vs-interrupt
|
||||||
* critical regions during buffer allocation, deallocation and memory
|
* protection) for certain critical regions during buffer allocation, deallocation
|
||||||
* allocation and deallocation.
|
* and memory allocation and deallocation.
|
||||||
|
* ATTENTION: This is required when using lwIP from more than one context! If
|
||||||
|
* you disable this, you must be sure what you are doing!
|
||||||
*/
|
*/
|
||||||
#ifndef SYS_LIGHTWEIGHT_PROT
|
#ifndef SYS_LIGHTWEIGHT_PROT
|
||||||
#define SYS_LIGHTWEIGHT_PROT 0
|
#define SYS_LIGHTWEIGHT_PROT 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* NO_SYS==1: Provides VERY minimal functionality. Otherwise,
|
* NO_SYS==1: Use lwIP without OS-awareness (no thread, semaphores, mutexes or
|
||||||
* use lwIP facilities.
|
* mboxes). This means threaded APIs cannot be used (socket, netconn,
|
||||||
|
* i.e. everything in the 'api' folder), only the callback-style raw API is
|
||||||
|
* available (and you have to watch out for yourself that
|
||||||
*/
|
*/
|
||||||
#ifndef NO_SYS
|
#ifndef NO_SYS
|
||||||
#define NO_SYS 0
|
#define NO_SYS 0
|
||||||
@ -96,7 +100,8 @@
|
|||||||
* LWIP_MPU_COMPATIBLE: enables special memory management mechanism
|
* LWIP_MPU_COMPATIBLE: enables special memory management mechanism
|
||||||
* which makes lwip able to work on MPU (Memory Protection Unit) system
|
* which makes lwip able to work on MPU (Memory Protection Unit) system
|
||||||
* by not passing stack-pointers to other threads
|
* by not passing stack-pointers to other threads
|
||||||
* (this decreases performance)
|
* (this decreases performance as memory is allocated from pools instead
|
||||||
|
* of keeping it on the stack)
|
||||||
*/
|
*/
|
||||||
#ifndef LWIP_MPU_COMPATIBLE
|
#ifndef LWIP_MPU_COMPATIBLE
|
||||||
#define LWIP_MPU_COMPATIBLE 0
|
#define LWIP_MPU_COMPATIBLE 0
|
||||||
@ -119,7 +124,11 @@
|
|||||||
/**
|
/**
|
||||||
* MEMP_MEM_MALLOC==1: Use mem_malloc/mem_free instead of the lwip pool allocator.
|
* MEMP_MEM_MALLOC==1: Use mem_malloc/mem_free instead of the lwip pool allocator.
|
||||||
* Especially useful with MEM_LIBC_MALLOC but handle with care regarding execution
|
* Especially useful with MEM_LIBC_MALLOC but handle with care regarding execution
|
||||||
* speed and usage from interrupts!
|
* speed (heap alloc can be much slower than pool alloc) and usage from interrupts
|
||||||
|
* (especially if your netif driver allocates PBUF_POOL pbufs for received frames
|
||||||
|
* from interrupt)!
|
||||||
|
* ATTENTION: Currently, this uses the heap for ALL pools (also for private pools,
|
||||||
|
* not only for internal pools defined in memp_std.h)!
|
||||||
*/
|
*/
|
||||||
#ifndef MEMP_MEM_MALLOC
|
#ifndef MEMP_MEM_MALLOC
|
||||||
#define MEMP_MEM_MALLOC 0
|
#define MEMP_MEM_MALLOC 0
|
||||||
|
Loading…
Reference in New Issue
Block a user