kfence-skip-__gfp_thisnode-allocations-on-numa-systems.patch removed from -mm tree
The quilt patch titled
Subject: kfence: skip __GFP_THISNODE allocations on NUMA systems
has been removed from the -mm tree. Its filename was
kfence-skip-__gfp_thisnode-allocations-on-numa-systems.patch
This patch was dropped because it was merged into the mm-hotfixes-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
------------------------------------------------------
From: Marco Elver <[email protected]>
Subject: kfence: skip __GFP_THISNODE allocations on NUMA systems
Date: Fri, 24 Jan 2025 13:01:38 +0100
On NUMA systems, __GFP_THISNODE indicates that an allocation _must_ be on a particular node, and failure to allocate on the desired node will result in a failed allocation.
Skip __GFP_THISNODE allocations if we are running on a NUMA system, since KFENCE can't guarantee which node its pool pages are allocated on.
---
mm/kfence/core.c | 2 ++ 1 file changed, 2 insertions(+)
mm/kfence/core.c renamed from mm/kfence/core.c~kfence-skip-__gfp_thisnode-allocations-on-numa-systems +2 -0
@@ -21,6 +21,7 @@#include <linux/log2.h> #include <linux/memblock.h> #include <linux/moduleparam.h> +#include <linux/nodemask.h> #include <linux/notifier.h> #include <linux/panic_notifier.h> #include <linux/random.h>
@@ -1084,6 +1085,7 @@ void *__kfence_alloc(struct kmem_cache ** properties (e.g. reside in DMAable memory). */ if ((flags &GFP_ZONEMASK ) || + ((flags & __GFP_THISNODE) &&num_online_nodes () >1 ) || (s->flags & (SLAB_CACHE_DMA |SLAB_CACHE_DMA32 ))) {atomic_long_inc (&counters[KFENCE_COUNTER_SKIP_INCOMPAT ]);return NULL ;
_
Patches currently in -mm which might be from [email protected] are