[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/6] target-i386: cpu: separate feature string p
From: |
Igor Mammedov |
Subject: |
Re: [Qemu-devel] [PATCH 2/6] target-i386: cpu: separate feature string parsing from CPU model lookup |
Date: |
Tue, 4 Dec 2012 20:47:56 +0100 |
On Tue, 4 Dec 2012 17:34:39 -0200
Eduardo Habkost <address@hidden> wrote:
> Instead of using parsing the whole cpu_model string inside
> cpu_x86_find_by_name(), first split it into the CPU model name and the
> full feature string, then parse the feature string into pieces.
>
> When using CPU model classes, those two pieces of information will be
> used at different moments (CPU model name will be used to find CPU
> class, feature string will be used after CPU object was created), so
> making the split in two steps will make it easier to refactor the code
> later.
>
> This should also help on the CPU properties work, that will just need to
> replace the cpu_x86_parse_featurestr() logic (and can keep the CPU model
> lookup code as-is).
>
> Signed-off-by: Eduardo Habkost <address@hidden>
> ---
> Changes v1 -> v2:
> - Coding style changes
> - Replace "goto error" with "return -1"
>
> Changes v2 -> v3:
> - Fix memory leak on handling of errors form object_property_set_str()
> ---
Reviewed-by: Igor Mammedov <address@hidden>
--
Regards,
Igor
- Re: [Qemu-devel] [PATCH 3/6] target-i386: use define for cpuid vendor string size, (continued)
[Qemu-devel] [PATCH 5/6] add visitor for parsing hz[KMG] input string, Eduardo Habkost, 2012/12/04
[Qemu-devel] [PATCH 2/6] target-i386: cpu: separate feature string parsing from CPU model lookup, Eduardo Habkost, 2012/12/04
[Qemu-devel] [PATCH 1/6] target-i386/cpu.c: coding style fixes, Eduardo Habkost, 2012/12/04
[Qemu-devel] [PATCH 6/6] target-i386: use visit_type_hz to parse tsc_freq property value, Eduardo Habkost, 2012/12/04
Re: [Qemu-devel] [PATCH 0/6] short x86 CPU init cleanup (v3), Andreas Färber, 2012/12/05