37#ifndef LWIP_HDR_SOCKETS_PRIV_H
38#define LWIP_HDR_SOCKETS_PRIV_H
52#define NUM_SOCKETS MEMP_NUM_NETCONN
61union lwip_sock_lastdata {
71 union lwip_sock_lastdata lastdata;
72#if LWIP_SOCKET_SELECT || LWIP_SOCKET_POLL
82 SELWAIT_T select_waiting;
84#if LWIP_NETCONN_FULLDUPLEX
89#define LWIP_SOCK_FD_FREE_TCP 1
90#define LWIP_SOCK_FD_FREE_FREE 2
95#define set_errno(err) do { if (err) { errno = (err); } } while(0)
98#if !LWIP_TCPIP_CORE_LOCKING
100#define LWIP_SETGETSOCKOPT_MAXOPTLEN LWIP_MAX(16, sizeof(struct ifreq))
104struct lwip_setgetsockopt_data {
113#if LWIP_MPU_COMPATIBLE
114 u8_t optval[LWIP_SETGETSOCKOPT_MAXOPTLEN];
134struct lwip_sock* lwip_socket_dbg_get_socket(
int fd);
136#if LWIP_SOCKET_SELECT || LWIP_SOCKET_POLL
138#if LWIP_NETCONN_SEM_PER_THREAD
139#define SELECT_SEM_T sys_sem_t*
140#define SELECT_SEM_PTR(sem) (sem)
142#define SELECT_SEM_T sys_sem_t
143#define SELECT_SEM_PTR(sem) (&(sem))
147struct lwip_select_cb {
149 struct lwip_select_cb *
next;
151 struct lwip_select_cb *prev;
152#if LWIP_SOCKET_SELECT
static unsigned __int64 next