From 7028531e74813b6097045bc0910c94115e517c89 Mon Sep 17 00:00:00 2001 From: Xiang Xiao Date: Sat, 12 Mar 2022 12:26:14 +0800 Subject: [PATCH] net/tcp: Remove tcp_listen_initialize Signed-off-by: Xiang Xiao --- net/net_initialize.c | 4 ---- net/tcp/tcp.h | 14 -------------- net/tcp/tcp_listen.c | 21 --------------------- 3 files changed, 39 deletions(-) diff --git a/net/net_initialize.c b/net/net_initialize.c index 185f354ba5..00c87c4f8d 100644 --- a/net/net_initialize.c +++ b/net/net_initialize.c @@ -137,10 +137,6 @@ void net_initialize(void) #endif #ifdef NET_TCP_HAVE_STACK - /* Initialize the listening port structures */ - - tcp_listen_initialize(); - /* Initialize the TCP/IP connection structures */ tcp_initialize(); diff --git a/net/tcp/tcp.h b/net/tcp/tcp.h index d5ec88cfa0..b45e888ba9 100644 --- a/net/tcp/tcp.h +++ b/net/tcp/tcp.h @@ -830,20 +830,6 @@ void tcp_poll(FAR struct net_driver_s *dev, FAR struct tcp_conn_s *conn); void tcp_timer(FAR struct net_driver_s *dev, FAR struct tcp_conn_s *conn, int hsec); -/**************************************************************************** - * Name: tcp_listen_initialize - * - * Description: - * Setup the listening data structures - * - * Assumptions: - * Called early in the initialization phase while the system is still - * single-threaded. - * - ****************************************************************************/ - -void tcp_listen_initialize(void); - /**************************************************************************** * Name: tcp_findlistener * diff --git a/net/tcp/tcp_listen.c b/net/tcp/tcp_listen.c index 4eb4c9c3f5..ad4397786d 100644 --- a/net/tcp/tcp_listen.c +++ b/net/tcp/tcp_listen.c @@ -145,27 +145,6 @@ FAR struct tcp_conn_s *tcp_findlistener(FAR union ip_binding_u *uaddr, * Public Functions ****************************************************************************/ -/**************************************************************************** - * Name: tcp_listen_initialize - * - * Description: - * Setup the listening data structures - * - * Assumptions: - * Called early in the initialization phase while the system is still - * single-threaded. - * - ****************************************************************************/ - -void tcp_listen_initialize(void) -{ - int ndx; - for (ndx = 0; ndx < CONFIG_NET_MAX_LISTENPORTS; ndx++) - { - tcp_listenports[ndx] = NULL; - } -} - /**************************************************************************** * Name: tcp_unlisten *