On Tue, Feb 5, 2013 at 2:07 PM, Li Haifeng <span dir="ltr"><<a href="mailto:omycle@gmail.com" target="_blank">omycle@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi, all in kernel.<br>
<br>
The page->_count is the page frame's usage count. When page is<br>
allocated, the page->_cout will be set 1.<br>
<br>
After be allocated from buddy system, the page will be used by<br>
process. get_page and put_page/put_page_testzero will used in pairs.<br>
is it right?<br>
<br>
When the page is reclaimed to buddy system, the page->_count should be<br>
0. However, Because the initialization of page->_count is 1,<br>
get_page() and put_page() is called in pairs, I coufused how<br>
page->_count will be 0?<br>
<br></blockquote><div><br></div><div>Not sure but I suspect that the page->_count will be 0 whenever the file is deleted.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Thanks.<br>
<br>
_______________________________________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org">Kernelnewbies@kernelnewbies.org</a><br>
<a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
</blockquote></div><br>