nuttx/net/Kconfig

318 lines
8.7 KiB
Plaintext
Raw Normal View History

#
# For a description of the syntax of this configuration file,
# see the file kconfig-language.txt in the NuttX tools repository.
#
config ARCH_HAVE_NET
bool
default n
config ARCH_HAVE_PHY
bool
default n
config NET
bool "Networking support"
default n
select ARCH_HAVE_NET
---help---
Enable or disable all network features
if NET
config NET_PROMISCUOUS
bool "Promiscuous mode"
default n
---help---
Force the Ethernet driver to operate in promiscuous mode (if supported
by the Ethernet driver).
menu "Driver buffer configuration"
config NET_ETH_MTU
int "Ethernet packet buffer size (MTU)"
default 1294 if NET_IPv6
default 590 if !NET_IPv6
depends on NET_ETHERNET
range 590 1518
---help---
Packet buffer size. This size includes the TCP/UDP payload plus the
size of TCP/UDP header, the IP header, and the Ethernet header.
This value is normally referred to as the MTU (Maximum Transmission
Unit); the payload is the MSS (Maximum Segment Size).
IPv4 hosts are required to be able to handle an MSS of at least
536 octets, resulting in a minimum buffer size of 536+20+20+14 =
590.
IPv6 hosts are required to be able to handle an MSS of 1220 octets,
resulting in a minimum buffer size of of 1220+20+40+14 = 1294
config NET_ETH_TCP_RECVWNDO
int "Ethernet TCP receive window size"
default 1220 if NET_IPv6
default 536 if !NET_IPv6
depends on NET_ETHERNET && NET_TCP
---help---
The size of the advertised receiver's window. Should be set low
(i.e., to the size of the MSS) if the application is slow to process
incoming data, or high (32768 bytes) if the application processes
data quickly.
config NET_SLIP_MTU
int # "SLIP packet buffer size (MTU)"
default 296
depends on NET_SLIP
range 296 1518
---help---
Provides the size of the SLIP packet buffers. This size includes
the TCP/UDP payload plus the size of TCP/UDP header and the IP header.
This value is normally referred to as the MTU (Maximum Transmission Unit);
the payload payload is the MSS (Maximum Segment Size).
SLIP is required to support at lest 256+20+20 = 296. Values other than
296 are not recommended.
The Linux slip module hard-codes its MTU size to 296 (40 bytes for
the IP+TPC headers plus 256 bytes of data). So you might as well
set CONFIG_NET_SLIP_MTU to 296 as well.
There may be an issue with this setting, however. I see that Linux
uses a MTU of 296 and window of 256, but actually only sends 168
bytes of data: 40 + 128. I believe that is to allow for the 2x
worst cast packet expansion. Ideally we would like to advertise the
256 MSS, but restrict transfers to 128 bytes (possibly by modifying
the MSS value in the TCP connection structure).
config NET_SLIP_TCP_RECVWNDO
int "SLIP TCP receive window size"
default 256
depends on NET_SLIP && NET_TCP
---help---
The size of the advertised receiver's window. Should be set low
(i.e., to the size of the MSS) if the application is slow to process
incoming data, or high (32768 bytes) if the application processes
data quickly.
config NET_GUARDSIZE
int "Driver I/O guard size"
default 2
---help---
Network drivers often receive packets with garbage at the end and
are longer than the size of packet in the TCP header. The following
"fudge" factor increases the size of the I/O buffering by a small
amount to allocate slightly oversize packets. After receipt, the
packet size will be chopped down to the size indicated in the TCP
header.
endmenu # Driver buffer configuration
menu "Data link support"
config NET_MULTILINK
bool
default n
2014-06-01 17:40:23 +02:00
2015-03-11 13:52:56 +01:00
config NET_USER_DEVFMT
bool "User provided devfmt"
default n
depends on EXPERIMENTAL
---help---
netdev_register will get devfmt form d_ifname if it is initialized.
2014-06-01 17:40:23 +02:00
config NET_ETHERNET
bool "Ethernet support"
default y
select NETDEV_MULTINIC if NET_6LOWPAN || NET_LOOPBACK || NET_SLIP || NET_TUN
select NET_MULTILINK if NET_6LOWPAN || NET_LOOPBACK || NET_SLIP || NET_TUN
2014-06-01 17:40:23 +02:00
---help---
If NET_SLIP is not selected, then Ethernet will be used (there is
no need to define anything special in the configuration file to use
Ethernet -- it is the default).
menuconfig NET_6LOWPAN
bool "IEEE 802.15.4 6LoWPAN support"
default n
select NETDEV_MULTINIC if NET_ETHERNET || NET_LOOPBACK || NET_SLIP || NET_TUN
select NET_MULTILINK if NET_ETHERNET || NET_LOOPBACK || NET_SLIP || NET_TUN
depends on EXPERIMENTAL && NET_IPv6
---help---
Enable support for IEEE 802.15.4 Low power Wireless Personal Area
Networking (6LoWPAN).
config NET_LOOPBACK
bool "Local loopback"
default n
select NETDEV_MULTINIC if NET_ETHERNET || NET_6LOWPAN || NET_SLIP || NET_TUN
select NET_MULTILINK if NET_ETHERNET || NET_6LOWPAN || NET_SLIP || NET_TUN
---help---
Add support for the local network loopback device, lo.
config NET_SLIP
bool "SLIP support"
default n
select NETDEV_MULTINIC if NET_ETHERNET || NET_6LOWPAN || NET_LOOPBACK || NET_TUN
select NET_MULTILINK if NET_ETHERNET || NET_6LOWPAN || NET_LOOPBACK || NET_TUN
---help---
Enables building of the SLIP driver. SLIP requires
at least one IP protocol selected.
SLIP supports point-to-point IP communications over a serial port.
The default data link layer for network layer is Ethernet. If
NET_SLIP is defined in the NuttX configuration file, then SLIP will
be supported. The basic differences between the SLIP and Ethernet
configurations is that when SLIP is selected:
* The link level header (that comes before the IP header) is omitted.
* All MAC address processing is suppressed.
* ARP is disabled.
If NET_SLIP is not selected, then Ethernet will be used (there is
no need to define anything special in the configuration file to use
Ethernet -- it is the default).
if NET_SLIP
config SLIP_NINTERFACES
int "Number of SLIP interfaces"
default 1
---help---
Selects the number of physical SLIP
interfaces to support.
Default: 1
config SLIP_STACKSIZE
int "SLIP stack size"
default 2048
---help---
Select the stack size of the SLIP RX and TX tasks. Default: 2048
config SLIP_DEFPRIO
int "SLIP priority"
default 128
---help---
The priority of the SLIP RX and TX tasks. Default: 128
endif # NET_SLIP
2015-03-11 13:52:56 +01:00
config NET_TUN
bool "TUN Virtual Network Device support"
default n
select NETDEV_MULTINIC if NET_ETHERNET || NET_6LOWPAN || NET_LOOPBACK || NET_SLIP
select NET_MULTILINK if NET_ETHERNET || NET_6LOWPAN || NET_LOOPBACK || NET_SLIP
select ARCH_HAVE_NETDEV_STATISTICS
2015-03-11 13:52:56 +01:00
if NET_TUN
config TUN_NINTERFACES
int "Number of TUN interfaces"
default 1
range 1 8
---help---
Selects the number of TUN
interfaces to support.
Default: 1
config NET_TUN_MTU
int "TUN packet buffer size (MTU)"
default 296
range 296 1518
config NET_TUN_TCP_RECVWNDO
int "TUN TCP receive window size"
default 256
depends on NET_TCP
choice
prompt "Work queue"
default LOOPBACK_LPWORK if SCHED_LPWORK
default TUN_HPWORK if !SCHED_LPWORK && SCHED_HPWORK
depends on SCHED_WORKQUEUE
---help---
Work queue support is required to use the TUN driver. If the
low priority work queue is available, then it should be used by the
TUN driver.
config TUN_HPWORK
bool "High priority"
depends on SCHED_HPWORK
config TUN_LPWORK
bool "Low priority"
depends on SCHED_LPWORK
endchoice # Work queue
2015-03-11 13:52:56 +01:00
endif # NET_TUN
config NET_USRSOCK
bool "User-space networking stack API"
default n
---help---
Enable or disable user-space networking stack support.
User-space networking stack API allows user-space daemon to
provide TCP/IP stack implementation for NuttX network.
Main use for this is to allow use and integration of
HW-provided TCP/IP stacks for NuttX.
For example, user-space daemon can translate /dev/usrsock API
requests to HW TCP/IP API requests while rest of the user-space
can access standard socket API, with socket descriptors that
can be used with NuttX system calls.
endmenu # Data link support
source "net/netdev/Kconfig"
menu "Internet Protocol Selection"
config NET_IPv4
bool "IPv4"
default y
---help---
Build in support for IPv4.
menuconfig NET_IPv6
bool "IPv6"
default n
---help---
Build in support for IPv6.
source "net/neighbor/Kconfig"
source "net/sixlowpan/Kconfig"
endmenu # Internet Protocol Selection
source "net/socket/Kconfig"
source "net/pkt/Kconfig"
source "net/local/Kconfig"
source "net/tcp/Kconfig"
source "net/udp/Kconfig"
source "net/icmp/Kconfig"
2015-01-14 21:26:50 +01:00
source "net/icmpv6/Kconfig"
source "net/igmp/Kconfig"
source "net/arp/Kconfig"
source "net/loopback/Kconfig"
source "net/iob/Kconfig"
source "net/procfs/Kconfig"
source "net/usrsock/Kconfig"
source "net/utils/Kconfig"
config NET_STATISTICS
bool "Collect network statistics"
default n
---help---
Network layer statistics on or off
source "net/route/Kconfig"
config NET_HOSTNAME
string "Host name for current machine"
default ""
---help---
A unique name to identify device on the network
endif # NET