]> git.karo-electronics.de Git - karo-tx-linux.git/commit
kvm tools: Respect guest tcp window size
authorAsias He <asias.hejun@gmail.com>
Thu, 23 Aug 2012 12:47:51 +0000 (20:47 +0800)
committerPekka Enberg <penberg@kernel.org>
Thu, 23 Aug 2012 16:41:31 +0000 (19:41 +0300)
commit27b0421296dc85d116e30db626ad457d73a483fc
tree88115b86b384018af824202dfc505059ce3d1fae
parent7069d7bd471fbf6cf838159a124a73c3bcb18095
kvm tools: Respect guest tcp window size

Respect guest tcp window size and stop sending tcp segments to guest
if guest's receive window is closed.

This fixes the TCP hang I'm seeing where guest and host are transferring
big chuck of data.

This problem was not triggered when guest and external host
communicates, probably because guest to external host communication
walks through real network and is much slower than guest and host
communication. Thus, guest's receive window has little chance to be
closed.

v2: use pthread_cond_wait to wait

Signed-off-by: Asias He <asias.hejun@gmail.com>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
tools/kvm/include/kvm/uip.h
tools/kvm/net/uip/tcp.c