linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [patch] mm, memcg: make mem_cgroup_out_of_memory static
@ 2012-10-11 20:09 David Rientjes
  2012-10-12  6:50 ` Michal Hocko
  2012-10-15  9:02 ` Kamezawa Hiroyuki
  0 siblings, 2 replies; 3+ messages in thread
From: David Rientjes @ 2012-10-11 20:09 UTC (permalink / raw)
  To: Andrew Morton; +Cc: KAMEZAWA Hiroyuki, Johannes Weiner, Michal Hocko, linux-mm

mem_cgroup_out_of_memory() is only referenced from within file scope, so 
it can be marked static.

Signed-off-by: David Rientjes <rientjes@google.com>
---
 include/linux/oom.h |    2 --
 mm/memcontrol.c     |    4 ++--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/include/linux/oom.h b/include/linux/oom.h
--- a/include/linux/oom.h
+++ b/include/linux/oom.h
@@ -56,8 +56,6 @@ extern void check_panic_on_oom(enum oom_constraint constraint, gfp_t gfp_mask,
 extern enum oom_scan_t oom_scan_process_thread(struct task_struct *task,
 		unsigned long totalpages, const nodemask_t *nodemask,
 		bool force_kill);
-extern void mem_cgroup_out_of_memory(struct mem_cgroup *memcg, gfp_t gfp_mask,
-				     int order);
 
 extern void out_of_memory(struct zonelist *zonelist, gfp_t gfp_mask,
 		int order, nodemask_t *mask, bool force_kill);
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 7acf43b..e4e9b18 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -1465,8 +1465,8 @@ static u64 mem_cgroup_get_limit(struct mem_cgroup *memcg)
 	return min(limit, memsw);
 }
 
-void mem_cgroup_out_of_memory(struct mem_cgroup *memcg, gfp_t gfp_mask,
-			      int order)
+static void mem_cgroup_out_of_memory(struct mem_cgroup *memcg, gfp_t gfp_mask,
+				     int order)
 {
 	struct mem_cgroup *iter;
 	unsigned long chosen_points = 0;

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-10-15  9:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-11 20:09 [patch] mm, memcg: make mem_cgroup_out_of_memory static David Rientjes
2012-10-12  6:50 ` Michal Hocko
2012-10-15  9:02 ` Kamezawa Hiroyuki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox