]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: compat: Add KUSER_HELPERS config option
authorVincenzo Frascino <vincenzo.frascino@arm.com>
Mon, 15 Apr 2019 09:49:37 +0000 (10:49 +0100)
committerWill Deacon <will.deacon@arm.com>
Tue, 23 Apr 2019 17:01:58 +0000 (18:01 +0100)
commit55234ccee542b10266ae8d817b0fb3cca053f0d2
tree67550d4018c6cc1e368214556d744317da53e689
parent508b4c651715adfd42621b5aa603c3a13ab61ff0
arm64: compat: Add KUSER_HELPERS config option

When kuser helpers are enabled the kernel maps the relative code at
a fixed address (0xffff0000). Making configurable the option to disable
them means that the kernel can remove this mapping and any access to
this memory area results in a sigfault.

Add a KUSER_HELPERS config option that can be used to disable the
mapping when it is turned off.

This option can be turned off if and only if the applications are
designed specifically for the platform and they do not make use of the
kuser helpers code.

Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
[will: Use IS_ENABLED() instead of #ifdef]
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/Kconfig
arch/arm64/kernel/Makefile
arch/arm64/kernel/kuser32.S
arch/arm64/kernel/vdso.c