Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
an LRU list, clears PageLRU and adjusts the

vmstat statistic corresponding to whatever LRU list the page was on.

Returns 0 if the page was removed from an LRU list. Returns -EBUSY if the page was not on an LRU list.

The returned page will have PageLRU() cleared. If it was found on the active list, it will have PageActive set. If it was found on the unevictable list, it will have the PageUnevictable bit set. That flag may need to be cleared by the caller before letting the page go.

The vmstat statistic corresponding to the list on which the page was found will be decremented.

Restrictions: (1) Must be called with an elevated refcount on the page. This is a fundamentnal difference from isolate_lru_pages (which is called without a stable reference). (2) the lru_lock must not be held. (3) interrupts must be enabled.