>>>>> "Nagaraj" == Nagaraj <nagaraj@smartyantra.com> writes: FWIW, the problem is the classic producer-consumer problem with solutions described in _any_ OS textbook. Thus, the right solution would be to use semaphores. But, AFAIK, there are no semaphores shared between the userspace and the kernel. Probably futexes can do the work. ~velco -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/