From: Vladimir Davydov <vdavydov@parallels.com>
To: akpm@linux-foundation.org
Cc: hannes@cmpxchg.org, mhocko@suse.cz, glommer@gmail.com,
david@fromorbit.com, viro@zeniv.linux.org.uk, gthelen@google.com,
mgorman@suse.de, linux-mm@kvack.org,
linux-kernel@vger.kernel.org
Subject: [PATCH -mm 6/6] memcg: iterator: do not skip offline css
Date: Mon, 28 Jul 2014 13:31:28 +0400 [thread overview]
Message-ID: <8406fefb5d1d05c775ff27613c49e104ecd7f409.1406536261.git.vdavydov@parallels.com> (raw)
In-Reply-To: <cover.1406536261.git.vdavydov@parallels.com>
After offline, memcg may still host kmem objects, which must be shrinked
on memory pressure.
Signed-off-by: Vladimir Davydov <vdavydov@parallels.com>
---
mm/memcontrol.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 1030bba4b94f..bf55088f0152 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -1100,8 +1100,7 @@ skip_node:
*/
if (next_css) {
if ((next_css == &root->css) ||
- ((next_css->flags & CSS_ONLINE) &&
- css_tryget_online(next_css)))
+ css_tryget(next_css))
return mem_cgroup_from_css(next_css);
prev_css = next_css;
@@ -1147,7 +1146,7 @@ mem_cgroup_iter_load(struct mem_cgroup_reclaim_iter *iter,
* would be returned all the time.
*/
if (position && position != root &&
- !css_tryget_online(&position->css))
+ !css_tryget(&position->css))
position = NULL;
}
return position;
--
1.7.10.4
--
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>
prev parent reply other threads:[~2014-07-28 9:32 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-28 9:31 [PATCH -mm 0/6] Per-memcg slab shrinkers Vladimir Davydov
2014-07-28 9:31 ` [PATCH -mm 1/6] list_lru, shrinkers: introduce list_lru_shrink_{count,walk} Vladimir Davydov
2014-07-28 9:31 ` [PATCH -mm 2/6] fs: consolidate {nr,free}_cached_objects args in shrink_control Vladimir Davydov
2014-07-28 9:31 ` [PATCH -mm 3/6] vmscan: shrink slab on memcg pressure Vladimir Davydov
2014-07-28 9:31 ` [PATCH -mm 4/6] list_lru: add per-memcg lists Vladimir Davydov
2014-07-28 9:31 ` [PATCH -mm 5/6] fs: make shrinker memcg aware Vladimir Davydov
2014-07-28 9:31 ` Vladimir Davydov [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8406fefb5d1d05c775ff27613c49e104ecd7f409.1406536261.git.vdavydov@parallels.com \
--to=vdavydov@parallels.com \
--cc=akpm@linux-foundation.org \
--cc=david@fromorbit.com \
--cc=glommer@gmail.com \
--cc=gthelen@google.com \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mgorman@suse.de \
--cc=mhocko@suse.cz \
--cc=viro@zeniv.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox