From 581b67ade30ce5a4e9e4ec2ab491acde6fc4a7aa Mon Sep 17 00:00:00 2001 From: "chao.an" Date: Fri, 31 Dec 2021 15:19:31 +0800 Subject: [PATCH] net: add config to support allocate connect dynamically add config CONFIG_NET_ALLOC_CONNS to support allocate connect. Use this feature if the number of connections can not be determined at compile time. When enabled the stack will be compiled without the static pre-allocate connection list and all connection instances will be dynamically allocated from heap at run time. Signed-off-by: chao.an --- net/Kconfig | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/net/Kconfig b/net/Kconfig index 481fa65c6f..f10f45d211 100644 --- a/net/Kconfig +++ b/net/Kconfig @@ -312,6 +312,16 @@ source "net/ipforward/Kconfig" endmenu # Internet Protocol Selection +config NET_ALLOC_CONNS + bool "Allocate connect instance dynamically" + default n + ---help--- + Enable to allocate connection instances dynamically. + Use this feature if the number of connections can not be determined at + compile time. When enabled the stack will be compiled without the static + pre-allocate connection list and all connection instances will be dynamically + allocated from heap at run time. + source "net/socket/Kconfig" source "net/inet/Kconfig" source "net/pkt/Kconfig"