aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/include/asm/dwarf.h
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2009-10-13 00:32:19 -0400
committerPaul Mundt <lethal@linux-sh.org>2009-10-13 00:32:19 -0400
commit5a3abba77dc0eb0b00332c21899123cdfa3b19e5 (patch)
treecb0b52bcb90f5c680faba380a0832203bdad2fed /arch/sh/include/asm/dwarf.h
parentac4fac8cb24ab209ae373a3e3e9995dff7d0c394 (diff)
sh: Tidy up the dwarf module helpers.
This enables us to build the dwarf unwinder both with modules enabled and disabled in addition to reducing code size in the latter case. The helpers are also consolidated, and modified to resemble the BUG module helpers. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/include/asm/dwarf.h')
-rw-r--r--arch/sh/include/asm/dwarf.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/arch/sh/include/asm/dwarf.h b/arch/sh/include/asm/dwarf.h
index d985148af19f..bdccbbfdc0bd 100644
--- a/arch/sh/include/asm/dwarf.h
+++ b/arch/sh/include/asm/dwarf.h
@@ -198,6 +198,7 @@
198#include <linux/compiler.h> 198#include <linux/compiler.h>
199#include <linux/bug.h> 199#include <linux/bug.h>
200#include <linux/list.h> 200#include <linux/list.h>
201#include <linux/module.h>
201 202
202/* 203/*
203 * Read either the frame pointer (r14) or the stack pointer (r15). 204 * Read either the frame pointer (r14) or the stack pointer (r15).
@@ -382,8 +383,10 @@ static inline unsigned int DW_CFA_operand(unsigned long insn)
382extern struct dwarf_frame *dwarf_unwind_stack(unsigned long, 383extern struct dwarf_frame *dwarf_unwind_stack(unsigned long,
383 struct dwarf_frame *); 384 struct dwarf_frame *);
384extern void dwarf_free_frame(struct dwarf_frame *); 385extern void dwarf_free_frame(struct dwarf_frame *);
385extern int dwarf_parse_section(char *, char *, struct module *); 386
386extern void dwarf_module_unload(struct module *); 387extern int module_dwarf_finalize(const Elf_Ehdr *, const Elf_Shdr *,
388 struct module *);
389extern void module_dwarf_cleanup(struct module *);
387 390
388#endif /* !__ASSEMBLY__ */ 391#endif /* !__ASSEMBLY__ */
389 392
@@ -412,6 +415,10 @@ extern void dwarf_module_unload(struct module *);
412static inline void dwarf_unwinder_init(void) 415static inline void dwarf_unwinder_init(void)
413{ 416{
414} 417}
418
419#define module_dwarf_finalize(hdr, sechdrs, me) (0)
420#define module_dwarf_cleanup(mod) do { } while (0)
421
415#endif 422#endif
416 423
417#endif /* CONFIG_DWARF_UNWINDER */ 424#endif /* CONFIG_DWARF_UNWINDER */