From 8cd8607510ca423089ca1b0266c22aeee685dcee Mon Sep 17 00:00:00 2001 From: patacongo Date: Thu, 20 Nov 2008 19:24:06 +0000 Subject: Add support for TCP/IP connection backlog git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1294 42af7a65-404d-4744-a932-0658087f49c3 --- nuttx/examples/README.txt | 5 +++++ nuttx/examples/poll/Makefile | 2 +- nuttx/examples/poll/poll_main.c | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) (limited to 'nuttx/examples') diff --git a/nuttx/examples/README.txt b/nuttx/examples/README.txt index f6528e5f4..f2a597800 100644 --- a/nuttx/examples/README.txt +++ b/nuttx/examples/README.txt @@ -118,6 +118,11 @@ examples/poll CONFIG_EXAMPLE_POLL_DRIPADDR - Default router IP addess CONFIG_EXAMPLE_POLL_NETMASK - Network mask + In order to for select to work with incoming connections, you + must also select: + + CONFIG_NET_TCPBACKLOG - Incoming connections pend in a backlog until accept() is called. + In additional to the target device-side example, there is also a host-side application in this directory. It can be compiled under Linux or Cygwin as follows: diff --git a/nuttx/examples/poll/Makefile b/nuttx/examples/poll/Makefile index b52719912..e91f5018c 100644 --- a/nuttx/examples/poll/Makefile +++ b/nuttx/examples/poll/Makefile @@ -70,6 +70,6 @@ clean: $(call CLEAN) distclean: clean - @rm -f Make.dep .depend + @rm -f Make.dep .depend host -include Make.dep diff --git a/nuttx/examples/poll/poll_main.c b/nuttx/examples/poll/poll_main.c index 713c77e3a..dbf5eec65 100644 --- a/nuttx/examples/poll/poll_main.c +++ b/nuttx/examples/poll/poll_main.c @@ -156,7 +156,7 @@ int user_start(int argc, char *argv[]) } #ifdef HAVE_NETPOLL -#if 0 /* select doesn't work for connections yet */ +#ifdef CONFIG_NET_TCPBACKLOG message("user_start: Starting net_listener thread\n"); ret = pthread_create(&tid3, NULL, net_listener, NULL); -- cgit v1.2.3