LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Kernel (https://www.linuxquestions.org/questions/linux-kernel-70/)
-   -   why it can access current pointer in timer func? (https://www.linuxquestions.org/questions/linux-kernel-70/why-it-can-access-current-pointer-in-timer-func-622190/)

linwenyuan 02-19-2008 04:58 AM

why it can access current pointer in timer func?
 
hi all ,
now i am reading and studying ldd 3rd ,the chapter about kernel time.i have a question: why it can access current pointer in timer funcs now that the time func resembles software irq.
i embed the statment in my timer func
printk(KERN_ALERT "The process is \"%s\" (pid %i)\n cpu is %i\n",current->comm,current->pid,smp_processor_id());

some time the process is "swapper"
somt time is "klogd" or "syslogd",
but most of time is "swapper"

any answer would be appreciated very much .


All times are GMT -5. The time now is 05:30 PM.