diff --git a/examples/cc3000/telnetd_daemon.c b/examples/cc3000/telnetd_daemon.c index 6793fc512..893e34c1b 100644 --- a/examples/cc3000/telnetd_daemon.c +++ b/examples/cc3000/telnetd_daemon.c @@ -175,7 +175,7 @@ static int telnetd_daemon(int argc, char *argv[]) for (;;) { - nllinfo("Accepting connections on port %d\n", ntohs(daemon->port)); + ninfo("Accepting connections on port %d\n", ntohs(daemon->port)); addrlen = sizeof(struct sockaddr_in); acceptsd = accept(listensd, (struct sockaddr*)&myaddr, &addrlen); @@ -199,7 +199,7 @@ static int telnetd_daemon(int argc, char *argv[]) /* Create a character device to "wrap" the accepted socket descriptor */ - nllinfo("Creating the telnet driver\n"); + ninfo("Creating the telnet driver\n"); devpath = telnetd_driver(acceptsd, daemon); if (devpath == NULL) { @@ -209,7 +209,7 @@ static int telnetd_daemon(int argc, char *argv[]) /* Open the driver */ - nllinfo("Opening the telnet driver\n"); + ninfo("Opening the telnet driver\n"); drvrfd = open(devpath, O_RDWR); if (drvrfd < 0) { @@ -238,7 +238,7 @@ static int telnetd_daemon(int argc, char *argv[]) * will inherit the new stdin, stdout, and stderr. */ - nllinfo("Starting the telnet session\n"); + ninfo("Starting the telnet session\n"); pid = task_create("Telnet session", daemon->priority, daemon->stacksize, daemon->entry, NULL); if (pid < 0) diff --git a/examples/cc3000/telnetd_driver.c b/examples/cc3000/telnetd_driver.c index 513486fc8..dfaad577e 100644 --- a/examples/cc3000/telnetd_driver.c +++ b/examples/cc3000/telnetd_driver.c @@ -227,12 +227,12 @@ static ssize_t telnetd_receive(FAR struct telnetd_dev_s *priv, FAR const char *s int nread; uint8_t ch; - nllinfo("srclen: %d destlen: %d\n", srclen, destlen); + ninfo("srclen: %d destlen: %d\n", srclen, destlen); for (nread = 0; srclen > 0 && nread < destlen; srclen--) { ch = *src++; - nllinfo("ch=%02x state=%d\n", ch, priv->td_state); + ninfo("ch=%02x state=%d\n", ch, priv->td_state); switch (priv->td_state) { @@ -412,7 +412,7 @@ static int telnetd_open(FAR struct file *filep) int tmp; int ret; - nllinfo("td_crefs: %d\n", priv->td_crefs); + ninfo("td_crefs: %d\n", priv->td_crefs); /* O_NONBLOCK is not supported */ @@ -468,7 +468,7 @@ static int telnetd_close(FAR struct file *filep) FAR char *devpath; int ret; - nllinfo("td_crefs: %d\n", priv->td_crefs); + ninfo("td_crefs: %d\n", priv->td_crefs); /* Get exclusive access to the device structures */ @@ -547,7 +547,7 @@ static ssize_t telnetd_read(FAR struct file *filep, FAR char *buffer, size_t len FAR struct telnetd_dev_s *priv = inode->i_private; ssize_t ret; - nllinfo("len: %d\n", len); + ninfo("len: %d\n", len); /* First, handle the case where there are still valid bytes left in the * I/O buffer from the last time that read was called. NOTE: Much of @@ -620,7 +620,7 @@ static ssize_t telnetd_write(FAR struct file *filep, FAR const char *buffer, siz char ch; bool eol; - nllinfo("len: %d\n", len); + ninfo("len: %d\n", len); /* Process each character from the user buffer */ diff --git a/examples/helloxx/helloxx_main.cxx b/examples/helloxx/helloxx_main.cxx index f91e9a9a5..8a1db396e 100644 --- a/examples/helloxx/helloxx_main.cxx +++ b/examples/helloxx/helloxx_main.cxx @@ -63,20 +63,9 @@ #endif #ifdef CONFIG_DEBUG_CXX -# define cxxdbg _err -# define cxxllerr llerr -# ifdef CONFIG_DEBUG_INFO -# define cxxinfo _info -# define cxxllinfo llinfo -# else -# define cxxinfo(x...) -# define cxxllinfo(x...) -# endif +# define cxxinfo _info #else -# define cxxdbg(x...) -# define cxxllerr(x...) # define cxxinfo(x...) -# define cxxllinfo(x...) #endif //*************************************************************************** @@ -88,17 +77,17 @@ class CHelloWorld public: CHelloWorld(void) : mSecret(42) { - cxxdbg("Constructor: mSecret=%d\n", mSecret); + cxxinfo("Constructor: mSecret=%d\n", mSecret); } ~CHelloWorld(void) { - cxxdbg("Destructor\n"); + cxxinfo("Destructor\n"); } bool HelloWorld(void) { - cxxdbg("HelloWorld: mSecret=%d\n", mSecret); + cxxinfo("HelloWorld: mSecret=%d\n", mSecret); if (mSecret != 42) { diff --git a/netutils/ping/icmpv6_ping.c b/netutils/ping/icmpv6_ping.c index abad366b9..d9cc7881d 100644 --- a/netutils/ping/icmpv6_ping.c +++ b/netutils/ping/icmpv6_ping.c @@ -95,7 +95,7 @@ static void icmpv6_echo_request(FAR struct net_driver_s *dev, uint16_t reqlen; int i; - nllinfo("Send ECHO request: seqno=%d\n", pstate->png_seqno); + ninfo("Send ECHO request: seqno=%d\n", pstate->png_seqno); /* Set up the IPv6 header (most is probably already in place) */ diff --git a/netutils/telnetd/telnetd_daemon.c b/netutils/telnetd/telnetd_daemon.c index 9b386c63f..69815f346 100644 --- a/netutils/telnetd/telnetd_daemon.c +++ b/netutils/telnetd/telnetd_daemon.c @@ -241,7 +241,7 @@ static int telnetd_daemon(int argc, char *argv[]) for (;;) { - nllinfo("Accepting connections on port %d\n", ntohs(daemon->port)); + ninfo("Accepting connections on port %d\n", ntohs(daemon->port)); addrlen = sizeof(struct sockaddr_in); acceptsd = accept(listensd, (struct sockaddr*)&myaddr, &addrlen); @@ -287,7 +287,7 @@ static int telnetd_daemon(int argc, char *argv[]) /* Create a character device to "wrap" the accepted socket descriptor */ - nllinfo("Creating the telnet driver\n"); + ninfo("Creating the telnet driver\n"); session.ts_sd = acceptsd; session.ts_devpath[0] = '\0'; @@ -303,7 +303,7 @@ static int telnetd_daemon(int argc, char *argv[]) /* Open the driver */ - nllinfo("Opening the telnet driver at %s\n", session.ts_devpath); + ninfo("Opening the telnet driver at %s\n", session.ts_devpath); drvrfd = open(session.ts_devpath, O_RDWR); if (drvrfd < 0) { @@ -328,7 +328,7 @@ static int telnetd_daemon(int argc, char *argv[]) * will inherit the new stdin, stdout, and stderr. */ - nllinfo("Starting the telnet session\n"); + ninfo("Starting the telnet session\n"); pid = task_create("Telnet session", daemon->priority, daemon->stacksize, daemon->entry, NULL); if (pid < 0) diff --git a/netutils/thttpd/fdwatch.c b/netutils/thttpd/fdwatch.c index 43b08f2cd..221e41065 100644 --- a/netutils/thttpd/fdwatch.c +++ b/netutils/thttpd/fdwatch.c @@ -57,33 +57,24 @@ ****************************************************************************/ /* Debug output from this file is normally suppressed. If enabled, be aware - * that output to stdout will interfere with CGI programs (you could use the - * the low-level debug (llerr) functions which probably do not use stdout + * that output to stdout will interfere with CGI programs. */ #ifdef CONFIG_THTTPD_FDWATCH_DEBUG # ifdef CONFIG_CPP_HAVE_VARARGS # define fwdbg(format, ...) nerr(format, ##__VA_ARGS__) -# define fwllerr(format, ...) nllerr(format, ##__VA_ARGS__) # define fwinfo(format, ...) ninfo(format, ##__VA_ARGS__) -# define fwllinfo(format, ...) nllinfo(format, ##__VA_ARGS__) # else # define fwdbg nerr -# define fwllerr nllerr # define fwinfo ninfo -# define fwllinfo nllinfo # endif #else # ifdef CONFIG_CPP_HAVE_VARARGS # define fwdbg(x...) -# define fwllerr(x...) # define fwinfo(x...) -# define fwllinfo(x...) # else # define fwdbg (void) -# define fwllerr (void) -# define fwinfo (void) -# define fwllinfo (void) +# define fwinfo (void) # endif #endif @@ -141,7 +132,7 @@ static int fdwatch_pollndx(FAR struct fdwatch_s *fw, int fd) } } - fwdbg("No poll index for fd %d: %d\n", fd); + fwerr("ERROR: No poll index for fd %d: %d\n", fd); return -1; } @@ -160,7 +151,7 @@ struct fdwatch_s *fdwatch_initialize(int nfds) fw = (struct fdwatch_s*)zalloc(sizeof(struct fdwatch_s)); if (!fw) { - fwdbg("Failed to allocate fdwatch\n"); + fwerr("ERROR: Failed to allocate fdwatch\n"); return NULL; } @@ -229,7 +220,7 @@ void fdwatch_add_fd(struct fdwatch_s *fw, int fd, void *client_data) if (fw->nwatched >= fw->nfds) { - fwdbg("too many fds\n"); + fwerr("ERROR: too many fds\n"); return; } diff --git a/netutils/thttpd/thttpd_cgi.c b/netutils/thttpd/thttpd_cgi.c index 5e57190f7..6487ec861 100644 --- a/netutils/thttpd/thttpd_cgi.c +++ b/netutils/thttpd/thttpd_cgi.c @@ -366,14 +366,14 @@ static inline int cgi_interpose_input(struct cgi_conn_s *cc) ssize_t nbytes_read; ssize_t nbytes_written; - nllinfo("nbytes: %d contentlength: %d\n", cc->inbuf.nbytes, cc->inbuf.contentlength); + ninfo("nbytes: %d contentlength: %d\n", cc->inbuf.nbytes, cc->inbuf.contentlength); if (cc->inbuf.nbytes < cc->inbuf.contentlength) { do { nbytes_read = read(cc->connfd, cc->inbuf.buffer, MIN(CONFIG_THTTPD_CGIINBUFFERSIZE, cc->inbuf.contentlength - cc->inbuf.nbytes)); - nllinfo("nbytes_read: %d\n", nbytes_read); + ninfo("nbytes_read: %d\n", nbytes_read); if (nbytes_read < 0) { if (errno != EINTR) @@ -388,7 +388,7 @@ static inline int cgi_interpose_input(struct cgi_conn_s *cc) if (nbytes_read > 0) { nbytes_written = httpd_write(cc->wrfd, cc->inbuf.buffer, nbytes_read); - nllinfo("nbytes_written: %d\n", nbytes_written); + ninfo("nbytes_written: %d\n", nbytes_written); if (nbytes_written != nbytes_read) { nllerr("ERROR: httpd_write failed\n"); @@ -447,7 +447,7 @@ static inline int cgi_interpose_output(struct cgi_conn_s *cc) /* Loop while there are things we can do without waiting for more input */ - nllinfo("state: %d\n", cc->outbuf.state); + ninfo("state: %d\n", cc->outbuf.state); switch (cc->outbuf.state) { case CGI_OUTBUFFER_READHEADER: @@ -461,7 +461,7 @@ static inline int cgi_interpose_output(struct cgi_conn_s *cc) */ nbytes_read = read(cc->rdfd, cc->inbuf.buffer, CONFIG_THTTPD_CGIINBUFFERSIZE); - nllinfo("Read %d bytes from fd %d\n", nbytes_read, cc->rdfd); + ninfo("Read %d bytes from fd %d\n", nbytes_read, cc->rdfd); if (nbytes_read < 0) { @@ -485,7 +485,7 @@ static inline int cgi_interpose_output(struct cgi_conn_s *cc) if (nbytes_read <= 0) { - nllinfo("End-of-file\n"); + ninfo("End-of-file\n"); br = &(cc->outbuf.buffer[cc->outbuf.len]); cc->outbuf.state = CGI_OUTBUFFER_HEADERREAD; } @@ -497,14 +497,14 @@ static inline int cgi_interpose_output(struct cgi_conn_s *cc) (void)memcpy(&(cc->outbuf.buffer[cc->outbuf.len]), cc->inbuf.buffer, nbytes_read); cc->outbuf.len += nbytes_read; cc->outbuf.buffer[cc->outbuf.len] = '\0'; - nllinfo("Header bytes accumulated: %d\n", cc->outbuf.len); + ninfo("Header bytes accumulated: %d\n", cc->outbuf.len); /* Check for end of header */ if ((br = strstr(cc->outbuf.buffer, "\r\n\r\n")) != NULL || (br = strstr(cc->outbuf.buffer, "\012\012")) != NULL) { - nllinfo("End-of-header\n"); + ninfo("End-of-header\n"); cc->outbuf.state = CGI_OUTBUFFER_HEADERREAD; } else @@ -559,7 +559,7 @@ static inline int cgi_interpose_output(struct cgi_conn_s *cc) /* Write the status line. */ - nllinfo("Status: %d\n", status); + ninfo("Status: %d\n", status); switch (status) { case 200: @@ -643,7 +643,7 @@ static inline int cgi_interpose_output(struct cgi_conn_s *cc) */ nbytes_read = read(cc->rdfd, cc->inbuf.buffer, CONFIG_THTTPD_CGIINBUFFERSIZE); - nllinfo("Read %d bytes from fd %d\n", nbytes_read, cc->rdfd); + ninfo("Read %d bytes from fd %d\n", nbytes_read, cc->rdfd); if (nbytes_read < 0) { @@ -667,7 +667,7 @@ static inline int cgi_interpose_output(struct cgi_conn_s *cc) if (nbytes_read == 0) { - nllinfo("End-of-file\n"); + ninfo("End-of-file\n"); cc->outbuf.state = CGI_OUTBUFFER_DONE; return 1; } @@ -713,7 +713,7 @@ static int cgi_child(int argc, char **argv) * all file descriptors */ - nllinfo("Started: %s\n", argv[1]); + ninfo("Started: %s\n", argv[1]); /* Allocate memory and initialize memory for interposing */ @@ -746,7 +746,7 @@ static int cgi_child(int argc, char **argv) * now prevents re-use of fd=0 and 1 by pipe(). */ - nllinfo("Closing descriptors\n"); + ninfo("Closing descriptors\n"); for (fd = 3; fd < (CONFIG_NFILE_DESCRIPTORS + CONFIG_NSOCKET_DESCRIPTORS); fd++) { /* Keep hc->conn_fd open for obvious reasons */ @@ -764,7 +764,7 @@ static int cgi_child(int argc, char **argv) * socket to the CGI program. */ - nllinfo("Create STDIN pipe\n"); + ninfo("Create STDIN pipe\n"); ret = pipe(pipefd); if (ret < 0) { @@ -795,7 +795,7 @@ static int cgi_child(int argc, char **argv) if (ret == 0) { - nllinfo("Create STDOUT pipe\n"); + ninfo("Create STDOUT pipe\n"); ret = pipe(pipefd); if (ret < 0) { @@ -857,7 +857,7 @@ static int cgi_child(int argc, char **argv) /* Run the CGI program. */ - nllinfo("Starting CGI: %s\n", hc->expnfilename); + ninfo("Starting CGI: %s\n", hc->expnfilename); #ifdef CONFIG_THTTPD_NXFLAT child = exec(hc->expnfilename, (FAR char * const *)argp, g_thttpdsymtab, g_thttpdnsymbols); @@ -891,7 +891,7 @@ static int cgi_child(int argc, char **argv) /* Send any data that is already buffer to the CGI task */ nbytes = hc->read_idx - hc->checked_idx; - nllinfo("nbytes: %d contentlength: %d\n", nbytes, hc->contentlength); + ninfo("nbytes: %d contentlength: %d\n", nbytes, hc->contentlength); if (nbytes > 0) { if (httpd_write(cc->wrfd, &(hc->read_buf[hc->checked_idx]), nbytes) != nbytes) @@ -909,7 +909,7 @@ static int cgi_child(int argc, char **argv) indone = false; outdone = false; - nllinfo("Interposing\n"); + ninfo("Interposing\n"); cgi_semgive(); /* Not safe to reference hc after this point */ do { @@ -921,7 +921,7 @@ static int cgi_child(int argc, char **argv) { /* Transfer data from the client to the CGI program (POST) */ - nllinfo("Interpose input\n"); + ninfo("Interpose input\n"); indone = cgi_interpose_input(cc); if (indone) { @@ -935,7 +935,7 @@ static int cgi_child(int argc, char **argv) { /* Handle receipt of headers and CGI program response (GET) */ - nllinfo("Interpose output\n"); + ninfo("Interpose output\n"); outdone = cgi_interpose_output(cc); } @@ -949,7 +949,7 @@ static int cgi_child(int argc, char **argv) else if (kill(child, 0) != 0) { - nllinfo("CGI no longer running: %d\n", errno); + ninfo("CGI no longer running: %d\n", errno); outdone = true; } } @@ -977,7 +977,7 @@ errout_with_cgiconn: httpd_free(cc); errout: - nllinfo("Return %d\n", errcode); + ninfo("Return %d\n", errcode); if (errcode != 0) { INTERNALERROR("errout"); @@ -1074,7 +1074,7 @@ static void cgi_kill(ClientData client_data, struct timeval *nowP) /* task_delete() is a very evil API. It can leave memory stranded! */ - nllinfo("Killing CGI child: %d\n", pid); + ninfo("Killing CGI child: %d\n", pid); if (task_delete(pid) != 0) { nllerr("ERROR: task_delete() failed: %d\n", errno); diff --git a/nshlib/nsh_netinit.c b/nshlib/nsh_netinit.c index 0adec1467..b8adb2ca9 100644 --- a/nshlib/nsh_netinit.c +++ b/nshlib/nsh_netinit.c @@ -366,14 +366,14 @@ static void nsh_netinit_signal(int signo, FAR siginfo_t *siginfo, /* What is the count on the semaphore? Don't over-post */ ret = sem_getvalue(&g_notify_sem, &semcount); - nllinfo("Entry: semcount=%d\n", semcount); + ninfo("Entry: semcount=%d\n", semcount); if (ret == OK && semcount <= 0) { sem_post(&g_notify_sem); } - nllinfo("Exit\n"); + ninfo("Exit\n"); } #endif diff --git a/system/ubloxmodem/ubloxmodem_main.c b/system/ubloxmodem/ubloxmodem_main.c index f9a897515..aecddf90b 100644 --- a/system/ubloxmodem/ubloxmodem_main.c +++ b/system/ubloxmodem/ubloxmodem_main.c @@ -62,16 +62,10 @@ # define m_err _err # define m_warn _llwarn # define m_info _info -# define m_llerr _llerr -# define m_llwarn _llwarn -# define m_llinfo _llinfo #else # define m_err(x...) # define m_warn(x...) # define m_info(x...) -# define m_llerr(x...) -# define m_llwarn(x...) -# define m_llinfo(x...) #endif #define UBLOXMODEM_MAX_REGISTERS 16