1# Setup for self-contained net testing without requiring a SLIP driver
2CONFIG_NET_TEST=y
3
4# General config
5CONFIG_REQUIRES_FULL_LIBC=y
6
7# Networking config
8CONFIG_NETWORKING=y
9CONFIG_NET_IPV4=y
10CONFIG_NET_IPV6=y
11CONFIG_NET_IPV6_ND=n
12CONFIG_NET_TCP=y
13CONFIG_NET_SOCKETS=y
14CONFIG_ZVFS_OPEN_MAX=10
15
16# Network driver config
17CONFIG_NET_DRIVERS=y
18CONFIG_NET_LOOPBACK=y
19CONFIG_NET_LOOPBACK_MTU=1280
20CONFIG_NET_LOOPBACK_SIMULATE_PACKET_DROP=y
21CONFIG_TEST_RANDOM_GENERATOR=y
22
23CONFIG_MAIN_STACK_SIZE=2048
24CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=2048
25CONFIG_TEST_USERSPACE=y
26
27# Allow tapping into the number of transmitted packets
28CONFIG_NET_MGMT=y
29CONFIG_NET_STATISTICS=y
30CONFIG_NET_STATISTICS_IPV4=y
31CONFIG_NET_STATISTICS_USER_API=y
32
33CONFIG_NET_PKT_RX_COUNT=16
34CONFIG_NET_PKT_TX_COUNT=16
35CONFIG_NET_BUF_RX_COUNT=64
36CONFIG_NET_BUF_TX_COUNT=64
37
38# Reduce the retry count, so the close always finishes within a second
39CONFIG_NET_TCP_RETRY_COUNT=3
40CONFIG_NET_TCP_INIT_RETRANSMISSION_TIMEOUT=120
41CONFIG_NET_TCP_KEEPALIVE=y
42
43CONFIG_ZTEST=y
44CONFIG_ZTEST_STACK_SIZE=2048
45
46CONFIG_NET_CONTEXT_RCVTIMEO=y
47CONFIG_NET_CONTEXT_SNDTIMEO=y
48CONFIG_NET_CONTEXT_RCVBUF=y
49CONFIG_NET_CONTEXT_SNDBUF=y
50
51# If you want to debug the tests, you can get logging using these statements
52#CONFIG_LOG=y
53#CONFIG_LOG_MODE_DEFERRED=y
54#CONFIG_NET_LOG=y
55#CONFIG_NET_TCP_LOG_LEVEL_DBG=y
56
57# Because of userspace and recvmsg() we need some extra heap in order to
58# copy the iovec in the recvmsg tests.
59CONFIG_HEAP_MEM_POOL_SIZE=512
60
61# If using TF-M, disable the BL2 bootloader to save flash-space for the test.
62CONFIG_TFM_BL2=n
63