[RFC, PATCH 20/24] i386 Vmi module fixups

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Add a sub-arch specifier to the module identification string to avoid
cross loading modules from different subarch compiles.

XXX FIXME.  Module loading is broken in paravirtualized VMI kernels,
since there is no annotation fixup applied to modules.

Signed-off-by: Zachary Amsden <[email protected]>

Index: linux-2.6.16-rc3/include/asm-i386/module.h
===================================================================
--- linux-2.6.16-rc3.orig/include/asm-i386/module.h	2006-02-24 16:00:21.000000000 -0800
+++ linux-2.6.16-rc3/include/asm-i386/module.h	2006-02-24 16:02:02.000000000 -0800
@@ -1,6 +1,8 @@
 #ifndef _ASM_I386_MODULE_H
 #define _ASM_I386_MODULE_H
 
+#include <mach_module.h>
+
 /* x86 is simple */
 struct mod_arch_specific
 {
@@ -72,6 +74,7 @@ struct mod_arch_specific
 #define MODULE_STACKSIZE ""
 #endif
 
-#define MODULE_ARCH_VERMAGIC MODULE_PROC_FAMILY MODULE_REGPARM MODULE_STACKSIZE
+#define MODULE_ARCH_VERMAGIC MODULE_PROC_FAMILY MODULE_REGPARM MODULE_STACKSIZE \
+	MODULE_SUBARCH_VERMAGIC
 
 #endif /* _ASM_I386_MODULE_H */
Index: linux-2.6.16-rc3/include/asm-i386/mach-vmi/mach_module.h
===================================================================
--- linux-2.6.16-rc3.orig/include/asm-i386/mach-vmi/mach_module.h	2006-02-24 16:02:02.000000000 -0800
+++ linux-2.6.16-rc3/include/asm-i386/mach-vmi/mach_module.h	2006-02-24 16:02:02.000000000 -0800
@@ -0,0 +1,6 @@
+#ifndef _ASM_I386_ARCH_MODULE_H
+#define _ASM_I386_ARCH_MODULE_H
+
+#define MODULE_SUBARCH_VERMAGIC "VMI "
+
+#endif /* _ASM_I386_ARCH_MODULE_H */
Index: linux-2.6.16-rc3/include/asm-i386/mach-default/mach_module.h
===================================================================
--- linux-2.6.16-rc3.orig/include/asm-i386/mach-default/mach_module.h	2006-02-24 16:02:02.000000000 -0800
+++ linux-2.6.16-rc3/include/asm-i386/mach-default/mach_module.h	2006-02-24 16:02:02.000000000 -0800
@@ -0,0 +1,6 @@
+#ifndef _ASM_I386_ARCH_MODULE_H
+#define _ASM_I386_ARCH_MODULE_H
+
+#define MODULE_SUBARCH_VERMAGIC
+
+#endif /* _ASM_I386_ARCH_MODULE_H */
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux