From: Zhongkun He <hezhongkun.hzk@bytedance.com>
To: minchan@kernel.org, senozhatsky@chromium.org, mhocko@suse.com
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Zhongkun He <hezhongkun.hzk@bytedance.com>
Subject: [RFC PATCH 2/3] memcg: export obj_cgroup* symbol to charge compressed RAM
Date: Thu, 15 Jun 2023 11:48:49 +0800 [thread overview]
Message-ID: <20230615034849.1361940-1-hezhongkun.hzk@bytedance.com> (raw)
Export obj_cgroup* symbol to charge compressed memory in
zsmalloc module.
Signed-off-by: Zhongkun He <hezhongkun.hzk@bytedance.com>
---
mm/memcontrol.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 4b27e245a055..8ba93afacf31 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -3064,6 +3064,7 @@ __always_inline struct obj_cgroup *get_obj_cgroup_from_current(void)
rcu_read_unlock();
return objcg;
}
+EXPORT_SYMBOL(get_obj_cgroup_from_current);
struct obj_cgroup *get_obj_cgroup_from_page(struct page *page)
{
@@ -3431,11 +3432,13 @@ int obj_cgroup_charge(struct obj_cgroup *objcg, gfp_t gfp, size_t size)
return ret;
}
+EXPORT_SYMBOL(obj_cgroup_charge);
void obj_cgroup_uncharge(struct obj_cgroup *objcg, size_t size)
{
refill_obj_stock(objcg, size, true);
}
+EXPORT_SYMBOL(obj_cgroup_uncharge);
#endif /* CONFIG_MEMCG_KMEM */
--
2.25.1
reply other threads:[~2023-06-15 3:49 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20230615034849.1361940-1-hezhongkun.hzk@bytedance.com \
--to=hezhongkun.hzk@bytedance.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mhocko@suse.com \
--cc=minchan@kernel.org \
--cc=senozhatsky@chromium.org \
/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