[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 0/2 v2] introduce visitor for parsing suffixed i
From: |
Anthony Liguori |
Subject: |
Re: [Qemu-devel] [PATCH 0/2 v2] introduce visitor for parsing suffixed integer |
Date: |
Sun, 23 Dec 2012 14:34:21 -0600 |
User-agent: |
Notmuch/0.13.2+93~ged93d79 (http://notmuchmail.org) Emacs/23.3.1 (x86_64-pc-linux-gnu) |
Igor Mammedov <address@hidden> writes:
> v2:
> * Naming changes:
> - s/visit_type_uint_suffixed_int/visit_type_suffixed_int/
> - use 'suffix_factor' instead of 'unit'
> * Added documentation to visit_type_suffixed_int()
> * Fixed errp check.
> * Style fixes
This is not how visitors are supposed to be used.
Just treat tsc_freq as a string property and parse it in the setter.
Regards,
Anthony Liguori
>
> Reference to previous version dicussion:
> http://lists.gnu.org/archive/html/qemu-devel/2012-12/msg00758.html
>
> Git tree for testing:
> https://github.com/imammedo/qemu/tree/type_suffixed_int_v2
>
> Igor Mammedov (2):
> add visitor for parsing int[KMGT] input string
> target-i386: use visit_type_suffixed_int() to parse tsc_freq property
> value
>
> qapi/qapi-dealloc-visitor.c | 8 ++++++++
> qapi/qapi-visit-core.c | 35 +++++++++++++++++++++++++++++++++++
> qapi/qapi-visit-core.h | 4 ++++
> qapi/string-input-visitor.c | 25 +++++++++++++++++++++++++
> target-i386/cpu.c | 3 ++-
> 5 files changed, 74 insertions(+), 1 deletion(-)
>
> --
> 1.7.11.7