[Top][All Lists]

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

Re: [Qemu-devel] [PATCH v22 01/25] add def_value_str to QemuOptDesc

From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v22 01/25] add def_value_str to QemuOptDesc
Date: Mon, 10 Mar 2014 13:52:49 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0

On 03/10/2014 01:31 AM, Chunyan Liu wrote:
> Add def_value_str (default value) to QemuOptDesc, to replace function of the
> default value in QEMUOptionParameter. And improved related functions.
> Signed-off-by: Dong Xu Wang <address@hidden>
> Signed-off-by: Chunyan Liu <address@hidden>
> ---
>  include/qemu/option.h |  3 ++-
>  util/qemu-option.c    | 59 
> +++++++++++++++++++++++++++++++++++++++++++--------
>  2 files changed, 52 insertions(+), 10 deletions(-)

> +++ b/util/qemu-option.c
> @@ -33,6 +33,9 @@
>  #include "qapi/qmp/qerror.h"
>  #include "qemu/option_int.h"
> +static const QemuOptDesc *find_desc_by_name(const QemuOptDesc *desc,
> +                                            const char *name);

I tend to avoid forward-declaration of static functions, except when
true mutual recursion is required - when I read a file, it's nicer to
see the smaller building blocks up front instead of having to skip to
the bottom to see what they do.  Do you need a forward-declaration, or
can you split this into two patches, one that does just code motion to
hoist find_desc_by_name() earlier, and the second to make use of it in
correct topological order?

But what you have is correct, so if you don't have a reason to respin
for anything else,

Reviewed-by: Eric Blake <address@hidden>

Eric Blake   eblake redhat com    +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]