Commit 417484d4 authored by Luca Barbieri's avatar Luca Barbieri Committed by H. Peter Anvin

x86, asm: Use a lower case name for the end macro in atomic64_386_32.S

Use a lowercase name for the end macro, which somehow fixes a binutils 2.16
problem.
Signed-off-by: default avatarLuca Barbieri <luca@luca-barbieri.com>
LKML-Reference: <tip-30246557@git.kernel.org>
Signed-off-by: default avatarH. Peter Anvin <hpa@zytor.com>
parent 30246557
...@@ -26,35 +26,37 @@ ...@@ -26,35 +26,37 @@
.endm .endm
#define BEGIN(op) \ #define BEGIN(op) \
.macro END; \ .macro endp; \
CFI_ENDPROC; \ CFI_ENDPROC; \
ENDPROC(atomic64_##op##_386); \ ENDPROC(atomic64_##op##_386); \
.purgem END; \ .purgem endp; \
.endm; \ .endm; \
ENTRY(atomic64_##op##_386); \ ENTRY(atomic64_##op##_386); \
CFI_STARTPROC; \ CFI_STARTPROC; \
LOCK v; LOCK v;
#define ENDP endp
#define RET \ #define RET \
UNLOCK v; \ UNLOCK v; \
ret ret
#define RET_END \ #define RET_ENDP \
RET; \ RET; \
END ENDP
#define v %ecx #define v %ecx
BEGIN(read) BEGIN(read)
movl (v), %eax movl (v), %eax
movl 4(v), %edx movl 4(v), %edx
RET_END RET_ENDP
#undef v #undef v
#define v %esi #define v %esi
BEGIN(set) BEGIN(set)
movl %ebx, (v) movl %ebx, (v)
movl %ecx, 4(v) movl %ecx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %esi #define v %esi
...@@ -63,14 +65,14 @@ BEGIN(xchg) ...@@ -63,14 +65,14 @@ BEGIN(xchg)
movl 4(v), %edx movl 4(v), %edx
movl %ebx, (v) movl %ebx, (v)
movl %ecx, 4(v) movl %ecx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %ecx #define v %ecx
BEGIN(add) BEGIN(add)
addl %eax, (v) addl %eax, (v)
adcl %edx, 4(v) adcl %edx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %ecx #define v %ecx
...@@ -79,14 +81,14 @@ BEGIN(add_return) ...@@ -79,14 +81,14 @@ BEGIN(add_return)
adcl 4(v), %edx adcl 4(v), %edx
movl %eax, (v) movl %eax, (v)
movl %edx, 4(v) movl %edx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %ecx #define v %ecx
BEGIN(sub) BEGIN(sub)
subl %eax, (v) subl %eax, (v)
sbbl %edx, 4(v) sbbl %edx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %ecx #define v %ecx
...@@ -98,14 +100,14 @@ BEGIN(sub_return) ...@@ -98,14 +100,14 @@ BEGIN(sub_return)
adcl 4(v), %edx adcl 4(v), %edx
movl %eax, (v) movl %eax, (v)
movl %edx, 4(v) movl %edx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %esi #define v %esi
BEGIN(inc) BEGIN(inc)
addl $1, (v) addl $1, (v)
adcl $0, 4(v) adcl $0, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %esi #define v %esi
...@@ -116,14 +118,14 @@ BEGIN(inc_return) ...@@ -116,14 +118,14 @@ BEGIN(inc_return)
adcl $0, %edx adcl $0, %edx
movl %eax, (v) movl %eax, (v)
movl %edx, 4(v) movl %edx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %esi #define v %esi
BEGIN(dec) BEGIN(dec)
subl $1, (v) subl $1, (v)
sbbl $0, 4(v) sbbl $0, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %esi #define v %esi
...@@ -134,7 +136,7 @@ BEGIN(dec_return) ...@@ -134,7 +136,7 @@ BEGIN(dec_return)
sbbl $0, %edx sbbl $0, %edx
movl %eax, (v) movl %eax, (v)
movl %edx, 4(v) movl %edx, 4(v)
RET_END RET_ENDP
#undef v #undef v
#define v %ecx #define v %ecx
...@@ -156,7 +158,7 @@ BEGIN(add_unless) ...@@ -156,7 +158,7 @@ BEGIN(add_unless)
jne 1b jne 1b
xorl %eax, %eax xorl %eax, %eax
jmp 2b jmp 2b
END ENDP
#undef v #undef v
#define v %esi #define v %esi
...@@ -177,7 +179,7 @@ BEGIN(inc_not_zero) ...@@ -177,7 +179,7 @@ BEGIN(inc_not_zero)
testl %edx, %edx testl %edx, %edx
jne 1b jne 1b
jmp 2b jmp 2b
END ENDP
#undef v #undef v
#define v %esi #define v %esi
...@@ -190,5 +192,5 @@ BEGIN(dec_if_positive) ...@@ -190,5 +192,5 @@ BEGIN(dec_if_positive)
movl %eax, (v) movl %eax, (v)
movl %edx, 4(v) movl %edx, 4(v)
1: 1:
RET_END RET_ENDP
#undef v #undef v
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