]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
slub: STACKDEPOT: rename save_stack_trace()
authorRandy Dunlap <rdunlap@infradead.org>
Wed, 2 Jun 2021 03:53:25 +0000 (13:53 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 3 Jun 2021 08:17:01 +0000 (18:17 +1000)
save_stack_trace() already exists, so change the one in
CONFIG_STACKDEPOT to be save_stack_depot_trace().

Fixes this build error:

../mm/slub.c:607:29: error: conflicting types for `save_stack_trace'
 static depot_stack_handle_t save_stack_trace(gfp_t flags)
                             ^~~~~~~~~~~~~~~~
In file included from ../include/linux/page_ext.h:6:0,
                 from ../include/linux/mm.h:25,
                 from ../mm/slub.c:13:
../include/linux/stacktrace.h:86:13: note: previous declaration of `save_stack_trace' was here
 extern void save_stack_trace(struct stack_trace *trace);
             ^~~~~~~~~~~~~~~~

from this patch in mmotm:
  Subject: mm/slub: use stackdepot to save stack trace in objects

Link: https://lkml.kernel.org/r/20210513051920.29320-1-rdunlap@infradead.org
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Acked-by: Oliver Glitta <glittao@gmail.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
mm/slub.c

index d800edb25d3ec2aa1ffe5b8a278e98f4871e70c0..e37f58882fb39be905ee6c3f1e47031aada22a6e 100644 (file)
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -619,7 +619,7 @@ static struct track *get_track(struct kmem_cache *s, void *object,
 }
 
 #ifdef CONFIG_STACKDEPOT
-static depot_stack_handle_t save_stack_trace(gfp_t flags)
+static depot_stack_handle_t save_stack_depot_trace(gfp_t flags)
 {
        unsigned long entries[TRACK_ADDRS_COUNT];
        depot_stack_handle_t handle;
@@ -638,7 +638,7 @@ static void set_track(struct kmem_cache *s, void *object,
 
        if (addr) {
 #ifdef CONFIG_STACKDEPOT
-               p->handle = save_stack_trace(GFP_KERNEL);
+               p->handle = save_stack_depot_trace(GFP_KERNEL);
 #endif
                p->addr = addr;
                p->cpu = smp_processor_id();