mirror of
https://github.com/apache/nuttx.git
synced 2026-05-29 20:56:47 +08:00
net/bufpool: Call init automatically on alloc
Note: Initialize function of protocols (tcp, udp, pkt, etc.) are kept empty. Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
This commit is contained in:
@@ -162,19 +162,6 @@ EXTERN const struct sock_intf_s g_icmp_sockif;
|
||||
|
||||
void icmp_input(FAR struct net_driver_s *dev);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: icmp_sock_initialize
|
||||
*
|
||||
* Description:
|
||||
* Initialize the IPPROTO_ICMP socket connection structures. Called once
|
||||
* and only from the network initialization layer.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_NET_ICMP_SOCKET
|
||||
void icmp_sock_initialize(void);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
* Name: icmp_alloc
|
||||
*
|
||||
|
||||
@@ -72,20 +72,6 @@ static dq_queue_t g_active_icmp_connections;
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Name: icmp_sock_initialize
|
||||
*
|
||||
* Description:
|
||||
* Initialize the IPPROTO_ICMP socket connection structures. Called once
|
||||
* and only from the network initialization layer.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
void icmp_sock_initialize(void)
|
||||
{
|
||||
NET_BUFPOOL_INIT(g_icmp_connections);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: icmp_alloc
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user