[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5d051998-015c-4da4-83f0-1b4fb9009c68@linux.dev>
Date: Tue, 11 Jun 2024 17:53:06 +0800
From: Chengming Zhou <chengming.zhou@...ux.dev>
To: Usama Arif <usamaarif642@...il.com>, akpm@...ux-foundation.org
Cc: willy@...radead.org, hannes@...xchg.org, yosryahmed@...gle.com,
nphamcs@...il.com, linux-mm@...ck.org, linux-kernel@...r.kernel.org,
kernel-team@...a.com
Subject: Re: [PATCH] mm: Do not start/end writeback for pages stored in zswap
On 2024/6/10 22:30, Usama Arif wrote:
> start/end writeback combination incorrectly increments NR_WRITTEN
> counter, eventhough the pages aren't written to disk. Pages successfully
> stored in zswap should just unlock folio and return from writepage.
>
> Signed-off-by: Usama Arif <usamaarif642@...il.com>
Looks good to me, thanks.
Reviewed-by: Chengming Zhou <chengming.zhou@...ux.dev>
> ---
> mm/page_io.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/mm/page_io.c b/mm/page_io.c
> index a360857cf75d..501784d79977 100644
> --- a/mm/page_io.c
> +++ b/mm/page_io.c
> @@ -196,9 +196,7 @@ int swap_writepage(struct page *page, struct writeback_control *wbc)
> return ret;
> }
> if (zswap_store(folio)) {
> - folio_start_writeback(folio);
> folio_unlock(folio);
> - folio_end_writeback(folio);
> return 0;
> }
> if (!mem_cgroup_zswap_writeback_enabled(folio_memcg(folio))) {
Powered by blists - more mailing lists