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>
This commit is contained in:

committed by
Will Deacon

parent
1255a7341b
commit
af1b3cf2c2
@@ -6,10 +6,9 @@
|
||||
* Copyright (C) 2005-2011 Nicolas Pitre <nico@fluxnic.net>
|
||||
* Copyright (C) 2012-2018 ARM Ltd.
|
||||
*
|
||||
* Each segment is 32-byte aligned and will be moved to the top of the high
|
||||
* vector page. New segments (if ever needed) must be added in front of
|
||||
* existing ones. This mechanism should be used only for things that are
|
||||
* really small and justified, and not be abused freely.
|
||||
* The kuser helpers below are mapped at a fixed address by
|
||||
* aarch32_setup_additional_pages() and are provided for compatibility
|
||||
* reasons with 32 bit (aarch32) applications that need them.
|
||||
*
|
||||
* See Documentation/arm/kernel_user_helpers.txt for formal definitions.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user