Hi... > Hi all > I tried a simple snippet like > ... > struct task_struct *p; > p = current; > printk(KERN_DEBUG "%u", p->pid); Try to do like below: struct task_struct *p = current In other word, maybe you need to enforce type cast.... > Second When i looked at the dmesg after insmod i found the pid > 3846,fine to me but when i rmmod the module i found that the same > entery has change to 3846<7> . Why didnt the KERN_DEBUG priority i.e > <7> is printed earlier? How did you find out that "3846" has been changed to "3846<7>"? Without looking at your complete code, maybe it is just printk that showed you the message priority. What debug features you had enabled ? regards Mulyadi -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/