net: add config menus for LwIP stat options
authorEunBong Song <eunb.song@samsung.com>
Tue, 21 Mar 2017 04:15:28 +0000 (13:15 +0900)
committerHeesub Shin <heesub.shin@samsung.com>
Mon, 17 Apr 2017 10:58:10 +0000 (19:58 +0900)
This patch adds for config menu for LwIP stat options.

Change-Id: I6db9427f0a61c219ed1e02fede6129df4ae04167
Signed-off-by: EunBong Song <eunb.song@samsung.com>
build/configs/sidk_s5jt200/sidk_tash_wlan/defconfig
os/include/net/lwip/lwipopts.h
os/net/lwip/Kconfig

index 1658b71..6c65fa8 100755 (executable)
@@ -703,6 +703,18 @@ CONFIG_NET_LWIP_LOOPBACK_INTERFACE=y
 # CONFIG_NET_LWIP_PPP_SUPPORT is not set
 # CONFIG_NET_LWIP_SNMP is not set
 # CONFIG_NET_LWIP_DEBUG is not set
+CONFIG_NET_LWIP_STATS=y
+CONFIG_NET_LWIP_STATS_DISPLAY=y
+CONFIG_NET_LWIP_STATS_LINK=y
+CONFIG_NET_LWIP_STATS_ARP=y
+CONFIG_NET_LWIP_STATS_IP=y
+CONFIG_NET_LWIP_STATS_IPFRAG=y
+# CONFIG_NET_LWIP_STATS_ICMP is not set
+# CONFIG_NET_LWIP_STATS_IGMP is not set
+CONFIG_NET_LWIP_STATS_UDP=y
+CONFIG_NET_LWIP_STATS_TCP=y
+CONFIG_NET_LWIP_STATS_MEM=y
+CONFIG_NET_LWIP_STATS_SYS=y
 CONFIG_NET_SECURITY_TLS=y
 # CONFIG_TLS_WITH_SSS is not set
 CONFIG_NET_NOINTS=y
index bbd4c2f..f7ff27e 100644 (file)
 /* Thread options */
 
 /* ---------- Debug options ---------- */
-
 #ifdef CONFIG_NET_LWIP_DEBUG
 #define LWIP_DEBUG                      1
 
 
 #endif
 
+/* ---------- Debug options ---------- */
+
 
+/* ---------- Stat options ---------- */
+#ifdef CONFIG_NET_LWIP_STATS
 #define LWIP_STATS                      1
-#define LWIP_COMPAT_MUTEX               1
-#define LWIP_STATS_DISPLAY              1
 
+#ifdef CONFIG_NET_LWIP_STATS_DISPLAY
+#define  LWIP_STATS_DISPLAY             1
+#else
+#define  LWIP_STATS_DISPLAY             0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_LINK
+#define  LINK_STATS                     1
+#else
+#define  LINK_STATS                     0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_ARP
+#define  ETHARP_STATS                   1
+#else
+#define  ETHARP_STATS                   0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_IP
+#define  IP_STATS                       1
+#else
+#define  IP_STATS                       0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_IPFRAG
+#define  IPFRAG_STATS                   1
+#else
+#define  IPFRAG_STATS                   0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_ICMP
+#define  ICMP_STATS                     1
+#else
+#define  ICMP_STATS                     0
+#endif
+
+
+#ifdef CONFIG_NET_LWIP_STATS_IGMP
+#define  IGMP_STATS                     1
+#else
+#define  IGMP_STATS                     0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_UDP
+#define  UDP_STATS                      1
+#else
+#define  UDP_STATS                      0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_TCP
+#define  TCP_STATS                      1
+#else
+#define  TCP_STATS                      0
+#endif
+
+#ifdef CONFIG_NET_LWIP_STATS_MEM
+#define  MEM_STATS                      1
+#else
+#define  MEM_STATS                      0
+#endif
+
+
+#ifdef CONFIG_NET_LWIP_STATS_SYS
+#define  SYS_STATS                      1
+#else
+#define  SYS_STATS                      0
+#endif
+
+#else
+#define LWIP_STATS                      0
+#endif
+/* ---------- Stat options ---------- */
+
+
+#define LWIP_COMPAT_MUTEX               1
 #endif                                                 /* __LWIP_LWIPOPTS_H__ */
index e5b5e8f..d637fae 100644 (file)
@@ -676,4 +676,56 @@ config NET_LWIP_DEBUG_SNMP_MIB
 
 endif #NET_LWIP_DEBUG
 
+menuconfig NET_LWIP_STATS
+       bool "LwIP stats options"
+       default y
+
+if NET_LWIP_STATS
+
+config NET_LWIP_STATS_DISPLAY
+       bool "Compile in the statistics output functions"
+       default n
+
+config NET_LWIP_STATS_LINK
+       bool "Enable link stats"
+       default y
+
+config NET_LWIP_STATS_ARP
+       bool "Enable ARP stats"
+       default y
+
+config NET_LWIP_STATS_IP
+       bool "Enable IP stats"
+       default y
+
+config NET_LWIP_STATS_IPFRAG
+       bool "Enable IP fragmentation stats"
+       default y
+
+config NET_LWIP_STATS_ICMP
+       bool "Enable ICMP stats"
+       default n
+
+config NET_LWIP_STATS_IGMP
+       bool "Enable IGMP stats"
+       default n
+
+config NET_LWIP_STATS_UDP
+       bool "Enable UDP stats"
+       default y
+
+config NET_LWIP_STATS_TCP
+       bool "Enable TCP stats"
+       default y
+
+config NET_LWIP_STATS_MEM
+       bool "Enable MEM stats"
+       default y
+
+config NET_LWIP_STATS_SYS
+       bool "Enable Sys stats"
+       default y
+
+endif #NET_LWIP_STATS
+
 endmenu #LwIP options