![]() | |||||||||||||
Messages in this thread |
Hi, I'm new to Linux module dev, I copied a very simple module from a book (http://lwn.net/Kernel/LDD2/ch02.lwn) and I can't insert it into the kernel. I found hundreds of bug reports about it on google without any solution. I must be doing something wrong... /*----------mymodule.c-----------*/ #define MODULE #include <linux/module.h> int init_module(void) { printk("<1>Hello, world\n"); return 0; } void cleanup_module(void) { printk("<1>Goodbye cruel world\n"); } /*----------EOF-----------*/ # gcc -c mymodule.c # insmod mymodule.o insmod: error inserting 'mymodule.o': -1 Invalid module format Thanks a lot steph - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ | ||||||||||||
| Last update: 2005-03-22 14:08 [from the cache] ©2003-2008 | |||||||||||||