From: Kevin Wolf <kwolf@redhat.com>
To: Stefan Hajnoczi <stefanha@gmail.com>
Cc: qemu-block@nongnu.org, Alberto Garcia <berto@igalia.com>,
qemu-devel@nongnu.org, Stefan Hajnoczi <stefanha@redhat.com>
Subject: Re: [Qemu-devel] [Qemu-block] [PATCH] qmp: fill in the image field in BlockDeviceInfo
Date: Tue, 21 Apr 2015 15:43:35 +0200 [thread overview]
Message-ID: <20150421134335.GH3835@noname.str.redhat.com> (raw)
In-Reply-To: <20150421132801.GE16345@stefanha-thinkpad.redhat.com>
[-- Attachment #1: Type: text/plain, Size: 1337 bytes --]
Am 21.04.2015 um 15:28 hat Stefan Hajnoczi geschrieben:
> On Fri, Apr 17, 2015 at 02:52:43PM +0300, Alberto Garcia wrote:
> > The image field in BlockDeviceInfo is supposed to contain an ImageInfo
> > object. However that is being filled in by bdrv_query_info(), not by
> > bdrv_block_device_info(), which is where BlockDeviceInfo is actually
> > created.
> >
> > Anyone calling bdrv_block_device_info() directly will get a null image
> > field. As a consequence of this, the HMP command 'info block -n -v'
> > crashes QEMU.
> >
> > This patch moves the code that fills in that field from
> > bdrv_query_info() to bdrv_block_device_info().
> >
> > Signed-off-by: Alberto Garcia <berto@igalia.com>
> > ---
> > block.c | 9 +++++++--
> > block/qapi.c | 46 +++++++++++++++++++++++++---------------------
> > blockdev.c | 2 +-
> > include/block/block.h | 2 +-
> > include/block/qapi.h | 2 +-
> > 5 files changed, 35 insertions(+), 26 deletions(-)
>
> For the record, the following patch has been merged instead:
> [PATCH for-2.3] hmp: fix crash in 'info block -n -v'
That was just a minimal stopgap solution that could still be applied
after -rc3. We should revert it in block-next and apply this one as a
replacement (after proper review, of course).
Kevin
[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2015-04-21 13:43 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-17 11:52 [Qemu-devel] [PATCH] qmp: fill in the image field in BlockDeviceInfo Alberto Garcia
2015-04-17 12:14 ` Alberto Garcia
2015-04-21 13:28 ` [Qemu-devel] [Qemu-block] " Stefan Hajnoczi
2015-04-21 13:43 ` Kevin Wolf [this message]
2015-04-22 10:18 ` Stefan Hajnoczi
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=20150421134335.GH3835@noname.str.redhat.com \
--to=kwolf@redhat.com \
--cc=berto@igalia.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.com \
--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).