Re: kernel_thread

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Chirag Kantharia wrote:
On Fri, Aug 20, 2004 at 11:05:05AM +0530, Nilanjan Roychowdhury wrote:
| > Can I access the user space data using copy_from_user from a
| > Kernel_thread ??
| No. Exactly whose user-space would the kernel thread access? | >>> if I do not call daemonize() then also I can't access any user space data ????


kernel threads don't run in context of a user process, and so, which user space data, do you wish to acces from kernel thread?

kernel threads don't have a user context. They cannot access any memory less than TASK_SIZE ( PAGE_OFFSET). Their mm field in the proc_struct is always null. They have only active_mm. This is implemented in daemonize() call.


HTH.
Om.


-- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux