qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v12 01/13] Add MigrationParams structure


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v12 01/13] Add MigrationParams structure
Date: Tue, 19 Jun 2012 10:00:37 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120605 Thunderbird/13.0

On 06/19/2012 09:43 AM, Orit Wasserman wrote:
> From: Isaku Yamahata <address@hidden>
> 
> Signed-off-by: Isaku Yamahata <address@hidden>
> ---

>  
> -static void block_set_params(int blk_enable, int shared_base, void *opaque)
> +static void block_set_params(const MigrationParams *params, void *opaque)

As long as we are changing this signature...

> @@ -394,9 +393,13 @@ void qmp_migrate(const char *uri, bool has_blk, bool blk,
>                   Error **errp)
>  {
>      MigrationState *s = migrate_get_current();
> +    MigrationParams params;
>      const char *p;
>      int ret;
>  
> +    params.blk = blk;

...and since blk is only ever a bool to begin with...

>  
> +struct MigrationParams {
> +    int blk;
> +    int shared;

...why not use bool instead of int in this struct to represent the fact
that it really is a binary choice?  I think the same can be said for shared.

-- 
Eric Blake   address@hidden    +1-919-301-3266
Libvirt virtualization library http://libvirt.org



Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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