memcontrol-implement-mem_cgroup_tryget_online.patch removed from -mm tree
The quilt patch titled
Subject: memcontrol: implement mem_cgroup_tryget_online()
has been removed from the -mm tree. Its filename was
memcontrol-implement-mem_cgroup_tryget_online.patch
This patch was dropped because it was merged into the mm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
------------------------------------------------------
From: Nhat Pham <[email protected]>
Subject: memcontrol: implement mem_cgroup_tryget_online()
Date: Thu, 30 Nov 2023 11:40:19 -0800
This patch implements a helper function that try to get a reference to an memcg's css, as well as checking if it is online. This new function is almost exactly the same as the existing mem_cgroup_tryget(), except for the onlineness check. In the !CONFIG_MEMCG case, it always returns true, analogous to mem_cgroup_tryget(). This is useful for e.g to the new zswap writeback scheme, where we need to select the next online memcg as a candidate for the global limit reclaim.
---
include/linux/memcontrol.h | 10 ++++++++++ 1 file changed, 10 insertions(+)
include/linux/memcontrol.h renamed from include/linux/memcontrol.h~memcontrol-implement-mem_cgroup_tryget_online +10 -0
@@ -821,6 +821,11 @@ static inline bool mem_cgroup_tryget(strreturn !memcg ||css_tryget (&memcg->css); } +static inline bool mem_cgroup_tryget_online (struct mem_cgroup *memcg) +{ +return !memcg ||css_tryget_online (&memcg->css); +} +static inline void mem_cgroup_put (struct mem_cgroup *memcg) {if (memcg)
@@ -1348,6 +1353,11 @@ static inline bool mem_cgroup_tryget(str {return true; } + +static inline bool mem_cgroup_tryget_online (struct mem_cgroup *memcg) +{ +return true; +}static inline void mem_cgroup_put (struct mem_cgroup *memcg) {
_
Patches currently in -mm which might be from [email protected] are
zswap-memcontrol-implement-zswap-writeback-disabling.patch