Drop the pool's reference at the end of the writeback step. Apply on top of the first fixlet:
https://lore.kernel.org/linux-mm/20231130203522.GC543908@cmpxchg.org/T/#m6ba...
Signed-off-by: Nhat Pham nphamcs@gmail.com --- mm/zswap.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/mm/zswap.c b/mm/zswap.c index 7a84c1454988..56d4a8cc461d 100644 --- a/mm/zswap.c +++ b/mm/zswap.c @@ -859,6 +859,7 @@ static void shrink_worker(struct work_struct *w) resched: cond_resched(); } while (!zswap_can_accept()); + zswap_pool_put(pool); }
static struct zswap_pool *zswap_pool_create(char *type, char *compressor)