Idle THPs

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

 



As part of the folio work, I'm looking at PageIdle and PageYoung and
they're defined to operate on PF_ANY.  So, for example, in
pagecache_get_page(), we will call clear_page_idle() on the head page
(actually, I changed this in a8cf7f272b5a -- before, it would call
clear_page_idle() on the tail page).

However, we never actually call set_page_idle() on tail pages.  This is
because we only call it here:

                        page = page_idle_get_page(pfn);
                        if (page) {
                                page_idle_clear_pte_refs(page);
                                set_page_idle(page);
                                put_page(page);
                        }

where page_idle_get_page() does:

        struct page *page = pfn_to_online_page(pfn);

        if (!page || !PageLRU(page) ||
            !get_page_unless_zero(page))
                return NULL;

get_page_unless_zero() will always fail for tail pages (as it uses
page_ref_add_unless(), which does not redirect to the head page's
refcount).  So all tail pages read back as !idle in
page_idle_bitmap_read().  Is this intended?  Should they rather
mirror the state of their head page?





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

  Powered by Linux