3e2cf187 | 24-Aug-2017 |
Igor Mammedov <imammedo@redhat.com> |
qom: cpu: fix parsed feature string length
since commit ( 9262685b cpu: Factor out cpu_generic_init() ) features parsed by it were truncated only to the 1st feature after CPU name due to fact that
qom: cpu: fix parsed feature string length
since commit ( 9262685b cpu: Factor out cpu_generic_init() ) features parsed by it were truncated only to the 1st feature after CPU name due to fact that
featurestr = strtok(NULL, ","); cc->parse_features(cpu, featurestr, &err);
would extract exactly one feature and parse_features() callback would parse it and only it leaving the rest of features ignored.
Reuse approach from x86 custom impl. i.e. replace strtok() token parsing with g_strsplit(), which would split feature string in 2 parts name and features list and pass the later to parse_features() callback.
Signed-off-by: Igor Mammedov <imammedo@redhat.com> Message-Id: <1503592308-93913-2-git-send-email-imammedo@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
show more ...
|
5ce46cb3 | 26-Jul-2017 |
Eduardo Habkost <ehabkost@redhat.com> |
cpu: cpu_by_arch_id() helper
The helper can be used for CPU object lookup using the CPU's arch-specific ID (the one returned by CPUClass::get_arch_id()).
Signed-off-by: Eduardo Habkost <ehabkost@re
cpu: cpu_by_arch_id() helper
The helper can be used for CPU object lookup using the CPU's arch-specific ID (the one returned by CPUClass::get_arch_id()).
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> [Yi Wang: Added documentation comments] Signed-off-by: Yi Wang <wang.yi59@zte.com.cn> Signed-off-by: Yun Liu <liu.yunh@zte.com.cn> [ehabkost: extracted cpu_by_arch_id() to a separate patch] Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
show more ...
|