1b2441318SGreg Kroah-Hartman /* SPDX-License-Identifier: GPL-2.0 */ 21da177e4SLinus Torvalds #ifndef _LINUX_LINKAGE_H 31da177e4SLinus Torvalds #define _LINUX_LINKAGE_H 41da177e4SLinus Torvalds 5d1515582SWill Deacon #include <linux/compiler_types.h> 6e1b5bb6dSAl Viro #include <linux/stringify.h> 7f8ce1fafSLinus Torvalds #include <linux/export.h> 81da177e4SLinus Torvalds #include <asm/linkage.h> 91da177e4SLinus Torvalds 109df62f05SChen Gang /* Some toolchains use other characters (e.g. '`') to mark new line in macro */ 119df62f05SChen Gang #ifndef ASM_NL 129df62f05SChen Gang #define ASM_NL ; 139df62f05SChen Gang #endif 149df62f05SChen Gang 151da177e4SLinus Torvalds #ifdef __cplusplus 163adc1beaSAndi Kleen #define CPP_ASMLINKAGE extern "C" 171da177e4SLinus Torvalds #else 183adc1beaSAndi Kleen #define CPP_ASMLINKAGE 191da177e4SLinus Torvalds #endif 201da177e4SLinus Torvalds 211da177e4SLinus Torvalds #ifndef asmlinkage 221da177e4SLinus Torvalds #define asmlinkage CPP_ASMLINKAGE 231da177e4SLinus Torvalds #endif 241da177e4SLinus Torvalds 25e1b5bb6dSAl Viro #ifndef cond_syscall 26f8ce1fafSLinus Torvalds #define cond_syscall(x) asm( \ 2700979ce4SMasahiro Yamada ".weak " __stringify(x) "\n\t" \ 2800979ce4SMasahiro Yamada ".set " __stringify(x) "," \ 2900979ce4SMasahiro Yamada __stringify(sys_ni_syscall)) 30e1b5bb6dSAl Viro #endif 31e1b5bb6dSAl Viro 32e1b5bb6dSAl Viro #ifndef SYSCALL_ALIAS 33f8ce1fafSLinus Torvalds #define SYSCALL_ALIAS(alias, name) asm( \ 3400979ce4SMasahiro Yamada ".globl " __stringify(alias) "\n\t" \ 3500979ce4SMasahiro Yamada ".set " __stringify(alias) "," \ 3600979ce4SMasahiro Yamada __stringify(name)) 37e1b5bb6dSAl Viro #endif 38e1b5bb6dSAl Viro 3933def849SJoe Perches #define __page_aligned_data __section(".data..page_aligned") __aligned(PAGE_SIZE) 4033def849SJoe Perches #define __page_aligned_bss __section(".bss..page_aligned") __aligned(PAGE_SIZE) 41a7bf0bd5SJeremy Fitzhardinge 42d10d89ecSLinus Torvalds /* 43d2af12aeSTim Abbott * For assembly routines. 44d2af12aeSTim Abbott * 45d2af12aeSTim Abbott * Note when using these that you must specify the appropriate 46d2af12aeSTim Abbott * alignment directives yourself 47d2af12aeSTim Abbott */ 4875b13483STim Abbott #define __PAGE_ALIGNED_DATA .section ".data..page_aligned", "aw" 497c74df07STim Abbott #define __PAGE_ALIGNED_BSS .section ".bss..page_aligned", "aw" 50d2af12aeSTim Abbott 51d2af12aeSTim Abbott /* 52d10d89ecSLinus Torvalds * This is used by architectures to keep arguments on the stack 53d10d89ecSLinus Torvalds * untouched by the compiler by keeping them live until the end. 54d10d89ecSLinus Torvalds * The argument stack may be owned by the assembly-language 55d10d89ecSLinus Torvalds * caller, not the callee, and gcc doesn't always understand 56d10d89ecSLinus Torvalds * that. 57d10d89ecSLinus Torvalds * 58d10d89ecSLinus Torvalds * We have the return value, and a maximum of six arguments. 59d10d89ecSLinus Torvalds * 60d10d89ecSLinus Torvalds * This should always be followed by a "return ret" for the 61d10d89ecSLinus Torvalds * protection to work (ie no more work that the compiler might 62d10d89ecSLinus Torvalds * end up needing stack temporaries for). 63d10d89ecSLinus Torvalds */ 64b0fac023SHeiko Carstens /* Assembly files may be compiled with -traditional .. */ 65b0fac023SHeiko Carstens #ifndef __ASSEMBLY__ 6654a01510SRoland McGrath #ifndef asmlinkage_protect 6754a01510SRoland McGrath # define asmlinkage_protect(n, ret, args...) do { } while (0) 681da177e4SLinus Torvalds #endif 69b0fac023SHeiko Carstens #endif 701da177e4SLinus Torvalds 711da177e4SLinus Torvalds #ifndef __ALIGN 72*d49a0626SPeter Zijlstra #define __ALIGN .balign CONFIG_FUNCTION_ALIGNMENT 73*d49a0626SPeter Zijlstra #define __ALIGN_STR __stringify(__ALIGN) 741da177e4SLinus Torvalds #endif 751da177e4SLinus Torvalds 761da177e4SLinus Torvalds #ifdef __ASSEMBLY__ 771da177e4SLinus Torvalds 78ffedeeb7SJiri Slaby /* SYM_T_FUNC -- type used by assembler to mark functions */ 79ffedeeb7SJiri Slaby #ifndef SYM_T_FUNC 80ffedeeb7SJiri Slaby #define SYM_T_FUNC STT_FUNC 81ffedeeb7SJiri Slaby #endif 82ffedeeb7SJiri Slaby 83ffedeeb7SJiri Slaby /* SYM_T_OBJECT -- type used by assembler to mark data */ 84ffedeeb7SJiri Slaby #ifndef SYM_T_OBJECT 85ffedeeb7SJiri Slaby #define SYM_T_OBJECT STT_OBJECT 86ffedeeb7SJiri Slaby #endif 87ffedeeb7SJiri Slaby 88ffedeeb7SJiri Slaby /* SYM_T_NONE -- type used by assembler to mark entries of unknown type */ 89ffedeeb7SJiri Slaby #ifndef SYM_T_NONE 90ffedeeb7SJiri Slaby #define SYM_T_NONE STT_NOTYPE 91ffedeeb7SJiri Slaby #endif 92ffedeeb7SJiri Slaby 93ffedeeb7SJiri Slaby /* SYM_A_* -- align the symbol? */ 94ffedeeb7SJiri Slaby #define SYM_A_ALIGN ALIGN 95ffedeeb7SJiri Slaby #define SYM_A_NONE /* nothing */ 96ffedeeb7SJiri Slaby 97ffedeeb7SJiri Slaby /* SYM_L_* -- linkage of symbols */ 98ffedeeb7SJiri Slaby #define SYM_L_GLOBAL(name) .globl name 99ffedeeb7SJiri Slaby #define SYM_L_WEAK(name) .weak name 100ffedeeb7SJiri Slaby #define SYM_L_LOCAL(name) /* nothing */ 101ffedeeb7SJiri Slaby 10242f29a25STim Abbott #ifndef LINKER_SCRIPT 1031da177e4SLinus Torvalds #define ALIGN __ALIGN 1041da177e4SLinus Torvalds #define ALIGN_STR __ALIGN_STR 1051da177e4SLinus Torvalds 106ffedeeb7SJiri Slaby /* === DEPRECATED annotations === */ 107ffedeeb7SJiri Slaby 1082ce0d7f9SMark Brown #ifndef CONFIG_ARCH_USE_SYM_ANNOTATIONS 109ad697a1aSMark Rutland #ifndef GLOBAL 110ffedeeb7SJiri Slaby /* deprecated, use SYM_DATA*, SYM_ENTRY, or similar */ 111ad697a1aSMark Rutland #define GLOBAL(name) \ 112ad697a1aSMark Rutland .globl name ASM_NL \ 113ad697a1aSMark Rutland name: 114ad697a1aSMark Rutland #endif 115ad697a1aSMark Rutland 116ab7efcc9SJan Beulich #ifndef ENTRY 117ffedeeb7SJiri Slaby /* deprecated, use SYM_FUNC_START */ 1181da177e4SLinus Torvalds #define ENTRY(name) \ 119ffedeeb7SJiri Slaby SYM_FUNC_START(name) 120ab7efcc9SJan Beulich #endif 1212ce0d7f9SMark Brown #endif /* CONFIG_ARCH_USE_SYM_ANNOTATIONS */ 12242f29a25STim Abbott #endif /* LINKER_SCRIPT */ 1231da177e4SLinus Torvalds 1242ce0d7f9SMark Brown #ifndef CONFIG_ARCH_USE_SYM_ANNOTATIONS 125214541d1SRusty Russell #ifndef WEAK 126ffedeeb7SJiri Slaby /* deprecated, use SYM_FUNC_START_WEAK* */ 127214541d1SRusty Russell #define WEAK(name) \ 128ffedeeb7SJiri Slaby SYM_FUNC_START_WEAK(name) 129214541d1SRusty Russell #endif 130214541d1SRusty Russell 131ab7efcc9SJan Beulich #ifndef END 132ffedeeb7SJiri Slaby /* deprecated, use SYM_FUNC_END, SYM_DATA_END, or SYM_END */ 133ab7efcc9SJan Beulich #define END(name) \ 134ab7efcc9SJan Beulich .size name, .-name 135ab7efcc9SJan Beulich #endif 136ab7efcc9SJan Beulich 137ab7efcc9SJan Beulich #ifndef ENDPROC 138ffedeeb7SJiri Slaby /* deprecated, use SYM_FUNC_END */ 139ab7efcc9SJan Beulich #define ENDPROC(name) \ 140ffedeeb7SJiri Slaby SYM_FUNC_END(name) 141ab7efcc9SJan Beulich #endif 1422ce0d7f9SMark Brown #endif /* CONFIG_ARCH_USE_SYM_ANNOTATIONS */ 143d0aaff97SPrasanna S Panchamukhi 144ffedeeb7SJiri Slaby /* === generic annotations === */ 145ffedeeb7SJiri Slaby 146ffedeeb7SJiri Slaby /* SYM_ENTRY -- use only if you have to for non-paired symbols */ 147ffedeeb7SJiri Slaby #ifndef SYM_ENTRY 148ffedeeb7SJiri Slaby #define SYM_ENTRY(name, linkage, align...) \ 149ffedeeb7SJiri Slaby linkage(name) ASM_NL \ 150ffedeeb7SJiri Slaby align ASM_NL \ 151ffedeeb7SJiri Slaby name: 1521da177e4SLinus Torvalds #endif 1531da177e4SLinus Torvalds 154ffedeeb7SJiri Slaby /* SYM_START -- use only if you have to */ 155ffedeeb7SJiri Slaby #ifndef SYM_START 156ffedeeb7SJiri Slaby #define SYM_START(name, linkage, align...) \ 157ffedeeb7SJiri Slaby SYM_ENTRY(name, linkage, align) 1581da177e4SLinus Torvalds #endif 159ffedeeb7SJiri Slaby 160ffedeeb7SJiri Slaby /* SYM_END -- use only if you have to */ 161ffedeeb7SJiri Slaby #ifndef SYM_END 162ffedeeb7SJiri Slaby #define SYM_END(name, sym_type) \ 163ffedeeb7SJiri Slaby .type name sym_type ASM_NL \ 164e0891269SMark Rutland .set .L__sym_size_##name, .-name ASM_NL \ 165e0891269SMark Rutland .size name, .L__sym_size_##name 166e0891269SMark Rutland #endif 167e0891269SMark Rutland 168e0891269SMark Rutland /* SYM_ALIAS -- use only if you have to */ 169e0891269SMark Rutland #ifndef SYM_ALIAS 1703ff5f784SPeter Zijlstra #define SYM_ALIAS(alias, name, linkage) \ 171e0891269SMark Rutland linkage(alias) ASM_NL \ 1723ff5f784SPeter Zijlstra .set alias, name ASM_NL 173ffedeeb7SJiri Slaby #endif 174ffedeeb7SJiri Slaby 175ffedeeb7SJiri Slaby /* === code annotations === */ 176ffedeeb7SJiri Slaby 177ffedeeb7SJiri Slaby /* 178ffedeeb7SJiri Slaby * FUNC -- C-like functions (proper stack frame etc.) 179ffedeeb7SJiri Slaby * CODE -- non-C code (e.g. irq handlers with different, special stack etc.) 180ffedeeb7SJiri Slaby * 181ffedeeb7SJiri Slaby * Objtool validates stack for FUNC, but not for CODE. 182ffedeeb7SJiri Slaby * Objtool generates debug info for both FUNC & CODE, but needs special 183ffedeeb7SJiri Slaby * annotations for each CODE's start (to describe the actual stack frame). 184ffedeeb7SJiri Slaby * 1855e6dca82SNick Desaulniers * Objtool requires that all code must be contained in an ELF symbol. Symbol 1865e6dca82SNick Desaulniers * names that have a .L prefix do not emit symbol table entries. .L 1875e6dca82SNick Desaulniers * prefixed symbols can be used within a code region, but should be avoided for 1885e6dca82SNick Desaulniers * denoting a range of code via ``SYM_*_START/END`` annotations. 1895e6dca82SNick Desaulniers * 190ffedeeb7SJiri Slaby * ALIAS -- does not generate debug info -- the aliased function will 191ffedeeb7SJiri Slaby */ 192ffedeeb7SJiri Slaby 193ffedeeb7SJiri Slaby /* SYM_INNER_LABEL_ALIGN -- only for labels in the middle of code */ 194ffedeeb7SJiri Slaby #ifndef SYM_INNER_LABEL_ALIGN 195ffedeeb7SJiri Slaby #define SYM_INNER_LABEL_ALIGN(name, linkage) \ 196ffedeeb7SJiri Slaby .type name SYM_T_NONE ASM_NL \ 197ffedeeb7SJiri Slaby SYM_ENTRY(name, linkage, SYM_A_ALIGN) 198ffedeeb7SJiri Slaby #endif 199ffedeeb7SJiri Slaby 200ffedeeb7SJiri Slaby /* SYM_INNER_LABEL -- only for labels in the middle of code */ 201ffedeeb7SJiri Slaby #ifndef SYM_INNER_LABEL 202ffedeeb7SJiri Slaby #define SYM_INNER_LABEL(name, linkage) \ 203ffedeeb7SJiri Slaby .type name SYM_T_NONE ASM_NL \ 204ffedeeb7SJiri Slaby SYM_ENTRY(name, linkage, SYM_A_NONE) 205ffedeeb7SJiri Slaby #endif 206ffedeeb7SJiri Slaby 207ffedeeb7SJiri Slaby /* SYM_FUNC_START -- use for global functions */ 208ffedeeb7SJiri Slaby #ifndef SYM_FUNC_START 209ffedeeb7SJiri Slaby #define SYM_FUNC_START(name) \ 210ffedeeb7SJiri Slaby SYM_START(name, SYM_L_GLOBAL, SYM_A_ALIGN) 211ffedeeb7SJiri Slaby #endif 212ffedeeb7SJiri Slaby 213ffedeeb7SJiri Slaby /* SYM_FUNC_START_NOALIGN -- use for global functions, w/o alignment */ 214ffedeeb7SJiri Slaby #ifndef SYM_FUNC_START_NOALIGN 215ffedeeb7SJiri Slaby #define SYM_FUNC_START_NOALIGN(name) \ 216ffedeeb7SJiri Slaby SYM_START(name, SYM_L_GLOBAL, SYM_A_NONE) 217ffedeeb7SJiri Slaby #endif 218ffedeeb7SJiri Slaby 219ffedeeb7SJiri Slaby /* SYM_FUNC_START_LOCAL -- use for local functions */ 220ffedeeb7SJiri Slaby #ifndef SYM_FUNC_START_LOCAL 221ffedeeb7SJiri Slaby #define SYM_FUNC_START_LOCAL(name) \ 222ffedeeb7SJiri Slaby SYM_START(name, SYM_L_LOCAL, SYM_A_ALIGN) 223ffedeeb7SJiri Slaby #endif 224ffedeeb7SJiri Slaby 225ffedeeb7SJiri Slaby /* SYM_FUNC_START_LOCAL_NOALIGN -- use for local functions, w/o alignment */ 226ffedeeb7SJiri Slaby #ifndef SYM_FUNC_START_LOCAL_NOALIGN 227ffedeeb7SJiri Slaby #define SYM_FUNC_START_LOCAL_NOALIGN(name) \ 228ffedeeb7SJiri Slaby SYM_START(name, SYM_L_LOCAL, SYM_A_NONE) 229ffedeeb7SJiri Slaby #endif 230ffedeeb7SJiri Slaby 231ffedeeb7SJiri Slaby /* SYM_FUNC_START_WEAK -- use for weak functions */ 232ffedeeb7SJiri Slaby #ifndef SYM_FUNC_START_WEAK 233ffedeeb7SJiri Slaby #define SYM_FUNC_START_WEAK(name) \ 234ffedeeb7SJiri Slaby SYM_START(name, SYM_L_WEAK, SYM_A_ALIGN) 235ffedeeb7SJiri Slaby #endif 236ffedeeb7SJiri Slaby 237ffedeeb7SJiri Slaby /* SYM_FUNC_START_WEAK_NOALIGN -- use for weak functions, w/o alignment */ 238ffedeeb7SJiri Slaby #ifndef SYM_FUNC_START_WEAK_NOALIGN 239ffedeeb7SJiri Slaby #define SYM_FUNC_START_WEAK_NOALIGN(name) \ 240ffedeeb7SJiri Slaby SYM_START(name, SYM_L_WEAK, SYM_A_NONE) 241ffedeeb7SJiri Slaby #endif 242ffedeeb7SJiri Slaby 243ffedeeb7SJiri Slaby /* 244ffedeeb7SJiri Slaby * SYM_FUNC_END -- the end of SYM_FUNC_START_LOCAL, SYM_FUNC_START, 245ffedeeb7SJiri Slaby * SYM_FUNC_START_WEAK, ... 246ffedeeb7SJiri Slaby */ 247ffedeeb7SJiri Slaby #ifndef SYM_FUNC_END 248ffedeeb7SJiri Slaby #define SYM_FUNC_END(name) \ 249ffedeeb7SJiri Slaby SYM_END(name, SYM_T_FUNC) 250ffedeeb7SJiri Slaby #endif 251ffedeeb7SJiri Slaby 252e0891269SMark Rutland /* 253e0891269SMark Rutland * SYM_FUNC_ALIAS -- define a global alias for an existing function 254e0891269SMark Rutland */ 255e0891269SMark Rutland #ifndef SYM_FUNC_ALIAS 256e0891269SMark Rutland #define SYM_FUNC_ALIAS(alias, name) \ 2573ff5f784SPeter Zijlstra SYM_ALIAS(alias, name, SYM_L_GLOBAL) 258e0891269SMark Rutland #endif 259e0891269SMark Rutland 260e0891269SMark Rutland /* 261e0891269SMark Rutland * SYM_FUNC_ALIAS_LOCAL -- define a local alias for an existing function 262e0891269SMark Rutland */ 263e0891269SMark Rutland #ifndef SYM_FUNC_ALIAS_LOCAL 264e0891269SMark Rutland #define SYM_FUNC_ALIAS_LOCAL(alias, name) \ 2653ff5f784SPeter Zijlstra SYM_ALIAS(alias, name, SYM_L_LOCAL) 266e0891269SMark Rutland #endif 267e0891269SMark Rutland 268e0891269SMark Rutland /* 269e0891269SMark Rutland * SYM_FUNC_ALIAS_WEAK -- define a weak global alias for an existing function 270e0891269SMark Rutland */ 271e0891269SMark Rutland #ifndef SYM_FUNC_ALIAS_WEAK 272e0891269SMark Rutland #define SYM_FUNC_ALIAS_WEAK(alias, name) \ 2733ff5f784SPeter Zijlstra SYM_ALIAS(alias, name, SYM_L_WEAK) 274e0891269SMark Rutland #endif 275e0891269SMark Rutland 276ffedeeb7SJiri Slaby /* SYM_CODE_START -- use for non-C (special) functions */ 277ffedeeb7SJiri Slaby #ifndef SYM_CODE_START 278ffedeeb7SJiri Slaby #define SYM_CODE_START(name) \ 279ffedeeb7SJiri Slaby SYM_START(name, SYM_L_GLOBAL, SYM_A_ALIGN) 280ffedeeb7SJiri Slaby #endif 281ffedeeb7SJiri Slaby 282ffedeeb7SJiri Slaby /* SYM_CODE_START_NOALIGN -- use for non-C (special) functions, w/o alignment */ 283ffedeeb7SJiri Slaby #ifndef SYM_CODE_START_NOALIGN 284ffedeeb7SJiri Slaby #define SYM_CODE_START_NOALIGN(name) \ 285ffedeeb7SJiri Slaby SYM_START(name, SYM_L_GLOBAL, SYM_A_NONE) 286ffedeeb7SJiri Slaby #endif 287ffedeeb7SJiri Slaby 288ffedeeb7SJiri Slaby /* SYM_CODE_START_LOCAL -- use for local non-C (special) functions */ 289ffedeeb7SJiri Slaby #ifndef SYM_CODE_START_LOCAL 290ffedeeb7SJiri Slaby #define SYM_CODE_START_LOCAL(name) \ 291ffedeeb7SJiri Slaby SYM_START(name, SYM_L_LOCAL, SYM_A_ALIGN) 292ffedeeb7SJiri Slaby #endif 293ffedeeb7SJiri Slaby 294ffedeeb7SJiri Slaby /* 295ffedeeb7SJiri Slaby * SYM_CODE_START_LOCAL_NOALIGN -- use for local non-C (special) functions, 296ffedeeb7SJiri Slaby * w/o alignment 297ffedeeb7SJiri Slaby */ 298ffedeeb7SJiri Slaby #ifndef SYM_CODE_START_LOCAL_NOALIGN 299ffedeeb7SJiri Slaby #define SYM_CODE_START_LOCAL_NOALIGN(name) \ 300ffedeeb7SJiri Slaby SYM_START(name, SYM_L_LOCAL, SYM_A_NONE) 301ffedeeb7SJiri Slaby #endif 302ffedeeb7SJiri Slaby 303ffedeeb7SJiri Slaby /* SYM_CODE_END -- the end of SYM_CODE_START_LOCAL, SYM_CODE_START, ... */ 304ffedeeb7SJiri Slaby #ifndef SYM_CODE_END 305ffedeeb7SJiri Slaby #define SYM_CODE_END(name) \ 306ffedeeb7SJiri Slaby SYM_END(name, SYM_T_NONE) 307ffedeeb7SJiri Slaby #endif 308ffedeeb7SJiri Slaby 309ffedeeb7SJiri Slaby /* === data annotations === */ 310ffedeeb7SJiri Slaby 311ffedeeb7SJiri Slaby /* SYM_DATA_START -- global data symbol */ 312ffedeeb7SJiri Slaby #ifndef SYM_DATA_START 313ffedeeb7SJiri Slaby #define SYM_DATA_START(name) \ 314ffedeeb7SJiri Slaby SYM_START(name, SYM_L_GLOBAL, SYM_A_NONE) 315ffedeeb7SJiri Slaby #endif 316ffedeeb7SJiri Slaby 317ffedeeb7SJiri Slaby /* SYM_DATA_START -- local data symbol */ 318ffedeeb7SJiri Slaby #ifndef SYM_DATA_START_LOCAL 319ffedeeb7SJiri Slaby #define SYM_DATA_START_LOCAL(name) \ 320ffedeeb7SJiri Slaby SYM_START(name, SYM_L_LOCAL, SYM_A_NONE) 321ffedeeb7SJiri Slaby #endif 322ffedeeb7SJiri Slaby 323ffedeeb7SJiri Slaby /* SYM_DATA_END -- the end of SYM_DATA_START symbol */ 324ffedeeb7SJiri Slaby #ifndef SYM_DATA_END 325ffedeeb7SJiri Slaby #define SYM_DATA_END(name) \ 326ffedeeb7SJiri Slaby SYM_END(name, SYM_T_OBJECT) 327ffedeeb7SJiri Slaby #endif 328ffedeeb7SJiri Slaby 329ffedeeb7SJiri Slaby /* SYM_DATA_END_LABEL -- the labeled end of SYM_DATA_START symbol */ 330ffedeeb7SJiri Slaby #ifndef SYM_DATA_END_LABEL 331ffedeeb7SJiri Slaby #define SYM_DATA_END_LABEL(name, linkage, label) \ 332ffedeeb7SJiri Slaby linkage(label) ASM_NL \ 333ffedeeb7SJiri Slaby .type label SYM_T_OBJECT ASM_NL \ 334ffedeeb7SJiri Slaby label: \ 335ffedeeb7SJiri Slaby SYM_END(name, SYM_T_OBJECT) 336ffedeeb7SJiri Slaby #endif 337ffedeeb7SJiri Slaby 338ffedeeb7SJiri Slaby /* SYM_DATA -- start+end wrapper around simple global data */ 339ffedeeb7SJiri Slaby #ifndef SYM_DATA 340ffedeeb7SJiri Slaby #define SYM_DATA(name, data...) \ 341ffedeeb7SJiri Slaby SYM_DATA_START(name) ASM_NL \ 342ffedeeb7SJiri Slaby data ASM_NL \ 343ffedeeb7SJiri Slaby SYM_DATA_END(name) 344ffedeeb7SJiri Slaby #endif 345ffedeeb7SJiri Slaby 346ffedeeb7SJiri Slaby /* SYM_DATA_LOCAL -- start+end wrapper around simple local data */ 347ffedeeb7SJiri Slaby #ifndef SYM_DATA_LOCAL 348ffedeeb7SJiri Slaby #define SYM_DATA_LOCAL(name, data...) \ 349ffedeeb7SJiri Slaby SYM_DATA_START_LOCAL(name) ASM_NL \ 350ffedeeb7SJiri Slaby data ASM_NL \ 351ffedeeb7SJiri Slaby SYM_DATA_END(name) 352ffedeeb7SJiri Slaby #endif 353ffedeeb7SJiri Slaby 354ffedeeb7SJiri Slaby #endif /* __ASSEMBLY__ */ 355ffedeeb7SJiri Slaby 356ffedeeb7SJiri Slaby #endif /* _LINUX_LINKAGE_H */ 357