aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorJohannes Weiner <hannes@cmpxchg.org>2014-12-10 18:44:55 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2014-12-10 20:41:09 -0500
commit5d1ea48bdde67898e87d6d8f511fd097fa64c749 (patch)
tree2936b8ed4b948ffdf655fd7b8fa71d68069f8bc4 /include/linux
parent1306a85aed3ec3db98945aafb7dfbe5648a1203c (diff)
mm: page_cgroup: rename file to mm/swap_cgroup.c
Now that the external page_cgroup data structure and its lookup is gone, the only code remaining in there is swap slot accounting. Rename it and move the conditional compilation into mm/Makefile. Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Acked-by: Michal Hocko <mhocko@suse.cz> Acked-by: Vladimir Davydov <vdavydov@parallels.com> Acked-by: David S. Miller <davem@davemloft.net> Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Cc: "Kirill A. Shutemov" <kirill@shutemov.name> Cc: Tejun Heo <tj@kernel.org> Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/swap_cgroup.h (renamed from include/linux/page_cgroup.h)8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/linux/page_cgroup.h b/include/linux/swap_cgroup.h
index 65be35785c86..145306bdc92f 100644
--- a/include/linux/page_cgroup.h
+++ b/include/linux/swap_cgroup.h
@@ -1,15 +1,17 @@
1#ifndef __LINUX_PAGE_CGROUP_H 1#ifndef __LINUX_SWAP_CGROUP_H
2#define __LINUX_PAGE_CGROUP_H 2#define __LINUX_SWAP_CGROUP_H
3 3
4#include <linux/swap.h> 4#include <linux/swap.h>
5 5
6#ifdef CONFIG_MEMCG_SWAP 6#ifdef CONFIG_MEMCG_SWAP
7
7extern unsigned short swap_cgroup_cmpxchg(swp_entry_t ent, 8extern unsigned short swap_cgroup_cmpxchg(swp_entry_t ent,
8 unsigned short old, unsigned short new); 9 unsigned short old, unsigned short new);
9extern unsigned short swap_cgroup_record(swp_entry_t ent, unsigned short id); 10extern unsigned short swap_cgroup_record(swp_entry_t ent, unsigned short id);
10extern unsigned short lookup_swap_cgroup_id(swp_entry_t ent); 11extern unsigned short lookup_swap_cgroup_id(swp_entry_t ent);
11extern int swap_cgroup_swapon(int type, unsigned long max_pages); 12extern int swap_cgroup_swapon(int type, unsigned long max_pages);
12extern void swap_cgroup_swapoff(int type); 13extern void swap_cgroup_swapoff(int type);
14
13#else 15#else
14 16
15static inline 17static inline
@@ -37,4 +39,4 @@ static inline void swap_cgroup_swapoff(int type)
37 39
38#endif /* CONFIG_MEMCG_SWAP */ 40#endif /* CONFIG_MEMCG_SWAP */
39 41
40#endif /* __LINUX_PAGE_CGROUP_H */ 42#endif /* __LINUX_SWAP_CGROUP_H */