Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1396817
| From | Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 4.5 38/88] mm: memcontrol: let v2 cgroups follow changes in system swappiness |
| Date | 2016-05-09 10:00 +0200 |
| Message-ID | <rwOgH-II-47@gated-at.bofh.it> (permalink) |
| References | <rwNNE-7J-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
4.5-stable review patch. If anyone has any objections, please let me know.
------------------
From: Johannes Weiner <hannes@cmpxchg.org>
commit 4550c4e157ca3da929593bb6c64080a59141af35 upstream.
Cgroup2 currently doesn't have a per-cgroup swappiness setting. We
might want to add one later - that's a different discussion - but until
we do, the cgroups should always follow the system setting. Otherwise
it will be unchangeably set to whatever the ancestor inherited from the
system setting at the time of cgroup creation.
Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Acked-by: Michal Hocko <mhocko@suse.com>
Acked-by: Vladimir Davydov <vdavydov@virtuozzo.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
diff --git a/include/linux/swap.h b/include/linux/swap.h
index 2b83359c19ca..0a4cd4703f40 100644
--- a/include/linux/swap.h
+++ b/include/linux/swap.h
@@ -533,6 +533,10 @@ static inline swp_entry_t get_swap_page(void)
#ifdef CONFIG_MEMCG
static inline int mem_cgroup_swappiness(struct mem_cgroup *memcg)
{
+ /* Cgroup2 doesn't have per-cgroup swappiness */
+ if (cgroup_subsys_on_dfl(memory_cgrp_subsys))
+ return vm_swappiness;
+
/* root ? */
if (mem_cgroup_disabled() || !memcg->css.parent)
return vm_swappiness;
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 4.5 00/88] 4.5.4-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 26/88] clk: xgene: Add missing parenthesis when clearing divider value Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 41/88] propogate_mnt: Handle the first propogated copy being a slave Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 39/88] mm, cma: prevent nr_isolated_* counters from going negative Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 35/88] tracing: Dont display trigger file for events that cant be enabled Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 44/88] ARM: SoCFPGA: Fix secondary CPU startup in thumb2 kernel Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 23/88] clk: versatile: sp810: support reentrance Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 36/88] MD: make bio mergeable Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
[PATCH 4.5 38/88] mm: memcontrol: let v2 cgroups follow changes in system swappiness Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:00 +0200
Re: [PATCH 4.5 00/88] 4.5.4-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-09 10:10 +0200
Re: [PATCH 4.5 00/88] 4.5.4-stable review Kevin Hilman <khilman@baylibre.com> - 2016-05-11 11:50 +0200
Re: [PATCH 4.5 00/88] 4.5.4-stable review Guenter Roeck <linux@roeck-us.net> - 2016-05-09 15:10 +0200
Re: [PATCH 4.5 00/88] 4.5.4-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-10 09:10 +0200
Re: [PATCH 4.5 00/88] 4.5.4-stable review Shuah Khan <shuahkh@osg.samsung.com> - 2016-05-09 21:50 +0200
Re: [PATCH 4.5 00/88] 4.5.4-stable review Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2016-05-10 09:10 +0200
csiph-web