From: Chengming Zhou <chengming.zhou@linux.dev>
To: hannes@cmpxchg.org, Andrew Morton <akpm@linux-foundation.org>,
Sergey Senozhatsky <senozhatsky@chromium.org>,
nphamcs@gmail.com, yosryahmed@google.com,
Minchan Kim <minchan@kernel.org>
Cc: linux-mm@kvack.org, Chengming Zhou <zhouchengming@bytedance.com>,
linux-kernel@vger.kernel.org
Subject: [PATCH RESEND 0/3] mm/zsmalloc: some cleanup for get/set_zspage_mapping()
Date: Tue, 20 Feb 2024 11:44:28 +0000 [thread overview]
Message-ID: <20240220-b4-zsmalloc-cleanup-v1-0-b7e9cbab9541@linux.dev> (raw)
RESEND:
- The sent patches were put into spam folder because of my mail problem,
so resend after I fixed it, sorry! It should be ok this time.
- Link to v1: https://lore.kernel.org/r/20240220-b4-zsmalloc-cleanup-v1-0-5c5ee4ccdd87@bytedance.com
Hello,
The discussion[1] with Sergey shows there are some cleanup works to do
in get/set_zspage_mapping():
- the fullness returned from get_zspage_mapping() is not stable outside
pool->lock, this usage pattern is confusing, but should be ok in this
free_zspage path.
- we seldom use the class_idx returned from get_zspage_mapping(), only
free_zspage path use to get its class.
- set_zspage_mapping() always set the zspage->class, but it's never
changed after zspage allocated.
Thanks for review and comments!
[1] https://lore.kernel.org/all/a6c22e30-cf10-4122-91bc-ceb9fb57a5d6@bytedance.com/
Signed-off-by: Chengming Zhou <zhouchengming@bytedance.com>
---
Chengming Zhou (3):
mm/zsmalloc: remove set_zspage_mapping()
mm/zsmalloc: remove_zspage() don't need fullness parameter
mm/zsmalloc: remove get_zspage_mapping()
mm/zsmalloc.c | 55 +++++++++++++------------------------------------------
1 file changed, 13 insertions(+), 42 deletions(-)
---
base-commit: 207636f0f52428f3b46540b212d6f93c6ac484cf
change-id: 20240220-b4-zsmalloc-cleanup-560a4159bb6b
Best regards,
--
Chengming Zhou <chengming.zhou@linux.dev>
next reply other threads:[~2024-02-20 11:44 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-20 11:44 Chengming Zhou [this message]
2024-02-20 11:44 ` [PATCH RESEND 1/3] mm/zsmalloc: remove set_zspage_mapping() Chengming Zhou
2024-02-23 5:46 ` Sergey Senozhatsky
2024-02-20 11:44 ` [PATCH RESEND 2/3] mm/zsmalloc: remove_zspage() don't need fullness parameter Chengming Zhou
2024-02-23 5:47 ` Sergey Senozhatsky
2024-02-20 11:44 ` [PATCH RESEND 3/3] mm/zsmalloc: remove get_zspage_mapping() Chengming Zhou
2024-02-23 5:48 ` Sergey Senozhatsky
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=20240220-b4-zsmalloc-cleanup-v1-0-b7e9cbab9541@linux.dev \
--to=chengming.zhou@linux.dev \
--cc=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=minchan@kernel.org \
--cc=nphamcs@gmail.com \
--cc=senozhatsky@chromium.org \
--cc=yosryahmed@google.com \
--cc=zhouchengming@bytedance.com \
/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