Skip to content

Commit

Permalink
mm: remove CONFIG_UNEVICTABLE_LRU config option
Browse files Browse the repository at this point in the history
Currently, nobody wants to turn UNEVICTABLE_LRU off.  Thus this
configurability is unnecessary.

Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Andi Kleen <andi@firstfloor.org>
Acked-by: Minchan Kim <minchan.kim@gmail.com>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Matt Mackall <mpm@selenic.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Lee Schermerhorn <lee.schermerhorn@hp.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
kosaki authored and torvalds committed Jun 17, 2009
1 parent bce7394 commit 6837765
Show file tree
Hide file tree
Showing 17 changed files with 3 additions and 153 deletions.
4 changes: 0 additions & 4 deletions drivers/base/node.c
Expand Up @@ -72,10 +72,8 @@ static ssize_t node_read_meminfo(struct sys_device * dev,
"Node %d Inactive(anon): %8lu kB\n" "Node %d Inactive(anon): %8lu kB\n"
"Node %d Active(file): %8lu kB\n" "Node %d Active(file): %8lu kB\n"
"Node %d Inactive(file): %8lu kB\n" "Node %d Inactive(file): %8lu kB\n"
#ifdef CONFIG_UNEVICTABLE_LRU
"Node %d Unevictable: %8lu kB\n" "Node %d Unevictable: %8lu kB\n"
"Node %d Mlocked: %8lu kB\n" "Node %d Mlocked: %8lu kB\n"
#endif
#ifdef CONFIG_HIGHMEM #ifdef CONFIG_HIGHMEM
"Node %d HighTotal: %8lu kB\n" "Node %d HighTotal: %8lu kB\n"
"Node %d HighFree: %8lu kB\n" "Node %d HighFree: %8lu kB\n"
Expand Down Expand Up @@ -105,10 +103,8 @@ static ssize_t node_read_meminfo(struct sys_device * dev,
nid, K(node_page_state(nid, NR_INACTIVE_ANON)), nid, K(node_page_state(nid, NR_INACTIVE_ANON)),
nid, K(node_page_state(nid, NR_ACTIVE_FILE)), nid, K(node_page_state(nid, NR_ACTIVE_FILE)),
nid, K(node_page_state(nid, NR_INACTIVE_FILE)), nid, K(node_page_state(nid, NR_INACTIVE_FILE)),
#ifdef CONFIG_UNEVICTABLE_LRU
nid, K(node_page_state(nid, NR_UNEVICTABLE)), nid, K(node_page_state(nid, NR_UNEVICTABLE)),
nid, K(node_page_state(nid, NR_MLOCK)), nid, K(node_page_state(nid, NR_MLOCK)),
#endif
#ifdef CONFIG_HIGHMEM #ifdef CONFIG_HIGHMEM
nid, K(i.totalhigh), nid, K(i.totalhigh),
nid, K(i.freehigh), nid, K(i.freehigh),
Expand Down
4 changes: 0 additions & 4 deletions fs/proc/meminfo.c
Expand Up @@ -64,10 +64,8 @@ static int meminfo_proc_show(struct seq_file *m, void *v)
"Inactive(anon): %8lu kB\n" "Inactive(anon): %8lu kB\n"
"Active(file): %8lu kB\n" "Active(file): %8lu kB\n"
"Inactive(file): %8lu kB\n" "Inactive(file): %8lu kB\n"
#ifdef CONFIG_UNEVICTABLE_LRU
"Unevictable: %8lu kB\n" "Unevictable: %8lu kB\n"
"Mlocked: %8lu kB\n" "Mlocked: %8lu kB\n"
#endif
#ifdef CONFIG_HIGHMEM #ifdef CONFIG_HIGHMEM
"HighTotal: %8lu kB\n" "HighTotal: %8lu kB\n"
"HighFree: %8lu kB\n" "HighFree: %8lu kB\n"
Expand Down Expand Up @@ -109,10 +107,8 @@ static int meminfo_proc_show(struct seq_file *m, void *v)
K(pages[LRU_INACTIVE_ANON]), K(pages[LRU_INACTIVE_ANON]),
K(pages[LRU_ACTIVE_FILE]), K(pages[LRU_ACTIVE_FILE]),
K(pages[LRU_INACTIVE_FILE]), K(pages[LRU_INACTIVE_FILE]),
#ifdef CONFIG_UNEVICTABLE_LRU
K(pages[LRU_UNEVICTABLE]), K(pages[LRU_UNEVICTABLE]),
K(global_page_state(NR_MLOCK)), K(global_page_state(NR_MLOCK)),
#endif
#ifdef CONFIG_HIGHMEM #ifdef CONFIG_HIGHMEM
K(i.totalhigh), K(i.totalhigh),
K(i.freehigh), K(i.freehigh),
Expand Down
2 changes: 0 additions & 2 deletions fs/proc/page.c
Expand Up @@ -172,10 +172,8 @@ static u64 get_uflags(struct page *page)
u |= kpf_copy_bit(k, KPF_SWAPCACHE, PG_swapcache); u |= kpf_copy_bit(k, KPF_SWAPCACHE, PG_swapcache);
u |= kpf_copy_bit(k, KPF_SWAPBACKED, PG_swapbacked); u |= kpf_copy_bit(k, KPF_SWAPBACKED, PG_swapbacked);


#ifdef CONFIG_UNEVICTABLE_LRU
u |= kpf_copy_bit(k, KPF_UNEVICTABLE, PG_unevictable); u |= kpf_copy_bit(k, KPF_UNEVICTABLE, PG_unevictable);
u |= kpf_copy_bit(k, KPF_MLOCKED, PG_mlocked); u |= kpf_copy_bit(k, KPF_MLOCKED, PG_mlocked);
#endif


#ifdef CONFIG_IA64_UNCACHED_ALLOCATOR #ifdef CONFIG_IA64_UNCACHED_ALLOCATOR
u |= kpf_copy_bit(k, KPF_UNCACHED, PG_uncached); u |= kpf_copy_bit(k, KPF_UNCACHED, PG_uncached);
Expand Down
13 changes: 0 additions & 13 deletions include/linux/mmzone.h
Expand Up @@ -83,13 +83,8 @@ enum zone_stat_item {
NR_ACTIVE_ANON, /* " " " " " */ NR_ACTIVE_ANON, /* " " " " " */
NR_INACTIVE_FILE, /* " " " " " */ NR_INACTIVE_FILE, /* " " " " " */
NR_ACTIVE_FILE, /* " " " " " */ NR_ACTIVE_FILE, /* " " " " " */
#ifdef CONFIG_UNEVICTABLE_LRU
NR_UNEVICTABLE, /* " " " " " */ NR_UNEVICTABLE, /* " " " " " */
NR_MLOCK, /* mlock()ed pages found and moved off LRU */ NR_MLOCK, /* mlock()ed pages found and moved off LRU */
#else
NR_UNEVICTABLE = NR_ACTIVE_FILE, /* avoid compiler errors in dead code */
NR_MLOCK = NR_ACTIVE_FILE,
#endif
NR_ANON_PAGES, /* Mapped anonymous pages */ NR_ANON_PAGES, /* Mapped anonymous pages */
NR_FILE_MAPPED, /* pagecache pages mapped into pagetables. NR_FILE_MAPPED, /* pagecache pages mapped into pagetables.
only modified from process context */ only modified from process context */
Expand Down Expand Up @@ -132,11 +127,7 @@ enum lru_list {
LRU_ACTIVE_ANON = LRU_BASE + LRU_ACTIVE, LRU_ACTIVE_ANON = LRU_BASE + LRU_ACTIVE,
LRU_INACTIVE_FILE = LRU_BASE + LRU_FILE, LRU_INACTIVE_FILE = LRU_BASE + LRU_FILE,
LRU_ACTIVE_FILE = LRU_BASE + LRU_FILE + LRU_ACTIVE, LRU_ACTIVE_FILE = LRU_BASE + LRU_FILE + LRU_ACTIVE,
#ifdef CONFIG_UNEVICTABLE_LRU
LRU_UNEVICTABLE, LRU_UNEVICTABLE,
#else
LRU_UNEVICTABLE = LRU_ACTIVE_FILE, /* avoid compiler errors in dead code */
#endif
NR_LRU_LISTS NR_LRU_LISTS
}; };


Expand All @@ -156,11 +147,7 @@ static inline int is_active_lru(enum lru_list l)


static inline int is_unevictable_lru(enum lru_list l) static inline int is_unevictable_lru(enum lru_list l)
{ {
#ifdef CONFIG_UNEVICTABLE_LRU
return (l == LRU_UNEVICTABLE); return (l == LRU_UNEVICTABLE);
#else
return 0;
#endif
} }


enum zone_watermarks { enum zone_watermarks {
Expand Down
16 changes: 1 addition & 15 deletions include/linux/page-flags.h
Expand Up @@ -95,9 +95,7 @@ enum pageflags {
PG_reclaim, /* To be reclaimed asap */ PG_reclaim, /* To be reclaimed asap */
PG_buddy, /* Page is free, on buddy lists */ PG_buddy, /* Page is free, on buddy lists */
PG_swapbacked, /* Page is backed by RAM/swap */ PG_swapbacked, /* Page is backed by RAM/swap */
#ifdef CONFIG_UNEVICTABLE_LRU
PG_unevictable, /* Page is "unevictable" */ PG_unevictable, /* Page is "unevictable" */
#endif
#ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT #ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT
PG_mlocked, /* Page is vma mlocked */ PG_mlocked, /* Page is vma mlocked */
#endif #endif
Expand Down Expand Up @@ -248,14 +246,8 @@ PAGEFLAG_FALSE(SwapCache)
SETPAGEFLAG_NOOP(SwapCache) CLEARPAGEFLAG_NOOP(SwapCache) SETPAGEFLAG_NOOP(SwapCache) CLEARPAGEFLAG_NOOP(SwapCache)
#endif #endif


#ifdef CONFIG_UNEVICTABLE_LRU
PAGEFLAG(Unevictable, unevictable) __CLEARPAGEFLAG(Unevictable, unevictable) PAGEFLAG(Unevictable, unevictable) __CLEARPAGEFLAG(Unevictable, unevictable)
TESTCLEARFLAG(Unevictable, unevictable) TESTCLEARFLAG(Unevictable, unevictable)
#else
PAGEFLAG_FALSE(Unevictable) TESTCLEARFLAG_FALSE(Unevictable)
SETPAGEFLAG_NOOP(Unevictable) CLEARPAGEFLAG_NOOP(Unevictable)
__CLEARPAGEFLAG_NOOP(Unevictable)
#endif


#ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT #ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT
#define MLOCK_PAGES 1 #define MLOCK_PAGES 1
Expand Down Expand Up @@ -382,12 +374,6 @@ static inline void __ClearPageTail(struct page *page)


#endif /* !PAGEFLAGS_EXTENDED */ #endif /* !PAGEFLAGS_EXTENDED */


#ifdef CONFIG_UNEVICTABLE_LRU
#define __PG_UNEVICTABLE (1 << PG_unevictable)
#else
#define __PG_UNEVICTABLE 0
#endif

#ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT #ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT
#define __PG_MLOCKED (1 << PG_mlocked) #define __PG_MLOCKED (1 << PG_mlocked)
#else #else
Expand All @@ -403,7 +389,7 @@ static inline void __ClearPageTail(struct page *page)
1 << PG_private | 1 << PG_private_2 | \ 1 << PG_private | 1 << PG_private_2 | \
1 << PG_buddy | 1 << PG_writeback | 1 << PG_reserved | \ 1 << PG_buddy | 1 << PG_writeback | 1 << PG_reserved | \
1 << PG_slab | 1 << PG_swapcache | 1 << PG_active | \ 1 << PG_slab | 1 << PG_swapcache | 1 << PG_active | \
__PG_UNEVICTABLE | __PG_MLOCKED) 1 << PG_unevictable | __PG_MLOCKED)


/* /*
* Flags checked when a page is prepped for return by the page allocator. * Flags checked when a page is prepped for return by the page allocator.
Expand Down
12 changes: 0 additions & 12 deletions include/linux/pagemap.h
Expand Up @@ -22,9 +22,7 @@ enum mapping_flags {
AS_EIO = __GFP_BITS_SHIFT + 0, /* IO error on async write */ AS_EIO = __GFP_BITS_SHIFT + 0, /* IO error on async write */
AS_ENOSPC = __GFP_BITS_SHIFT + 1, /* ENOSPC on async write */ AS_ENOSPC = __GFP_BITS_SHIFT + 1, /* ENOSPC on async write */
AS_MM_ALL_LOCKS = __GFP_BITS_SHIFT + 2, /* under mm_take_all_locks() */ AS_MM_ALL_LOCKS = __GFP_BITS_SHIFT + 2, /* under mm_take_all_locks() */
#ifdef CONFIG_UNEVICTABLE_LRU
AS_UNEVICTABLE = __GFP_BITS_SHIFT + 3, /* e.g., ramdisk, SHM_LOCK */ AS_UNEVICTABLE = __GFP_BITS_SHIFT + 3, /* e.g., ramdisk, SHM_LOCK */
#endif
}; };


static inline void mapping_set_error(struct address_space *mapping, int error) static inline void mapping_set_error(struct address_space *mapping, int error)
Expand All @@ -37,8 +35,6 @@ static inline void mapping_set_error(struct address_space *mapping, int error)
} }
} }


