[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <44867c60-db1a-4a0c-8973-c8a03e8da0f3@app.fastmail.com>
Date: Tue, 26 Sep 2023 09:33:48 +0200
From: "Arnd Bergmann" <arnd@...db.de>
To: "Mike Rapoport" <rppt@...nel.org>, linux-kernel@...r.kernel.org
Cc: "Andrew Morton" <akpm@...ux-foundation.org>,
Björn Töpel <bjorn@...nel.org>,
"Catalin Marinas" <catalin.marinas@....com>,
"Christophe Leroy" <christophe.leroy@...roup.eu>,
"David S . Miller" <davem@...emloft.net>,
"Dinh Nguyen" <dinguyen@...nel.org>,
"Heiko Carstens" <hca@...ux.ibm.com>,
"Helge Deller" <deller@....de>,
"Huacai Chen" <chenhuacai@...nel.org>,
"Kent Overstreet" <kent.overstreet@...ux.dev>,
"Luis Chamberlain" <mcgrof@...nel.org>,
"Mark Rutland" <mark.rutland@....com>,
"Michael Ellerman" <mpe@...erman.id.au>,
"Nadav Amit" <nadav.amit@...il.com>,
"Naveen N. Rao" <naveen.n.rao@...ux.ibm.com>,
"Palmer Dabbelt" <palmer@...belt.com>,
"Puranjay Mohan" <puranjay12@...il.com>,
"Rick Edgecombe" <rick.p.edgecombe@...el.com>,
"Russell King" <linux@...linux.org.uk>,
"Song Liu" <song@...nel.org>,
"Steven Rostedt" <rostedt@...dmis.org>,
"Thomas Bogendoerfer" <tsbogend@...ha.franken.de>,
"Thomas Gleixner" <tglx@...utronix.de>,
"Will Deacon" <will@...nel.org>, bpf@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, linux-mips@...r.kernel.org,
linux-mm@...ck.org, linux-modules@...r.kernel.org,
linux-parisc@...r.kernel.org, linux-riscv@...ts.infradead.org,
linux-s390@...r.kernel.org, linux-trace-kernel@...r.kernel.org,
linuxppc-dev@...ts.ozlabs.org, loongarch@...ts.linux.dev,
Netdev <netdev@...r.kernel.org>, sparclinux@...r.kernel.org,
x86@...nel.org
Subject: Re: [PATCH v3 10/13] arch: make execmem setup available regardless of
CONFIG_MODULES
On Mon, Sep 18, 2023, at 09:29, Mike Rapoport wrote:
> index a42e4cd11db2..c0b536e398b4 100644
> --- a/arch/arm/mm/init.c
> +++ b/arch/arm/mm/init.c
> +#ifdef CONFIG_XIP_KERNEL
> +/*
> + * The XIP kernel text is mapped in the module area for modules and
> + * some other stuff to work without any indirect relocations.
> + * MODULES_VADDR is redefined here and not in asm/memory.h to avoid
> + * recompiling the whole kernel when CONFIG_XIP_KERNEL is turned
> on/off.
> + */
> +#undef MODULES_VADDR
> +#define MODULES_VADDR (((unsigned long)_exiprom + ~PMD_MASK) &
> PMD_MASK)
> +#endif
> +
> +#if defined(CONFIG_MMU) && defined(CONFIG_EXECMEM)
> +static struct execmem_params execmem_params __ro_after_init = {
> + .ranges = {
> + [EXECMEM_DEFAULT] = {
> + .start = MODULES_VADDR,
> + .end = MODULES_END,
> + .alignment = 1,
> + },
This causes a randconfig build failure for me on linux-next now:
arch/arm/mm/init.c:499:25: error: initializer element is not constant
499 | #define MODULES_VADDR (((unsigned long)_exiprom + ~PMD_MASK) & PMD_MASK)
| ^
arch/arm/mm/init.c:506:34: note: in expansion of macro 'MODULES_VADDR'
506 | .start = MODULES_VADDR,
| ^~~~~~~~~~~~~
arch/arm/mm/init.c:499:25: note: (near initialization for 'execmem_params.ranges[0].start')
499 | #define MODULES_VADDR (((unsigned long)_exiprom + ~PMD_MASK) & PMD_MASK)
| ^
arch/arm/mm/init.c:506:34: note: in expansion of macro 'MODULES_VADDR'
506 | .start = MODULES_VADDR,
| ^~~~~~~~~~~~~
I have not done any analysis on the issue so far, I hope
you can see the problem directly. See
https://pastebin.com/raw/xVqAyakH for a .config that runs into
this problem with gcc-13.2.0.
Arnd
Powered by blists - more mailing lists