Commit Graph

4535 Commits

Author SHA1 Message Date
Dirk Ziegelmeier
d9eaf6f310 docs: Remove link to example ports again, this should rather go to lwIP wiki... 2016-08-23 09:34:44 +02:00
Axel Lin
42c193821c netbuf: Use memset to zero the allocated memory for netbuf_new
Use memset to zero the allocated memory rather than explicitly init each field.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: goldsimon <goldsimon@gmx.de>
2016-08-23 08:59:11 +02:00
Axel Lin
1c5c96a50a pbuf: Use SYS_ARCH_INC in pbuf_ref()
Use SYS_ARCH_INC to simplify the code.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: goldsimon <goldsimon@gmx.de>
2016-08-23 08:59:10 +02:00
Axel Lin
40f2bed5c4 mem: Simplify the code for try bigger pool in mem_malloc
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: sg <goldsimon@gmx.de>
2016-08-20 11:29:57 +02:00
Dirk Ziegelmeier
21c99b6ebb Add documentation page about example lwIP ports. Start with FreeRTOS from Pavel Pisa. 2016-08-20 09:23:29 +02:00
Axel Lin
a032ccafe7 mem: Fix trivial comment typo about using custom pools
Signed-off-by: Axel Lin <axel.lin@ingics.com>
2016-08-20 09:17:37 +02:00
goldsimon
4f4d16260f minor: fixed typo 2016-08-19 15:40:36 +02:00
goldsimon
6b1e1af3d1 combine MAC filter actions for IGMP and MLD6 (IGMP has compatibility defines for old code, MLD6 filter functions must be adapted) 2016-08-19 13:54:14 +02:00
Axel Lin
b3bae1b44c memp: Fix unused variable build error when MEMP_SANITY_REGION_BEFORE/AFTER is 0
MEMP_SANITY_REGION_BEFORE and MEMP_SANITY_REGION_AFTER can be overridden in
lwipopts.h, if one of it is set to 0 we got build error due to unused variable.

Fix unused variable build error when MEMP_OVERFLOW_CHECK >= 1 &&
(MEMP_SANITY_REGION_BEFORE == 0 || MEMP_SANITY_REGION_AFTER == 0).

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: goldsimon <goldsimon@gmx.de>
2016-08-19 13:47:37 +02:00
Dirk Ziegelmeier
730080f20e Fix doxygen comment in lwip/prot/igmp.h 2016-08-19 13:15:23 +02:00
goldsimon
a189941da6 make igmp/mld6 filter actions an enum and define them in netif.h where the callback function prototypes are defined 2016-08-19 13:10:57 +02:00
Dirk Ziegelmeier
f93a6e3310 Rename lwip/prot/arp.h to lwip/prot/etharp.h for consistence 2016-08-19 13:09:58 +02:00
Dirk Ziegelmeier
5e36815867 init.c: Implement check for correct implementation of struct packing in lwip port 2016-08-19 13:05:51 +02:00
Dirk Ziegelmeier
01d8e5013f Add missing include in prot/igmp.h 2016-08-19 13:02:17 +02:00
Dirk Ziegelmeier
6688033bc4 Move IGMP protocol struct to prot/igmp.h 2016-08-19 12:50:41 +02:00
goldsimon
ed566cceaa minor cleaup in (eth)arp 2016-08-19 12:49:02 +02:00
goldsimon
55d05092ef simplify memp.c code a bit 2016-08-19 12:25:48 +02:00
Axel Lin
0e9ef19cfb memp: Remove memp_overflow_init() function
There is only one caller using memp_overflow_init(), and at that context
calling memp_overflow_init_element() actually simplifes the code.
Thus remove memp_overflow_init() function.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: goldsimon <goldsimon@gmx.de>
2016-08-19 12:25:47 +02:00
Dirk Ziegelmeier
fefb782bfe Apply fix by Marco Veeneman in SNMPv3: The outbound_padding is calculated wrong in snmp_complete_outbound_frame() 2016-08-19 12:22:59 +02:00
Dirk Ziegelmeier
12609c951c Fix compile of SNMPv3 code with MSVC 2016-08-19 12:22:58 +02:00
Axel Lin
64f79e7ffc PPP, PPPoE: Include netif/ethernet.h to fix build error
Fix below build errors:
In file included from ../../../../../lwip/src/include/netif/ppp/ppp_opts.h:31:0,
                 from ../../../../../lwip/src/netif/ppp/pppoe.c:71:
