aboutsummaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorKevin Hilman <khilman@linaro.org>2015-12-08 16:03:46 -0800
committerKevin Hilman <khilman@linaro.org>2015-12-08 16:03:46 -0800
commitabacc500b7cddb62f7efc04d7c21d56375f42646 (patch)
tree66f38c531bfce494b836d9c9227fe208dd79e955 /Documentation
parente46761bb82818df3c422f784cc8fba9b40fd0ad6 (diff)
parent20af540051e1c1f7a7d9b9e4613c1ecc53ded4a6 (diff)
downloadlinux-linaro-stable-abacc500b7cddb62f7efc04d7c21d56375f42646.tar.gz
Merge branch 'pan-3.18' of https://git.linaro.org/people/david.brown/linux-lsk into linux-linaro-lsk-v3.18
* 'pan-3.18' of https://git.linaro.org/people/david.brown/linux-lsk: (27 commits) arm64: kernel: Add support for Privileged Access Never arm64: Generalise msr_s/mrs_s operations arm64: kernel: Add cpufeature 'enable' callback arm64: kernel: Add cpuid_feature_extract_field() for 4bit sign extension arm64: kernel: Add min_field_value and use '>=' for feature detection arm64: kernel: Add optional CONFIG_ parameter to ALTERNATIVE() arm64: alternative: Provide if/else/endif assembler macros arm64: alternative: Work around .inst assembler bugs arm64: alternative: Merge alternative-asm.h into alternative.h arm64: Add AArch32 instruction set condition code checks arm64: lib: use pair accessors for copy_*_user routines arm64/uaccess: fix sparse errors arm64: kernel: Move config_sctlr_el1 arm64: Emulate SETEND for AArch32 tasks arm64: kconfig: move emulation option under kernel features arm64: Consolidate hotplug notifier for instruction emulation arm64: fix return code check when changing emulation handler arm64: Trace emulation of AArch32 legacy instructions arm64: Emulate CP15 Barrier instructions arm64: Port SWP/SWPB emulation support from arm ... Conflicts: arch/arm64/kernel/Makefile
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/arm64/legacy_instructions.txt57
1 files changed, 57 insertions, 0 deletions
diff --git a/Documentation/arm64/legacy_instructions.txt b/Documentation/arm64/legacy_instructions.txt
new file mode 100644
index 000000000000..01bf3d9fac85
--- /dev/null
+++ b/Documentation/arm64/legacy_instructions.txt
@@ -0,0 +1,57 @@
+The arm64 port of the Linux kernel provides infrastructure to support
+emulation of instructions which have been deprecated, or obsoleted in
+the architecture. The infrastructure code uses undefined instruction
+hooks to support emulation. Where available it also allows turning on
+the instruction execution in hardware.
+
+The emulation mode can be controlled by writing to sysctl nodes
+(/proc/sys/abi). The following explains the different execution
+behaviours and the corresponding values of the sysctl nodes -
+
+* Undef
+ Value: 0
+ Generates undefined instruction abort. Default for instructions that
+ have been obsoleted in the architecture, e.g., SWP
+
+* Emulate
+ Value: 1
+ Uses software emulation. To aid migration of software, in this mode
+ usage of emulated instruction is traced as well as rate limited
+ warnings are issued. This is the default for deprecated
+ instructions, .e.g., CP15 barriers
+
+* Hardware Execution
+ Value: 2
+ Although marked as deprecated, some implementations may support the
+ enabling/disabling of hardware support for the execution of these
+ instructions. Using hardware execution generally provides better
+ performance, but at the loss of ability to gather runtime statistics
+ about the use of the deprecated instructions.
+
+The default mode depends on the status of the instruction in the
+architecture. Deprecated instructions should default to emulation
+while obsolete instructions must be undefined by default.
+
+Note: Instruction emulation may not be possible in all cases. See
+individual instruction notes for further information.
+
+Supported legacy instructions
+-----------------------------
+* SWP{B}
+Node: /proc/sys/abi/swp
+Status: Obsolete
+Default: Undef (0)
+
+* CP15 Barriers
+Node: /proc/sys/abi/cp15_barrier
+Status: Deprecated
+Default: Emulate (1)
+
+* SETEND
+Node: /proc/sys/abi/setend
+Status: Deprecated
+Default: Emulate (1)*
+Note: All the cpus on the system must have mixed endian support at EL0
+for this feature to be enabled. If a new CPU - which doesn't support mixed
+endian - is hotplugged in after this feature has been enabled, there could
+be unexpected results in the application.