Skip to content

Commit

Permalink
ARM: 7150/1: Allow kernel unaligned accesses on ARMv6+ processors
Browse files Browse the repository at this point in the history
Recent gcc versions generate unaligned accesses by default on ARMv6 and
later processors. This patch ensures that the SCTLR.A bit is always
cleared on such processors to avoid kernel traping before
alignment_init() is called.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Tested-by: John Linn <John.Linn@xilinx.com>
Acked-by: Nicolas Pitre <nico@linaro.org>
Cc: stable@vger.kernel.org
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
ctmarinas authored and lgeek committed Feb 8, 2015
1 parent acbc585 commit 901d32d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/arm/kernel/head.S
Expand Up @@ -160,7 +160,7 @@ __secondary_data:
* registers.
*/
__enable_mmu:
#ifdef CONFIG_ALIGNMENT_TRAP
#if defined(CONFIG_ALIGNMENT_TRAP) && __LINUX_ARM_ARCH__ < 6
orr r0, r0, #CR_A
#else
bic r0, r0, #CR_A
Expand Down

0 comments on commit 901d32d

Please sign in to comment.