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 <cy...@suse.com> > --- > 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 <ebl...@redhat.com> -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature