37 #ifndef LWIP_HDR_SOCKETS_PRIV_H
38 #define LWIP_HDR_SOCKETS_PRIV_H
52 #define NUM_SOCKETS MEMP_NUM_NETCONN
58 #define SELWAIT_T u8_t
61 union lwip_sock_lastdata {
62 struct netbuf *netbuf;
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))
104 struct lwip_setgetsockopt_data {
113 #if LWIP_MPU_COMPATIBLE
114 u8_t optval[LWIP_SETGETSOCKOPT_MAXOPTLEN];
134 struct 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))
147 struct lwip_select_cb {
149 struct lwip_select_cb *next;
151 struct lwip_select_cb *prev;
152 #if LWIP_SOCKET_SELECT
162 struct pollfd *poll_fds;
uint8_t u8_t
Definition: arch.h:125
uint16_t u16_t
Definition: arch.h:127
int16_t s16_t
Definition: arch.h:128