]> granicus.if.org Git - esp-idf/commitdiff
lwip: add ip frag and reassembly option in menuconfig
authorXiaXiaotian <xiaxiaotian@espressif.com>
Mon, 26 Dec 2016 07:47:20 +0000 (15:47 +0800)
committerXiaXiaotian <xiaxiaotian@espressif.com>
Mon, 26 Dec 2016 07:47:20 +0000 (15:47 +0800)
components/lwip/Kconfig
components/lwip/include/lwip/port/lwipopts.h

index 2e7e31a8a9f584780eacf25d069c88093073c014..9e2b0316747ccc6efc8e8bb2c235171b33aafbb9 100644 (file)
@@ -49,6 +49,19 @@ config LWIP_DHCP_MAX_NTP_SERVERS
                First argument of sntp_setserver/sntp_setservername functions
                is limited to this value. 
 
+config LWIP_IP_FRAG
+    bool "Enable fragment outgoing IP packets"
+    default 0
+    help 
+        Enabling this option allows fragmenting outgoing IP packets if their size
+        exceeds MTU.
+
+config LWIP_IP_REASSEMBLY
+    bool "Enable reassembly incoming fragmented IP packets"
+    default 0
+    help 
+        Enabling this option allows reassemblying incoming fragmented IP packets.
+
 endmenu
 
 
index 8612eb11b0f9b61abb90d41e5652ca6e2e918be9..5000d63ba94f46d5d029b4477c82e47b2ea65658 100755 (executable)
  * this option does not affect outgoing packet sizes, which can be controlled
  * via IP_FRAG.
  */
-#define IP_REASSEMBLY                   0
+#define IP_REASSEMBLY                   CONFIG_LWIP_IP_REASSEMBLY
 
 /**
  * IP_FRAG==1: Fragment outgoing IP packets if their size exceeds MTU. Note
  * that this option does not affect incoming packet sizes, which can be
  * controlled via IP_REASSEMBLY.
  */
-#define IP_FRAG                         0
+#define IP_FRAG                         CONFIG_LWIP_IP_FRAG
 
 /**
  * IP_REASS_MAXAGE: Maximum time (in multiples of IP_TMR_INTERVAL - so seconds, normally)