#ifdef CONFIG_UNEVICTABLE_LRU

static inline void mapping_set_unevictable(struct address_space *mapping) static inline void mapping_set_unevictable(struct address_space *mapping)
{ {
set_bit(AS_UNEVICTABLE, &mapping->flags); set_bit(AS_UNEVICTABLE, &mapping->flags);
Expand All @@ -55,14 +51,6 @@ static inline int mapping_unevictable(struct address_space *mapping)
return test_bit(AS_UNEVICTABLE, &mapping->flags); return test_bit(AS_UNEVICTABLE, &mapping->flags);
return !!mapping; return !!mapping;
} }
#else
static inline void mapping_set_unevictable(struct address_space *mapping) { }
static inline void mapping_clear_unevictable(struct address_space *mapping) { }
static inline int mapping_unevictable(struct address_space *mapping)
{
return 0;
}
#endif


static inline gfp_t mapping_gfp_mask(struct address_space * mapping) static inline gfp_t mapping_gfp_mask(struct address_space * mapping)
{ {
Expand Down
7 changes: 0 additions & 7 deletions include/linux/rmap.h
Expand Up @@ -105,18 +105,11 @@ unsigned long page_address_in_vma(struct page *, struct vm_area_struct *);
*/ */
int page_mkclean(struct page *); int page_mkclean(struct page *);


#ifdef CONFIG_UNEVICTABLE_LRU
/* /*
* called in munlock()/munmap() path to check for other vmas holding * called in munlock()/munmap() path to check for other vmas holding
* the page mlocked. * the page mlocked.
*/ */
int try_to_munlock(struct page *); int try_to_munlock(struct page *);
#else
static inline int try_to_munlock(struct page *page)
{
return 0; /* a.k.a. SWAP_SUCCESS */
}
#endif


#else /* !CONFIG_MMU */ #else /* !CONFIG_MMU */


Expand Down
19 changes: 0 additions & 19 deletions include/linux/swap.h
Expand Up @@ -235,7 +235,6 @@ static inline int zone_reclaim(struct zone *z, gfp_t mask, unsigned int order)
} }
#endif #endif


