OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [rtos/] [freertos-6.1.1/] [Demo/] [lwIP_MCF5235_GCC/] [lwipopts.h] - Blame information for rev 792

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 583 jeremybenn
/*
2
 * Copyright (c) 2001-2003 Swedish Institute of Computer Science.
3
 * All rights reserved.
4
 *
5
 * Redistribution and use in source and binary forms, with or without modification,
6
 * are permitted provided that the following conditions are met:
7
 *
8
 * 1. Redistributions of source code must retain the above copyright notice,
9
 *    this list of conditions and the following disclaimer.
10
 * 2. Redistributions in binary form must reproduce the above copyright notice,
11
 *    this list of conditions and the following disclaimer in the documentation
12
 *    and/or other materials provided with the distribution.
13
 * 3. The name of the author may not be used to endorse or promote products
14
 *    derived from this software without specific prior written permission.
15
 *
16
 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
17
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
18
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
19
 * SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
20
 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
21
 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
22
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
23
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
24
 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
25
 * OF SUCH DAMAGE.
26
 *
27
 * This file is part of the lwIP TCP/IP stack.
28
 *
29
 * Author: Adam Dunkels <adam@sics.se>
30
 * Modifications: Christian Walter <wolti@sil.at>
31
 */
32
#ifndef __LWIPOPTS_H__
33
#define __LWIPOPTS_H__
34
 
35
/* ------------------------ Generic options ------------------------------- */
36
#undef  LWIP_NOASSERT
37
 
38
#define SYS_LIGHTWEIGHT_PROT    1
39
#define TCPIP_THREAD_PRIO       3
40
 
41
#define LWIP_DEBUG              1
42
#define DBG_TYPES_ON            ( DBG_LEVEL_WARNING | DBG_LEVEL_SEVERE | DBG_LEVEL_SERIOUS )
43
#define FEC_DEBUG               ( DBG_LEVEL_WARNING | DBG_ON )
44
 
45
/* ------------------------ Memory options -------------------------------- */
46
/* MEM_ALIGNMENT: should be set to the alignment of the CPU for which
47
   lwIP is compiled. 4 byte alignment -> define MEM_ALIGNMENT to 4, 2
48
   byte alignment -> define MEM_ALIGNMENT to 2. */
49
#define MEM_ALIGNMENT           4
50
 
51
/* MEM_SIZE: the size of the heap memory. If the application will send
52
a lot of data that needs to be copied, this should be set high. */
53
#define MEM_SIZE                2000
54
 
55
/* MEMP_NUM_PBUF: the number of memp struct pbufs. If the application
56
   sends a lot of data out of ROM (or other static memory), this
57
   should be set high. */
58
#define MEMP_NUM_PBUF           20
59
/* MEMP_NUM_UDP_PCB: the number of UDP protocol control blocks. One
60
   per active UDP "connection". */
61
#define MEMP_NUM_UDP_PCB        4
62
/* MEMP_NUM_TCP_PCB: the number of simulatenously active TCP
63
   connections. */
64
#define MEMP_NUM_TCP_PCB        10
65
/* MEMP_NUM_TCP_PCB_LISTEN: the number of listening TCP
66
   connections. */
67
#define MEMP_NUM_TCP_PCB_LISTEN 8
68
/* MEMP_NUM_TCP_SEG: the number of simultaneously queued TCP
69
   segments. */
70
#define MEMP_NUM_TCP_SEG        8
71
/* MEMP_NUM_SYS_TIMEOUT: the number of simulateously active
72
   timeouts. */
73
#define MEMP_NUM_SYS_TIMEOUT    3
74
 
75
/* The following four are used only with the sequential API and can be
76
   set to 0 if the application only will use the raw API. */
77
/* MEMP_NUM_NETBUF: the number of struct netbufs. */
78
#define MEMP_NUM_NETBUF         4
79
/* MEMP_NUM_NETCONN: the number of struct netconns. */
80
#define MEMP_NUM_NETCONN        4
81
/* MEMP_NUM_APIMSG: the number of struct api_msg, used for
82
   communication between the TCP/IP stack and the sequential
83
   programs. */
