Re: [PATCHv4 14/39] thp, mm: rewrite delete_from_page_cache() to support huge pages

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

 



Dave Hansen wrote:
> On 06/07/2013 08:10 AM, Kirill A. Shutemov wrote:
> > +	/*
> > +	 * When we add a huge page to page cache we take only reference to head
> > +	 * page, but on split we need to take addition reference to all tail
> > +	 * pages since they are still in page cache after splitting.
> > +	 */
> > +	init_tail_refcount = PageAnon(page) ? 0 : 1;
> 
> What's the "init" for in the name?

initial_tail_refcount?

> In add_to_page_cache_locked() in patch 12/39, you do
> > +       spin_lock_irq(&mapping->tree_lock);
> > +       for (i = 0; i < nr; i++) {
> > +               page_cache_get(page + i);
> 
> That looks to me to be taking references to the tail pages.  What gives? :)

The point is to drop this from add_to_page_cache_locked() and make distribution
on split.

-- 
 Kirill A. Shutemov

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]