mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
Merge remote-tracking branch 'remotes/stefanha/tags/net-pull-request' into staging
Net patches # gpg: Signature made Wed 12 Mar 2014 13:48:20 GMT using RSA key ID 81AB73C8 # gpg: Good signature from "Stefan Hajnoczi <stefanha@redhat.com>" # gpg: aka "Stefan Hajnoczi <stefanha@gmail.com>" # gpg: WARNING: This key is not certified with a trusted signature! # gpg: There is no indication that the signature belongs to the owner. # Primary key fingerprint: 8695 A8BF D3F9 7CDA AC35 775A 9CA4 ABB3 81AB 73C8 * remotes/stefanha/tags/net-pull-request: tap: avoid deadlocking rx Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
@@ -190,7 +190,7 @@ static void tap_send(void *opaque)
|
||||
TAPState *s = opaque;
|
||||
int size;
|
||||
|
||||
do {
|
||||
while (qemu_can_send_packet(&s->nc)) {
|
||||
uint8_t *buf = s->buf;
|
||||
|
||||
size = tap_read_packet(s->fd, s->buf, sizeof(s->buf));
|
||||
@@ -206,8 +206,11 @@ static void tap_send(void *opaque)
|
||||
size = qemu_send_packet_async(&s->nc, buf, size, tap_send_completed);
|
||||
if (size == 0) {
|
||||
tap_read_poll(s, false);
|
||||
break;
|
||||
} else if (size < 0) {
|
||||
break;
|
||||
}
|
||||
} while (size > 0 && qemu_can_send_packet(&s->nc));
|
||||
}
|
||||
}
|
||||
|
||||
static bool tap_has_ufo(NetClientState *nc)
|
||||
|
||||
Reference in New Issue
Block a user