On 02/13/2015 03:08 PM, John Snow wrote: > We treat this field with a variety of different types everywhere > in the code. Now it's just uint32_t. > > Signed-off-by: John Snow <js...@redhat.com> > --- > block.c | 11 ++++++----- > block/mirror.c | 4 ++-- > include/block/block.h | 2 +- > include/block/block_int.h | 2 +- > qapi/block-core.json | 2 +- > 5 files changed, 11 insertions(+), 10 deletions(-) >
> +++ b/qapi/block-core.json > @@ -335,7 +335,7 @@ > # Since: 1.3 > ## > { 'type': 'BlockDirtyInfo', > - 'data': {'*name': 'str', 'count': 'int', 'granularity': 'int'} } > + 'data': {'*name': 'str', 'count': 'int', 'granularity': 'uint32'} } The wire format of QMP is unchanged. Prior to this patch, a user could pass a value larger than 4G and get past initial validation, but as other code then capped the value (for example, drive-mirror caps at a maximum of 64M), we aren't changing working semantics. Narrowing a type is not always backwards-compatible, but in this case it looks fine. So: Reviewed-by: Eric Blake <ebl...@redhat.com> -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature