Skip to content

Commit dd72078

Browse files
brooniectmarinas
authored andcommitted
arm64: Document sysctls for emulated deprecated instructions
We have support for emulating a number of deprecated instructions in the kernel with individual Kconfig options enabling this support per instruction. In addition to the Kconfig options we also provide runtime control via sysctls but this is not currently mentioned in the Kconfig so not very discoverable for users. This is particularly important for SWP/SWPB since this is disabled by default at runtime and must be enabled via the sysctl, causing considerable frustration for users who have enabled the config option and are then confused to find that the instruction is still faulting. Add a reference to the sysctls in the help text for each of the config options, noting that SWP/SWPB is disabled by default, to improve the user experience. Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Catalin Marinas <[email protected]>
1 parent 638d503 commit dd72078

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

arch/arm64/Kconfig

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1327,6 +1327,8 @@ config SWP_EMULATION
13271327
ARMv8 obsoletes the use of A32 SWP/SWPB instructions such that
13281328
they are always undefined. Say Y here to enable software
13291329
emulation of these instructions for userspace using LDXR/STXR.
1330+
This feature can be controlled at runtime with the abi.swp
1331+
sysctl which is disabled by default.
13301332

13311333
In some older versions of glibc [<=2.8] SWP is used during futex
13321334
trylock() operations with the assumption that the code will not
@@ -1353,7 +1355,8 @@ config CP15_BARRIER_EMULATION
13531355
Say Y here to enable software emulation of these
13541356
instructions for AArch32 userspace code. When this option is
13551357
enabled, CP15 barrier usage is traced which can help
1356-
identify software that needs updating.
1358+
identify software that needs updating. This feature can be
1359+
controlled at runtime with the abi.cp15_barrier sysctl.
13571360

13581361
If unsure, say Y
13591362

@@ -1364,7 +1367,8 @@ config SETEND_EMULATION
13641367
AArch32 EL0, and is deprecated in ARMv8.
13651368

13661369
Say Y here to enable software emulation of the instruction
1367-
for AArch32 userspace code.
1370+
for AArch32 userspace code. This feature can be controlled
1371+
at runtime with the abi.setend sysctl.
13681372

13691373
Note: All the cpus on the system must have mixed endian support at EL0
13701374
for this feature to be enabled. If a new CPU - which doesn't support mixed

0 commit comments

Comments
 (0)