Change how TCP read-ahead is selected to better integrate with TCP write buffering
This commit is contained in:
parent
b889cae796
commit
af14026800
@ -1183,6 +1183,7 @@ examples/poll
|
||||
CONFIG_NET - Defined for general network support
|
||||
CONFIG_NET_TCP - Defined for TCP/IP support
|
||||
CONFIG_NSOCKET_DESCRIPTORS - Defined to be greater than 0
|
||||
CONFIG_NET_TCP_READAHEAD - Defined
|
||||
CONFIG_NET_NTCP_READAHEAD_BUFFERS - Defined to be greater than zero
|
||||
|
||||
CONFIG_EXAMPLES_POLL_NOMAC - (May be defined to use software assigned MAC)
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* examples/poll/poll_internal.h
|
||||
*
|
||||
* Copyright (C) 2008, 2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2008, 2009, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -33,8 +33,8 @@
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __EXAMPLES_PIPE_PIPE_H
|
||||
#define __EXAMPLES_PIPE_PIPE_H
|
||||
#ifndef __EXAMPLES_POLL_POLL_INTERNAL_H
|
||||
#define __EXAMPLES_POLL_POLL_INTERNAL_H
|
||||
|
||||
/****************************************************************************
|
||||
* Compilation Switches
|
||||
@ -57,15 +57,15 @@
|
||||
/* Here are all of the configuration settings that must be met to have TCP/IP
|
||||
* poll/select support. This kind of looks like overkill.
|
||||
*
|
||||
* CONFIG_NET - Network support must be enabled
|
||||
* CONFIG_NSOCKET_DESCRIPTORS - Socket descriptors must be allocated
|
||||
* CONFIG_NET_TCP - Only support on TCP (because read-ahead
|
||||
* ibuffering s not yet support for UDP)
|
||||
* CONFIG_NET_NTCP_READAHEAD_BUFFERS - TCP/IP read-ahead buffering must be enabled
|
||||
* CONFIG_NET - Network support must be enabled
|
||||
* CONFIG_NSOCKET_DESCRIPTORS - Socket descriptors must be allocated
|
||||
* CONFIG_NET_TCP - Only support on TCP (because read-ahead
|
||||
* buffering s not yet support for UDP)
|
||||
* CONFIG_NET_TCP_READAHEAD - TCP/IP read-ahead buffering must be enabled
|
||||
*/
|
||||
|
||||
#if defined(CONFIG_NET) && CONFIG_NSOCKET_DESCRIPTORS > 0 && \
|
||||
defined(CONFIG_NET_TCP) && CONFIG_NET_NTCP_READAHEAD_BUFFERS > 0
|
||||
defined(CONFIG_NET_TCP) && defined(CONFIG_NET_TCP_READAHEAD)
|
||||
# define HAVE_NETPOLL 1
|
||||
#else
|
||||
# undef HAVE_NETPOLL
|
||||
@ -125,4 +125,4 @@ extern void *select_listener(pthread_addr_t pvarg);
|
||||
extern void *net_listener(pthread_addr_t pvarg);
|
||||
extern void *net_reader(pthread_addr_t pvarg);
|
||||
#endif
|
||||
#endif /* __EXAMPLES_PIPE_PIPE_H */
|
||||
#endif /* __EXAMPLES_POLL_POLL_INTERNAL_H */
|
||||
|
@ -53,7 +53,7 @@
|
||||
#undef CONFIG_THTTPD
|
||||
#if defined(CONFIG_NET) && defined(CONFIG_NET_TCP) && \
|
||||
defined(CONFIG_NET_TCPBACKLOG) && !defined(CONFIG_DISABLE_ENVIRONMENT) && \
|
||||
!defined(CONFIG_SDCLONE_DISABLE) && CONFIG_NET_NTCP_READAHEAD_BUFFERS > 0
|
||||
!defined(CONFIG_SDCLONE_DISABLE) && defined(CONFIG_NET_TCP_READAHEAD)
|
||||
|
||||
# define CONFIG_THTTPD 1
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user