diff options
author | Dave Martin <dave.martin@linaro.org> | 2011-07-28 14:28:52 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2011-08-09 08:42:39 +0100 |
commit | 088c01f1e39dbe93a13e0b00f4532ed8b79d35f4 (patch) | |
tree | beaf9200bfd86e7250413a1c5490457bab90c8d3 /README | |
parent | bf912d99e94cd1f43a7decce2e9b79a3ca7f2418 (diff) | |
download | blackbird-op-linux-088c01f1e39dbe93a13e0b00f4532ed8b79d35f4.tar.gz blackbird-op-linux-088c01f1e39dbe93a13e0b00f4532ed8b79d35f4.zip |
ARM: 7007/1: alignment: Prevent ignoring of faults with ARMv6 unaligned access model
Currently, it's possible to set the kernel to ignore alignment
faults when changing the alignment fault handling mode at runtime
via /proc/sys/alignment, even though this is undesirable on ARMv6
and above, where it can result in infinite spins where an un-fixed-
up instruction repeatedly faults.
In addition, the kernel clobbers any alignment mode specified on
the command-line if running on ARMv6 or above.
This patch factors out the necessary safety check into a couple of
new helper functions, and checks and modifies the fault handling
mode as appropriate on boot and on writes to /proc/cpu/alignment.
Prior to ARMv6, the behaviour is unchanged.
For ARMv6 and above, the behaviour changes as follows:
* Attempting to ignore faults on ARMv6 results in the mode being
forced to UM_FIXUP instead. A warning is printed if this
happened as a result of a write to /proc/cpu/alignment. The
user's UM_WARN bit (if present) is still honoured.
* An alignment= argument from the kernel command-line is now
honoured, except that the kernel will modify the specified mode
as described above. This is allows modes such as UM_SIGNAL and
UM_WARN to be active immediately from boot, which is useful for
debugging purposes.
Signed-off-by: Dave Martin <dave.martin@linaro.org>
Acked-by: Nicolas Pitre <nicolas.pitre@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions