Gregory Nutt
94f9312150
Networking: Save the IP domain in the connection structure
2015-01-17 13:07:48 -06:00
Gregory Nutt
4a0eb1f0b1
Networking: Calculation of TCP and UDP checksums differ with IPv4 and IPv6
2015-01-17 12:31:39 -06:00
Gregory Nutt
e2933ca4cc
Networking: Oops. Forgot to add a couple of files that were part of an earlier commit
2015-01-17 09:35:27 -06:00
Gregory Nutt
820509eadc
Networking: Fix accept() so that it returns the correct IP address for the selected socket IP domain.
2015-01-17 09:27:05 -06:00
Gregory Nutt
4ad5998db3
net/socket and net/tcp: When we are ready to receive data or when we have outgoing data ready to be sent, we need to the notify the appropriate device driver of this condition. The notifying socket will be configured as either PF_INET or PF_INET6 and must look up the correct driver using the correct IP domain.
2015-01-17 08:33:14 -06:00
Gregory Nutt
2c251d845c
include/net/if.h: Add a bit to the device flags to indicate if the device packet buffer holds an IPv4 or an IPv6 domain packet. Set/clear the flag along with the correct offset to the application payload data as each packet is received.
...
net/socket, net/tcp, net/udp: Add logic to select the domain of the outputgoing packet before sending any UDP or TCP packet. This sets the bit to indicate the IPv4 or IPv6 domain and the correct offset to the output going payload data.
2015-01-17 07:42:09 -06:00
Gregory Nutt
88a0e82934
Networking: Remove field d_sndata from the device structure. It is the same as d_appdata and unnecessary
2015-01-17 05:59:13 -06:00
Gregory Nutt
0f364f6ae6
Networking: Move net/ipv6 to net/neighbor
2015-01-16 16:49:48 -06:00
Gregory Nutt
8f8259a0d6
Networking: UDP and TCP MSS depends on the IP header size (as well as the link layer header size) and cannot be represented with a single value.
2015-01-16 15:03:10 -06:00
Gregory Nutt
2663538b0a
Networking: Replace all references to the macros net_ipaddr_copy, net_ipaddr_hdrcopy, net_ipaddr_cmp, net_ipaddr_hdrcmp, and net_ipaddr_maskcmp with the appropriate IPv4 or IPv6 version of the macro (such as net_ipv4addr_copy). The goal is to support both IPv4 and IPv6 simultaneously. This requires that the macros be distinct and not conditionally defined to one on or the other.
2015-01-16 13:01:08 -06:00
Gregory Nutt
5e938941a6
Networking: Replace all references to net_ipaddr_t with either in_addr_t on net_ipv6addr_t. The goal is to support both IPv4 and IPv6 simultaneously. This requires that the two types be distinct and not conditionally typedef'ed to net_ipaddr_t.
2015-01-16 12:30:18 -06:00
Gregory Nutt
bee89be4f4
Networking: Drivers can have both IPv4 and IPv6 addesses, but a socket can only only one or the other; The socket connnection structures need to include a union of IPv4 and IPv6 addresses for the local address binding and for the remote address connections
2015-01-16 10:01:54 -06:00
Gregory Nutt
fe8b3c5220
Networking: More detangling of IPv6 logic. Next steps will be more invasive and will get moved to a branch
2015-01-16 08:51:18 -06:00
Gregory Nutt
5b45605991
Clean a few more IPv6 compilation issues; Add implementation of net_ipv6_maskcmp()
2015-01-15 15:55:52 -06:00
Gregory Nutt
630366272a
Networking: Seperate tcp_input() and udp_input() into seprate functions tcp_ipv4_input(), tcp_ipv6_input(), udp_ipv4_input(), and upd_ipv6_input() than can deal will the data offsets caused by the differing sizes of the IP header.
2015-01-15 15:06:46 -06:00
Gregory Nutt
60e50ff3b5
Networking: More IPv6 detanglement
2015-01-15 13:08:28 -06:00
Gregory Nutt
5a441ce03b
Networking: Misck IPv6 detanglement
2015-01-15 12:19:44 -06:00
Gregory Nutt
89538ac4a2
- Rename devif_input() ipv4_input()
...
- Copy net/devif/devif_input.c to ipv6_input.c. Remove all IPv4-specific logic.
- Rename net/devif/devif_input.c to ipv4_input.c. Remove all IPv6-specific logic
- Split IPv4 header structure out as net_ipv4hdr_s from net_iphdr_s
2015-01-15 08:03:56 -06:00
Gregory Nutt
a49f0231d2
Networking: A few more IPv6-related fixes
2015-01-14 18:34:28 -06:00
Gregory Nutt
a7ce1279f9
Networking: (1) Copied all ICMP sources files to net/icmpv6 with proper renaming and removal of IPv4 logic, (2) remove IPv6 logic from files in net/icmp, (3) copied include/nuttx/icmp.h to icmpv6.h and removed IPv4 specific logic, (4) removed all IPv6 logic from icmp.h, (5) IP_HDRLEN became IPv4_HDRLEN and IPv6_HDRLEN, (6) ip_chksum() became ipv4_chksum() and ipv6_chksum(), and (7) added partial support for ICMPv6 statistics.
2015-01-14 16:10:38 -06:00
Gregory Nutt
99a18c84ff
Networking: Remove all logic conditioned upon IPv6 from the net/icmp/directory
2015-01-14 14:47:40 -06:00
Gregory Nutt
fcd65e9d7d
Networking: Make a home for ICMPv6
2015-01-14 14:26:50 -06:00
Gregory Nutt
7d68c22d7f
Networking: Add support for IPv6 ioctls
2015-01-14 13:03:12 -06:00
Gregory Nutt
babe9cf08e
Network: Add an IPv4 configuration option. Hardcoded to =y for now, but I would like to be able to select IPv4 and/or IPv6 in the future
2015-01-14 10:51:09 -06:00
Gregory Nutt
a6a9452c05
net/tcp/tcp_conn.c: Fix a logic error when CONFIG_NETDEV_MULTINIC is selected: net_unlock(flags) will be called will an uninitialized variable (2015-01-03).
2015-01-02 12:03:08 -06:00
Gregory Nutt
1aa528a572
More fixes to problems noted by cppcheck. Some are kind of risky; some are real bugs.
2014-11-25 14:10:35 -06:00
Gregory Nutt
6a3a2f466c
Update comments and README
2014-11-24 07:25:40 -06:00
Gregory Nutt
8de38d719a
Fix included IPv6 file name
2014-11-24 07:25:03 -06:00
Gregory Nutt
aa9700c1ab
Update comments and read me
2014-11-23 12:52:18 -06:00
Gregory Nutt
b36dbe1d89
Add logic to netdev_findbyaddr() to return the correct network device for the case where a broadcast address is used. This change caused trivial ripples through other files because additional parameters are required for netdev_findbyaddr() when CONFIG_NET_MULTINIC
2014-11-23 11:00:22 -06:00
Gregory Nutt
43d036f587
Network routing: Refuse to perform routing table lookups for the Broadcast IP address. From Brennan Ashton
2014-11-23 08:36:34 -06:00
Gregory Nutt
d2a323ca19
Back inclusion of ipv6.h
2014-11-22 13:26:27 -06:00
Gregory Nutt
dc7a45ecf8
Extensions to ECP conneciton structure for the case of multiple networks. See additional comments regarding the similar change for UDP
2014-11-22 10:46:37 -06:00
Gregory Nutt
fbd82712da
Add a comment
2014-11-22 09:08:31 -06:00
Gregory Nutt
d76ed2cbc5
Fix UDP routing error in last commit
2014-11-22 09:08:06 -06:00
Gregory Nutt
251249a954
Back out a misconception about INADDR_ANY introduce with some previous commits
2014-11-22 07:55:45 -06:00
Gregory Nutt
80fc094734
Make tcp_listener static scope; it is not used outside of tcp_conn.c
2014-11-22 07:14:17 -06:00
Gregory Nutt
2c2b5e6738
Fix routing of muli-network UDP packets
2014-11-21 17:44:12 -06:00
Gregory Nutt
15c07e0d67
Network: Misc changes to UDP bind logic for the case of multiple networks
2014-11-21 17:00:08 -06:00
Gregory Nutt
4dd021f351
Some ideas for how port assignments might work with multiple network interfaces
2014-11-21 14:21:30 -06:00
Gregory Nutt
fbedc361bb
File missed in previous commit
2014-11-21 14:19:36 -06:00
Gregory Nutt
735aa4289a
Network: Add logic to get a default network device (for the case where are multiple devices). For INADDR_ANY
2014-11-21 14:14:39 -06:00
Gregory Nutt
d297b623b4
Network: Add a file of IPv6 globals
2014-11-21 14:10:25 -06:00
Gregory Nutt
c64cb19861
Move IP header flags from tcp.h to ip.h and rename IP_FLAGS vs TCPFLAGS. The problem fixed here is that there IP flags were not available when TCP was disabled. The IP flags are used in ICMP and IGFMP
2014-11-17 17:16:46 -06:00
Gregory Nutt
8b2b7afdae
Update TODO; Cosmetic changes to comments
2014-11-17 15:34:50 -06:00
Gregory Nutt
57bcb28991
changes for clean build with Ethernet+SLIP
2014-11-16 11:27:53 -06:00
Gregory Nutt
38754a3466
Completes basic changes to support per-device/per-link TCP receive window size
2014-11-16 11:15:21 -06:00
Gregory Nutt
2340d46d20
Rename NET_LL_MTU to NET_DEV_MTU; rename d_llmtu to d_mtu
2014-11-16 10:42:19 -06:00
Gregory Nutt
859748a94e
Completes conversion of CONFIG_NET_BUFIZE to CONFIG_NET_ETH/SLIP_MTU
2014-11-16 09:22:38 -06:00
Gregory Nutt
ca7486d7f3
Add link MTU size to network device structure.
2014-11-16 08:49:14 -06:00
Gregory Nutt
51adb90e9a
Network: Update SLIP configuration; Fix compile issues when building SLIP only
2014-11-15 14:36:49 -06:00
Gregory Nutt
daa94934eb
Network: netdev_register() must assign the device name appropriately according to the link layer type
2014-11-15 14:21:11 -06:00
Gregory Nutt
08de18c1a6
Network: Various fixes for clean compile with both Ethernet and SLIP
2014-11-15 13:52:39 -06:00
Gregory Nutt
2e55db369d
Network: All logic will now handle varialbe length link layer protocol headers within incoming packets. This permits use of multiple network interfaces with differing data links. For example, ETHERNET + SLIP
2014-11-15 13:13:23 -06:00
Gregory Nutt
a831ab21bc
Merge remote-tracking branch 'origin/master' into llhdrlen
2014-11-15 10:04:49 -06:00
Gregory Nutt
ebb6fd1e9c
Resove merge conflicts
2014-11-15 10:04:33 -06:00
Gregory Nutt
25d787ff12
Remove use of NET_LL_HDRLEN from net/arp logic. Use ETH_HDRLEN instead
2014-11-15 09:13:50 -06:00
Gregory Nutt
2b758537ea
Network: Misc fixes for clean complete with both Ethernet and SLIP enabled
2014-11-15 08:55:50 -06:00
Gregory Nutt
388ef8db1a
Netwoek: Ada a parameter to netdev_register() to indicate the link protocol supported by the driver. Use this value to replace some logic commited yesterday
2014-11-15 08:22:51 -06:00
Gregory Nutt
64d18bfe12
NET: Fix some some more ARP/Ethernet releated configuration
2014-11-14 21:22:45 -06:00
Gregory Nutt
0d7c378e4e
Costmetic change
2014-11-14 18:51:57 -06:00
Gregory Nutt
ebdff66c8b
ARP: Add support for the case where there are multiple networks: One being Etherenet and the other not (say slip or perhaps someday PPP). In that case, we need to suppress ARP-related operations on the SLIP/PPP interface only
2014-11-14 18:25:33 -06:00
Gregory Nutt
e03c764d92
I don't think that the net_route function has ever worked correctly. The source ip was updated in the match struct instead of the route ip. From Brennan Ashton.
2014-11-14 16:45:25 -06:00
Gregory Nutt
8e5ae2ee18
EFM32: Fix typo in connecting ODD GPIO interrupt. Noted by Pierre
2014-11-08 06:18:21 -06:00
Gregory Nutt
ae3cc327c7
AIO now also supports socket transfers
2014-10-11 08:15:23 -06:00
Gregory Nutt
0abe6c66d7
Update everything under nuttx/net to use the corrected syslog interfaces
2014-10-08 10:48:11 -06:00
Gregory Nutt
d914f3ceec
Major structure of file system functions to better support asynchronous I/O. Respository should not be trusted until I have a chance to verify everything
2014-10-06 10:53:25 -06:00
Gregory Nutt
205260d5e2
Reanem kzalloc to kmm_zalloc for consistency
2014-08-31 17:34:44 -06:00
Gregory Nutt
1780810d3d
Rename kmalloc to kmm_malloc for consistency
2014-08-31 17:26:36 -06:00
Gregory Nutt
54fa3b0b59
Rename kfree to kmm_free for consistency with other naming conventions
2014-08-31 17:04:02 -06:00
Gregory Nutt
ad9b3f8ab8
wdog.h does not contain any application interface, only internal OS interface. Further, it is non-standard. Move wdog.h from include/ to include/nuttx. For the same reason, move the description of the watchdog timer interfaces from the Users Guide to the Porting Guide.
2014-08-21 11:16:55 -06:00
Gregory Nutt
21add71646
ARP reuestion logc needs to do the right thing if (1) the address is a broadcast or multicast address, and (2) if the IP address lies outside of the network. Thanks to Manuel Stuehn
2014-08-20 07:09:02 -06:00
Gregory Nutt
27cc2a3fc3
ARP request logic is no longer EXPERIMENTAL
2014-08-20 07:07:24 -06:00
Gregory Nutt
8e84282c05
ARP: Fix bid conversion from msec to nsec
2014-08-19 08:37:14 -06:00
Gregory Nutt
a9ca05266b
Update ChangeLog
2014-08-19 07:52:52 -06:00
Gregory Nutt
9662f1750c
ARP: Add signal logic so that we do not have to wait so long with the network responses to ARP requests quickly
2014-08-19 07:47:32 -06:00
Gregory Nutt
4bba611dc6
Move some internal networking function protoypes out of the public include/nuttx/net/arp.h into to the private net/arp/arp.h
2014-08-18 16:35:20 -06:00
Gregory Nutt
6e04518e4a
If CONFIG_NET_ARP_SEND is enabled, then all ICMP, TCP, and UDP send operations will call arp_send() before attempting the real send operation. arp_send() will check if the the IP address mapping is in the ARP table and, if not send ARP requests periodically until it is. This eliminates losing the first outgoing message because there is not mapping in the ARP table.
2014-08-18 16:22:14 -06:00
Gregory Nutt
548fda7834
arp_poll(): inished the implementation of logic to send ARP requests. Complete, fully hooked into the networking logic, and ready for test (but still untested)
2014-08-18 15:24:51 -06:00
Gregory Nutt
b440fa18ca
arp_send.c: Partial implementation of logic to send ARP requests to assure that an IP address mapping is present in the ARP table
2014-08-18 14:29:02 -06:00
Gregory Nutt
ec429fdf00
PKT sockets: Change how the IFF_NOARP flag is handled. This should be set only when data is moved into the buffer and cleared after tested by the ARP logic. Setting it globally can cause packets to be sent with no valid MAC addresses
2014-08-18 13:42:51 -06:00
Gregory Nutt
1a7e1fb93b
arp_format.c: Move the logic that formats an ARP packet into a separate file where it can be re-used.
2014-08-18 12:37:40 -06:00
Gregory Nutt
1323ab9352
Move arp_arpin() from arp_inout.c to its own file. Rename arp_inout.c to arpipin.c because that is all that is left in the file
2014-08-18 11:36:39 -06:00
Gregory Nutt
6f1d354ef1
Move arp_out() from arp_inout.c to its own file
2014-08-18 11:21:53 -06:00
Gregory Nutt
985c016150
ARP: Add missing configuration option to select dumping of ARP packet headers. Move ARP dumping logic from arp_inout.c to its own file
2014-08-18 11:08:15 -06:00
Gregory Nutt
057af36c1d
More of the PHY event notification logic change: Fix some compile errors when full feature is enabled; Add some missing ioctol logic
2014-08-16 15:04:09 -06:00
Gregory Nutt
eb5e2e4b20
Finishes the ioctl definition to subscribe to PHY events. Revamp network ioctl signature to support arguments other than struct mii_ioctl_data.
2014-08-16 14:08:04 -06:00
Gregory Nutt
e463730c2f
A little too much was deleted in a recent commit
2014-08-16 12:52:28 -06:00
Gregory Nutt
79e098b20e
Clean missing function headers
2014-08-16 10:24:06 -06:00
Gregory Nutt
caba61999a
Remove CONFIG_DISABLE_CLOCK
2014-08-07 12:35:24 -06:00
Gregory Nutt
cab24a4bd8
Add inclusion of assert.h to so files that use DEBUGASSERT
2014-07-21 18:46:47 -06:00
Gregory Nutt
4f60bfb485
IOB: Change suggested by Rony Xln
2014-07-08 07:13:50 -06:00
Gregory Nutt
178b2b0cbe
NET: Important fix to the read-ahead buffer queue managment: Consumed bytes were being trimmed from the head of the queue, but the queue head itself was not being updated. From Rony XLN
2014-07-07 07:28:17 -06:00
Gregory Nutt
e89eac6365
NET: Fix a few problems after big merge of network reorganization
2014-07-06 17:58:36 -06:00
Gregory Nutt
73f3ecf7e2
NET: Rename network interrupt event flags more appropriately: TCP_, UDP_, ICMP_, or PKT_ vs UIP_
2014-07-06 17:22:02 -06:00
Gregory Nutt
a251259f90
NET: Rename some non-configurable constants UIP_ to IP_ or TCP_
2014-07-06 16:19:26 -06:00
Gregory Nutt
b77fda2c95
NET: Rename TCP state values: UIP_ -> TCP_
2014-07-06 16:10:26 -06:00
Gregory Nutt
1f11a452dd
NET: Add a few missing configuration options to the Kconfig files
2014-07-06 13:04:27 -06:00
Gregory Nutt
2d52d70d4c
NET: Move private definitions from include/nuttx/net/tcp to net/tcp/tcp.h
2014-07-06 12:34:27 -06:00
Gregory Nutt
9e87ab90b8
NET: Move private definitions from include/nuttx/net/arp.h to net/arp/arp.h
2014-07-06 11:05:28 -06:00