From: Andrew Morton Date: Fri, 30 Aug 2019 23:04:35 +0000 (-0700) Subject: mm/zsmalloc.c: fix build when CONFIG_COMPACTION=n X-Git-Tag: v4.9.191~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9ae4611431af5efa334e1256de88f32b5dff6538;p=platform%2Fkernel%2Flinux-amlogic.git mm/zsmalloc.c: fix build when CONFIG_COMPACTION=n [ Upstream commit 441e254cd40dc03beec3c650ce6ce6074bc6517f ] Fixes: 701d678599d0c1 ("mm/zsmalloc.c: fix race condition in zs_destroy_pool") Link: http://lkml.kernel.org/r/201908251039.5oSbEEUT%25lkp@intel.com Reported-by: kbuild test robot Cc: Sergey Senozhatsky Cc: Henry Burns Cc: Minchan Kim Cc: Shakeel Butt Cc: Jonathan Adams Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Sasha Levin --- diff --git a/mm/zsmalloc.c b/mm/zsmalloc.c index ad8a34b..5a50ad5 100644 --- a/mm/zsmalloc.c +++ b/mm/zsmalloc.c @@ -2488,7 +2488,9 @@ struct zs_pool *zs_create_pool(const char *name) if (!pool->name) goto err; +#ifdef CONFIG_COMPACTION init_waitqueue_head(&pool->migration_wait); +#endif if (create_cache(pool)) goto err;