* [merged mm-stable] mm-zswap-warn-when-referencing-a-dead-entry.patch removed from -mm tree
@ 2024-02-22 0:01 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2024-02-22 0:01 UTC (permalink / raw)
To: mm-commits, zhouchengming, yosryahmed, nphamcs, hannes, akpm
The quilt patch titled
Subject: mm: zswap: warn when referencing a dead entry
has been removed from the -mm tree. Its filename was
mm-zswap-warn-when-referencing-a-dead-entry.patch
This patch was dropped because it was merged into the mm-stable branch
of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
------------------------------------------------------
From: Johannes Weiner <hannes@cmpxchg.org>
Subject: mm: zswap: warn when referencing a dead entry
Date: Mon, 29 Jan 2024 20:36:40 -0500
Put a standard sanity check on zswap_entry_get() for UAF scenario.
Link: https://lkml.kernel.org/r/20240130014208.565554-5-hannes@cmpxchg.org
Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Reviewed-by: Nhat Pham <nphamcs@gmail.com>
Acked-by: Yosry Ahmed <yosryahmed@google.com>
Reviewed-by: Chengming Zhou <zhouchengming@bytedance.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
mm/zswap.c | 1 +
1 file changed, 1 insertion(+)
--- a/mm/zswap.c~mm-zswap-warn-when-referencing-a-dead-entry
+++ a/mm/zswap.c
@@ -541,6 +541,7 @@ static void zswap_entry_free(struct zswa
/* caller must hold the tree lock */
static void zswap_entry_get(struct zswap_entry *entry)
{
+ WARN_ON_ONCE(!entry->refcount);
entry->refcount++;
}
_
Patches currently in -mm which might be from hannes@cmpxchg.org are
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-02-22 0:01 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-22 0:01 [merged mm-stable] mm-zswap-warn-when-referencing-a-dead-entry.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.