Hi, You get tainted message while loading the kernel, if you
have not used MODULE_LICENSE macro in your module. As Suneesh has mentioned you can visit the link mentioned in
his mail below to know more about tainted kernels. To avoid taint error while loading the kernel module use
following macro in your module MODULE_LICENSE(“GPL”) You might not be able to see the printk() messages. This is
because you, printk() function puts all the messages in kernel’s circular
queue (it is a kernel data structure). On other side Kernel Daemon “klogd”
is responsible for fetching the messages from this circular queue and forwarding
it to syslogd daemon or showing it on consol if the message priority is less
than ‘consol’ parameter of klogd daemon. In case the message is
forwarded to “syslogd” daemon, slogd puts the messages in
/var/log/messages file (which you can read by ‘cat’ command or ‘dmesg’
command) or some other file as per its configuration file. For more information on printk() kernel function and logging
mechanism of kernel, do read the 4th chapter of Rubini’s book
on Linux Device Drivers. Following is the link to it. Link: http://www.xml.com/ldd/chapter/book/ch04.html#t1 If I am wrong at some place, do correct me. Regards, Gaurav From:
kernelnewbies-bounce@xxxxxxxxxxxx [mailto:kernelnewbies-bounce@xxxxxxxxxxxx] On Behalf Of suneesh Hi hello,I have a little problem after
do as you suggest: Create
a makefile like this : when i insmod ./hello.o,the
kernel says like this: no liscense,the kernel will
be tainted, module hello loaded with
warning The 'tainted' problem and solution has described here .. and I didn't see any message which
should be printed by "printk"in init_module method, how should I solve the problem You may be running your insmod or rmmod from an xterm, then it will |