All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next v7 0/4] Delay the initialization of zswap
@ 2023-03-25  7:14 Liu Shixin
  2023-03-25  7:14 ` [PATCH -next v7 1/4] mm/zswap: remove zswap_entry_cache_{create,destroy} helper function Liu Shixin
                   ` (3 more replies)
  0 siblings, 4 replies; 13+ messages in thread
From: Liu Shixin @ 2023-03-25  7:14 UTC (permalink / raw)
  To: Seth Jennings, Dan Streetman, Vitaly Wool, Andrew Morton,
	Nathan Chancellor, Christoph Hellwig
  Cc: linux-kernel, linux-mm, Liu Shixin

In the initialization of zswap, about 18MB memory will be allocated for
zswap_pool. Since some users may not use zswap, the zswap_pool is wasted.
Save memory by delaying the initialization of zswap until enabled.

v6->v7: Add two new patch[1,3] to cleanup the code. And cover zswap_init_*
	parameter by zswap_init_lock to protect against conflicts.
v5->v6: Simplify the code and delete the patches about frontswap suggested
	by Christoph.

Liu Shixin (4):
  mm/zswap: remove zswap_entry_cache_{create,destroy} helper function
  mm/zswap: skip invalid or unchanged parameter
  mm/zswap: replace zswap_init_{started/failed} with zswap_init_state
  mm/zswap: delay the initializaton of zswap

 mm/zswap.c | 94 +++++++++++++++++++++++++++++++++++-------------------
 1 file changed, 61 insertions(+), 33 deletions(-)

-- 
2.25.1


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

end of thread, other threads:[~2023-03-27  1:22 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-25  7:14 [PATCH -next v7 0/4] Delay the initialization of zswap Liu Shixin
2023-03-25  7:14 ` [PATCH -next v7 1/4] mm/zswap: remove zswap_entry_cache_{create,destroy} helper function Liu Shixin
2023-03-26 23:19   ` Christoph Hellwig
2023-03-25  7:14 ` [PATCH -next v7 2/4] mm/zswap: skip invalid or unchanged parameter Liu Shixin
2023-03-26  3:08   ` Sergey Senozhatsky
2023-03-26  3:17   ` Sergey Senozhatsky
2023-03-26  4:53     ` Sergey Senozhatsky
2023-03-26 23:25       ` Christoph Hellwig
2023-03-27  1:22         ` Liu Shixin
2023-03-25  7:14 ` [PATCH -next v7 3/4] mm/zswap: replace zswap_init_{started/failed} with zswap_init_state Liu Shixin
2023-03-26 23:26   ` Christoph Hellwig
2023-03-25  7:14 ` [PATCH -next v7 4/4] mm/zswap: delay the initializaton of zswap Liu Shixin
2023-03-26 23:29   ` Christoph Hellwig

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.