summaryrefslogtreecommitdiff
path: root/lib_arm
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2009-08-06 21:29:59 +0200
committerWolfgang Denk <wd@denx.de>2009-08-09 23:08:59 +0200
commit59b4d7471c42e955bd9846892a0cc7478171778d (patch)
tree15db0fed51aa56d6337019c1002e14c559d08f11 /lib_arm
parent197324d7d998a791e5137b8176981b4af25220ae (diff)
downloadu-boot-imx-59b4d7471c42e955bd9846892a0cc7478171778d.zip
u-boot-imx-59b4d7471c42e955bd9846892a0cc7478171778d.tar.gz
u-boot-imx-59b4d7471c42e955bd9846892a0cc7478171778d.tar.bz2
ARM EABI: add new helper functions resp. function names
The ARM EABI defines new names for GCC helper functions, and GCC seems to need some new functions as well. This patch is a minimal-invasive approach to fix problems with EABI conformant tool chains (to be used with "USE_PRIVATE_LIBGCC=yes"). Signed-off-by: Wolfgang Denk <wd@denx.de> Tested-by: Dirk Behme <dirk.behme@googlemail.com>
Diffstat (limited to 'lib_arm')
-rw-r--r--lib_arm/_ashldi3.S2
-rw-r--r--lib_arm/_ashrdi3.S2
-rw-r--r--lib_arm/_divsi3.S2
-rw-r--r--lib_arm/_lshrdi3.S2
-rw-r--r--lib_arm/_udivsi3.S34
5 files changed, 33 insertions, 9 deletions
diff --git a/lib_arm/_ashldi3.S b/lib_arm/_ashldi3.S
index de4403d..834ddc2 100644
--- a/lib_arm/_ashldi3.S
+++ b/lib_arm/_ashldi3.S
@@ -35,7 +35,9 @@ Boston, MA 02110-1301, USA. */
#endif
.globl __ashldi3
+.globl __aeabi_llsl
__ashldi3:
+__aeabi_llsl:
subs r3, r2, #32
rsb ip, r2, #32
diff --git a/lib_arm/_ashrdi3.S b/lib_arm/_ashrdi3.S
index 5edbcb3..671ac87 100644
--- a/lib_arm/_ashrdi3.S
+++ b/lib_arm/_ashrdi3.S
@@ -35,7 +35,9 @@ Boston, MA 02110-1301, USA. */
#endif
.globl __ashrdi3
+.globl __aeabi_lasr
__ashrdi3:
+__aeabi_lasr:
subs r3, r2, #32
rsb ip, r2, #32
diff --git a/lib_arm/_divsi3.S b/lib_arm/_divsi3.S
index 9dc15f6..cfbadb2 100644
--- a/lib_arm/_divsi3.S
+++ b/lib_arm/_divsi3.S
@@ -96,7 +96,9 @@
.align 5
.globl __divsi3
+.globl __aeabi_idiv
__divsi3:
+__aeabi_idiv:
cmp r1, #0
eor ip, r0, r1 @ save the sign of the result.
beq Ldiv0
diff --git a/lib_arm/_lshrdi3.S b/lib_arm/_lshrdi3.S
index fabfd9f..e7fa799 100644
--- a/lib_arm/_lshrdi3.S
+++ b/lib_arm/_lshrdi3.S
@@ -35,7 +35,9 @@ Boston, MA 02110-1301, USA. */
#endif
.globl __lshrdi3
+.globl __aeabi_llsr
__lshrdi3:
+__aeabi_llsr:
subs r3, r2, #32
rsb ip, r2, #32
diff --git a/lib_arm/_udivsi3.S b/lib_arm/_udivsi3.S
index a3f9b59..1309802 100644
--- a/lib_arm/_udivsi3.S
+++ b/lib_arm/_udivsi3.S
@@ -11,9 +11,12 @@ curbit .req r3
/* pc .req r15 */
.text
.globl __udivsi3
- .type __udivsi3 ,function
+ .type __udivsi3 ,function
+ .globl __aeabi_uidiv
+ .type __aeabi_uidiv ,function
.align 0
- __udivsi3 :
+ __udivsi3:
+ __aeabi_uidiv:
cmp divisor, #0
beq Ldiv0
mov curbit, #1
@@ -68,10 +71,23 @@ Ldiv0:
mov r0, #0 @ about as wrong as it could be
ldmia sp!, {pc}
.size __udivsi3 , . - __udivsi3
-/* # 235 "libgcc1.S" */
-/* # 320 "libgcc1.S" */
-/* # 421 "libgcc1.S" */
-/* # 433 "libgcc1.S" */
-/* # 456 "libgcc1.S" */
-/* # 500 "libgcc1.S" */
-/* # 580 "libgcc1.S" */
+
+.globl __aeabi_uidivmod
+__aeabi_uidivmod:
+
+ stmfd sp!, {r0, r1, ip, lr}
+ bl __aeabi_uidiv
+ ldmfd sp!, {r1, r2, ip, lr}
+ mul r3, r0, r2
+ sub r1, r1, r3
+ mov pc, lr
+
+.globl __aeabi_idivmod
+__aeabi_idivmod:
+
+ stmfd sp!, {r0, r1, ip, lr}
+ bl __aeabi_idiv
+ ldmfd sp!, {r1, r2, ip, lr}
+ mul r3, r0, r2
+ sub r1, r1, r3
+ mov pc, lr