Linux-mm Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/2] Two small patches to clean up mm/mm_slot.h
@ 2026-07-14  1:24 xu.xin16
  2026-07-14  1:26 ` [PATCH v3 1/2] mm/mm_slot.h: add a helper function mm_slot_remove xu.xin16
  2026-07-14  1:28 ` [PATCH v3 2/2] mm/mm_slot.h: add comments for mm_slot_lookup/insert xu.xin16
  0 siblings, 2 replies; 7+ messages in thread
From: xu.xin16 @ 2026-07-14  1:24 UTC (permalink / raw)
  To: akpm, david, ljs, xu.xin16, ziy, baolin.wang, baohua, lance.yang,
	usama.arif, chengming.zhou, qi.zheng, npache, ryan.roberts,
	dev.jain
  Cc: linux-mm, linux-kernel, wang.yaxin

From: xu xin <xu.xin16@zte.com.cn>

mm_slot.h is mainly used by THP and KSM.

Patch 1 introduces mm_slot_remove() to abstract the common
hash_del() + list_del() sequence used in both khugepaged and KSM.

Patch 2 adds a comment explaining why mm_slot_lookup/insert cannot
be converted to static inline functions.

xu xin (2):
  mm/mm_slot.h: add a helper function mm_slot_remove
  mm/mm_slot.h: add comments for mm_slot_lookup/insert

 mm/khugepaged.c |  6 ++----
 mm/ksm.c        |  9 +++------
 mm/mm_slot.h    | 11 +++++++++++
 3 files changed, 16 insertions(+), 10 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-07-14 13:26 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-14  1:24 [PATCH v3 0/2] Two small patches to clean up mm/mm_slot.h xu.xin16
2026-07-14  1:26 ` [PATCH v3 1/2] mm/mm_slot.h: add a helper function mm_slot_remove xu.xin16
2026-07-14  1:28 ` [PATCH v3 2/2] mm/mm_slot.h: add comments for mm_slot_lookup/insert xu.xin16
2026-07-14  1:37   ` Barry Song
2026-07-14  9:35   ` Lorenzo Stoakes (ARM)
2026-07-14  9:44   ` Qi Zheng
2026-07-14 13:26   ` David Hildenbrand (Arm)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox