qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Max Reitz <mreitz@redhat.com>
To: Alberto Garcia <berto@igalia.com>, qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>, Stefan Hajnoczi <stefanha@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 2/3] block: use bdrv_get_device_or_node_name() in error messages
Date: Thu, 19 Mar 2015 15:37:06 -0400	[thread overview]
Message-ID: <550B2562.4090506@redhat.com> (raw)
In-Reply-To: <5ad1c53c8b0dad6347d66af08e44c2faadff8612.1426779661.git.berto@igalia.com>

On 2015-03-19 at 11:43, Alberto Garcia wrote:
> There are several error messages that identify a BlockDriverState by
> its device name. However those errors can be produced in nodes that
> don't have a device name associated.
>
> In those cases we should use bdrv_get_device_or_node_name() to fall
> back to the node name and produce a more meaningful message.
>
> Signed-off-by: Alberto Garcia <berto@igalia.com>
> ---
>   block.c       | 13 +++++++------
>   block/qcow.c  |  4 ++--
>   block/qcow2.c |  2 +-
>   block/qed.c   |  2 +-
>   block/vdi.c   |  2 +-
>   block/vhdx.c  |  2 +-
>   block/vmdk.c  |  4 ++--
>   block/vpc.c   |  2 +-
>   block/vvfat.c |  3 ++-
>   9 files changed, 18 insertions(+), 16 deletions(-)

Well, it may pose a problem that the error messages often state "Device 
'%s'", but with this change, it's not always a device, but sometimes 
just a node. Maybe it would be better to replace the "Device" in the 
error messages by "Node" (a node can be specified both by the node name 
and the device name, whereas a device can only be referenced by its 
device name).

Apart from this, the idea of this change looks good, though, as do the 
changes done by this patch.

Max

  reply	other threads:[~2015-03-19 19:37 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-19 15:43 [Qemu-devel] [PATCH 0/3] Add bdrv_get_device_or_node_name() Alberto Garcia
2015-03-19 15:43 ` [Qemu-devel] [PATCH 1/3] block: add bdrv_get_device_or_node_name() Alberto Garcia
2015-03-19 19:26   ` Max Reitz
2015-03-20  7:40   ` Markus Armbruster
2015-03-20  8:03     ` Alberto Garcia
2015-03-20  8:47       ` Markus Armbruster
2015-03-19 15:43 ` [Qemu-devel] [PATCH 2/3] block: use bdrv_get_device_or_node_name() in error messages Alberto Garcia
2015-03-19 19:37   ` Max Reitz [this message]
2015-03-20  7:52   ` Markus Armbruster
2015-03-19 15:43 ` [Qemu-devel] [PATCH 3/3] block: allow BLOCK_IMAGE_CORRUPTED to have a node name Alberto Garcia
2015-03-19 19:42   ` Max Reitz
2015-03-19 21:42     ` Alberto Garcia
2015-03-19 21:52       ` Max Reitz
2015-03-19 22:04         ` Alberto Garcia
2015-03-19 22:15       ` Eric Blake
2015-03-19 22:38         ` Alberto Garcia
2015-03-19 23:14           ` Eric Blake
2015-03-20  9:23             ` Alberto Garcia
2015-03-19 19:37 ` [Qemu-devel] [PATCH 0/3] Add bdrv_get_device_or_node_name() Max Reitz
2015-03-19 21:49   ` Alberto Garcia
  -- strict thread matches above, loose matches on Subject: below --
2015-03-20 10:19 [Qemu-devel] [PATCH v2 " Alberto Garcia
2015-03-20 10:19 ` [Qemu-devel] [PATCH 2/3] block: use bdrv_get_device_or_node_name() in error messages Alberto Garcia
2015-03-20 13:22   ` Max Reitz
2015-03-20 13:57     ` Markus Armbruster
2015-03-20 14:33 [Qemu-devel] [PATCH v3 0/3] Add bdrv_get_device_or_node_name() Alberto Garcia
2015-03-20 14:33 ` [Qemu-devel] [PATCH 2/3] block: use bdrv_get_device_or_node_name() in error messages Alberto Garcia
2015-03-20 19:24   ` Max Reitz
2015-04-08  9:29 [Qemu-devel] [PATCH v4 0/3] Add bdrv_get_device_or_node_name() Alberto Garcia
2015-04-08  9:29 ` [Qemu-devel] [PATCH 2/3] block: use bdrv_get_device_or_node_name() in error messages Alberto Garcia
2015-04-08 16:27   ` Eric Blake
2015-04-09  8:25     ` Alberto Garcia

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=550B2562.4090506@redhat.com \
    --to=mreitz@redhat.com \
    --cc=berto@igalia.com \
    --cc=kwolf@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).