linux-next: build failure after merge of the rcu tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

After merging the rcu tree, today's linux-next build (sparc defconfig)
failed like this:

mm/slab_common.o: In function `kmem_last_alloc':
slab_common.c:(.text+0xc4): undefined reference to `kmem_cache_last_alloc'

Caused by commit

  f7c3fb4fc476 ("mm: Add kmem_last_alloc() to return last allocation for memory block")

in mm/slab.c, kmem_cache_last_alloc() is only defined when CONFIG_NUMA
is set - which is not for this build.

I applied the following hack fix patch for today.

From ac5dcf78be1e6da530302966369a3bd63007cf81 Mon Sep 17 00:00:00 2001
From: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
Date: Fri, 4 Dec 2020 19:11:01 +1100
Subject: [PATCH] fixup for "mm: Add kmem_last_alloc() to return last
 allocation for memory block"

Signed-off-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
---
 mm/slab.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/mm/slab.c b/mm/slab.c
index 1f3b263f81ee..064707ac9f54 100644
--- a/mm/slab.c
+++ b/mm/slab.c
@@ -3650,6 +3650,11 @@ void *__kmalloc_node_track_caller(size_t size, gfp_t flags,
 	return __do_kmalloc_node(size, flags, node, caller);
 }
 EXPORT_SYMBOL(__kmalloc_node_track_caller);
+#else
+void *kmem_cache_last_alloc(struct kmem_cache *cachep, void *object)
+{
+	return NULL;
+}
 #endif /* CONFIG_NUMA */
 
 /**
-- 
2.29.2

-- 
Cheers,
Stephen Rothwell

Attachment: pgpghpm0joAhB.pgp
Description: OpenPGP digital signature


[Index of Archives]     [Linux Kernel]     [Linux USB Development]     [Yosemite News]     [Linux SCSI]

  Powered by Linux