Unified · Split
| @@ -34,7 +34,8 @@ void apply_alternatives(struct alt_instr *start, struct alt_instr *end, · 33 unmodified lines | |||
| 34 | 34 | ||
| 35 | /* Alternative SMP implementation. */ | 35 | /* Alternative SMP implementation. */ |
| 36 | #define ALTERNATIVE(cond, replacement) "!0:" \ | 36 | #define ALTERNATIVE(cond, replacement) "!0:" \ |
| 37 | ".section .altinstructions, \"aw\" !" \ | 37 | ".section .altinstructions, \"a\" !" \ |
| 38 | ".align 4 !" \ | ||
| 38 | ".word (0b-4-.) !" \ | 39 | ".word (0b-4-.) !" \ |
| 39 | ".hword 1, " __stringify(cond) " !" \ | 40 | ".hword 1, " __stringify(cond) " !" \ |
| 40 | ".word " __stringify(replacement) " !" \ | 41 | ".word " __stringify(replacement) " !" \ |
| @@ -44,7 +45,8 @@ void apply_alternatives(struct alt_instr *start, struct alt_instr *end, · 3 unmodified lines | |||
| 44 | 45 | ||
| 45 | /* to replace one single instructions by a new instruction */ | 46 | /* to replace one single instructions by a new instruction */ |
| 46 | #define ALTERNATIVE(from, to, cond, replacement)\ | 47 | #define ALTERNATIVE(from, to, cond, replacement)\ |
| 47 | .section .altinstructions, "aw" ! \ | 48 | .section .altinstructions, "a" ! \ |
| 49 | .align 4 ! \ | ||
| 48 | .word (from - .) ! \ | 50 | .word (from - .) ! \ |
| 49 | .hword (to - from)/4, cond ! \ | 51 | .hword (to - from)/4, cond ! \ |
| 50 | .word replacement ! \ | 52 | .word replacement ! \ |
| @@ -52,7 +54,8 @@ void apply_alternatives(struct alt_instr *start, struct alt_instr *end, · 1 unmodified line | |||
| 52 | 54 | ||
| 53 | /* to replace multiple instructions by new code */ | 55 | /* to replace multiple instructions by new code */ |
| 54 | #define ALTERNATIVE_CODE(from, num_instructions, cond, new_instr_ptr)\ | 56 | #define ALTERNATIVE_CODE(from, num_instructions, cond, new_instr_ptr)\ |
| 55 | .section .altinstructions, "aw" ! \ | 57 | .section .altinstructions, "a" ! \ |
| 58 | .align 4 ! \ | ||
| 56 | .word (from - .) ! \ | 59 | .word (from - .) ! \ |
| 57 | .hword -num_instructions, cond ! \ | 60 | .hword -num_instructions, cond ! \ |
| 58 | .word (new_instr_ptr - .) ! \ | 61 | .word (new_instr_ptr - .) ! \ |