linux/Documentation
Marc Zyngier ac821b6257 UPSTREAM: KVM: arm64: Reject VM creation when the default IPA size is unsupported
KVM/arm64 has forever used a 40bit default IPA space, partially
due to its 32bit heritage (where the only choice is 40bit).

However, there are implementations in the wild that have a *cough*
much smaller *cough* IPA space, which leads to a misprogramming of
VTCR_EL2, and a guest that is stuck on its first memory access
if userspace dares to ask for the default IPA setting (which most
VMMs do).

Instead, blundly reject the creation of such VM, as we can't
satisfy the requirements from userspace (with a one-off warning).
Also clarify the boot warning, and document that the VM creation
will fail when an unsupported IPA size is provided.

Although this is an ABI change, it doesn't really change much
for userspace:

- the guest couldn't run before this change, but no error was
  returned. At least userspace knows what is happening.

- a memory slot that was accepted because it did fit the default
  IPA space now doesn't even get a chance to be registered.

The other thing that is left doing is to convince userspace to
actually use the IPA space setting instead of relying on the
antiquated default.

Fixes: 233a7cb235 ("kvm: arm64: Allow tuning the physical address size for VM")
Signed-off-by: Marc Zyngier <maz@kernel.org>
Cc: stable@vger.kernel.org
Reviewed-by: Andrew Jones <drjones@redhat.com>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Link: https://lore.kernel.org/r/20210311100016.3830038-2-maz@kernel.org
(cherry picked from commit 7d717558dd)
Signed-off-by: Will Deacon <willdeacon@google.com>
Bug: 178098380
Test: atest VirtualizationHostTestCases on an EL2-enabled device
Change-Id: I36332fbe5606affd151976a6354f3e9c45fc214a
2021-03-15 10:47:05 +00:00
..
ABI Merge remote-tracking branch 'aosp/upstream-f2fs-stable-linux-5.10.y' into android12-5.10 2021-03-01 19:06:56 -08:00
accounting
admin-guide Merge 5.10.20 into android12-5.10 2021-03-07 12:33:33 +01:00
arm
arm64 UPSTREAM: arm64: spectre: Rename ARM64_HARDEN_EL2_VECTORS to ARM64_SPECTRE_V3A 2021-01-28 17:57:08 +00:00
block UPSTREAM: block/keyslot-manager: introduce devm_blk_ksm_init() 2021-02-23 08:10:56 +01:00
bpf
cdrom
core-api
cpu-freq
crypto
dev-tools UPSTREAM: kfence: report sensitive information based on no_hash_pointers 2021-03-01 18:11:05 +01:00
device-mapper
devicetree This is the 5.10.21 stable release 2021-03-07 12:53:30 +01:00
doc-guide
driver-api
fault-injection
fb
features
filesystems Merge 5.10.20 into android12-5.10 2021-03-07 12:33:33 +01:00
firmware_class
firmware-guide
fpga
gpu
hid
hwmon
i2c
ia64
ide
iio
infiniband
input
isdn
kbuild
kernel-hacking
leds
litmus-tests
livepatch
locking
m68k
maintainer
mhi
mips
misc-devices
netlabel
networking This is the 5.10.21 stable release 2021-03-07 12:53:30 +01:00
nios2
nvdimm
openrisc
parisc
PCI
pcmcia
power UPSTREAM: Documentation/powercap/dtpm: Add documentation for dtpm 2021-03-11 16:02:39 +00:00
powerpc
process
RCU
riscv
s390
scheduler
scsi scsi: libsas: docs: Remove notify_ha_event() 2021-03-04 11:37:17 +01:00
security watch_queue: Drop references to /dev/watch_queue 2021-03-04 11:37:59 +01:00
sh
sound
sparc
sphinx
sphinx-static
spi
staging
target
timers
trace FROMLIST: coresight: sink: Add TRBE driver 2021-03-01 12:52:16 -08:00
translations
usb
userspace-api BACKPORT: media: v4l2-ctrl: Add base layer priority id control. 2021-03-02 01:43:47 +00:00
virt UPSTREAM: KVM: arm64: Reject VM creation when the default IPA size is unsupported 2021-03-15 10:47:05 +00:00
vm
w1
watchdog
x86
xtensa
.gitignore
asm-annotations.rst x86/entry: Emit a symbol for register restoring thunk 2021-02-03 23:28:40 +01:00
atomic_bitops.txt
atomic_t.txt
Changes
CodingStyle
conf.py
COPYING-logo
docutils.conf
dontdiff
index.rst
Kconfig
logo.gif
Makefile
memory-barriers.txt
SubmittingPatches
watch_queue.rst