../../../../../lwip/src/netif/ppp/pppoe.c: In function ‘pppoe_timeout’:
../../../../../lwip/src/netif/ppp/pppoe.c:861:30: error: ‘ethbroadcast’ undeclared (first use in this function)
         MEMCPY(&sc->sc_dest, ethbroadcast.addr, sizeof(sc->sc_dest));
                              ^
../../../../../lwip/src/include/lwip/opt.h:137:52: note: in definition of macro ‘MEMCPY’
 #define MEMCPY(dst,src,len)             memcpy(dst,src,len)
                                                    ^
../../../../../lwip/src/netif/ppp/pppoe.c:861:30: note: each undeclared identifier is reported only once for each function it appears in
         MEMCPY(&sc->sc_dest, ethbroadcast.addr, sizeof(sc->sc_dest));
                              ^
../../../../../lwip/src/include/lwip/opt.h:137:52: note: in definition of macro ‘MEMCPY’
 #define MEMCPY(dst,src,len)             memcpy(dst,src,len)
                                                    ^
../../../../../lwip/src/netif/ppp/pppoe.c: In function ‘pppoe_connect’:
../../../../../lwip/src/netif/ppp/pppoe.c:899:24: error: ‘ethbroadcast’ undeclared (first use in this function)
   MEMCPY(&sc->sc_dest, ethbroadcast.addr, sizeof(sc->sc_dest));
                        ^
../../../../../lwip/src/include/lwip/opt.h:137:52: note: in definition of macro ‘MEMCPY’
 #define MEMCPY(dst,src,len)             memcpy(dst,src,len)
                                                    ^
../../Common.mk:94: recipe for target 'pppoe.o' failed
make: *** [pppoe.o] Error 1

