[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <8e1e4a9c-6ef8-a1a7-ad1f-84b5bf2a0b7d@csgroup.eu>
Date: Tue, 3 May 2022 16:03:20 +0200
From: Christophe Leroy <christophe.leroy@...roup.eu>
To: Naresh Kamboju <naresh.kamboju@...aro.org>,
Linux-Next Mailing List <linux-next@...r.kernel.org>,
open list <linux-kernel@...r.kernel.org>,
linuxppc-dev <linuxppc-dev@...ts.ozlabs.org>,
lkft-triage@...ts.linaro.org, Peter Collingbourne <pcc@...gle.com>,
Andrew Morton <akpm@...ux-foundation.org>,
"linux-mm@...ck.org" <linux-mm@...ck.org>
Cc: Stephen Rothwell <sfr@...b.auug.org.au>,
Baoquan He <bhe@...hat.com>,
Heiko Carstens <hca@...ux.ibm.com>,
Matthew Wilcox <willy@...radead.org>,
aul Mackerras <paulus@...ba.org>,
Christoph Hellwig <hch@....de>
Subject: Re: [next] powerpc: multiple definition of `____cacheline_aligned';
sound/core/oss/pcm_oss.o:(.bss+0x40): first defined here
Le 03/05/2022 à 15:10, Christophe Leroy a écrit :
>
>
> Le 29/04/2022 à 16:45, Naresh Kamboju a écrit :
>> Following powerpc builds failed on Linux next-20220428 and next-20220429.
>>
>> Regressions found on powerpc:
>> - gcc-11-ppc64e_defconfig
>> - gcc-10-ppc64e_defconfig
>> - gcc-9-ppc64e_defconfig
>> - gcc-8-ppc64e_defconfig
>> - clang-14-ppc64e_defconfig
>> - clang-nightly-ppc64e_defconfig
>> - clang-13-ppc64e_defconfig
>>
>>
>> Build error:
>> -------------
>> Error: Section .bss not empty in prom_init.c
>> make[3]: *** [arch/powerpc/kernel/Makefile:191:
>> arch/powerpc/kernel/prom_init_check] Error 1
>> make[3]: Target '__build' not remade because of errors.
>> make[2]: *** [scripts/Makefile.build:595: arch/powerpc/kernel] Error 2
>> make[2]: Target '__build' not remade because of errors.
>> make[1]: *** [Makefile:1996: arch/powerpc] Error 2
>> powerpc64le-linux-gnu-ld: sound/core/oss/pcm_plugin.o:(.bss+0x0):
>> multiple definition of `____cacheline_aligned';
>> sound/core/oss/pcm_oss.o:(.bss+0x40): first defined here
>> make[4]: *** [scripts/Makefile.build:530:
>> sound/core/oss/snd-pcm-oss.o] Error 1
>> make[4]: Target '__build' not remade because of errors.
>> make[3]: *** [scripts/Makefile.build:595: sound/core/oss] Error 2
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_clientmgr.o:(.bss+0x900):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_memory.o:(.bss+0x0):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_queue.o:(.bss+0x140):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_fifo.o:(.bss+0x0):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_timer.o:(.bss+0x0):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_system.o:(.bss+0x0):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_ports.o:(.bss+0x0):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> powerpc64le-linux-gnu-ld: sound/core/seq/seq_info.o:(.bss+0x40):
>> multiple definition of `____cacheline_aligned';
>> sound/core/seq/seq_lock.o:(.bss+0x0): first defined here
>> make[4]: *** [scripts/Makefile.build:530: sound/core/seq/snd-seq.o]
>> Error 1
>> make[4]: Target '__build' not remade because of errors.
>>
>>
>> Reported-by: Linux Kernel Functional Testing <lkft@...aro.org>
>>
>>
>> steps to reproduce:
>> -------------------
>> # To install tuxmake on your system globally:
>> # sudo pip3 install -U tuxmake
>>
>> tuxmake --runtime podman --target-arch powerpc --toolchain gcc-11
>> --kconfig ppc64e_defconfig
>>
>> --
>> Linaro LKFT
>> https://lkft.linaro.org
>>
>> [1] https://builds.tuxbuild.com/28Sn15hB2la1PweieGMLrUdbFMQ/
>
> Bisected to:
>
> 366e7b61ca1f115d38138236467068d8aacabcbc is the first bad commit
> commit 366e7b61ca1f115d38138236467068d8aacabcbc
> Author: Peter Collingbourne <pcc@...gle.com>
> Date: Fri Apr 29 14:42:51 2022 -0700
>
> printk: stop including cache.h from printk.h
>
> An inclusion of cache.h in printk.h was added in 2014 in commit
> c28aa1f0a847 ("printk/cache: mark printk_once test variable
> __read_mostly") in order to bring in the definition of
> __read_mostly. The
> usage of __read_mostly was later removed in commit 3ec25826ae33
> ("printk:
> Tie printk_once / printk_deferred_once into .data.once for reset")
> which
> made the inclusion of cache.h unnecessary, so remove it.
>
> We have a small amount of code that depended on the inclusion of
> cache.h
> from printk.h; fix that code to include the appropriate header.
>
> This fixes a circular inclusion on arm64 (linux/printk.h ->
> linux/cache.h
> -> asm/cache.h -> linux/kasan-enabled.h -> linux/static_key.h ->
> linux/jump_label.h -> linux/bug.h -> asm/bug.h -> linux/printk.h) that
> would otherwise be introduced by the next patch.
>
> Build tested using {allyesconfig,defconfig} x {arm64,x86_64}.
>
> Link:
> https://linux-review.googlesource.com/id/I8fd51f72c9ef1f2d6afd3b2cbc875aa4792c1fba
>
> Link:
> https://lkml.kernel.org/r/20220427195820.1716975-1-pcc@google.com
> Signed-off-by: Peter Collingbourne <pcc@...gle.com>
> Cc: Alexander Potapenko <glider@...gle.com>
> Cc: Andrey Konovalov <andreyknvl@...il.com>
> Cc: Andrey Ryabinin <ryabinin.a.a@...il.com>
> Cc: Catalin Marinas <catalin.marinas@....com>
> Cc: David Rientjes <rientjes@...gle.com>
> Cc: Dmitry Vyukov <dvyukov@...gle.com>
> Cc: Eric W. Biederman <ebiederm@...ssion.com>
> Cc: Herbert Xu <herbert@...dor.apana.org.au>
> Cc: Hyeonggon Yoo <42.hyeyoo@...il.com>
> Cc: Joonsoo Kim <iamjoonsoo.kim@....com>
> Cc: Kees Cook <keescook@...omium.org>
> Cc: Pekka Enberg <penberg@...nel.org>
> Cc: Roman Gushchin <roman.gushchin@...ux.dev>
> Cc: Vlastimil Babka <vbabka@...e.cz>
> Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
>
> arch/arm64/include/asm/mte-kasan.h | 1 +
> arch/arm64/include/asm/percpu.h | 1 +
> arch/csky/include/asm/processor.h | 2 +-
> drivers/firmware/smccc/kvm_guest.c | 1 +
> include/linux/printk.h | 1 -
> kernel/bpf/bpf_lru_list.h | 1 +
> 6 files changed, 5 insertions(+), 2 deletions(-)
I think you need to fix all files that use ____cacheline_aligned without
including linux/cache.h
You can locate them with:
git grep -L linux/cache.h `git grep -l ____cacheline_aligned `
Christophe
Powered by blists - more mailing lists