All of lore.kernel.org
 help / color / mirror / Atom feed
* [folded-merged] mm-zswap-interact-directly-with-zsmalloc-fix.patch removed from -mm tree
@ 2025-09-21 19:50 Andrew Morton
  0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2025-09-21 19:50 UTC (permalink / raw)
  To: mm-commits, zhouchengming, yosry.ahmed, vitaly.wool, sj, nphamcs,
	hannes, akpm


The quilt patch titled
     Subject: mm: zswap: interact directly with zsmalloc fix
has been removed from the -mm tree.  Its filename was
     mm-zswap-interact-directly-with-zsmalloc-fix.patch

This patch was dropped because it was folded into mm-zswap-interact-directly-with-zsmalloc.patch

------------------------------------------------------
From: Johannes Weiner <hannes@cmpxchg.org>
Subject: mm: zswap: interact directly with zsmalloc fix
Date: Mon, 15 Sep 2025 10:56:15 -0400

Yosry points out that the default compressor check only applies when
something else is configured and we fall back, but not if it was
configured out of the box but isn't available.  Move the test.  Kconfig
should not permit this, so replace the pr_err() with a WARN.

Link: https://lkml.kernel.org/r/20250915153640.GA828739@cmpxchg.org
Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Acked-by: Yosry Ahmed <yosry.ahmed@linux.dev>
Cc: Chengming Zhou <zhouchengming@bytedance.com>
Cc: Nhat Pham <nphamcs@gmail.com>
Cc: SeongJae Park <sj@kernel.org>
Cc: Vitaly Wool <vitaly.wool@konsulko.se>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 mm/zswap.c |   12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

--- a/mm/zswap.c~mm-zswap-interact-directly-with-zsmalloc-fix
+++ a/mm/zswap.c
@@ -306,12 +306,12 @@ static struct zswap_pool *__zswap_pool_c
 		       zswap_compressor, CONFIG_ZSWAP_COMPRESSOR_DEFAULT);
 		param_free_charp(&zswap_compressor);
 		zswap_compressor = CONFIG_ZSWAP_COMPRESSOR_DEFAULT;
-		if (!crypto_has_acomp(zswap_compressor, 0, 0)) {
-			pr_err("default compressor %s not available\n",
-			       zswap_compressor);
-			zswap_compressor = ZSWAP_PARAM_UNSET;
-			return NULL;
-		}
+	}
+
+	/* Default compressor should be available. Kconfig bug? */
+	if (WARN_ON_ONCE(!crypto_has_acomp(zswap_compressor, 0, 0))) {
+		zswap_compressor = ZSWAP_PARAM_UNSET;
+		return NULL;
 	}
 
 	return zswap_pool_create(zswap_compressor);
_

Patches currently in -mm which might be from hannes@cmpxchg.org are

mm-zswap-interact-directly-with-zsmalloc.patch
mm-remove-unused-zpool-layer.patch
mm-zpdesc-minor-naming-and-comment-corrections.patch
mm-page_alloc-avoid-kswapd-thrashing-due-to-numa-restrictions.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-09-21 19:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-21 19:50 [folded-merged] mm-zswap-interact-directly-with-zsmalloc-fix.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.