From: Andrew Morton <akpm@linux-foundation.org>
To: mm-commits@vger.kernel.org,zhengqi.arch@bytedance.com,roman.gushchin@linux.dev,muchun.song@linux.dev,david@fromorbit.com,liuye@kylinos.cn,akpm@linux-foundation.org
Subject: [merged mm-stable] mm-shrinker-fix-name-consistency-issue-in-shrinker_debugfs_rename.patch removed from -mm tree
Date: Sun, 16 Mar 2025 22:15:47 -0700 [thread overview]
Message-ID: <20250317051547.B0B39C4CEEC@smtp.kernel.org> (raw)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2043 bytes --]
The quilt patch titled
Subject: mm/shrinker: fix name consistency issue in shrinker_debugfs_rename()
has been removed from the -mm tree. Its filename was
mm-shrinker-fix-name-consistency-issue-in-shrinker_debugfs_rename.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: Liu Ye <liuye@kylinos.cn>
Subject: mm/shrinker: fix name consistency issue in shrinker_debugfs_rename()
Date: Wed, 5 Mar 2025 15:17:59 +0800
After calling debugfs_change_name function, the return value should be
checked and the old name restored. If debugfs_change_name fails, the new
name memory should be freed. The effect is that the shrinker->name is not
consistent with the name displayed in debugfs.
Link: https://lkml.kernel.org/r/20250305071759.661055-1-liuye@kylinos.cn
Signed-off-by: Liu Ye <liuye@kylinos.cn>
Reviewed-by: Muchun Song <muchun.song@linux.dev>
Reviewed-by:Qi Zheng <zhengqi.arch@bytedance.co
Reviewed-by: Roman Gushchin <roman.gushchin@linux.dev>
Cc: Dave Chinner <david@fromorbit.com>
Cc: Muchun Song <muchun.song@linux.dev>
Cc: Qi Zheng <zhengqi.arch@bytedance.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
mm/shrinker_debug.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
--- a/mm/shrinker_debug.c~mm-shrinker-fix-name-consistency-issue-in-shrinker_debugfs_rename
+++ a/mm/shrinker_debug.c
@@ -214,10 +214,14 @@ int shrinker_debugfs_rename(struct shrin
ret = debugfs_change_name(shrinker->debugfs_entry, "%s-%d",
shrinker->name, shrinker->debugfs_id);
+ if (ret) {
+ shrinker->name = old;
+ kfree_const(new);
+ } else {
+ kfree_const(old);
+ }
mutex_unlock(&shrinker_mutex);
- kfree_const(old);
-
return ret;
}
EXPORT_SYMBOL(shrinker_debugfs_rename);
_
Patches currently in -mm which might be from liuye@kylinos.cn are
mm-vmalloc-refactoring-function-__vmalloc_node_range_noprof.patch
mm-debug-add-line-breaks.patch
reply other threads:[~2025-03-17 5:15 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=20250317051547.B0B39C4CEEC@smtp.kernel.org \
--to=akpm@linux-foundation.org \
--cc=david@fromorbit.com \
--cc=liuye@kylinos.cn \
--cc=mm-commits@vger.kernel.org \
--cc=muchun.song@linux.dev \
--cc=roman.gushchin@linux.dev \
--cc=zhengqi.arch@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.