1 /* SPDX-License-Identifier: GPL-2.0+ */
5 * Copyright (c) 2005-2007 Analog Devices Inc.
8 #ifndef _LINUX_LINKAGE_H
9 #define _LINUX_LINKAGE_H
11 #include <asm/linkage.h>
13 /* Some toolchains use other characters (e.g. '`') to mark new line in macro */
19 #define CPP_ASMLINKAGE extern "C"
21 #define CPP_ASMLINKAGE
25 #define asmlinkage CPP_ASMLINKAGE
28 #define SYMBOL_NAME_STR(X) #X
29 #define SYMBOL_NAME(X) X
31 #define SYMBOL_NAME_LABEL(X) X##:
33 #define SYMBOL_NAME_LABEL(X) X:
37 #define __ALIGN .align 4
41 #define __ALIGN_STR ".align 4"
47 #define ALIGN_STR __ALIGN_STR
49 #define LENTRY(name) \
51 SYMBOL_NAME_LABEL(name)
54 .globl SYMBOL_NAME(name) ASM_NL \
58 .weak SYMBOL_NAME(name) ASM_NL \
67 #define ENDPROC(name) \
68 .type name STT_FUNC ASM_NL \