summaryrefslogtreecommitdiff
path: root/kernel/trace/trace_functions_graph.c
diff options
context:
space:
mode:
authorArd Biesheuvel <ard.biesheuvel@linaro.org>2016-03-21 18:35:11 +0100
committerNeeraj Upadhyay <neeraju@codeaurora.org>2017-03-22 19:22:53 +0530
commit9fcccba399ea0d840d0f6e60ff7efccef1d7a08e (patch)
tree359362191672e1220e15c1ff33d356f245f584b1 /kernel/trace/trace_functions_graph.c
parentc1ef16be6d3c5606edb7a23398611d010b405aa8 (diff)
arm64: kaslr: use callee saved register to preserve SCTLR across C call
The KASLR code incorrectly expects the contents of x18 to be preserved across a call into C code, and uses it to stash the contents of SCTLR_EL1 before enabling the MMU. If the MMU needs to be disabled again to create the randomized kernel mapping, x18 is written back to SCTLR_EL1, which is likely to crash the system if x18 has been clobbered by kasan_early_init() or kaslr_early_init(). So use x22 instead, which is not in use so far in head.S Change-Id: I6a79b0c3b2e2306d080406c7f617483f6f1519b0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Git-commit: d5e5743797adc26e09db262e7a4b6b81d8c0f45c Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git [neeraju@codeaurora.org: resolve trivial merge conflicts] Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
Diffstat (limited to 'kernel/trace/trace_functions_graph.c')
0 files changed, 0 insertions, 0 deletions