84
#define MEMP_NUM_API_MSG        8
85
/* MEMP_NUM_TCPIPMSG: the number of struct tcpip_msg, which is used
86
   for sequential API communication and incoming packets. Used in
87
   src/api/tcpip.c. */
88
#define MEMP_NUM_TCPIP_MSG      8
89
 
90
/* These two control is reclaimer functions should be compiled
91
   in. Should always be turned on (1). */
92
#define MEM_RECLAIM             1
93
#define MEMP_RECLAIM            1
94
 
95
/* ---------- Pbuf options ---------- */
96
/* PBUF_POOL_SIZE: the number of buffers in the pbuf pool. */
97
#define PBUF_POOL_SIZE          16
98
 
99
/* PBUF_POOL_BUFSIZE: the size of each pbuf in the pbuf pool. */
100
#define PBUF_POOL_BUFSIZE       512
101
 
102
/* PBUF_LINK_HLEN: the number of bytes that should be allocated for a
103
   link level header. */
104
#define PBUF_LINK_HLEN          16
105
 
106
/* ------------------------ TCP options ----------------------------------- */
107
#define LWIP_TCP                1
108
#define TCP_TTL                 255
109
 
110
/* Controls if TCP should queue segments that arrive out of
111
   order. Define to 0 if your device is low on memory. */
112
#define TCP_QUEUE_OOSEQ         1
113
 
114
/* TCP Maximum segment size. */
115
#define TCP_MSS                 512
116
 
117
/* TCP sender buffer space (bytes). */
118
#define TCP_SND_BUF             512
119
 
120
/* TCP sender buffer space (pbufs). This must be at least = 2 *
121
   TCP_SND_BUF/TCP_MSS for things to work. */
122
#define TCP_SND_QUEUELEN        6 * TCP_SND_BUF/TCP_MSS
123
 
124
/* TCP receive window. */
125
#define TCP_WND                 512
126
 
127
/* Maximum number of retransmissions of data segments. */
128
#define TCP_MAXRTX              12
129
 
130
/* Maximum number of retransmissions of SYN segments. */
131
#define TCP_SYNMAXRTX           4
132
 
133
/* ------------------------ ARP options ----------------------------------- */
134
#define ARP_TABLE_SIZE          10
135
#define ARP_QUEUEING            1
136
 
137
/* ------------------------ IP options ------------------------------------ */
138
/* Define IP_FORWARD to 1 if you wish to have the ability to forward
139
   IP packets across network interfaces. If you are going to run lwIP
140
   on a device with only one network interface, define this to 0. */
141
#define IP_FORWARD              1
142
 
143
/* If defined to 1, IP options are allowed (but not parsed). If
144
   defined to 0, all packets with IP options are dropped. */
145
#define IP_OPTIONS              1
146
 
147
/* ------------------------ ICMP options ---------------------------------- */
148
#define ICMP_TTL                255
149
 
150
 
151
/* ------------------------ DHCP options ---------------------------------- */
152
/* Define LWIP_DHCP to 1 if you want DHCP configuration of
153
   interfaces. DHCP is not implemented in lwIP 0.5.1, however, so
154
   turning this on does currently not work. */
155
#define LWIP_DHCP               0
156
 
157
/* 1 if you want to do an ARP check on the offered address
158
   (recommended). */
159
#define DHCP_DOES_ARP_CHECK     1
160
 
161
/* ------------------------ UDP options ----------------------------------- */
162
#define LWIP_UDP                1
163
#define UDP_TTL                 255
164
 
165
/* ------------------------ Statistics options ---------------------------- */
166
#define STATS
167
 
168
#ifdef STATS
169
#define LINK_STATS              1
170
#define IP_STATS                1
171
#define ICMP_STATS              1
172
#define UDP_STATS               1
173
#define TCP_STATS               1
174
#define MEM_STATS               1
175
#define MEMP_STATS              1
176
#define PBUF_STATS              1
177
#define SYS_STATS               1
178
#endif /* STATS */
179
 
180
#define LWIP_PROVIDE_ERRNO      1
181
 
182
#endif /* __LWIPOPTS_H__ */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.