[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 2.1 2/3] blockjob: Fix recent BLOCK_JOB_ERROR
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-devel] [PATCH v2 2.1 2/3] blockjob: Fix recent BLOCK_JOB_ERROR regression |
Date: |
Wed, 02 Jul 2014 08:46:34 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Paolo Bonzini <address@hidden> writes:
> Il 01/07/2014 16:42, Wenchao Xia ha scritto:
>>> 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 think consistency between BLOCK_IO_ERROR and BLOCK_JOB_ERROR is
> better.
Moreover, BlockdevOnError's enospc is meaningless here.
> Let's fix the BlockErrorAction documentation instead.
I didn't quite understand what's wrong with it; I expect a patch will
enlighten me :)