aboutsummaryrefslogtreecommitdiffstats
path: root/arch/microblaze/kernel
diff options
context:
space:
mode:
authorMichal Simek <monstr@monstr.eu>2011-01-28 07:14:58 -0500
committerMichal Simek <monstr@monstr.eu>2011-01-28 08:05:00 -0500
commit9c749e177ccc0b3ee9589425c7255079e7a726fc (patch)
tree24a4f8f56b4f6b545bd4c688d50e6d855a43d731 /arch/microblaze/kernel
parent026a2078791b64aede220b1b1a3e4dfe4ab175e7 (diff)
microblaze: Fix unaligned issue on MMU system with BS=0 DIV=1
Unaligned code use shift for finding register operand. There is used BSRLI(r8,r8,2) macro which is expand for BS=0, DIV=1 by ori rD, r0, (1 << imm); \ idivu rD, rD, rA but if rD is equal rA then ori instruction rewrite value which should be devide. The patch remove this macro which use idivu instruction because idivu takes 32/34 cycles. The highest shifting is 20 which takes 20 cycles. Signed-off-by: Michal Simek <monstr@monstr.eu>
Diffstat (limited to 'arch/microblaze/kernel')
-rw-r--r--arch/microblaze/kernel/hw_exception_handler.S4
1 files changed, 0 insertions, 4 deletions
diff --git a/arch/microblaze/kernel/hw_exception_handler.S b/arch/microblaze/kernel/hw_exception_handler.S
index 25f6e07d8de8..782680de3121 100644
--- a/arch/microblaze/kernel/hw_exception_handler.S
+++ b/arch/microblaze/kernel/hw_exception_handler.S
@@ -147,10 +147,6 @@
147 #if CONFIG_XILINX_MICROBLAZE0_USE_BARREL > 0 147 #if CONFIG_XILINX_MICROBLAZE0_USE_BARREL > 0
148 #define BSRLI(rD, rA, imm) \ 148 #define BSRLI(rD, rA, imm) \
149 bsrli rD, rA, imm 149 bsrli rD, rA, imm
150 #elif CONFIG_XILINX_MICROBLAZE0_USE_DIV > 0
151 #define BSRLI(rD, rA, imm) \
152 ori rD, r0, (1 << imm); \
153 idivu rD, rD, rA
154 #else 150 #else
155 #define BSRLI(rD, rA, imm) BSRLI ## imm (rD, rA) 151 #define BSRLI(rD, rA, imm) BSRLI ## imm (rD, rA)
156 /* Only the used shift constants defined here - add more if needed */ 152 /* Only the used shift constants defined here - add more if needed */