Linux MIPS Architecture development
 help / color / mirror / Atom feed
* [patch] modutils 2.4.6: Make __dbe_table available to modules
@ 2001-08-13 13:43 Maciej W. Rozycki
  2001-08-13 14:19 ` Keith Owens
  2001-08-20 14:04 ` [patch] modutils 2.4.6: __dbe_table iteration #2 Maciej W. Rozycki
  0 siblings, 2 replies; 5+ messages in thread
From: Maciej W. Rozycki @ 2001-08-13 13:43 UTC (permalink / raw)
  To: Keith Owens, Ralf Baechle, Harald Koerfgen; +Cc: linux-mips, linux-mips

Hi,

 The following patch is needed for modutils to initialize __dbe_table
table pointers appropriately for modules that want to handle bus error
exceptions on MIPS.  A separate patch is needed for the kernel.

  Maciej

-- 
+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+--------------------------------------------------------------+
+        e-mail: macro@ds2.pg.gda.pl, PGP key available        +

modutils-2.4.6-mips-dbe.patch
diff -up --recursive --new-file modutils-2.4.6.macro/include/module.h modutils-2.4.6/include/module.h
--- modutils-2.4.6.macro/include/module.h	Fri Jan  5 01:45:19 2001
+++ modutils-2.4.6/include/module.h	Sun Aug 12 13:16:13 2001
@@ -153,6 +153,10 @@ struct module
   unsigned tgt_long cleanup;
   unsigned tgt_long ex_table_start;
   unsigned tgt_long ex_table_end;
+#ifdef __mips__
+  unsigned tgt_long dbe_table_start;
+  unsigned tgt_long dbe_table_end;
+#endif
 #ifdef __alpha__
   unsigned tgt_long gp;
 #endif
diff -up --recursive --new-file modutils-2.4.6.macro/man/init_module.2 modutils-2.4.6/man/init_module.2
--- modutils-2.4.6.macro/man/init_module.2	Fri Jan  5 01:45:19 2001
+++ modutils-2.4.6/man/init_module.2	Sun Aug 12 13:17:14 2001
@@ -39,6 +39,10 @@ struct module
   void (*cleanup)(void);
   const struct exception_table_entry *ex_table_start;
   const struct exception_table_entry *ex_table_end;
+#ifdef __mips__
+  const struct exception_table_entry *dbe_table_start;
+  const struct exception_table_entry *dbe_table_end;
+#endif
 #ifdef __alpha__
   unsigned long gp;
 #endif
diff -up --recursive --new-file modutils-2.4.6.macro/obj/obj_mips.c modutils-2.4.6/obj/obj_mips.c
--- modutils-2.4.6.macro/obj/obj_mips.c	Fri Jan  5 01:45:19 2001
+++ modutils-2.4.6/obj/obj_mips.c	Sun Aug 12 16:16:26 2001
@@ -217,6 +217,15 @@ arch_create_got (struct obj_file *f)
 int
 arch_init_module (struct obj_file *f, struct module *mod)
 {
+  struct obj_section *sec;
+
+  sec = obj_find_section(f, "__dbe_table");
+  if (sec)
+    {
+      mod->dbe_table_start = sec->header.sh_addr;
+      mod->dbe_table_end = sec->header.sh_addr + sec->header.sh_size;
+    }
+
   return 1;
 }
 

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2001-08-20 14:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-08-13 13:43 [patch] modutils 2.4.6: Make __dbe_table available to modules Maciej W. Rozycki
2001-08-13 14:19 ` Keith Owens
2001-08-13 14:49   ` Maciej W. Rozycki
2001-08-13 15:14     ` Keith Owens
2001-08-20 14:04 ` [patch] modutils 2.4.6: __dbe_table iteration #2 Maciej W. Rozycki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox