Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

x86/copy_mc_64: Remove .fixup usage

Place the anonymous .fixup code at the tail of the regular functions.

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Josh Poimboeuf <jpoimboe@redhat.com>
Reviewed-by: Borislav Petkov <bp@suse.de>
Link: https://lore.kernel.org/r/20211110101325.127055887@infradead.org

+4 -8
+4 -8
arch/x86/lib/copy_mc_64.S
··· 78 78 xorl %eax, %eax 79 79 .L_done: 80 80 RET 81 - SYM_FUNC_END(copy_mc_fragile) 82 81 83 - .section .fixup, "ax" 84 82 /* 85 83 * Return number of bytes not copied for any failure. Note that 86 84 * there is no "tail" handling since the source buffer is 8-byte ··· 103 105 movl %ecx, %edx 104 106 jmp copy_mc_fragile_handle_tail 105 107 106 - .previous 107 - 108 108 _ASM_EXTABLE_TYPE(.L_read_leading_bytes, .E_leading_bytes, EX_TYPE_DEFAULT_MCE_SAFE) 109 109 _ASM_EXTABLE_TYPE(.L_read_words, .E_read_words, EX_TYPE_DEFAULT_MCE_SAFE) 110 110 _ASM_EXTABLE_TYPE(.L_read_trailing_bytes, .E_trailing_bytes, EX_TYPE_DEFAULT_MCE_SAFE) 111 111 _ASM_EXTABLE(.L_write_leading_bytes, .E_leading_bytes) 112 112 _ASM_EXTABLE(.L_write_words, .E_write_words) 113 113 _ASM_EXTABLE(.L_write_trailing_bytes, .E_trailing_bytes) 114 + 115 + SYM_FUNC_END(copy_mc_fragile) 114 116 #endif /* CONFIG_X86_MCE */ 115 117 116 118 /* ··· 131 133 /* Copy successful. Return zero */ 132 134 xorl %eax, %eax 133 135 RET 134 - SYM_FUNC_END(copy_mc_enhanced_fast_string) 135 136 136 - .section .fixup, "ax" 137 137 .E_copy: 138 138 /* 139 139 * On fault %rcx is updated such that the copy instruction could ··· 143 147 movq %rcx, %rax 144 148 RET 145 149 146 - .previous 147 - 148 150 _ASM_EXTABLE_TYPE(.L_copy, .E_copy, EX_TYPE_DEFAULT_MCE_SAFE) 151 + 152 + SYM_FUNC_END(copy_mc_enhanced_fast_string) 149 153 #endif /* !CONFIG_UML */