Changeset ae481e0 in mainline for uspace/srv/net/tl/tcp/tcp_type.h
- Timestamp:
- 2011-12-29T14:47:00Z (12 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2943db4
- Parents:
- 827ec41
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/tl/tcp/tcp_type.h
r827ec41 rae481e0 152 152 } acpass_t; 153 153 154 typedef struct tcp_conn { 154 typedef enum { 155 tcp_open_nonblock = 1 156 } tcp_open_flags_t; 157 158 typedef struct tcp_conn tcp_conn_t; 159 160 /** Connection state change callback function */ 161 typedef void (*tcp_cstate_cb_t)(tcp_conn_t *, void *); 162 163 /** Connection */ 164 struct tcp_conn { 155 165 char *name; 156 166 link_t link; 167 168 /** Connection state change callback function */ 169 tcp_cstate_cb_t cstate_cb; 170 /** Argument to @c cstate_cb */ 171 void *cstate_cb_arg; 157 172 158 173 /** Connection identification (local and foreign socket) */ … … 233 248 /** Initial receive sequence number */ 234 249 uint32_t irs; 235 } tcp_conn_t; 236 237 typedef struct { 238 unsigned dummy; 250 }; 251 252 /** Data returned by Status user call */ 253 typedef struct { 254 /** Connection state */ 255 tcp_cstate_t cstate; 239 256 } tcp_conn_status_t; 240 257 … … 314 331 } tcp_client_t; 315 332 316 typedef struct { 333 typedef struct tcp_sockdata { 334 /** Lock */ 335 fibril_mutex_t lock; 336 /** Socket core */ 337 socket_core_t *sock_core; 317 338 /** Client */ 318 339 tcp_client_t *client; … … 321 342 /** Local address */ 322 343 netaddr_t laddr; 344 /** Backlog size */ 345 int backlog; 346 /** Array of listening connections, @c backlog elements */ 347 struct tcp_sock_lconn **lconn; 348 /** List of connections (from lconn) that are ready to be accepted */ 349 list_t ready; 323 350 } tcp_sockdata_t; 351 352 typedef struct tcp_sock_lconn { 353 tcp_conn_t *conn; 354 tcp_sockdata_t *socket; 355 int index; 356 link_t ready_list; 357 } tcp_sock_lconn_t; 358 324 359 325 360 #endif
Note:
See TracChangeset
for help on using the changeset viewer.