ARM: update asm implementation and remove -lgcc from arm
PATCH 1/1 ARM: update asm implementation and remove -lgcc from arm
libgcc functions - functions that are used internally by the compiler
Signed-off-by Jean-Christophe PLAGNIOL-VILLARD <[email protected]>
---
Makefile | 5 +-
include/asm-arm/assembler.h | 116 ++++++++++++
include/asm-arm/linkage.h | 11 ++
include/linux/linkage.h | 95 ++++++++++
lib_arm/Makefile | 9 +-
lib_arm/_divsi3.S | 140 ---------------
lib_arm/_modsi3.S | 99 -----------
lib_arm/_udivsi3.S | 77 --------
lib_arm/_umodsi3.S | 88 ----------
lib_arm/{_ashldi3.S => ashldi3.S} | 9 +-
lib_arm/{_ashrdi3.S => ashrdi3.S} | 9 +-
lib_arm/lib1funcs.S | 348 +++++++++++++++++++++++++++++++++++++
12 files changed, 591 insertions(+), 415 deletions(-)
create mode 100644 include/asm-arm/assembler.h
create mode 100644 include/asm-arm/linkage.h
create mode 100644 include/linux/linkage.h
delete mode 100644 lib_arm/_divsi3.S
delete mode 100644 lib_arm/_modsi3.S
delete mode 100644 lib_arm/_udivsi3.S
delete mode 100644 lib_arm/_umodsi3.S
rename lib_arm/{_ashldi3.S => ashldi3.S} (93%)
rename lib_arm/{_ashrdi3.S => ashrdi3.S} (93%)
create mode 100644 lib_arm/lib1funcs.SMakefile +4 -1
@@ -266,7 +266,10 @@ LIBBOARD = board/$(BOARDDIR)/lib$(BOARD).a LIBBOARD := $(addprefix $(obj),$(LIBBOARD)) # Add GCC lib -PLATFORM_LIBS += -L $(shell dirname `$(CC) $(CFLAGS) -print-libgcc-file-name`) -lgcc +PLATFORM_LIBS += -L $(shell dirname `$(CC) $(CFLAGS) -print-libgcc-file-name`) +ifneq ($(ARCH),arm) +PLATFORM_LIBS += -lgcc +endif # The "tools" are needed early, so put this first # Don't include stuff already done in $(LIBS)
include/asm-arm/assembler.h new file +116 -0
116 lines not on this page · raw message
include/asm-arm/linkage.h new file +11 -0
@@ -0,0 +1,11 @@ +#ifndef __ASM_LINKAGE_H +#define __ASM_LINKAGE_H + +#define __ALIGN .align 0 +#define __ALIGN_STR ".align 0" + +#define ENDPROC (name) \ + .type name, %function; \ + END(name) + +#endif
include/linux/linkage.h new file +95 -0
95 lines not on this page · raw message
lib_arm/Makefile +3 -6
@@ -25,12 +25,9 @@ include $(TOPDIR)/config.mk LIB = $(obj)lib$(ARCH).a -SOBJS-y += _ashldi3.o -SOBJS-y += _ashrdi3.o -SOBJS-y += _divsi3.o -SOBJS-y += _modsi3.o -SOBJS-y += _udivsi3.o -SOBJS-y += _umodsi3.o +SOBJS-y += lib1funcs.o +SOBJS-y += ashldi3.o +SOBJS-y += ashrdi3.o COBJS-y += board.o COBJS-y += bootm.o
lib_arm/_divsi3.S deleted +0 -140
140 lines not on this page · raw message
lib_arm/_modsi3.S deleted +0 -99
99 lines not on this page · raw message
lib_arm/_udivsi3.S deleted +0 -77
77 lines not on this page · raw message
lib_arm/_umodsi3.S deleted +0 -88
88 lines not on this page · raw message
lib_arm/ashldi3.S renamed from lib_arm/_ashldi3.S +7 -2
@@ -26,6 +26,8 @@ the Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +#include <linux/linkage.h> + #ifdef __ARMEB__ #define al r1 #define ah r0
@@ -34,8 +36,8 @@ Boston, MA 02110-1301, USA. */ #define ah r1 #endif -.globl __ashldi3 -__ashldi3: +ENTRY(__ashldi3) +ENTRY(__aeabi_llsl) subs r3, r2, #32 rsb ip, r2, #32
@@ -44,3 +46,6 @@ __ashldi3: orrmi ah, ah, al, lsr ip mov al, al, lsl r2 mov pc, lr + +ENDPROC(__ashldi3) +ENDPROC(__aeabi_llsl)
lib_arm/ashrdi3.S renamed from lib_arm/_ashrdi3.S +7 -2
@@ -26,6 +26,8 @@ the Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +#include <linux/linkage.h> + #ifdef __ARMEB__ #define al r1 #define ah r0
@@ -34,8 +36,8 @@ Boston, MA 02110-1301, USA. */ #define ah r1 #endif -.globl __ashrdi3 -__ashrdi3: +ENTRY(__ashrdi3) +ENTRY(__aeabi_lasr) subs r3, r2, #32 rsb ip, r2, #32
@@ -44,3 +46,6 @@ __ashrdi3: orrmi al, al, ah, lsl ip mov ah, ah, asr r2 mov pc, lr + +ENDPROC(__ashrdi3) +ENDPROC(__aeabi_lasr)
lib_arm/lib1funcs.S new file +348 -0
348 lines not on this page · raw message
Signature · 4 lines
1.5.6.5 --PEIAKu/WMn1b1Hv9--