Fixes: 8eb9db18a2 ("Reduce usage of netif/ethernet.h header, mostly lwip/prot/ethernet.h is sufficient")
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: goldsimon <goldsimon@gmx.de>
2016-08-19 12:12:57 +02:00
goldsimon
ebd1bf8a49 fixed typo :-( 2016-08-19 11:03:09 +02:00
goldsimon
4a7dafc6a6 fixed compiling mdns.c after moving things to mdns_priv.h 2016-08-19 11:02:37 +02:00
goldsimon
1e6f33d44b tcp: move tcp header flags definitions to 'prot' 2016-08-19 10:41:01 +02:00
goldsimon
96c3c48ba7 mdns: moved private things into mdns_priv.h 2016-08-19 09:52:30 +02:00
goldsimon
14fb48cd7a minor: whitespace cleanups 2016-08-19 09:41:34 +02:00
goldsimon
9725a496b5 moved 2 enums from 'prot' headers to where they belong (dns, dhcp) 2016-08-19 09:41:33 +02:00
Dirk Ziegelmeier
967516aa40 Add #include to netif/ethernet.h to netif/etharp.h to maintian compatibility 2016-08-19 09:15:35 +02:00
Dirk Ziegelmeier
e844159f0a Fix warning in test_etharp.c 2016-08-19 09:03:57 +02:00
Dirk Ziegelmeier
11386a26d9 Fix compile of DHCP unit test 2016-08-19 09:00:35 +02:00
Dirk Ziegelmeier
8eb9db18a2 Reduce usage of netif/ethernet.h header, mostly lwip/prot/ethernet.h is sufficient 2016-08-19 08:36:00 +02:00
sg
43d6812b3e IPv6 addr: clarify tentative count/LWIP_IPV6_DUP_DETECT_ATTEMPTS 2016-08-18 22:02:57 +02:00
Dirk Ziegelmeier
7c0d952379 Add explicit documentation page about reporting bugs 2016-08-18 21:09:34 +02:00
Dirk Ziegelmeier
c4e3be814f Work on bug #48728: headers should cleanly separate API vs. implementation
ARP
2016-08-18 20:58:51 +02:00
Dirk Ziegelmeier
ad357a4c89 Work on bug #48728: headers should cleanly separate API vs. implementation
ICMP
2016-08-18 20:55:09 +02:00
Dirk Ziegelmeier
2d503f4433 Work on bug #48728: headers should cleanly separate API vs. implementation
ICMP6
2016-08-18 20:52:00 +02:00
Dirk Ziegelmeier
5df88220c4 Fix compile of MDNS unit test with GCC 2016-08-18 20:43:33 +02:00
Dirk Ziegelmeier
458211c2af Comment fixes in my last commits 2016-08-18 20:41:39 +02:00
Dirk Ziegelmeier
84e139f20c Work on bug #48728: headers should cleanly separate API vs. implementation
IP6
2016-08-18 20:40:15 +02:00
Dirk Ziegelmeier
81c68f529b Work on bug #48728: headers should cleanly separate API vs. implementation
MLD6
2016-08-18 20:36:44 +02:00
Dirk Ziegelmeier
f299b4b7cf Work on bug #48728: headers should cleanly separate API vs. implementation
Ethernet
2016-08-18 20:33:38 +02:00
Dirk Ziegelmeier
8d68400387 Work on bug #48728: headers should cleanly separate API vs. implementation
ND6
2016-08-18 20:28:03 +02:00
Dirk Ziegelmeier
d89fa2dcbc Work on bug #48728: headers should cleanly separate API vs. implementation
UDP
2016-08-18 20:22:35 +02:00
Dirk Ziegelmeier
16293125a6 Work on bug #48728: headers should cleanly separate API vs. implementation
TCP
2016-08-18 20:22:14 +02:00
Axel Lin
e24fde05db memp: Fix memp_overflow_check_element_overflow assertion
Use LWIP_MEM_ALIGN() in memp_overflow_init() to get alignment address for memp.
This fixes assertion in memp_overflow_check_element_overflow when
MEMP_OVERFLOW_CHECK is set.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
2016-08-18 19:24:34 +02:00
Axel Lin
ef31afb921 memp: Fix build error when LWIP_HOOK_MEMP_AVAILABLE is defined
Fix below build error.

../../../../../lwip/src/core/memp.c: In function ‘memp_free’:
../../../../../lwip/src/core/memp.c:490:31: error: request for member ‘tab’ in something not a structure or union
   old_first = memp_pools[type].tab;
                               ^
../../Common.mk:94: recipe for target 'memp.o' failed
make: *** [memp.o] Error 1

Fixes: de9054cb7a ("memp: cleaned up MEMP_MEM_MALLOC")
Signed-off-by: Axel Lin <axel.lin@ingics.com>
2016-08-18 19:20:26 +02:00
Dirk Ziegelmeier
a8c8e08984 Minor: cleanups in unit test code 2016-08-18 13:02:59 +02:00
Dirk Ziegelmeier
97fae7e41b Code cleanup in autoip.c and dhcp.c 2016-08-18 12:49:59 +02:00
Dirk Ziegelmeier
7f60cb3889 Improve netif client data API for lwIP internal clients - these can use a compile-time constant to access their data now 2016-08-18 12:37:21 +02:00
Dirk Ziegelmeier
ebf7959880 Coding style fixes in netif.c 2016-08-18 11:44:19 +02:00