OSDN Git Service

UPSTREAM: arm64: kaslr: Put kernel vectors address in separate data page
authorWill Deacon <will.deacon@arm.com>
Wed, 6 Dec 2017 11:24:02 +0000 (11:24 +0000)
committerGreg Kroah-Hartman <gregkh@google.com>
Fri, 5 Jan 2018 21:46:47 +0000 (22:46 +0100)
commit06fe41f85237c9d3c915447b9f9d51f1e85c4891
tree51617b8621da3b9dac99f2de80c661d8652d7b19
parentd7013ede260486a55b254e1f95127a2b0f24cdc1
UPSTREAM: arm64: kaslr: Put kernel vectors address in separate data page

The literal pool entry for identifying the vectors base is the only piece
of information in the trampoline page that identifies the true location
of the kernel.

This patch moves it into a page-aligned region of the .rodata section
and maps this adjacent to the trampoline text via an additional fixmap
entry, which protects against any accidental leakage of the trampoline
contents.

Suggested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
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 6c27c4082f4f70b9f41df4d0adf51128b40351df)

Change-Id: Id125331e7fa5645c801a26843fecca53f8773705
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
arch/arm64/include/asm/fixmap.h
arch/arm64/kernel/entry.S
arch/arm64/kernel/vmlinux.lds.S
arch/arm64/mm/mmu.c