On 11/11/05, Jim Bauer <jfbauer@xxxxxxx> wrote: > Laurent Nadeau wrote: > > > > I am not sure exactly what this means. Should I change > > the context and how? > > No. You need to redesign your code so you don't try to access > user-space memory when from code that is run when not in process context. > > Adding one more thing to Jim's reply: Try to avoid accessing user space pointer/memory other than the system-calls because they might be swapped-out at the later time when you will be going to access user memory in kernel (might be accessing in some other than process context). So for making user memory available at any time in kernel, you have to create mapping of user memory with-in kernel address space such that it won't be able to swapped-out and the pointer for that memory location mapped in kernel space will be available for directly usage (like without using copy_from_user and friends). For this you can use get_user_pages (declared in linux/mm.h) but I can't say much about this (as I havn't used it in 2.6.x kernels) but in 2.4.x kernels I did this through kiobuf ! -- Fawad Lateef -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/