]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
arm64: tls: Avoid unconditional zeroing of tpidrro_el0 for native tasks
authorWill Deacon <will.deacon@arm.com>
Tue, 14 Nov 2017 14:33:28 +0000 (14:33 +0000)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Mon, 5 Feb 2018 17:23:02 +0000 (18:23 +0100)
commit7144db30a62db929571714349bbf270eae2b9a23
tree7ae2d46199927d9dab4f2f2c4a9abb509c3f6688
parent498359bb80b8d576134f5ecd1fe73347d7f84944
arm64: tls: Avoid unconditional zeroing of tpidrro_el0 for native tasks

CVE-2017-5754 ARM64 KPTI fixes

When unmapping the kernel at EL0, we use tpidrro_el0 as a scratch register
during exception entry from native tasks and subsequently zero it in
the kernel_ventry macro. We can therefore avoid zeroing tpidrro_el0
in the context-switch path for native tasks using the entry trampoline.

Reviewed-by: Mark Rutland <mark.rutland@arm.com>
Tested-by: Laura Abbott <labbott@redhat.com>
Tested-by: Shanker Donthineni <shankerd@codeaurora.org>
Signed-off-by: Will Deacon <will.deacon@arm.com>
(cherry picked from commit 18011eac28c7cb31c87b86b7d0e5b01894405c7f)
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Acked-by: Brad Figg <brad.figg@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
arch/arm64/kernel/process.c