Here are my views > Does anyone know if it is possible to have a > copy-on-write page that is shared? > After forking all the pages are marked COW. COW pages are always shared. >Shared page is represented by "page_count(page) >= 2". > > So can I have a copy-on-write page that its count is > >= 2 (shared)? > > Yes, rather one should bother about internal details and should use directly page_count() macro and not page->_count directly because for a free page this value is -1 (-ve) and if only one process is there then page->_count equals zero. So better use page_count(). COW pages will be alwys read only. One process trying to write will lead to generate page fault. page fault handler will give new copy of the page to write. Regards, lk -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/