* [to-be-updated] mm-zswap-fix-the-lack-of-page-lru-flag-in-zswap_writeback_entry.patch removed from -mm tree
@ 2024-01-03 20:10 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2024-01-03 20:10 UTC (permalink / raw)
To: mm-commits, yosryahmed, vitaly.wool, sjenning, nphamcs, hannes,
ddstreet, hezhongkun.hzk, akpm
The quilt patch titled
Subject: mm: zswap: fix the lack of page lru flag in zswap_writeback_entry
has been removed from the -mm tree. Its filename was
mm-zswap-fix-the-lack-of-page-lru-flag-in-zswap_writeback_entry.patch
This patch was dropped because an updated version will be merged
------------------------------------------------------
From: Zhongkun He <hezhongkun.hzk@bytedance.com>
Subject: mm: zswap: fix the lack of page lru flag in zswap_writeback_entry
Date: Tue, 24 Oct 2023 22:27:06 +0800
The zswap_writeback_entry() will add a page to the swap cache, decompress
the entry data into the page, and issue a bio write to write the page back
to the swap device. Move the page to the tail of lru list through
SetPageReclaim(page) and folio_rotate_reclaimable().
Currently, about half of the pages will fail to move to the tail of lru
list because there is no LRU flag in page which is not in the LRU list but
the cpu_fbatches. So fix it.
Link: https://lkml.kernel.org/r/20231024142706.195517-1-hezhongkun.hzk@bytedance.com
Signed-off-by: Zhongkun He <hezhongkun.hzk@bytedance.com>
Cc: Dan Streetman <ddstreet@ieee.org>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Nhat Pham <nphamcs@gmail.com>
Cc: Seth Jennings <sjenning@redhat.com>
Cc: Vitaly Wool <vitaly.wool@konsulko.com>
Cc: Yosry Ahmed <yosryahmed@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
mm/zswap.c | 5 +++++
1 file changed, 5 insertions(+)
--- a/mm/zswap.c~mm-zswap-fix-the-lack-of-page-lru-flag-in-zswap_writeback_entry
+++ a/mm/zswap.c
@@ -1454,6 +1454,11 @@ static int zswap_writeback_entry(struct
/* move it to the tail of the inactive list after end_writeback */
folio_set_reclaim(folio);
+ if (!folio_test_lru(folio)) {
+ /* drain lru cache to help folio_rotate_reclaimable() */
+ lru_add_drain();
+ }
+
/* start writeback */
__swap_writepage(folio, &wbc);
folio_put(folio);
_
Patches currently in -mm which might be from hezhongkun.hzk@bytedance.com are
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-01-03 20:10 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-03 20:10 [to-be-updated] mm-zswap-fix-the-lack-of-page-lru-flag-in-zswap_writeback_entry.patch removed from -mm tree Andrew Morton
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.