Remove uIP logging

git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@377 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
patacongo 2007-11-07 23:26:29 +00:00
parent d622214165
commit f6547ca194
18 changed files with 17 additions and 80 deletions

View File

@ -1364,9 +1364,6 @@ The system can be re-made subsequently by just typing <code>make</code>.
<li>
<code>CONFIG_NET_BUFFER_SIZE</code>: uIP buffer size
</li>
<li>
<code>CONFIG_NET_LOGGING</code>: Logging on or off
</li>
<li>
<code>CONFIG_NET_UDP</code>: UDP support on or off
</li>

View File

@ -218,7 +218,6 @@ defconfig -- This is a configuration file similar to the Linux
CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
CONFIG_NET_BUFFER_SIZE - uIP buffer size
CONFIG_NET_LOGGING - Logging on or off
CONFIG_NET_UDP - UDP support on or off
CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP

View File

@ -258,7 +258,6 @@ CONFIG_PREALLOC_TIMERS=8
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -276,7 +275,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=n
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10

View File

@ -247,7 +247,6 @@ CONFIG_PREALLOC_TIMERS=8
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -265,7 +264,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=n
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10

View File

@ -271,7 +271,6 @@ CONFIG_PREALLOC_TIMERS=8
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -289,7 +288,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=n
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10

View File

@ -256,7 +256,6 @@ CONFIG_PREALLOC_TIMERS=8
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -274,7 +273,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=n
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10
@ -304,7 +302,7 @@ CONFIG_EXAMPLE_NETTEST_CLIENTIP=(10<<24|0<<16|0<<8|1)
# DM90x0 Driver Settings
CONFIG_NET_DM90x0=n
CONFIG_DM9X_NINTERFACES=1
CONFIG_DM9X_STATS=1
CONFIG_DM9X_STATS=n
CONFIG_DM9X_BASE=0xd0000300
CONFIG_DM9X_IRQ=27
CONFIG_DM9X_BUSWIDTH8=n

View File

@ -257,7 +257,6 @@ CONFIG_PREALLOC_TIMERS=8
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -275,7 +274,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=y
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10
@ -305,7 +303,7 @@ CONFIG_EXAMPLE_NETTEST_CLIENTIP=(10<<24|0<<16|0<<8|1)
# DM90x0 Driver Settings
CONFIG_NET_DM90x0=y
CONFIG_DM9X_NINTERFACES=1
CONFIG_DM9X_STATS=1
CONFIG_DM9X_STATS=n
CONFIG_DM9X_BASE=0xd0000300
CONFIG_DM9X_IRQ=27
CONFIG_DM9X_BUSWIDTH8=n

View File

@ -244,7 +244,6 @@ CONFIG_PREALLOC_TIMERS=0
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -262,7 +261,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=n
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10

View File

@ -218,7 +218,6 @@ CONFIG_FS_FAT=y
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -236,7 +235,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=n
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10

View File

@ -219,7 +219,6 @@ CONFIG_FS_FAT=y
# CONFIG_NET_MAX_LISTENPORTS - Maximum number of listening TCP ports (all tasks)
# CONFIG_NET_SOCKOPTS - Enable or disable support for socket options
# CONFIG_NET_BUFFER_SIZE - uIP buffer size
# CONFIG_NET_LOGGING - Logging on or off
# CONFIG_NET_UDP - UDP support on or off
# CONFIG_NET_UDP_CHECKSUMS - UDP checksums on or off
# CONFIG_NET_UDP_CONNS - The maximum amount of concurrent UDP connections
@ -237,7 +236,6 @@ CONFIG_NET_MAX_CONNECTIONS=40
CONFIG_NET_MAX_LISTENPORTS=40
CONFIG_NET_SOCKOPTS=y
CONFIG_NET_BUFFER_SIZE=420
CONFIG_NET_LOGGING=y
CONFIG_NET_UDP=y
CONFIG_NET_UDP_CHECKSUMS=y
#CONFIG_NET_UDP_CONNS=10

View File

@ -102,16 +102,3 @@ int user_start(int argc, char *argv[])
return 0;
}
/****************************************************************************
* uip_log
****************************************************************************/
void uip_log(char *m)
{
/* Since uip_log is called from interrupt handling logic, it cannot use
* or other standard I/O. This should work from an interrupt handler:
*/
lib_rawprintf("uIP log message: %s\n", m);
}

View File

@ -208,15 +208,6 @@ int user_start(int argc, char *argv[])
return 0;
}
void uip_log(char *m)
{
/* Since uip_log is called from interrupt handling logic, it cannot use
* or other standard I/O. This should work from an interrupt handler:
*/
lib_rawprintf("uIP log message: %s\n", m);
}
#if defined(CONFIG_EXAMPLE_UIP_WEBCLIENT)
void webclient_closed(void)
{

View File

@ -960,12 +960,4 @@ extern void uip_udpdisable(struct uip_udp_conn *conn);
(in_addr_t)(dest) = (in_addr_t)(src) & (in_addr_t)(mask); \
} while(0)
/* Print out a uIP log message.
*
* This function must be implemented by the module that uses uIP, and
* is called by uIP whenever a log message is generated.
*/
extern void uip_log(char *msg);
#endif /* __NET_UIP_UIP_H */

