https://github.com/torvalds/linux
Revision 27e91ad1e746e341ca2312f29bccb9736be7b476 authored by Marc Zyngier on 06 March 2018, 21:44:37 UTC, committed by Marc Zyngier on 14 March 2018, 18:31:26 UTC
On guest exit, and when using GICv2 on GICv3, we use a dsb(st) to
force synchronization between the memory-mapped guest view and
the system-register view that the hypervisor uses.

This is incorrect, as the spec calls out the need for "a DSB whose
required access type is both loads and stores with any Shareability
attribute", while we're only synchronizing stores.

We also lack an isb after the dsb to ensure that the latter has
actually been executed before we start reading stuff from the sysregs.

The fix is pretty easy: turn dsb(st) into dsb(sy), and slap an isb()
just after.

Cc: stable@vger.kernel.org
Fixes: f68d2b1b73cc ("arm64: KVM: Implement vgic-v3 save/restore")
Acked-by: Christoffer Dall <cdall@kernel.org>
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
1 parent 16ca6a6
History
Tip revision: 27e91ad1e746e341ca2312f29bccb9736be7b476 authored by Marc Zyngier on 06 March 2018, 21:44:37 UTC
kvm: arm/arm64: vgic-v3: Tighten synchronization for guests using v2 on v3
Tip revision: 27e91ad
File Mode Size
Documentation
LICENSES
arch
block
certs
crypto
drivers
firmware
fs
include
init
ipc
kernel
lib
mm
net
samples
scripts
security
sound
tools
usr
virt
.cocciconfig -rw-r--r-- 59 bytes
.get_maintainer.ignore -rw-r--r-- 31 bytes
.gitattributes -rw-r--r-- 30 bytes
.gitignore -rw-r--r-- 1.4 KB
.mailmap -rw-r--r-- 8.8 KB
COPYING -rw-r--r-- 18.3 KB
CREDITS -rw-r--r-- 96.2 KB
Kbuild -rw-r--r-- 2.2 KB
Kconfig -rw-r--r-- 287 bytes
MAINTAINERS -rw-r--r-- 435.0 KB
Makefile -rw-r--r-- 60.1 KB
README -rw-r--r-- 722 bytes

README

back to top