Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753779AbbGANb1 (ORCPT ); Wed, 1 Jul 2015 09:31:27 -0400 Received: from mail-ob0-f173.google.com ([209.85.214.173]:34287 "EHLO mail-ob0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753191AbbGANbV (ORCPT ); Wed, 1 Jul 2015 09:31:21 -0400 MIME-Version: 1.0 In-Reply-To: References: <20150630135009.75cb607a@canb.auug.org.au> Date: Wed, 1 Jul 2015 15:31:20 +0200 X-Google-Sender-Auth: rE_SYxfufmnshaspnvK1Gtkj2O0 Message-ID: Subject: Re: linux-next: build warning in the origin tree From: Geert Uytterhoeven To: Christoph Lameter Cc: Stephen Rothwell , Linus Torvalds , Linux-Next , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1858 Lines: 47 On Tue, Jun 30, 2015 at 4:01 PM, Christoph Lameter wrote: > On Tue, 30 Jun 2015, Stephen Rothwell wrote: >> WARNING: mm/built-in.o(.text.unlikely+0xc22): Section mismatch in reference from the function .new_kmalloc_cache() to the variable .init.rodata:kmalloc_info >> The function .new_kmalloc_cache() references >> the variable __initconst kmalloc_info. >> This is often because .new_kmalloc_cache lacks a __initconst >> annotation or the annotation of kmalloc_info is wrong. >> >> Caused by commit a9730fca9946 ("Fix kmalloc slab creation sequence"). > > > Subject: Add __init attribute to new_kmalloc_cache > > Signed-off-by: Christoph Lameter Tested-by: Geert Uytterhoeven > > Index: linux/mm/slab_common.c > =================================================================== > --- linux.orig/mm/slab_common.c > +++ linux/mm/slab_common.c > @@ -855,7 +855,7 @@ void __init setup_kmalloc_cache_index_ta > } > } > > -static void new_kmalloc_cache(int idx, unsigned long flags) > +static void __init new_kmalloc_cache(int idx, unsigned long flags) > { > kmalloc_caches[idx] = create_kmalloc_cache(kmalloc_info[idx].name, > kmalloc_info[idx].size, flags); Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/