memcg: trivial cleanups

Clean up some mess made by the "Soft limit rework" series, and a few other
things.

Cc: Michal Hocko <mhocko@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Andrew Morton
2013-09-12 15:13:35 -07:00
committed by Linus Torvalds
parent e975de998b
commit f894ffa865
2 changed files with 21 additions and 21 deletions

View File

@@ -835,12 +835,12 @@ static bool mem_cgroup_event_ratelimit(struct mem_cgroup *memcg,
} }
/* /*
* Called from rate-limitted memcg_check_events when enough * Called from rate-limited memcg_check_events when enough
* MEM_CGROUP_TARGET_SOFTLIMIT events are accumulated and it makes sure * MEM_CGROUP_TARGET_SOFTLIMIT events are accumulated and it makes sure
* that all the parents up the hierarchy will be noticed that this group * that all the parents up the hierarchy will be notified that this group
* is in excess or that it is not in excess anymore. mmecg->soft_contributed * is in excess or that it is not in excess anymore. mmecg->soft_contributed
* makes the transition a single action whenever the state flips from one to * makes the transition a single action whenever the state flips from one to
* other. * the other.
*/ */
static void mem_cgroup_update_soft_limit(struct mem_cgroup *memcg) static void mem_cgroup_update_soft_limit(struct mem_cgroup *memcg)
{ {
@@ -1904,7 +1904,7 @@ mem_cgroup_soft_reclaim_eligible(struct mem_cgroup *memcg,
* If any parent up to the root in the hierarchy is over its soft limit * If any parent up to the root in the hierarchy is over its soft limit
* then we have to obey and reclaim from this group as well. * then we have to obey and reclaim from this group as well.
*/ */
while((parent = parent_mem_cgroup(parent))) { while ((parent = parent_mem_cgroup(parent))) {
if (res_counter_soft_limit_excess(&parent->res)) if (res_counter_soft_limit_excess(&parent->res))
return VISIT; return VISIT;
if (parent == root) if (parent == root)