qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 9/9] vhost-user: Improve -netdev/netdev_add/-net


From: Stefan Hajnoczi
Subject: Re: [Qemu-devel] [PATCH 9/9] vhost-user: Improve -netdev/netdev_add/-net/... error reporting
Date: Tue, 2 Jun 2015 17:32:07 +0100
User-agent: Mutt/1.5.23 (2014-03-12)

On Thu, May 28, 2015 at 02:21:35PM +0200, Markus Armbruster wrote:
> When -netdev vhost-user fails, it first reports a specific error, then
> one or more generic ones, like this:
> 
>     $ qemu-system-x86_64 -netdev vhost-user,id=foo,chardev=xxx
>     qemu-system-x86_64: -netdev vhost-user,id=foo,chardev=xxx: chardev "xxx" 
> not found
>     qemu-system-x86_64: -netdev vhost-user,id=foo,chardev=xxx: No suitable 
> chardev found
>     qemu-system-x86_64: -netdev vhost-user,id=foo,chardev=xxx: Device 
> 'vhost-user' could not be initialized
> 
> With the command line, the messages go to stderr.  In HMP, they go to
> the monitor.  In QMP, the last one becomes the error reply, and the
> others go to stderr.
> 
> Convert net_init_vhost_user() and its helpers to Error.  This
> suppresses the unwanted unspecific error messages, and makes the
> specific error the QMP error reply.
> 
> Cc: Stefan Hajnoczi <address@hidden>
> Cc: Jason Wang <address@hidden>
> Signed-off-by: Markus Armbruster <address@hidden>
> ---
>  net/vhost-user.c | 27 ++++++++++++---------------
>  1 file changed, 12 insertions(+), 15 deletions(-)

Reviewed-by: Stefan Hajnoczi <address@hidden>

Attachment: pgpqqxmpHyqLn.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]