From: Wenchao Xia <wenchaoqemu@gmail.com>
To: Markus Armbruster <armbru@redhat.com>, qemu-devel@nongnu.org
Cc: kwolf@redhat.com, pbonzini@redhat.com, stefanha@redhat.com,
lcapitulino@redhat.com
Subject: Re: [Qemu-devel] [PATCH v2 2.1 2/3] blockjob: Fix recent BLOCK_JOB_ERROR regression
Date: Tue, 01 Jul 2014 22:42:08 +0800 [thread overview]
Message-ID: <53B2C8C0.6030303@gmail.com> (raw)
In-Reply-To: <1403889855-5740-3-git-send-email-armbru@redhat.com>
于 2014/6/28 1:24, Markus Armbruster 写道:
> Commit 5a2d2cb screwed up the the value of members device and action,
> breaking tests/qemu-iotests/041.
>
> Signed-off-by: Markus Armbruster <armbru@redhat.com>
> Tested-By: Benoit Canet <benoit@irqsave.net>
> Reviewed-by: Kevin Wolf <kwolf@redhat.com>
> Reviewed-by: Luiz Capitulino <lcapitulino@redhat.com>
> ---
> blockjob.c | 2 +-
> qapi/block-core.json | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/blockjob.c b/blockjob.c
> index 37a8f1f..4d8ff45 100644
> --- a/blockjob.c
> +++ b/blockjob.c
> @@ -286,7 +286,7 @@ BlockErrorAction block_job_error_action(BlockJob *job, BlockDriverState *bs,
> default:
> abort();
> }
> - qapi_event_send_block_job_error(bdrv_get_device_name(bs),
> + qapi_event_send_block_job_error(bdrv_get_device_name(job->bs),
> is_read ? IO_OPERATION_TYPE_READ :
> IO_OPERATION_TYPE_WRITE,
> action, &error_abort);
> diff --git a/qapi/block-core.json b/qapi/block-core.json
> index 822fe16..fd5b579 100644
> --- a/qapi/block-core.json
> +++ b/qapi/block-core.json
> @@ -1544,7 +1544,7 @@
> { 'event': 'BLOCK_JOB_ERROR',
> 'data': { 'device' : 'str',
> 'operation': 'IoOperationType',
> - 'action' : 'BlockdevOnError' } }
> + 'action' : 'BlockErrorAction' } }
>
It is my mistake to use BlockdevOnError in code incorrectly.
The define as 'BlockdevOnError' before is on purpose, since the
doc for 'BlockErrorAction' says: stop means a VM is stoped, but
for block-job it is not true, so I chosed a different type, and
'BlockdevOnError' seems the right one(see the doc for it). We can
fix it in C caller or add doc in .json file later.
I am occupied by other things these days, thanks for fixing
the bugs introduced by me!
> ##
> # @BLOCK_JOB_READY
>
next prev parent reply other threads:[~2014-07-01 14:42 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-27 17:24 [Qemu-devel] [PATCH v2 2.1 0/3] Fix two recent event regressions Markus Armbruster
2014-06-27 17:24 ` [Qemu-devel] [PATCH v2 2.1 1/3] blockjob: Fix recent BLOCK_JOB_READY regression Markus Armbruster
2014-07-01 17:08 ` Eric Blake
2014-07-01 17:10 ` Paolo Bonzini
2014-07-02 6:55 ` Markus Armbruster
2014-07-02 8:23 ` Paolo Bonzini
2014-07-02 8:44 ` Kevin Wolf
2014-07-02 8:59 ` Paolo Bonzini
2014-07-02 14:58 ` Markus Armbruster
2014-07-02 15:03 ` Paolo Bonzini
2014-07-02 16:05 ` Eric Blake
2014-07-03 7:19 ` Markus Armbruster
2014-07-03 9:25 ` Paolo Bonzini
2014-07-03 15:06 ` Markus Armbruster
2014-06-27 17:24 ` [Qemu-devel] [PATCH v2 2.1 2/3] blockjob: Fix recent BLOCK_JOB_ERROR regression Markus Armbruster
2014-07-01 14:42 ` Wenchao Xia [this message]
2014-07-01 16:46 ` Paolo Bonzini
2014-07-02 6:46 ` Markus Armbruster
2014-07-02 8:20 ` Paolo Bonzini
2014-06-27 17:24 ` [Qemu-devel] [PATCH v2 2.1 3/3] docs/qmp: Fix documentation of BLOCK_JOB_READY to match code Markus Armbruster
2014-06-27 17:42 ` Luiz Capitulino
2014-07-01 17:12 ` Eric Blake
2014-07-02 6:49 ` Markus Armbruster
2014-07-02 8:48 ` Kevin Wolf
2014-07-02 7:55 ` Paolo Bonzini
2014-06-27 18:37 ` [Qemu-devel] [PATCH v2 2.1 0/3] Fix two recent event regressions Kevin Wolf
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=53B2C8C0.6030303@gmail.com \
--to=wenchaoqemu@gmail.com \
--cc=armbru@redhat.com \
--cc=kwolf@redhat.com \
--cc=lcapitulino@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.