diff options
author | Michal Simek <michal.simek@xilinx.com> | 2013-08-23 01:16:50 -0400 |
---|---|---|
committer | Michal Simek <michal.simek@xilinx.com> | 2014-01-27 05:26:32 -0500 |
commit | 34b9c07a3b644760159571ee99d0f7fc67b83a8d (patch) | |
tree | 2902a75c08c09fba499e7307bd0ff7aa56432189 /arch/microblaze | |
parent | 17578ea198a9b9210ba7846029624d57be6acea2 (diff) |
microblaze: Disable stack protection from bootloader
Microblaze without MMU can use stack protection in bootloader
and kernel should clear this setting ASAP.
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'arch/microblaze')
-rw-r--r-- | arch/microblaze/kernel/head.S | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/microblaze/kernel/head.S b/arch/microblaze/kernel/head.S index 817b7eec95b6..b7fb0438458c 100644 --- a/arch/microblaze/kernel/head.S +++ b/arch/microblaze/kernel/head.S | |||
@@ -64,6 +64,10 @@ real_start: | |||
64 | #endif | 64 | #endif |
65 | 65 | ||
66 | mts rmsr, r0 | 66 | mts rmsr, r0 |
67 | /* Disable stack protection from bootloader */ | ||
68 | mts rslr, r0 | ||
69 | addi r8, r0, 0xFFFFFFF | ||
70 | mts rshr, r8 | ||
67 | /* | 71 | /* |
68 | * According to Xilinx, msrclr instruction behaves like 'mfs rX,rpc' | 72 | * According to Xilinx, msrclr instruction behaves like 'mfs rX,rpc' |
69 | * if the msrclr instruction is not enabled. We use this to detect | 73 | * if the msrclr instruction is not enabled. We use this to detect |