make.tmpl: add missing compiler attribute to build_progs
[AROS.git] / arch / m68k-mac / exec / traps.h
blobfb616896d8b8b68a30fdbbb02935837e6b6cd916
1 #ifndef _TRAPS_H
2 #define _TRAPS_H
4 #include <asm/irq.h>
5 #include <asm/linkage.h>
7 /* Here are some macros used to build trap table in core file. */
9 #define TRAP_NAME2(nr) nr##_trap(void)
10 #define TRAP_NAME(nr) TRAP_NAME2(TRAP##nr)
12 #define BUILD_COMMON_TRAP() \
13 __asm__( \
14 "\n"__ALIGN_STR"\n" \
15 "common_trap:\n\t" \
16 SAVE_REGS \
17 "call "SYMBOL_NAME_STR(do_TRAP)"\n\t"\
18 RESTORE_REGS \
19 "rte\n");
21 #define BUILD_TRAP(nr) \
22 asmlinkage void TRAP_NAME(nr); \
23 __asm__( \
24 "\n"__ALIGN_STR"\n" \
25 SYMBOL_NAME_STR(TRAP) #nr "_trap:\n\t" \
26 "pushl $"#nr"\n\t" \
27 "jmp common_trap");
29 void Init_Traps(void);
31 #endif /* _TRAPS_H */