linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] mm/ksm: fix some accounting problems
@ 2024-05-08  9:55 Chengming Zhou
  2024-05-08  9:55 ` [PATCH 1/4] mm/ksm: fix ksm_pages_scanned accounting Chengming Zhou
                   ` (4 more replies)
  0 siblings, 5 replies; 12+ messages in thread
From: Chengming Zhou @ 2024-05-08  9:55 UTC (permalink / raw)
  To: Andrew Morton, David Hildenbrand, Stefan Roesch, xu xin
  Cc: linux-mm, linux-kernel, zhouchengming, Chengming Zhou

We encounter some abnormal ksm_pages_scanned and ksm_zero_pages during
some random tests.

1. ksm_pages_scanned unchanged even ksmd scanning has progress.
2. ksm_zero_pages maybe -1 in some rare cases.

The first two patches fix these problems and the last two patches are
minor optimizations about ksm_stable_node and general_profit calculation.

Thanks for review and comments!

Signed-off-by: Chengming Zhou <chengming.zhou@linux.dev>
---
Chengming Zhou (4):
      mm/ksm: fix ksm_pages_scanned accounting
      mm/ksm: fix ksm_zero_pages accounting
      mm/ksm: union hlist_node with list_head in struct ksm_stable_node
      mm/ksm: calculate general_profit more accurately

 fs/proc/base.c           |  2 +-
 include/linux/ksm.h      | 22 +++++++++++++++++++---
 include/linux/mm_types.h |  2 +-
 mm/ksm.c                 | 33 ++++++++++++++++++++-------------
 4 files changed, 41 insertions(+), 18 deletions(-)
---
base-commit: fb0f40125feec3de7ef4524600ac83946207117e
change-id: 20240508-b4-ksm-counters-04817b40d3ee

Best regards,
-- 
Chengming Zhou <chengming.zhou@linux.dev>



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

end of thread, other threads:[~2024-05-08 13:52 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-08  9:55 [PATCH 0/4] mm/ksm: fix some accounting problems Chengming Zhou
2024-05-08  9:55 ` [PATCH 1/4] mm/ksm: fix ksm_pages_scanned accounting Chengming Zhou
2024-05-08 10:35   ` Chengming Zhou
2024-05-08 12:32     ` David Hildenbrand
2024-05-08  9:55 ` [PATCH 2/4] mm/ksm: fix ksm_zero_pages accounting Chengming Zhou
2024-05-08 10:37   ` Chengming Zhou
2024-05-08 12:36   ` David Hildenbrand
2024-05-08 13:52     ` Chengming Zhou
2024-05-08  9:55 ` [PATCH 3/4] mm/ksm: union hlist_node with list_head in struct ksm_stable_node Chengming Zhou
2024-05-08  9:55 ` [PATCH 4/4] mm/ksm: calculate general_profit more accurately Chengming Zhou
2024-05-08 10:24 ` [PATCH 0/4] mm/ksm: fix some accounting problems David Hildenbrand
2024-05-08 10:28   ` Chengming Zhou

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