View File

@ -110,7 +110,7 @@ void uip_icmpinput(struct uip_driver_s *dev)
if (ICMPBUF->type != ICMP_ECHO)
{
uip_log("icmp: not ICMP echo.");
dbg("Unknown ICMP cmd: %d\n", ICMPBUF->type);
goto typeerr;
}
@ -213,7 +213,7 @@ typeerr:
}
else
{
uip_log("icmp: unknown ICMP6 message.");
dbg("Unknown ICMP6 cmd: %d\n", ICMPBUF->type);
goto typeerr;
}

View File

@ -316,7 +316,7 @@ void uip_input(struct uip_driver_s *dev)
uip_stat.ip.drop++;
uip_stat.ip.vhlerr++;
#endif
uip_log("ipv6: invalid version.");
dbg("Invalid IPv6 version: %d\n", BUF->vtc >> 4);
goto drop;
}
#else /* CONFIG_NET_IPv6 */
@ -330,7 +330,7 @@ void uip_input(struct uip_driver_s *dev)
uip_stat.ip.drop++;
uip_stat.ip.vhlerr++;
#endif
uip_log("ip: invalid version or header length.");
dbg("Invalid IP version or header length: %02x\n", BUF->vhl);
goto drop;
}
#endif /* CONFIG_NET_IPv6 */
@ -359,7 +359,7 @@ void uip_input(struct uip_driver_s *dev)
}
else
{
uip_log("ip: packet shorter than reported in IP header.");
dbg("IP packet shorter than length in IP header\n");
goto drop;
}
@ -379,7 +379,7 @@ void uip_input(struct uip_driver_s *dev)
uip_stat.ip.drop++;
uip_stat.ip.fragerr++;
#endif
uip_log("ip: fragment dropped.");
dbg("IP fragment dropped\n");
goto drop;
#endif /* UIP_REASSEMBLY */
}
@ -395,14 +395,14 @@ void uip_input(struct uip_driver_s *dev)
#if UIP_PINGADDRCONF && !CONFIG_NET_IPv6
if (BUF->proto == UIP_PROTO_ICMP)
{
uip_log("ip: possible ping config packet received.");
dbg("Possible ping config packet received\n");
uip_icmpinput(dev);
goto done;
}
else
#endif /* UIP_PINGADDRCONF */
{
uip_log("ip: packet dropped since no address assigned.");
dbg("No IP address assigned\n");
goto drop;
}
}
@ -457,7 +457,7 @@ void uip_input(struct uip_driver_s *dev)
uip_stat.ip.drop++;
uip_stat.ip.chkerr++;
#endif
uip_log("ip: bad checksum.");
dbg("Bad IP checksum\n");
goto drop;
}
#endif /* CONFIG_NET_IPv6 */
@ -494,7 +494,7 @@ void uip_input(struct uip_driver_s *dev)
uip_stat.ip.protoerr++;
#endif
uip_log("ip: Unrecognized IP protocol.");
dbg("Unrecognized IP protocol\n");
goto drop;
}

View File

@ -192,18 +192,6 @@ EXTERN void uip_udpcallback(struct uip_driver_s *dev);
EXTERN void uip_icmpinput(struct uip_driver_s *dev);
/* UIP logging **************************************************************/
/* This function must be provided by the application if CONFIG_NET_LOGGING
* is defined.
*/
#ifdef CONFIG_NET_LOGGING
EXTERN void uip_log(char *msg);
#else
# define uip_log(m)
#endif
#undef EXTERN
#ifdef __cplusplus
}

View File

@ -115,7 +115,7 @@ void uip_tcpinput(struct uip_driver_s *dev)
uip_stat.tcp.drop++;
uip_stat.tcp.chkerr++;
#endif
uip_log("tcp: bad checksum.");
dbg("Bad TCP checksum\n");
goto drop;
}
@ -179,7 +179,7 @@ void uip_tcpinput(struct uip_driver_s *dev)
#ifdef CONFIG_NET_STATISTICS
uip_stat.tcp.syndrop++;
#endif
uip_log("tcp: found no unused connections.");
dbg("No free TCP connections\n");
goto drop;
}
@ -276,8 +276,7 @@ found:
if (BUF->flags & TCP_RST)
{
uip_connr->tcpstateflags = UIP_CLOSED;
vdbg("TCP state: UIP_CLOSED\n");
uip_log("tcp: got reset, aborting connection.");
dbg("Recvd reset - TCP state: UIP_CLOSED\n");
uip_flags = UIP_ABORT;
uip_tcpcallback(dev);

View File

@ -109,7 +109,7 @@ void uip_udpinput(struct uip_driver_s *dev)
uip_stat.udp.drop++;
uip_stat.udp.chkerr++;
#endif
uip_log("udp: bad checksum.");
dbg("Bad UDP checksum\n");
dev->d_len = 0;
}
else
@ -145,7 +145,7 @@ void uip_udpinput(struct uip_driver_s *dev)
}
else
{
uip_log("udp: no matching connection found");
dbg("No listener on UDP port\n");
dev->d_len = 0;
}
}