qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [PATCH 1/5] block/dirty-bitmap: add recording and busy


From: John Snow
Subject: Re: [Qemu-block] [PATCH 1/5] block/dirty-bitmap: add recording and busy properties
Date: Tue, 12 Feb 2019 13:23:11 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0


On 2/12/19 1:17 PM, Eric Blake wrote:
> On 2/11/19 7:02 PM, John Snow wrote:
>> The current API allows us to report a single status, which we've defined as:
>>
>> Frozen: has a successor, treated as qmp_locked, may or may not be enabled.
>> Locked: no successor, qmp_locked. may or may not be enabled.
>> Disabled: Not frozen or locked, disabled.
>> Active: Not frozen, locked, or disabled.
>>
>> The problem is that both "Frozen" and "Locked" mean nearly the same thing,
>> and that both of them do not intuit whether they are recording guest writes
>> or not.
>>
>> This patch deprecates that status field and introduces two orthogonal
>> properties instead to replace it.
>> ---
> 
> No S-o-b?
> 

Ah, heck, what's wrong with my script that it keeps dropping this? sorry.

> 
>> +++ b/qapi/block-core.json
>> @@ -455,7 +455,13 @@
>>  #
>>  # @granularity: granularity of the dirty bitmap in bytes (since 1.4)
>>  #
>> -# @status: current status of the dirty bitmap (since 2.4)
>> +# @status: Deprecated in favor of @recording and @locked. (since 4.0)
> 
> I'd leave this one as (since 2.4). The deprecation clock is starting in
> 4.0, but the field has been present longer, and it is still obvious to
> readers...
> >> +#
>> +# @recording: true if the bitmap is recording new writes from the guest.
>> +#             Replaces `active` status. (since 4.0)
> 
> ...that the replacement fields are only usable in 4.0 and newer.
> 

OK. I'll just add a small note for what it was deprecated in favor of.

>> +#
>> +# @busy: true if the bitmap is in-use by some operation (NBD or jobs)
>> +#        and cannot be modified via QMP right now. (since 4.0)
>>  #
>>  # @persistent: true if the bitmap will eventually be flushed to persistent
>>  #              storage (since 4.0)
>> @@ -464,6 +470,7 @@
>>  ##
>>  { 'struct': 'BlockDirtyInfo',
>>    'data': {'*name': 'str', 'count': 'int', 'granularity': 'uint32',
>> +           'recording': 'bool', 'busy': 'bool',
>>             'status': 'DirtyBitmapStatus', 'persistent': 'bool' } }
> 
> The UI changes look reasonable.
> 
> No iotests coverage of "busy":true?
> 

I'll add it to the list. I wrote test 124 when I was pretty new at
python and it's a dense monster to add things to, but I can probably
work it in without much problem.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]