qemu-e2k/net
Stefan Hajnoczi 45a7f54a8b net: EAGAIN handling for net/socket.c TCP
Replace spinning send_all() with a proper non-blocking send.  When the
socket write buffer limit is reached, we should stop trying to send and
wait for the socket to become writable again.

Non-blocking TCP sockets can return in two different ways when the write
buffer limit is reached:

1. ret = -1 and errno = EAGAIN/EWOULDBLOCK.  No data has been written.

2. ret < total_size.  Short write, only part of the message was
   transmitted.

Handle both cases and keep track of how many bytes have been written in
s->send_index.  (This includes the 'length' header before the actual
payload buffer.)

Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
2012-09-14 08:40:33 +01:00
..
checksum.c
checksum.h
dump.c
dump.h
hub.c net: broadcast hub packets if at least one port can receive 2012-09-14 08:40:33 +01:00
hub.h
Makefile.objs
queue.c net: do not report queued packets as sent 2012-09-14 08:40:32 +01:00
queue.h net: notify iothread after flushing queue 2012-09-14 08:40:31 +01:00
slirp.c qapi: avoid reserved keywords 2012-08-09 18:34:57 +00:00
slirp.h
socket.c net: EAGAIN handling for net/socket.c TCP 2012-09-14 08:40:33 +01:00
socket.h
tap-aix.c
tap-bsd.c
tap-haiku.c
tap-linux.c
tap-linux.h
tap-solaris.c
tap-win32.c
tap.c monitor: Rename+move net_handle_fd_param -> monitor_handle_fd_param 2012-09-07 09:15:08 +03:00
tap.h
util.c
util.h
vde.c
vde.h