revert between 56095 -> 55830 in arch
[AROS.git] / arch / m68k-mac / include / asm / linkage.h
blob2a4f06460fed2cb617ccf5f9da31d7fa88c23640
1 /*
2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
3 $Id$
4 */
6 #ifndef ASM_LINKAGE_H
7 #define ASM_LINKAGE_H
9 #ifdef __cplusplus
10 #define CPP_ASMLINKAGE extern "C"
11 #else
12 #define CPP_ASMLINKAGE
13 #endif
15 #if defined __i386__ && (__GNUC__ > 2 || __GNUC_MINOR__ > 7)
16 #define asmlinkage CPP_ASMLINKAGE __attribute__((regparm(0)))
17 #else
18 #define asmlinkage CPP_ASMLINKAGE
19 #endif
21 #define SYMBOL_NAME_STR(X) #X
22 #define SYMBOL_NAME(X) X
23 #ifdef __STDC__
24 #define SYMBOL_NAME_LABEL(X) X##:
25 #else
26 #define SYMBOL_NAME_LABEL(X) X/**/:
27 #endif
29 #ifdef __arm__
30 #define __ALIGN .align 0
31 #define __ALIGN_STR ".align 0"
32 #else
33 #ifdef __mc68000__
34 #define __ALIGN .align 4
35 #define __ALIGN_STR ".align 4"
36 #else
37 #if !defined(__i486__) && !defined(__i586__)
38 #define __ALIGN .align 4,0x90
39 #define __ALIGN_STR ".align 4,0x90"
40 #else /* __i486__/__i586__ */
41 #define __ALIGN .align 16,0x90
42 #define __ALIGN_STR ".align 16,0x90"
43 #endif /* __i486__/__i586__ */
44 #endif /* __mc68000__ */
45 #endif /* __arm__ */
47 #ifdef __ASSEMBLY__
49 #define ALIGN __ALIGN
50 #define ALIGN_STR __ALIGN_STR
52 #define ENTRY(name) \
53 .globl SYMBOL_NAME(name); \
54 ALIGN; \
55 SYMBOL_NAME_LABEL(name)
57 #endif
59 #endif