qemu-e2k/target/ppc
David Gibson e5ca28ecab spapr: Don't rewrite mmu capabilities in KVM mode
Currently during KVM initialization on POWER, kvm_fixup_page_sizes()
rewrites a bunch of information in the cpu state to reflect the
capabilities of the host MMU and KVM.  This overwrites the information
that's already there reflecting how the TCG implementation of the MMU will
operate.

This means that we can get guest-visibly different behaviour between KVM
and TCG (and between different KVM implementations).  That's bad.  It also
prevents migration between KVM and TCG.

The pseries machine type now has filtering of the pagesizes it allows the
guest to use which means it can present a consistent model of the MMU
across all accelerators.

So, we can now replace kvm_fixup_page_sizes() with kvm_check_mmu() which
merely verifies that the expected cpu model can be faithfully handled by
KVM, rather than updating the cpu model to match KVM.

We call kvm_check_mmu() from the spapr cpu reset code.  This is a hack:
conceptually it makes more sense where fixup_page_sizes() was - in the KVM
cpu init path.  However, doing that would require moving the platform's
pagesize filtering much earlier, which would require a lot of work making
further adjustments.  There wouldn't be a lot of concrete point to doing
that, since the only KVM implementation which has the awkward MMU
restrictions is KVM HV, which can only work with an spapr guest anyway.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
2018-06-22 14:19:07 +10:00
..
translate
arch_dump.c
compat.c target/ppc: Allow cpu compatiblity checks based on type, not instance 2018-06-21 21:22:53 +10:00
cpu-models.c
cpu-models.h
cpu-qom.h
cpu.c
cpu.h target/ppc: Allow cpu compatiblity checks based on type, not instance 2018-06-21 21:22:53 +10:00
dfp_helper.c
excp_helper.c
fpu_helper.c fpu_helper.c: fix helper_fpscr_clrbit() function 2018-06-21 21:22:53 +10:00
gdbstub.c
helper_regs.h
helper.h target/ppc: Allow privileged access to SPR_PCR 2018-06-12 09:33:52 +10:00
int_helper.c target: Do not include "exec/exec-all.h" if it is not necessary 2018-06-01 14:15:10 +02:00
internal.h
kvm_ppc.h spapr: Don't rewrite mmu capabilities in KVM mode 2018-06-22 14:19:07 +10:00
kvm-stub.c
kvm.c spapr: Don't rewrite mmu capabilities in KVM mode 2018-06-22 14:19:07 +10:00
machine.c
Makefile.objs
mem_helper.c
mfrom_table_gen.c
mfrom_table.inc.c
misc_helper.c target/ppc: Allow privileged access to SPR_PCR 2018-06-12 09:33:52 +10:00
mmu_helper.c
mmu-book3s-v3.c
mmu-book3s-v3.h
mmu-hash32.c
mmu-hash32.h
mmu-hash64.c target/ppc: Add ppc_hash64_filter_pagesizes() 2018-06-22 14:19:07 +10:00
mmu-hash64.h target/ppc: Add ppc_hash64_filter_pagesizes() 2018-06-22 14:19:07 +10:00
mmu-radix64.c
mmu-radix64.h
monitor.c
timebase_helper.c
trace-events
translate_init.inc.c target/ppc, spapr: Move VPA information to machine_data 2018-06-16 16:32:50 +10:00
translate.c target/ppc: Add missing opcode for icbt on PPC440 2018-06-21 21:22:53 +10:00
user_only_helper.c