qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RFC v2 7/7] remove QEMUOptionParameter


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [RFC v2 7/7] remove QEMUOptionParameter
Date: Thu, 27 Sep 2012 14:03:27 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120911 Thunderbird/15.0.1

Il 27/09/2012 07:14, Dong Xu Wang ha scritto:
> remove QEMUOptionParameter, and use QemuOpts and QemuOptsList.
> 
> Signed-off-by: Dong Xu Wang <address@hidden>
> ---
>  block.c             |   88 ++++++------
>  block.h             |    5 +-
>  block/Makefile.objs |    9 +-
>  block/qcow2.c       |  175 ++++++++++++-----------
>  block/raw-posix.c   |   68 ++++-----
>  block/raw.c         |   31 +++--
>  block_int.h         |    6 +-
>  qemu-config.c       |    3 +
>  qemu-img.c          |   58 ++++----
>  qemu-option.c       |  408 
> +++++++++++++++------------------------------------
>  qemu-option.h       |   45 +-----
>  11 files changed, 347 insertions(+), 549 deletions(-)

The patch is already quite big, so please move the qemu-option.c changes
to separate patches.

For example, patch 7 could add def_value and use it in qemu_opts_print.
 Patch 8 should add append_opts_list, free_opts_list, print_opts_list.
Patch 9 should touch only the block layer.  Patch 10 should remove the
now-unuse QEMUOptionParameter code.

(Regarding def_value, it is quite unintuitive that you need to specify
the value again when calling qemu_opt_get_*.  Perhaps,
qemu_opts_validate could instead walk through descriptors that are not
present but have a default value, and add new options with the default
value to the QemuOpts object).

Paolo




reply via email to

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