mirror_qemu/hw
David Gibson 49e9fdd741 spapr: Correctly set LPCR[GTSE] in H_REGISTER_PROCESS_TABLE
176dccee "target/ppc/spapr: Clear partition table entry when allocating
hash table" reworked the H_REGISTER_PROCESS_TABLE hypercall, but
unfortunately due to a small error no longer correctly sets the LPCR[GTSE]
bit which allows the guest to directly execute (some types of) tlbie (TLB
flush) instructions without involving the hypervisor.

We got away with this, initially, because POWER9 did not have hypervisor
mode enabled in its msr_mask, which meant we didn't actually run hypervisor
privilege checks in TCG at all.  However, da874d90 "target/ppc: add HV
support for POWER9" turned on HV support on POWER9 for the benefit of the
powernv machine type.

This exposed the earlier bug in H_REGISTER_PROCESS_TABLE, and causes guests
which rely on LPCR[GTSE] (i.e. basically all of them) to crash during early
boot when their first tlbie instruction causes an unexpected trap.

Fixes: 176dccee target/ppc/spapr: Clear partition table entry when allocating hash table
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Greg Kurz <groug@kaod.org>
Tested-by: Cleber Rosa <crosa@redhat.com>
2019-03-19 15:20:14 +11:00
..
9pfs virtio: express virtio dependencies with Kconfig 2019-03-07 21:45:53 +01:00
acpi i386, acpi: check acpi_memory_hotplug capacity in pre_plug 2019-03-12 22:31:21 -04:00
adc kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
alpha - qtest fixes 2019-03-08 16:31:34 +00:00
arm hw/arm/virt-acpi-build: use PCIE_MMCFG_BUS to retrieve end_bus_number 2019-03-15 11:12:29 +00:00
audio audio: use qapi AudioFormat instead of audfmt_e 2019-03-11 10:29:26 +01:00
block pci, pc, virtio: features, fixes, cleanups 2019-03-13 19:10:40 +00:00
bt kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
char spapr: Use CamelCase properly 2019-03-12 14:33:05 +11:00
core Machine queue, 2019-03-11 2019-03-12 15:25:46 +00:00
cpu kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
cris cris-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
display virtio-gpu: clear command and fence queues on reset 2019-03-18 13:10:57 +01:00
dma isa: express dependencies with kconfig 2019-03-07 21:45:53 +01:00
gpio i2c: express dependencies with Kconfig 2019-03-07 21:45:53 +01:00
hppa Update seabios-hppa to latest upstream 2019-03-15 10:11:16 -07:00
hyperv hyperv: express dependencies with kconfig 2019-03-07 21:45:53 +01:00
i2c PPC: E500: Add FSL I2C controller and integrate RTC with it 2019-03-12 14:33:04 +11:00
i386 i386, acpi: check acpi_memory_hotplug capacity in pre_plug 2019-03-12 22:31:21 -04:00
ide isa: express dependencies with kconfig 2019-03-07 21:45:53 +01:00
input audio: use qapi AudioFormat instead of audfmt_e 2019-03-11 10:29:26 +01:00
intc hw/intc/bcm2836_control: Implement local timer 2019-03-15 11:12:28 +00:00
ipack build: convert pci.mak to Kconfig 2019-03-07 21:45:53 +01:00
ipmi ipmi: express dependencies with kconfig 2019-03-07 21:45:53 +01:00
isa i386, acpi: check acpi_memory_hotplug capacity in pre_plug 2019-03-12 22:31:21 -04:00
lm32 pflash: Clean up after commit 368a354f02, part 2 2019-03-11 22:53:44 +01:00
m68k m68k-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
mem ppc64: Express dependencies of 'pseries' and 'powernv' machines with kconfig 2019-03-07 21:45:53 +01:00
microblaze pflash: Clean up after commit 368a354f02, part 2 2019-03-11 22:53:44 +01:00
mips pflash: Clean up after commit 368a354f02, part 2 2019-03-11 22:53:44 +01:00
misc sparc-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
moxie moxie-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
net spapr: Use CamelCase properly 2019-03-12 14:33:05 +11:00
nios2 nios2-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
nvram fw_cfg and thunk code clean up 2019-03-12 12:29:53 +00:00
openrisc or1k-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
pci pcie: Add a simple PCIe ACS (Access Control Services) helper function 2019-03-12 22:31:21 -04:00
pci-bridge gen_pcie_root_port: Add ACS (Access Control Services) capability 2019-03-12 22:31:21 -04:00
pci-host ppc: Express dependencies of the Mac machines with kconfig 2019-03-07 21:46:19 +01:00
pcmcia kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
ppc spapr: Correctly set LPCR[GTSE] in H_REGISTER_PROCESS_TABLE 2019-03-19 15:20:14 +11:00
rdma hw/rdma: Fix the error prints in create_qp_rings() 2019-03-16 15:52:44 +02:00
riscv riscv/Kconfig: enable PCI_DEVICES 2019-03-11 16:33:49 +01:00
s390x s390x: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
scsi vhost-user: simplify vhost_user_init/vhost_user_cleanup 2019-03-12 21:22:31 -04:00
sd hw/sd/sdhci: Move PCI-related code into a separate file 2019-03-12 07:49:04 +01:00
sh4 pflash: Clean up after commit 368a354f02, part 2 2019-03-11 22:53:44 +01:00
smbios kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
sparc sparc-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
sparc64 sparc64-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
ssi ssi: express dependencies with kconfig 2019-03-07 21:45:53 +01:00
timer i386-softmmu.mak: remove all CONFIG_* except boards definitions 2019-03-07 21:45:53 +01:00
tpm tpm: express dependencies with Kconfig 2019-03-07 21:45:53 +01:00
tricore - qtest fixes 2019-03-08 16:31:34 +00:00
unicore32 unicore32-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
usb audio: use qapi AudioFormat instead of audfmt_e 2019-03-11 10:29:26 +01:00
vfio VFIO updates 2019-03-11 2019-03-12 13:37:29 +00:00
virtio vhost-user: Support transferring inflight buffer between qemu and backend 2019-03-12 22:31:21 -04:00
watchdog ptimer: express dependencies with Kconfig 2019-03-07 21:45:53 +01:00
xen xen: fix xen-bus state model to allow frontend re-connection 2019-02-04 11:04:49 +00:00
xenpv xen: Replace few mentions of xend by libxl 2019-01-14 13:45:40 +00:00
xtensa hw: Use PFLASH_CFI0{1,2} and TYPE_PFLASH_CFI0{1,2} 2019-03-11 22:53:44 +01:00
Kconfig ptimer: express dependencies with Kconfig 2019-03-07 21:45:53 +01:00
Makefile.objs i2c: express dependencies with Kconfig 2019-03-07 21:45:53 +01:00