]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
arm64: KVM: Increment PC after handling an SMC trap
authorMarc Zyngier <marc.zyngier@arm.com>
Tue, 6 Feb 2018 17:56:07 +0000 (17:56 +0000)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Wed, 7 Mar 2018 11:14:11 +0000 (12:14 +0100)
commit6fe176d72c7ef7f4b979050f1fbcdbc02b3aed08
tree7ec25c569c574b5d34778eee9054311a9b3b3e15
parentf56f3b7c95a4f73f419353075cdcbb9120572c8e
arm64: KVM: Increment PC after handling an SMC trap

Commit f5115e8869e1 upstream.

When handling an SMC trap, the "preferred return address" is set
to that of the SMC, and not the next PC (which is a departure from
the behaviour of an SMC that isn't trapped).

Increment PC in the handler, as the guest is otherwise forever
stuck...

Cc: stable@vger.kernel.org
Fixes: acfb3b883f6d ("arm64: KVM: Fix SMCCC handling of unimplemented SMC/HVC calls")
Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org>
Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 0b3512fa7b0a4f1f187a5e38112c5bebaea87fc1)

CVE-2017-5753
CVE-2017-5715
CVE-2017-5754

Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Acked-by: Brad Figg <brad.figg@canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Acked-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
arch/arm64/kvm/handle_exit.c