#ifdef CONFIG_UNEVICTABLE_LRU
extern int page_evictable(struct page *page, struct vm_area_struct *vma); extern int page_evictable(struct page *page, struct vm_area_struct *vma);
extern void scan_mapping_unevictable_pages(struct address_space *); extern void scan_mapping_unevictable_pages(struct address_space *);


Expand All @@ -244,24 +243,6 @@ extern int scan_unevictable_handler(struct ctl_table *, int, struct file *,
void __user *, size_t *, loff_t *); void __user *, size_t *, loff_t *);
extern int scan_unevictable_register_node(struct node *node); extern int scan_unevictable_register_node(struct node *node);
extern void scan_unevictable_unregister_node(struct node *node); extern void scan_unevictable_unregister_node(struct node *node);
#else
static inline int page_evictable(struct page *page,
struct vm_area_struct *vma)
{
return 1;
}

static inline void scan_mapping_unevictable_pages(struct address_space *mapping)
{
}

static inline int scan_unevictable_register_node(struct node *node)
{
return 0;
}

static inline void scan_unevictable_unregister_node(struct node *node) { }
#endif


extern int kswapd_run(int nid); extern int kswapd_run(int nid);


Expand Down
2 changes: 0 additions & 2 deletions include/linux/vmstat.h
Expand Up @@ -41,7 +41,6 @@ enum vm_event_item { PGPGIN, PGPGOUT, PSWPIN, PSWPOUT,
#ifdef CONFIG_HUGETLB_PAGE #ifdef CONFIG_HUGETLB_PAGE
HTLB_BUDDY_PGALLOC, HTLB_BUDDY_PGALLOC_FAIL, HTLB_BUDDY_PGALLOC, HTLB_BUDDY_PGALLOC_FAIL,
#endif #endif
#ifdef CONFIG_UNEVICTABLE_LRU
UNEVICTABLE_PGCULLED, /* culled to noreclaim list */ UNEVICTABLE_PGCULLED, /* culled to noreclaim list */
UNEVICTABLE_PGSCANNED, /* scanned for reclaimability */ UNEVICTABLE_PGSCANNED, /* scanned for reclaimability */
UNEVICTABLE_PGRESCUED, /* rescued from noreclaim list */ UNEVICTABLE_PGRESCUED, /* rescued from noreclaim list */
Expand All @@ -50,7 +49,6 @@ enum vm_event_item { PGPGIN, PGPGOUT, PSWPIN, PSWPOUT,
UNEVICTABLE_PGCLEARED, /* on COW, page truncate */ UNEVICTABLE_PGCLEARED, /* on COW, page truncate */
UNEVICTABLE_PGSTRANDED, /* unable to isolate on unlock */ UNEVICTABLE_PGSTRANDED, /* unable to isolate on unlock */
UNEVICTABLE_MLOCKFREED, UNEVICTABLE_MLOCKFREED,
#endif
NR_VM_EVENT_ITEMS NR_VM_EVENT_ITEMS
}; };


