Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | #ifndef _ASM_M68K_MODULE_H |
| 2 | #define _ASM_M68K_MODULE_H |
Roman Zippel | fbe9c96 | 2007-05-31 00:40:50 -0700 | [diff] [blame] | 3 | |
| 4 | struct mod_arch_specific { |
| 5 | struct m68k_fixup_info *fixup_start, *fixup_end; |
| 6 | }; |
| 7 | |
| 8 | #define MODULE_ARCH_INIT { \ |
| 9 | .fixup_start = __start_fixup, \ |
| 10 | .fixup_end = __stop_fixup, \ |
| 11 | } |
| 12 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 13 | #define Elf_Shdr Elf32_Shdr |
| 14 | #define Elf_Sym Elf32_Sym |
| 15 | #define Elf_Ehdr Elf32_Ehdr |
Roman Zippel | fbe9c96 | 2007-05-31 00:40:50 -0700 | [diff] [blame] | 16 | |
| 17 | |
| 18 | enum m68k_fixup_type { |
| 19 | m68k_fixup_memoffset, |
Roman Zippel | 12d810c | 2007-05-31 00:40:54 -0700 | [diff] [blame] | 20 | m68k_fixup_vnode_shift, |
Roman Zippel | fbe9c96 | 2007-05-31 00:40:50 -0700 | [diff] [blame] | 21 | }; |
| 22 | |
| 23 | struct m68k_fixup_info { |
| 24 | enum m68k_fixup_type type; |
| 25 | void *addr; |
| 26 | }; |
| 27 | |
| 28 | #define m68k_fixup(type, addr) \ |
| 29 | " .section \".m68k_fixup\",\"aw\"\n" \ |
| 30 | " .long " #type "," #addr "\n" \ |
| 31 | " .previous\n" |
| 32 | |
| 33 | extern struct m68k_fixup_info __start_fixup[], __stop_fixup[]; |
| 34 | |
| 35 | struct module; |
| 36 | extern void module_fixup(struct module *mod, struct m68k_fixup_info *start, |
| 37 | struct m68k_fixup_info *end); |
| 38 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 39 | #endif /* _ASM_M68K_MODULE_H */ |