[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status |
Date: |
Tue, 26 May 2015 10:13:30 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
John Snow <address@hidden> writes:
> On 05/22/2015 04:52 AM, Markus Armbruster wrote:
>> Eric Blake <address@hidden> writes:
>>
>>> On 05/12/2015 01:53 PM, John Snow wrote:
>>>> Bitmaps can be in a handful of different states with potentially
>>>> more to come as we tool around with migration and persistence patches.
>>>>
>>>> Instead of having a bunch of boolean fields, it was suggested that we
>>>> just have an enum status field that will help expose the reason to
>>>> management APIs why certain bitmaps may be unavailable for various
>>>> commands
>>>>
>>>> (e.g. busy in another operation, busy being migrated, etc.)
>>>
>>> Might be worth mentioning that this is an API change, but safe because
>>> the old API is unreleased (and therefore, this patch MUST go in the 2.4
>>> time frame, if at all).
>>>
>>>>
>>>> Suggested-by: Eric Blake <address@hidden>
>>>> Signed-off-by: John Snow <address@hidden>
>>>> ---
>>>> block.c | 13 ++++++++++++-
>>>> include/block/block.h | 1 +
>>>> qapi/block-core.json | 23 +++++++++++++++++++++--
>>>> 3 files changed, 34 insertions(+), 3 deletions(-)
>>>>
>>>
>>> Reviewed-by: Eric Blake <address@hidden>
>>
>> Patch does two things:
>>
>> 1. Convert status from bool frozen to enum.
>> 2. Add new status 'disabled'.
>>
>> I would've done this separately, but it's no big deal. But I think we
>> should spell it out in the commit message.
>>
>> What about:
>>
>> qapi: add dirty bitmap status
>>
>> Bitmaps can be in a handful of different states with potentially
>> more to come as we tool around with migration and persistence patches.
>>
>> Management applications may need to know why certain bitmaps are
>> unavailable for various commands, e.g. busy in another operation,
>> busy being migrated, etc.
>>
>> Right now, all we offer is BlockDirtyInfo's boolean member 'frozen'.
>> Instead of adding more booleans, replace it by an enumeration member
>> 'status' with values 'active' and 'frozen'. Then add new value
>> 'disabled'.
>>
>> Incompatible change. Fine because the changed part hasn't been
>> released so far.
>>
>> Suggested-by: Eric Blake <address@hidden>
>> Signed-off-by: John Snow <address@hidden>
>> Reviewed-by: Eric Blake <address@hidden>
>> [Commit message tweaked]
>> Signed-off-by: Markus Armbruster <address@hidden>
>>
>
> This is OK by me, Markus. I'll assume that you are OK with or have
> already made these changes locally, so I won't resend.
Applied to my block-next branch, thanks!
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, (continued)
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, John Snow, 2015/05/19
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, Markus Armbruster, 2015/05/20
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, John Snow, 2015/05/21
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, Kevin Wolf, 2015/05/22
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, Markus Armbruster, 2015/05/22
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, Kevin Wolf, 2015/05/22
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, John Snow, 2015/05/22
- Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, John Snow, 2015/05/22
Re: [Qemu-devel] [PATCH] qapi: add dirty bitmap status, Markus Armbruster, 2015/05/22