From: Cornelia Huck <cornelia.huck@de.ibm.com>
To: Greg Kurz <groug@kaod.org>
Cc: qemu-devel@nongnu.org, Kevin Wolf <kwolf@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
Jason Wang <jasowang@redhat.com>, Max Reitz <mreitz@redhat.com>,
"Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>,
Stefan Hajnoczi <stefanha@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 3/7] virtio-net: handle virtio_net_handle_ctrl() error
Date: Wed, 21 Sep 2016 16:30:16 +0200 [thread overview]
Message-ID: <20160921163016.7b4ff3b3.cornelia.huck@de.ibm.com> (raw)
In-Reply-To: <147446365782.4880.9477223746897679434.stgit@bahia>
On Wed, 21 Sep 2016 15:14:17 +0200
Greg Kurz <groug@kaod.org> wrote:
> This error is caused by a buggy guest: let's switch the device to the
> broken state instead of terminating QEMU.
>
> Signed-off-by: Greg Kurz <groug@kaod.org>
> ---
> hw/net/virtio-net.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c
> index 01f1351554aa..68a448acd81b 100644
> --- a/hw/net/virtio-net.c
> +++ b/hw/net/virtio-net.c
> @@ -892,8 +892,8 @@ static void virtio_net_handle_ctrl(VirtIODevice *vdev, VirtQueue *vq)
> }
> if (iov_size(elem->in_sg, elem->in_num) < sizeof(status) ||
> iov_size(elem->out_sg, elem->out_num) < sizeof(ctrl)) {
> - error_report("virtio-net ctrl missing headers");
> - exit(1);
> + virtio_error(vdev, "virtio-net ctrl missing headers");
> + return;
Do a 'break;' for consistency's sake?
> }
>
> iov_cnt = elem->out_num;
>
next prev parent reply other threads:[~2016-09-21 14:30 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-21 13:13 [Qemu-devel] [PATCH 0/7] virtio: avoid inappropriate QEMU termination Greg Kurz
2016-09-21 13:14 ` [Qemu-devel] [PATCH 1/7] virtio-9p: handle handle_9p_output() error Greg Kurz
2016-09-21 14:16 ` Cornelia Huck
2016-09-21 14:38 ` Greg Kurz
2016-09-21 14:43 ` Cornelia Huck
2016-09-21 14:42 ` Greg Kurz
2016-09-21 13:14 ` [Qemu-devel] [PATCH 2/7] virtio-blk: handle virtio_blk_handle_request() errors Greg Kurz
2016-09-21 14:28 ` Cornelia Huck
2016-09-21 15:01 ` Greg Kurz
2016-09-21 13:14 ` [Qemu-devel] [PATCH 3/7] virtio-net: handle virtio_net_handle_ctrl() error Greg Kurz
2016-09-21 14:30 ` Cornelia Huck [this message]
2016-09-21 15:03 ` Greg Kurz
2016-09-21 13:14 ` [Qemu-devel] [PATCH 4/7] virtio-net: handle virtio_net_receive() errors Greg Kurz
2016-09-21 14:38 ` Cornelia Huck
2016-09-21 13:14 ` [Qemu-devel] [PATCH 5/7] virtio-net: handle virtio_net_flush_tx() errors Greg Kurz
2016-09-21 13:14 ` [Qemu-devel] [PATCH 6/7] virtio-scsi: convert virtio_scsi_bad_req() to use virtio_error() Greg Kurz
2016-09-21 13:14 ` [Qemu-devel] [PATCH 7/7] virtio-scsi: handle virtio_scsi_set_config() error Greg Kurz
2016-09-21 13:35 ` [Qemu-devel] [PATCH 0/7] virtio: avoid inappropriate QEMU termination no-reply
2016-09-21 13:44 ` Greg Kurz
2016-09-21 14:01 ` Fam Zheng
2016-09-21 14:29 ` Eric Blake
2016-09-22 5:39 ` Fam Zheng
2016-09-21 14:34 ` Greg Kurz
2016-09-21 17:38 ` Michael S. Tsirkin
2016-09-21 17:35 ` Michael S. Tsirkin
2016-09-21 18:12 ` Greg Kurz
2016-09-22 1:19 ` Gonglei
2016-09-22 6:43 ` Greg Kurz
2016-09-22 6:55 ` Gonglei (Arei)
2016-09-22 7:21 ` Greg Kurz
2016-09-22 7:30 ` Gonglei (Arei)
2016-09-22 7:38 ` Gonglei (Arei)
2016-09-22 8:14 ` Greg Kurz
2016-09-22 8:28 ` Cornelia Huck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160921163016.7b4ff3b3.cornelia.huck@de.ibm.com \
--to=cornelia.huck@de.ibm.com \
--cc=aneesh.kumar@linux.vnet.ibm.com \
--cc=groug@kaod.org \
--cc=jasowang@redhat.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).