arm64: kpti: Make use of nG dependent on arm64_kernel_unmapped_at_el0()

Commit 41acec6240 upstream.

To allow systems which do not require kpti to continue running with
global kernel mappings (which appears to be a requirement for Cavium
ThunderX due to a CPU erratum), make the use of nG in the kernel page
tables dependent on arm64_kernel_unmapped_at_el0(), which is resolved
at runtime.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Will Deacon 2018-01-29 11:59:53 +00:00 • committed by Greg Kroah-Hartman
commit 3fb3a06fb8
2 changed files with 16 additions and 26 deletions