qemu/target/ppc
David Gibson 165dc3edd7 spapr/kvm: Set default cpu model for all machine classes
We have to set the default model of all machine classes, not just for
the active one. Otherwise, "query-machines" will indicate the wrong
CPU model (e.g. "power9_v2.0-powerpc64-cpu" instead of
"host-powerpc64-cpu") as "default-cpu-type".

s390x already fixed this in de60a92e "s390x/kvm: Set default cpu model for
all machine classes".  This patch applies a similar fix for the pseries-*
machine types on ppc64.

Doing a
    {"execute":"query-machines"}
under KVM now results in
    {
      "hotpluggable-cpus": true,
      "name": "pseries-4.2",
      "numa-mem-supported": true,
      "default-cpu-type": "host-powerpc64-cpu",
      "is-default": true,
      "cpu-max": 1024,
      "deprecated": false,
      "alias": "pseries"
    },
    {
      "hotpluggable-cpus": true,
      "name": "pseries-4.1",
      "numa-mem-supported": true,
      "default-cpu-type": "host-powerpc64-cpu",
      "cpu-max": 1024,
      "deprecated": false
    },
    ...

Libvirt probes all machines via "-machine none,accel=kvm:tcg" and will
currently see the wrong CPU model under KVM.

Reported-by: Jiři Denemark <jdenemar@redhat.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: David Hildenbrand <david@redhat.com>
Reviewed-by: Greg Kurz <groug@kaod.org>
Tested-by: Jiri Denemark <jdenemar@redhat.com>
Signed-off-by: Laurent Vivier <lvivier@redhat.com>
2019-11-18 11:50:39 +01:00
..
translate target/ppc: Fix for optimized vsl/vsr instructions 2019-10-24 09:36:55 +11:00
Makefile.objs
arch_dump.c
compat.c
cpu-models.c
cpu-models.h
cpu-param.h
cpu-qom.h
cpu.c
cpu.h target/ppc: update {get,set}_dfp{64,128}() helper functions to read/write DFP numbers correctly 2019-10-04 19:08:21 +10:00
dfp_helper.c target/ppc: remove unnecessary if() around calls to set_dfp{64,128}() in DFP macros 2019-10-04 19:08:21 +10:00
excp_helper.c
fpu_helper.c ppc: Use FPSCR defines instead of constants 2019-10-04 10:25:23 +10:00
gdbstub.c
helper.h target/ppc: update {get,set}_dfp{64,128}() helper functions to read/write DFP numbers correctly 2019-10-04 19:08:21 +10:00
helper_regs.h
int_helper.c target/ppc: use Vsr macros in BCD helpers 2019-10-04 19:08:21 +10:00
internal.h ppc: Add support for 'mffscrn','mffscrni' instructions 2019-10-04 10:25:23 +10:00
kvm-stub.c
kvm.c spapr/kvm: Set default cpu model for all machine classes 2019-11-18 11:50:39 +01:00
kvm_ppc.h
machine.c
mem_helper.c
mfrom_table.inc.c
mfrom_table_gen.c
misc_helper.c
mmu-book3s-v3.c
mmu-book3s-v3.h
mmu-hash32.c
mmu-hash32.h
mmu-hash64.c
mmu-hash64.h
mmu-radix64.c
mmu-radix64.h
mmu_helper.c
monitor.c
timebase_helper.c
trace-events
translate.c target/ppc: fetch code with translator_ld 2019-10-28 15:12:38 +00:00
translate_init.inc.c ppc/kvm: Skip writing DPDES back when in run time state 2019-10-04 10:25:23 +10:00
user_only_helper.c