x86/asm: Replace WEAK uses by SYM_INNER_LABEL_ALIGN

Use the new SYM_INNER_LABEL_ALIGN for WEAK entries in the middle of x86
assembly functions.

And make sure WEAK is not defined for x86 anymore as these were the last
users.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Borislav Petkov <bp@suse.de>
Cc: Andrey Ryabinin <aryabinin@virtuozzo.com>
Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: linux-arch@vger.kernel.org
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
Cc: "Steven Rostedt (VMware)" <rostedt@goodmis.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: x86-ml <x86@kernel.org>
Link: https://lkml.kernel.org/r/20191011115108.12392-29-jslaby@suse.cz
This commit is contained in:
Jiri Slaby 2019-10-11 13:51:08 +02:00 committed by Borislav Petkov
parent 6d685e5318
commit 13fbe784ef
4 changed files with 4 additions and 4 deletions

View File

@ -85,7 +85,7 @@ ftrace_graph_call:
#endif #endif
/* This is weak to keep gas from relaxing the jumps */ /* This is weak to keep gas from relaxing the jumps */
WEAK(ftrace_stub) SYM_INNER_LABEL_ALIGN(ftrace_stub, SYM_L_WEAK)
ret ret
SYM_CODE_END(ftrace_caller) SYM_CODE_END(ftrace_caller)

View File

@ -168,7 +168,7 @@ SYM_INNER_LABEL(ftrace_graph_call, SYM_L_GLOBAL)
* This is weak to keep gas from relaxing the jumps. * This is weak to keep gas from relaxing the jumps.
* It is also used to copy the retq for trampolines. * It is also used to copy the retq for trampolines.
*/ */
WEAK(ftrace_stub) SYM_INNER_LABEL_ALIGN(ftrace_stub, SYM_L_WEAK)
retq retq
SYM_FUNC_END(ftrace_caller) SYM_FUNC_END(ftrace_caller)

View File

@ -156,7 +156,7 @@ SYM_CODE_START(startup_32)
jmp *%eax jmp *%eax
.Lbad_subarch: .Lbad_subarch:
WEAK(xen_entry) SYM_INNER_LABEL_ALIGN(xen_entry, SYM_L_WEAK)
/* Unknown implementation; there's really /* Unknown implementation; there's really
nothing we can do at this point. */ nothing we can do at this point. */
ud2a ud2a

View File

@ -121,13 +121,13 @@
#endif /* CONFIG_X86 */ #endif /* CONFIG_X86 */
#endif /* LINKER_SCRIPT */ #endif /* LINKER_SCRIPT */
#ifndef CONFIG_X86
#ifndef WEAK #ifndef WEAK
/* deprecated, use SYM_FUNC_START_WEAK* */ /* deprecated, use SYM_FUNC_START_WEAK* */
#define WEAK(name) \ #define WEAK(name) \
SYM_FUNC_START_WEAK(name) SYM_FUNC_START_WEAK(name)
#endif #endif
#ifndef CONFIG_X86
#ifndef END #ifndef END
/* deprecated, use SYM_FUNC_END, SYM_DATA_END, or SYM_END */ /* deprecated, use SYM_FUNC_END, SYM_DATA_END, or SYM_END */
#define END(name) \ #define END(name) \