kernel modules
rinku rathore
rinku_ques@yahoo.com
Tue Sep 7 11:30:00 GMT 2004
Hello,
I am trying to build a kernel module that is:-
/*module name is "hello.c"*/
#include <linux/module.h>// Needed by all
modules
#include <linux/kernel.h>
int init_module(void)
{
printk("<1>Hello world 1.\n");
// A non 0 return means init_module failed;
module can't be loaded.
return 0;
}
void cleanup_module(void)
{
printk("<1>Goodbye world 1.\n");
}
And then compiling it with the command:-
gcc -c hello.c
it get successfully compiled and then I am trying to
insert it with command
insmod ./hello.o
An error as followed is arived how can I remove this
error:-
error: ./hell.o: couldn't find the kernel version the
module was compiled for
Thanx Rinku Rathore
__________________________________
Do you Yahoo!?
Read only the mail you want - Yahoo! Mail SpamGuard.
http://promotions.yahoo.com/new_mail
More information about the Gcc
mailing list