aboutsummaryrefslogtreecommitdiffstats
path: root/arch/i386/kernel/module.c
diff options
context:
space:
mode:
authorJeremy Fitzhardinge <jeremy@goop.org>2006-12-08 05:36:21 -0500
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-08 11:28:39 -0500
commit91768d6c2bad0d2766a166f13f2f57e197de3458 (patch)
tree3857842d8635b2032c84c5e2e1b05181cd48ca65 /arch/i386/kernel/module.c
parent7664c5a1da4711bb6383117f51b94c8dc8f3f1cd (diff)
[PATCH] Generic BUG for i386
This makes i386 use the generic BUG machinery. There are no functional changes from the old i386 implementation. The main advantage in using the generic BUG machinery for i386 is that the inlined overhead of BUG is just the ud2a instruction; the file+line(+function) information are no longer inlined into the instruction stream. This reduces cache pollution, and makes disassembly work properly. Signed-off-by: Jeremy Fitzhardinge <jeremy@goop.org> Cc: Andi Kleen <ak@muc.de> Cc: Hugh Dickens <hugh@veritas.com> Cc: Michael Ellerman <michael@ellerman.id.au> Cc: Paul Mackerras <paulus@samba.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/i386/kernel/module.c')
-rw-r--r--arch/i386/kernel/module.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/i386/kernel/module.c b/arch/i386/kernel/module.c
index d7d9c8b23f72..3db0a5442eb1 100644
--- a/arch/i386/kernel/module.c
+++ b/arch/i386/kernel/module.c
@@ -21,6 +21,7 @@
21#include <linux/fs.h> 21#include <linux/fs.h>
22#include <linux/string.h> 22#include <linux/string.h>
23#include <linux/kernel.h> 23#include <linux/kernel.h>
24#include <linux/bug.h>
24 25
25#if 0 26#if 0
26#define DEBUGP printk 27#define DEBUGP printk
@@ -141,10 +142,11 @@ int module_finalize(const Elf_Ehdr *hdr,
141 apply_paravirt(pseg, pseg + para->sh_size); 142 apply_paravirt(pseg, pseg + para->sh_size);
142 } 143 }
143 144
144 return 0; 145 return module_bug_finalize(hdr, sechdrs, me);
145} 146}
146 147
147void module_arch_cleanup(struct module *mod) 148void module_arch_cleanup(struct module *mod)
148{ 149{
149 alternatives_smp_module_del(mod); 150 alternatives_smp_module_del(mod);
151 module_bug_cleanup(mod);
150} 152}