Skip to content

Commit cf64f09

Browse files
authored
Merge pull request #3721 from mikaleppanen/lwip_2_0_1_stable
Lwip 2.0.1 stable
2 parents 30ddefc + 90db9c0 commit cf64f09

File tree

217 files changed

+12903
-4707
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

217 files changed

+12903
-4707
lines changed

features/FEATURE_LWIP/lwip-interface/lwip-eth/arch/TARGET_Freescale/k64f_emac.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -296,10 +296,10 @@ err_t k64f_etharp_output_ipv6(struct netif *netif, struct pbuf *q, const ip6_add
296296
* \param[in] action
297297
* \return ERR_OK or error code
298298
*/
299-
err_t igmp_mac_filter(struct netif *netif, const ip4_addr_t *group, u8_t action)
299+
err_t igmp_mac_filter(struct netif *netif, const ip4_addr_t *group, enum netif_mac_filter_action action)
300300
{
301301
switch (action) {
302-
case IGMP_ADD_MAC_FILTER:
302+
case NETIF_ADD_MAC_FILTER:
303303
{
304304
uint32_t group23 = ntohl(group->addr) & 0x007FFFFF;
305305
uint8_t addr[6];
@@ -312,7 +312,7 @@ err_t igmp_mac_filter(struct netif *netif, const ip4_addr_t *group, u8_t action)
312312
ENET_AddMulticastGroup(ENET, addr);
313313
return ERR_OK;
314314
}
315-
case IGMP_DEL_MAC_FILTER:
315+
case NETIF_DEL_MAC_FILTER:
316316
/* As we don't reference count, silently ignore delete requests */
317317
return ERR_OK;
318318
default:
@@ -330,10 +330,10 @@ err_t igmp_mac_filter(struct netif *netif, const ip4_addr_t *group, u8_t action)
330330
* \param[in] action
331331
* \return ERR_OK or error code
332332
*/
333-
err_t mld_mac_filter(struct netif *netif, const ip6_addr_t *group, u8_t action)
333+
err_t mld_mac_filter(struct netif *netif, const ip6_addr_t *group, enum netif_mac_filter_action action)
334334
{
335335
switch (action) {
336-
case MLD6_ADD_MAC_FILTER:
336+
case NETIF_ADD_MAC_FILTER:
337337
{
338338
uint32_t group32 = ntohl(group->addr[3]);
339339
uint8_t addr[6];
@@ -346,7 +346,7 @@ err_t mld_mac_filter(struct netif *netif, const ip6_addr_t *group, u8_t action)
346346
ENET_AddMulticastGroup(ENET, addr);
347347
return ERR_OK;
348348
}
349-
case MLD6_DEL_MAC_FILTER:
349+
case NETIF_DEL_MAC_FILTER:
350350
/* As we don't reference count, silently ignore delete requests */
351351
return ERR_OK;
352352
default:

features/FEATURE_LWIP/lwip-interface/lwip-sys/arch/cc.h

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -35,24 +35,6 @@
3535
#include <stdint.h>
3636
#include <stddef.h> /* for size_t */
3737

38-
/* Types based on stdint.h */
39-
typedef uint8_t u8_t;
40-
typedef int8_t s8_t;
41-
typedef uint16_t u16_t;
42-
typedef int16_t s16_t;
43-
typedef uint32_t u32_t;
44-
typedef int32_t s32_t;
45-
typedef uintptr_t mem_ptr_t;
46-
47-
/* Define (sn)printf formatters for these lwIP types */
48-
#define U16_F "hu"
49-
#define S16_F "hd"
50-
#define X16_F "hx"
51-
#define U32_F "lu"
52-
#define S32_F "ld"
53-
#define X32_F "lx"
54-
#define SZT_F "uz"
55-
5638
/* ARM/LPC17xx is little endian only */
5739
#if !defined(BYTE_ORDER) || (BYTE_ORDER != LITTLE_ENDIAN && BYTE_ORDER != BIG_ENDIAN)
5840
#ifdef BYTE_ORDER
@@ -97,7 +79,7 @@ typedef uintptr_t mem_ptr_t;
9779
#define LWIP_CHKSUM_ALGORITHM 0
9880

9981
void* thumb2_memcpy(void* pDest, const void* pSource, size_t length);
100-
u16_t thumb2_checksum(const void* pData, int length);
82+
uint16_t thumb2_checksum(const void* pData, int length);
10183
#else
10284
/* Used with IP headers only */
10385
#define LWIP_CHKSUM_ALGORITHM 1

features/FEATURE_LWIP/lwip-interface/lwip/.gitignore

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
/doc/doxygen/output
1+
*.o
2+
*.a
3+
/doc/doxygen/output/html
24
/src/apps/snmp/LwipMibCompiler/CCodeGeneration/bin/
35
/src/apps/snmp/LwipMibCompiler/CCodeGeneration/obj/
46
/src/apps/snmp/LwipMibCompiler/LwipMibCompiler/bin/
@@ -11,3 +13,6 @@
1113
/src/apps/snmp/LwipMibCompiler/SharpSnmpLib/obj/
1214
/src/apps/snmp/LwipMibCompiler/LwipMibCompiler.userprefs
1315
/src/apps/snmp/LwipMibCompiler/*.suo
16+
/test/fuzz/output
17+
/test/fuzz/lwip_fuzz
18+
/test/fuzz/.depend

features/FEATURE_LWIP/lwip-interface/lwip/CHANGELOG

Lines changed: 74 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,77 @@ HISTORY
33
(git master)
44

55
* [Enter new changes just after this line - do not remove this line]
6+
7+
++ New features:
8+
9+
2016-12-31: Simon Goldschmidt
10+
* tcp.h/.c: added function tcp_listen_with_backlog_and_err() to get the error
11+
reason when listening fails (bug #49861)
12+
13+
2016-12-20: Erik Andersen
14+
* Add MQTT client
15+
16+
2016-12-14: Jan Breuer:
17+
* opt.h, ndc.h/.c: add support for RDNSS option (as per RFC 6106)
18+
19+
2016-12-14: David van Moolenbroek
20+
* opt.h, nd6.c: Added LWIP_HOOK_ND6_GET_GW()
21+
22+
2016-12-09: Dirk Ziegelmeier
23+
* ip6_frag.c: Implemented support for LWIP_NETIF_TX_SINGLE_PBUF
24+
25+
2016-12-09: Simon Goldschmidt
26+
* dns.c: added one-shot multicast DNS queries
27+
28+
2016-11-24: Ambroz Bizjak, David van Moolenbroek
29+
* tcp_out.c: Optimize passing contiguous nocopy buffers to tcp_write (bug #46290)
30+
31+
2016-11-16: Dirk Ziegelmeier
32+
* sockets.c: added support for IPv6 mapped IPv4 addresses
33+
34+
++ Bugfixes:
35+
36+
2016-12-16: Thomas Mueller
37+
* api_lib.c: fixed race condition in return value of netconn_gethostbyname()
38+
(and thus also lwip_gethostbyname/_r() and lwip_getaddrinfo())
39+
40+
2016-12-15: David van Moolenbroek
41+
* opt.h, tcp: added LWIP_HOOK_TCP_ISN() to implement less predictable initial
42+
sequence numbers (see contrib/addons/tcp_isn for an example implementation)
43+
44+
2016-12-05: Dirk Ziegelmeier
45+
* fixed compiling with IPv4 disabled (IPv6 only case)
46+
47+
2016-11-28: Simon Goldschmidt
48+
* api_lib.c: fixed bug #49725 (send-timeout: netconn_write() can return
49+
ERR_OK without all bytes being written)
50+
51+
2016-11-28: Ambroz Bizjak
52+
* tcpi_in.c: fixed bug #49717 (window size in received SYN and SYN-ACK
53+
assumed scaled)
54+
55+
2016-11-25: Simon Goldschmidt
56+
* dhcp.c: fixed bug #49676 (Possible endless loop when parsing dhcp options)
57+
58+
2016-11-23: Dirk Ziegelmeier
59+
* udp.c: fixed bug #49662: multicast traffic is now only received on a UDP PCB
60+
(and therefore on a UDP socket/netconn) when the PCB is bound to IP_ADDR_ANY
61+
62+
2016-11-16: Dirk Ziegelmeier
63+
* *: Fixed dual-stack behaviour, IPv6 mapped IPv4 support in socket API
64+
65+
2016-11-14: Joel Cunningham
66+
* tcp_out.c: fixed bug #49533 (start persist timer when unsent seg can't fit
67+
in window)
68+
69+
2016-11-16: Roberto Barbieri Carrera
70+
* autoip.c: fixed bug #49610 (sometimes AutoIP fails to reuse the same address)
71+
72+
2016-11-11: Dirk Ziegelmeier
73+
* sockets.c: fixed bug #49578 (dropping multicast membership does not work
74+
with LWIP_SOCKET_OFFSET)
75+
76+
(STABLE-2.0.0)
677

778
++ New features:
879

@@ -328,8 +399,9 @@ HISTORY
328399

329400
++ Bugfixes:
330401

331-
2016-11-25: Simon Goldschmidt
332-
* dhcp.c: fixed bug #49676 (Possible endless loop when parsing dhcp options)
402+
2016-08-23: Simon Goldschmidt
403+
* etharp: removed ETHARP_TRUST_IP_MAC since it is insecure and we don't need
404+
it any more after implementing unicast ARP renewal towards arp entry timeout
333405

334406
2016-07-20: Simon Goldschmidt
335407
* memp.h/.c: fixed bug #48442 (memp stats don't work for MEMP_MEM_MALLOC)
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
src/ - The source code for the lwIP TCP/IP stack.
22
doc/ - The documentation for lwIP.
3+
test/ - Some code to test whether the sources do what they should.
34

45
See also the FILES file in each subdirectory.

features/FEATURE_LWIP/lwip-interface/lwip/README

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ APPLICATIONS
3535
* HTTP server with SSI and CGI
3636
* SNMPv2c agent with MIB compiler (Simple Network Management Protocol)
3737
* SNTP (Simple network time protocol)
38+
* NetBIOS name service responder
39+
* MDNS (Multicast DNS) responder
40+
* iPerf server implementation
3841

3942

4043
LICENSE
@@ -77,7 +80,7 @@ Self documentation of the source code is regularly extracted from the current
7780
Git sources and is available from this web page:
7881
http://www.nongnu.org/lwip/
7982

80-
There is now a constantly growin wiki about lwIP at
83+
There is now a constantly growing wiki about lwIP at
8184
http://lwip.wikia.com/wiki/LwIP_Uncyclo
8285

8386
Also, there are mailing lists you can subscribe at

features/FEATURE_LWIP/lwip-interface/lwip/UPGRADING

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,14 @@ with newer versions.
88

99
* [Enter new changes just after this line - do not remove this line]
1010

11-
* TODO
11+
(2.0.1)
12+
13+
++ Application changes:
14+
15+
* UDP does NOT receive multicast traffic from ALL netifs on an UDP PCB bound to a specific
16+
netif any more. Users need to bind to IP_ADDR_ANY to receive multicast traffic and compare
17+
ip_current_netif() to the desired netif for every packet.
18+
See bug #49662 for an explanation.
1219

1320
(2.0.0)
1421

@@ -20,7 +27,7 @@ with newer versions.
2027
* Added IPv6 support (dual-stack or IPv4/IPv6 only)
2128
* Changed ip_addr_t to be a union in dual-stack mode (use ip4_addr_t where referring to IPv4 only).
2229
* Major rewrite of SNMP (added MIB parser that creates code stubs for custom MIBs);
23-
supports SNMP2vc (experimental v3 support)
30+
supports SNMPv2c (experimental v3 support)
2431
* Moved some core applications from contrib repository to src/apps (and include/lwip/apps)
2532

2633
+++ Raw API:
@@ -34,7 +41,8 @@ with newer versions.
3441
++ Port changes
3542

3643
+++ new files:
37-
* MANY new and moved files!
44+
* MANY new and moved files!
45+
* Added src/Filelists.mk for use in Makefile projects
3846
* Continued moving stack-internal parts from abc.h to abc_priv.h in sub-folder "priv"
3947
to let abc.h only contain the actual application programmer's API
4048

@@ -45,6 +53,13 @@ with newer versions.
4553
* Added LWIP_NETCONN_SEM_PER_THREAD to use one "op_completed" semaphore per thread
4654
instead of using one per netconn (these semaphores are used even with core locking
4755
enabled as some longer lasting functions like big writes still need to delay)
56+
* Added generalized abstraction for itoa(), strnicmp(), stricmp() and strnstr()
57+
in def.h (to be overridden in cc.h) instead of config
58+
options for netbiosns, httpd, dns, etc. ...
59+
* New abstraction for hton* and ntoh* functions in def.h.
60+
To override them, use the following in cc.h:
61+
#define lwip_htons(x) <your_htons>
62+
#define lwip_htonl(x) <your_htonl>
4863

4964
+++ new options:
5065
* TODO
@@ -56,6 +71,8 @@ with newer versions.
5671
* added hook LWIP_HOOK_MEMP_AVAILABLE() to get informed when a memp pool was empty and an item
5772
is now available
5873

74+
* Signature of LWIP_HOOK_VLAN_SET macro was changed
75+
5976
* LWIP_DECLARE_MEMORY_ALIGNED() may be used to declare aligned memory buffers (mem/memp)
6077
or to move buffers to dedicated memory using compiler attributes
6178

@@ -68,6 +85,7 @@ with newer versions.
6885

6986
* Added IPv6 support (dual-stack or IPv4/IPv6 only)
7087
* Major rewrite of PPP (incl. keep-up with apache pppd)
88+
see doc/ppp.txt for an upgrading how-to
7189
* Major rewrite of SNMP (incl. MIB parser)
7290
* Fixed timing issues that might have lead to losing a DHCP lease
7391
* Made rx processing path more robust against crafted errors
@@ -77,7 +95,7 @@ with newer versions.
7795
* support PBUF_REF for RX packets
7896
* LWIP_NETCONN_FULLDUPLEX allows netconn/sockets to be used for reading/writing from separate
7997
threads each (needs LWIP_NETCONN_SEM_PER_THREAD)
80-
* Moved and reorderd stats (mainly memp/mib2)
98+
* Moved and reordered stats (mainly memp/mib2)
8199

82100
(1.4.0)
83101

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1+
doxygen/ - Configuration files and scripts to create the lwIP doxygen source
2+
documentation (found at http://www.nongnu.org/lwip/)
3+
14
savannah.txt - How to obtain the current development source code.
25
contrib.txt - How to contribute to lwIP as a developer.
36
rawapi.txt - The documentation for the core API of lwIP.
47
Also provides an overview about the other APIs and multithreading.
5-
snmp_agent.txt - The documentation for the lwIP SNMP agent.
68
sys_arch.txt - The documentation for a system abstraction layer of lwIP.
9+
ppp.txt - Documentation of the PPP interface for lwIP.

0 commit comments

Comments
 (0)