headers: move module_bug_finalize()/module_bug_cleanup() definitions into module.h
[sfrench/cifs-2.6.git] / include / linux / bug.h
index 42aa0a54b6f4d919a1568a881aeaabb9469640d7..d276b5510c83498bbd4815367ef05cf398beee3b 100644 (file)
@@ -1,7 +1,6 @@
 #ifndef _LINUX_BUG_H
 #define _LINUX_BUG_H
 
-#include <linux/module.h>
 #include <asm/bug.h>
 
 enum bug_trap_type {
@@ -10,6 +9,8 @@ enum bug_trap_type {
        BUG_TRAP_TYPE_BUG = 2,
 };
 
+struct pt_regs;
+
 #ifdef CONFIG_GENERIC_BUG
 #include <asm-generic/bug.h>
 
@@ -20,28 +21,18 @@ static inline int is_warning_bug(const struct bug_entry *bug)
 
 const struct bug_entry *find_bug(unsigned long bugaddr);
 
-enum bug_trap_type report_bug(unsigned long bug_addr);
-
-int  module_bug_finalize(const Elf_Ehdr *, const Elf_Shdr *,
-                        struct module *);
-void module_bug_cleanup(struct module *);
+enum bug_trap_type report_bug(unsigned long bug_addr, struct pt_regs *regs);
 
 /* These are defined by the architecture */
 int is_valid_bugaddr(unsigned long addr);
 
 #else  /* !CONFIG_GENERIC_BUG */
 
-static inline enum bug_trap_type report_bug(unsigned long bug_addr)
+static inline enum bug_trap_type report_bug(unsigned long bug_addr,
+                                           struct pt_regs *regs)
 {
        return BUG_TRAP_TYPE_BUG;
 }
-static inline int  module_bug_finalize(const Elf_Ehdr *hdr,
-                                       const Elf_Shdr *sechdrs,
-                                       struct module *mod)
-{
-       return 0;
-}
-static inline void module_bug_cleanup(struct module *mod) {}
 
 #endif /* CONFIG_GENERIC_BUG */
 #endif /* _LINUX_BUG_H */