Expand Down
2 changes: 0 additions & 2 deletions kernel/sysctl.c
Expand Up @@ -1325,7 +1325,6 @@ static struct ctl_table vm_table[] = {
.extra2 = &one, .extra2 = &one,
}, },
#endif #endif
#ifdef CONFIG_UNEVICTABLE_LRU
{ {
.ctl_name = CTL_UNNUMBERED, .ctl_name = CTL_UNNUMBERED,
.procname = "scan_unevictable_pages", .procname = "scan_unevictable_pages",
Expand All @@ -1334,7 +1333,6 @@ static struct ctl_table vm_table[] = {
.mode = 0644, .mode = 0644,
.proc_handler = &scan_unevictable_handler, .proc_handler = &scan_unevictable_handler,
}, },
#endif
/* /*
* NOTE: do not add new entries to this table unless you have read * NOTE: do not add new entries to this table unless you have read
* Documentation/sysctl/ctl_unnumbered.txt * Documentation/sysctl/ctl_unnumbered.txt
Expand Down
14 changes: 1 addition & 13 deletions mm/Kconfig
Expand Up @@ -203,25 +203,13 @@ config VIRT_TO_BUS
def_bool y def_bool y
depends on !ARCH_NO_VIRT_TO_BUS depends on !ARCH_NO_VIRT_TO_BUS


config UNEVICTABLE_LRU
bool "Add LRU list to track non-evictable pages"
default y
help
Keeps unevictable pages off of the active and inactive pageout
lists, so kswapd will not waste CPU time or have its balancing
algorithms thrown off by scanning these pages. Selecting this
will use one page flag and increase the code size a little,
say Y unless you know what you are doing.

See Documentation/vm/unevictable-lru.txt for more information.

config HAVE_MLOCK config HAVE_MLOCK
bool bool
default y if MMU=y default y if MMU=y


config HAVE_MLOCKED_PAGE_BIT config HAVE_MLOCKED_PAGE_BIT
bool bool
default y if HAVE_MLOCK=y && UNEVICTABLE_LRU=y default y if HAVE_MLOCK=y


config MMU_NOTIFIER config MMU_NOTIFIER
bool bool
Expand Down
6 changes: 0 additions & 6 deletions mm/internal.h
Expand Up @@ -73,7 +73,6 @@ static inline void munlock_vma_pages_all(struct vm_area_struct *vma)
} }
#endif #endif


#ifdef CONFIG_UNEVICTABLE_LRU
/* /*
* unevictable_migrate_page() called only from migrate_page_copy() to * unevictable_migrate_page() called only from migrate_page_copy() to
* migrate unevictable flag to new page. * migrate unevictable flag to new page.
Expand All @@ -85,11 +84,6 @@ static inline void unevictable_migrate_page(struct page *new, struct page *old)
if (TestClearPageUnevictable(old)) if (TestClearPageUnevictable(old))
SetPageUnevictable(new); SetPageUnevictable(new);
} }
#else
static inline void unevictable_migrate_page(struct page *new, struct page *old)
{
}
#endif


#ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT #ifdef CONFIG_HAVE_MLOCKED_PAGE_BIT
/* /*
Expand Down
22 changes: 0 additions & 22 deletions mm/mlock.c
Expand Up @@ -31,7 +31,6 @@ int can_do_mlock(void)
} }
EXPORT_SYMBOL(can_do_mlock); EXPORT_SYMBOL(can_do_mlock);


#ifdef CONFIG_UNEVICTABLE_LRU
/* /*
* Mlocked pages are marked with PageMlocked() flag for efficient testing * Mlocked pages are marked with PageMlocked() flag for efficient testing
* in vmscan and, possibly, the fault path; and to support semi-accurate * in vmscan and, possibly, the fault path; and to support semi-accurate
Expand Down Expand Up @@ -261,27 +260,6 @@ static int __mlock_posix_error_return(long retval)
return retval; return retval;
} }


#else /* CONFIG_UNEVICTABLE_LRU */

/*
* Just make pages present if VM_LOCKED. No-op if unlocking.
*/
static long __mlock_vma_pages_range(struct vm_area_struct *vma,
unsigned long start, unsigned long end,
int mlock)
{
if (mlock && (vma->vm_flags & VM_LOCKED))
return make_pages_present(start, end);
return 0;
}

static inline int __mlock_posix_error_return(long retval)
{
return 0;
}

#endif /* CONFIG_UNEVICTABLE_LRU */

/** /**
* mlock_vma_pages_range() - mlock pages in specified vma range. * mlock_vma_pages_range() - mlock pages in specified vma range.
* @vma - the vma containing the specfied address range * @vma - the vma containing the specfied address range
Expand Down
9 changes: 0 additions & 9 deletions mm/page_alloc.c
Expand Up @@ -2077,19 +2077,14 @@ void show_free_areas(void)


printk("Active_anon:%lu active_file:%lu inactive_anon:%lu\n" printk("Active_anon:%lu active_file:%lu inactive_anon:%lu\n"
" inactive_file:%lu" " inactive_file:%lu"
//TODO: check/adjust line lengths
#ifdef CONFIG_UNEVICTABLE_LRU
" unevictable:%lu" " unevictable:%lu"
#endif
" dirty:%lu writeback:%lu unstable:%lu\n" " dirty:%lu writeback:%lu unstable:%lu\n"
" free:%lu slab:%lu mapped:%lu pagetables:%lu bounce:%lu\n", " free:%lu slab:%lu mapped:%lu pagetables:%lu bounce:%lu\n",
global_page_state(NR_ACTIVE_ANON), global_page_state(NR_ACTIVE_ANON),
global_page_state(NR_ACTIVE_FILE), global_page_state(NR_ACTIVE_FILE),
global_page_state(NR_INACTIVE_ANON), global_page_state(NR_INACTIVE_ANON),
global_page_state(NR_INACTIVE_FILE), global_page_state(NR_INACTIVE_FILE),
#ifdef CONFIG_UNEVICTABLE_LRU
global_page_state(NR_UNEVICTABLE), global_page_state(NR_UNEVICTABLE),
#endif
global_page_state(NR_FILE_DIRTY), global_page_state(NR_FILE_DIRTY),
global_page_state(NR_WRITEBACK), global_page_state(NR_WRITEBACK),
global_page_state(NR_UNSTABLE_NFS), global_page_state(NR_UNSTABLE_NFS),
Expand All @@ -2113,9 +2108,7 @@ void show_free_areas(void)
" inactive_anon:%lukB" " inactive_anon:%lukB"
" active_file:%lukB" " active_file:%lukB"
" inactive_file:%lukB" " inactive_file:%lukB"
#ifdef CONFIG_UNEVICTABLE_LRU
" unevictable:%lukB" " unevictable:%lukB"
#endif
" present:%lukB" " present:%lukB"
" pages_scanned:%lu" " pages_scanned:%lu"
" all_unreclaimable? %s" " all_unreclaimable? %s"
Expand All @@ -2129,9 +2122,7 @@ void show_free_areas(void)
K(zone_page_state(zone, NR_INACTIVE_ANON)), K(zone_page_state(zone, NR_INACTIVE_ANON)),
K(zone_page_state(zone, NR_ACTIVE_FILE)), K(zone_page_state(zone, NR_ACTIVE_FILE)),
K(zone_page_state(zone, NR_INACTIVE_FILE)), K(zone_page_state(zone, NR_INACTIVE_FILE)),
#ifdef CONFIG_UNEVICTABLE_LRU
K(zone_page_state(zone, NR_UNEVICTABLE)), K(zone_page_state(zone, NR_UNEVICTABLE)),
#endif
K(zone->present_pages), K(zone->present_pages),
zone->pages_scanned, zone->pages_scanned,
(zone_is_all_unreclaimable(zone) ? "yes" : "no") (zone_is_all_unreclaimable(zone) ? "yes" : "no")
Expand Down
3 changes: 1 addition & 2 deletions mm/rmap.c
Expand Up @@ -1202,7 +1202,6 @@ int try_to_unmap(struct page *page, int migration)
return ret; return ret;
} }


#ifdef CONFIG_UNEVICTABLE_LRU
/** /**
* try_to_munlock - try to munlock a page * try_to_munlock - try to munlock a page
* @page: the page to be munlocked * @page: the page to be munlocked
Expand All @@ -1226,4 +1225,4 @@ int try_to_munlock(struct page *page)
else else
return try_to_unmap_file(page, 1, 0); return try_to_unmap_file(page, 1, 0);
} }
#endif

0 comments on commit 6837765

Please sign in to comment.