Thread (31 messages) 31 messages, 4 authors, 2012-03-14

Re: [PATCH -V3 2/8] memcg: Add HugeTLB extension

From: Glauber Costa <hidden>
Date: 2012-03-13 13:30:11
Also in: linux-mm

On 03/13/2012 11:07 AM, Aneesh Kumar K.V wrote:
quoted hunk ↗ jump to hunk
@@ -4951,6 +5083,12 @@ static int mem_cgroup_pre_destroy(struct cgroup_subsys *ss,
  					struct cgroup *cont)
  {
  	struct mem_cgroup *memcg = mem_cgroup_from_cont(cont);
+	/*
+	 * Don't allow memcg removal if we have HugeTLB resource
+	 * usage.
+	 */
+	if (mem_cgroup_hugetlb_usage(memcg)>  0)
+		return -EBUSY;

  	return mem_cgroup_force_empty(memcg, false);
Why can't you move the charges like everyone else?

--
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/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help