Commit 7a085672 authored by Russell King's avatar Russell King

[ARM] Fix div64 implementation.

Our do_div implementation can't correctly handle divisors with the
top bit set.  This cset fixes this up with a minimal change.
parent 5b84ad19
...@@ -30,6 +30,8 @@ ENTRY(do_div64) ...@@ -30,6 +30,8 @@ ENTRY(do_div64)
moveq lr, #1 @ only divide low bits moveq lr, #1 @ only divide low bits
moveq nh, onl moveq nh, onl
tst dh, #0x80000000
bne 2f
1: cmp nh, dh 1: cmp nh, dh
bls 2f bls 2f
add lr, lr, #1 add lr, lr, #1
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment