diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2007-11-22 18:36:46 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2007-11-22 18:36:46 +0000 |
commit | c5148ad9e5d0c44c891f843bc7927bdcce0aee1a (patch) | |
tree | 6f54ddc25051c52d0ce5226bfac63c0054137b7c /nuttx/net/uip/uip-input.c | |
parent | 7d4b2f6253d8ac898def6839b2ccc2ae61e24135 (diff) | |
download | px4-nuttx-c5148ad9e5d0c44c891f843bc7927bdcce0aee1a.tar.gz px4-nuttx-c5148ad9e5d0c44c891f843bc7927bdcce0aee1a.tar.bz2 px4-nuttx-c5148ad9e5d0c44c891f843bc7927bdcce0aee1a.zip |
TCP and ICMP protocols may now be disabled
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@398 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/net/uip/uip-input.c')
-rw-r--r-- | nuttx/net/uip/uip-input.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/nuttx/net/uip/uip-input.c b/nuttx/net/uip/uip-input.c index b8d8ebb7e..6ee748c89 100644 --- a/nuttx/net/uip/uip-input.c +++ b/nuttx/net/uip/uip-input.c @@ -102,8 +102,8 @@ /* Macros. */ -#define BUF ((struct uip_tcpip_hdr *)&dev->d_buf[UIP_LLH_LEN]) -#define FBUF ((struct uip_tcpip_hdr *)&uip_reassbuf[0]) +#define BUF ((struct uip_ip_hdr *)&dev->d_buf[UIP_LLH_LEN]) +#define FBUF ((struct uip_ip_hdr *)&uip_reassbuf[0]) /* IP fragment re-assembly */ @@ -294,9 +294,6 @@ nullreturn: void uip_input(struct uip_driver_s *dev) { - dev->d_snddata = &dev->d_buf[UIP_IPTCPH_LEN + UIP_LLH_LEN]; - dev->d_appdata = &dev->d_buf[UIP_IPTCPH_LEN + UIP_LLH_LEN]; - /* This is where the input processing starts. */ #ifdef CONFIG_NET_STATISTICS @@ -468,9 +465,11 @@ void uip_input(struct uip_driver_s *dev) switch (BUF->proto) { +#ifdef CONFIG_NET_TCP case UIP_PROTO_TCP: /* TCP input */ uip_tcpinput(dev); break; +#endif #ifdef CONFIG_NET_UDP case UIP_PROTO_UDP: /* UDP input */ @@ -480,6 +479,7 @@ void uip_input(struct uip_driver_s *dev) /* Check for ICMP input */ +#ifdef CONFIG_NET_ICMP #ifndef CONFIG_NET_IPv6 case UIP_PROTO_ICMP: /* ICMP input */ #else @@ -487,6 +487,7 @@ void uip_input(struct uip_driver_s *dev) #endif uip_icmpinput(dev); break; +#endif default: /* Unrecognized/unsupported protocol */ #ifdef CONFIG_NET_STATISTICS |