diff options
| author | Luca Barbieri <luca@luca-barbieri.com> | 2010-08-12 10:00:35 -0400 |
|---|---|---|
| committer | H. Peter Anvin <hpa@zytor.com> | 2010-08-12 10:04:16 -0400 |
| commit | 417484d47e115774745ef025bce712a102b6f86f (patch) | |
| tree | 2a898b29b691ae0f1617e1189d57abbcbeb7383c | |
| parent | 30246557a06bb20618bed906a06d1e1e0faa8bb4 (diff) | |
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: Luca Barbieri <luca@luca-barbieri.com>
LKML-Reference: <tip-30246557a06bb20618bed906a06d1e1e0faa8bb4@git.kernel.org>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
| -rw-r--r-- | arch/x86/lib/atomic64_386_32.S | 38 |
1 files changed, 20 insertions, 18 deletions
diff --git a/arch/x86/lib/atomic64_386_32.S b/arch/x86/lib/atomic64_386_32.S index 78ee8e0fa278..2cda60a06e65 100644 --- a/arch/x86/lib/atomic64_386_32.S +++ b/arch/x86/lib/atomic64_386_32.S | |||
| @@ -26,35 +26,37 @@ | |||
| 26 | .endm | 26 | .endm |
| 27 | 27 | ||
| 28 | #define BEGIN(op) \ | 28 | #define BEGIN(op) \ |
| 29 | .macro END; \ | 29 | .macro endp; \ |
| 30 | CFI_ENDPROC; \ | 30 | CFI_ENDPROC; \ |
| 31 | ENDPROC(atomic64_##op##_386); \ | 31 | ENDPROC(atomic64_##op##_386); \ |
| 32 | .purgem END; \ | 32 | .purgem endp; \ |
| 33 | .endm; \ | 33 | .endm; \ |
| 34 | ENTRY(atomic64_##op##_386); \ | 34 | ENTRY(atomic64_##op##_386); \ |
| 35 | CFI_STARTPROC; \ | 35 | CFI_STARTPROC; \ |
| 36 | LOCK v; | 36 | LOCK v; |
| 37 | 37 | ||
| 38 | #define ENDP endp | ||
| 39 | |||
| 38 | #define RET \ | 40 | #define RET \ |
| 39 | UNLOCK v; \ | 41 | UNLOCK v; \ |
| 40 | ret | 42 | ret |
| 41 | 43 | ||
| 42 | #define RET_END \ | 44 | #define RET_ENDP \ |
| 43 | RET; \ | 45 | RET; \ |
| 44 | END | 46 | ENDP |
| 45 | 47 | ||
| 46 | #define v %ecx | 48 | #define v %ecx |
| 47 | BEGIN(read) | 49 | BEGIN(read) |
| 48 | movl (v), %eax | 50 | movl (v), %eax |
| 49 | movl 4(v), %edx | 51 | movl 4(v), %edx |
| 50 | RET_END | 52 | RET_ENDP |
| 51 | #undef v | 53 | #undef v |
| 52 | 54 | ||
| 53 | #define v %esi | 55 | #define v %esi |
| 54 | BEGIN(set) | 56 | BEGIN(set) |
| 55 | movl %ebx, (v) | 57 | movl %ebx, (v) |
| 56 | movl %ecx, 4(v) | 58 | movl %ecx, 4(v) |
| 57 | RET_END | 59 | RET_ENDP |
| 58 | #undef v | 60 | #undef v |
| 59 | 61 | ||
| 60 | #define v %esi | 62 | #define v %esi |
| @@ -63,14 +65,14 @@ BEGIN(xchg) | |||
| 63 | movl 4(v), %edx | 65 | movl 4(v), %edx |
| 64 | movl %ebx, (v) | 66 | movl %ebx, (v) |
| 65 | movl %ecx, 4(v) | 67 | movl %ecx, 4(v) |
| 66 | RET_END | 68 | RET_ENDP |
| 67 | #undef v | 69 | #undef v |
| 68 | 70 | ||
| 69 | #define v %ecx | 71 | #define v %ecx |
| 70 | BEGIN(add) | 72 | BEGIN(add) |
| 71 | addl %eax, (v) | 73 | addl %eax, (v) |
| 72 | adcl %edx, 4(v) | 74 | adcl %edx, 4(v) |
| 73 | RET_END | 75 | RET_ENDP |
| 74 | #undef v | 76 | #undef v |
| 75 | 77 | ||
| 76 | #define v %ecx | 78 | #define v %ecx |
| @@ -79,14 +81,14 @@ BEGIN(add_return) | |||
| 79 | adcl 4(v), %edx | 81 | adcl 4(v), %edx |
| 80 | movl %eax, (v) | 82 | movl %eax, (v) |
| 81 | movl %edx, 4(v) | 83 | movl %edx, 4(v) |
| 82 | RET_END | 84 | RET_ENDP |
| 83 | #undef v | 85 | #undef v |
| 84 | 86 | ||
| 85 | #define v %ecx | 87 | #define v %ecx |
| 86 | BEGIN(sub) | 88 | BEGIN(sub) |
| 87 | subl %eax, (v) | 89 | subl %eax, (v) |
| 88 | sbbl %edx, 4(v) | 90 | sbbl %edx, 4(v) |
| 89 | RET_END | 91 | RET_ENDP |
| 90 | #undef v | 92 | #undef v |
| 91 | 93 | ||
| 92 | #define v %ecx | 94 | #define v %ecx |
| @@ -98,14 +100,14 @@ BEGIN(sub_return) | |||
| 98 | adcl 4(v), %edx | 100 | adcl 4(v), %edx |
| 99 | movl %eax, (v) | 101 | movl %eax, (v) |
| 100 | movl %edx, 4(v) | 102 | movl %edx, 4(v) |
| 101 | RET_END | 103 | RET_ENDP |
| 102 | #undef v | 104 | #undef v |
| 103 | 105 | ||
| 104 | #define v %esi | 106 | #define v %esi |
| 105 | BEGIN(inc) | 107 | BEGIN(inc) |
| 106 | addl $1, (v) | 108 | addl $1, (v) |
| 107 | adcl $0, 4(v) | 109 | adcl $0, 4(v) |
| 108 | RET_END | 110 | RET_ENDP |
| 109 | #undef v | 111 | #undef v |
| 110 | 112 | ||
| 111 | #define v %esi | 113 | #define v %esi |
| @@ -116,14 +118,14 @@ BEGIN(inc_return) | |||
| 116 | adcl $0, %edx | 118 | adcl $0, %edx |
| 117 | movl %eax, (v) | 119 | movl %eax, (v) |
| 118 | movl %edx, 4(v) | 120 | movl %edx, 4(v) |
| 119 | RET_END | 121 | RET_ENDP |
| 120 | #undef v | 122 | #undef v |
| 121 | 123 | ||
| 122 | #define v %esi | 124 | #define v %esi |
| 123 | BEGIN(dec) | 125 | BEGIN(dec) |
| 124 | subl $1, (v) | 126 | subl $1, (v) |
| 125 | sbbl $0, 4(v) | 127 | sbbl $0, 4(v) |
| 126 | RET_END | 128 | RET_ENDP |
| 127 | #undef v | 129 | #undef v |
| 128 | 130 | ||
| 129 | #define v %esi | 131 | #define v %esi |
| @@ -134,7 +136,7 @@ BEGIN(dec_return) | |||
| 134 | sbbl $0, %edx | 136 | sbbl $0, %edx |
| 135 | movl %eax, (v) | 137 | movl %eax, (v) |
| 136 | movl %edx, 4(v) | 138 | movl %edx, 4(v) |
| 137 | RET_END | 139 | RET_ENDP |
| 138 | #undef v | 140 | #undef v |
| 139 | 141 | ||
| 140 | #define v %ecx | 142 | #define v %ecx |
| @@ -156,7 +158,7 @@ BEGIN(add_unless) | |||
| 156 | jne 1b | 158 | jne 1b |
| 157 | xorl %eax, %eax | 159 | xorl %eax, %eax |
| 158 | jmp 2b | 160 | jmp 2b |
| 159 | END | 161 | ENDP |
| 160 | #undef v | 162 | #undef v |
| 161 | 163 | ||
| 162 | #define v %esi | 164 | #define v %esi |
| @@ -177,7 +179,7 @@ BEGIN(inc_not_zero) | |||
| 177 | testl %edx, %edx | 179 | testl %edx, %edx |
| 178 | jne 1b | 180 | jne 1b |
| 179 | jmp 2b | 181 | jmp 2b |
| 180 | END | 182 | ENDP |
| 181 | #undef v | 183 | #undef v |
| 182 | 184 | ||
| 183 | #define v %esi | 185 | #define v %esi |
| @@ -190,5 +192,5 @@ BEGIN(dec_if_positive) | |||
| 190 | movl %eax, (v) | 192 | movl %eax, (v) |
| 191 | movl %edx, 4(v) | 193 | movl %edx, 4(v) |
| 192 | 1: | 194 | 1: |
| 193 | RET_END | 195 | RET_ENDP |
| 194 | #undef v | 196 | #undef v |
