aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mm_inline.h
diff options
context:
space:
mode:
authorKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>2009-01-07 21:08:14 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-01-08 11:31:07 -0500
commitf89eb90e33fd4e4e0cc1a6d20afd63c5a561885a (patch)
tree2e39e02196dda539c900383ab03f08a311124cd9 /include/linux/mm_inline.h
parent670ec2f170301425fc4fdfa63d40652071fe85f6 (diff)
inactive_anon_is_low: move to vmscan
The inactive_anon_is_low() is called only vmscan. Then it can move to vmscan.c This patch doesn't have any functional change. Reviewd-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Acked-by: Rik van Riel <riel@redhat.com> Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Cc: Balbir Singh <balbir@in.ibm.com> Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp> Cc: Hugh Dickins <hugh@veritas.com> Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/mm_inline.h')
-rw-r--r--include/linux/mm_inline.h19
1 files changed, 0 insertions, 19 deletions
diff --git a/include/linux/mm_inline.h b/include/linux/mm_inline.h
index 37ef13d0f01e..7fbb97267556 100644
--- a/include/linux/mm_inline.h
+++ b/include/linux/mm_inline.h
@@ -81,23 +81,4 @@ static inline enum lru_list page_lru(struct page *page)
81 return lru; 81 return lru;
82} 82}
83 83
84/**
85 * inactive_anon_is_low - check if anonymous pages need to be deactivated
86 * @zone: zone to check
87 *
88 * Returns true if the zone does not have enough inactive anon pages,
89 * meaning some active anon pages need to be deactivated.
90 */
91static inline int inactive_anon_is_low(struct zone *zone)
92{
93 unsigned long active, inactive;
94
95 active = zone_page_state(zone, NR_ACTIVE_ANON);
96 inactive = zone_page_state(zone, NR_INACTIVE_ANON);
97
98 if (inactive * zone->inactive_ratio < active)
99 return 1;
100
101 return 0;
102}
103#endif 84#endif