* [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels @ 2022-03-09 14:40 Arnd Bergmann 2022-03-09 14:40 ` [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 Arnd Bergmann ` (2 more replies) 0 siblings, 3 replies; 14+ messages in thread From: Arnd Bergmann @ 2022-03-09 14:40 UTC (permalink / raw) To: Russell King Cc: Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Linus Walleij, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, linux-arm-kernel, linux-kernel From: Arnd Bergmann <arnd@arndb.de> The removal of the old-style irq entry broke obscure NOMMU configurations on machines that have an MMU: ld.lld: error: undefined symbol: generic_handle_arch_irq referenced by kernel/entry-armv.o:(__irq_svc) in archive arch/arm/built-in.a A follow-up patch to convert nvic to the generic_handle_arch_irq() could have fixed this by removing the Kconfig conditional, but did it differently. Change the Kconfig logic so ARM machines now unconditionally enable the feature. I have also submitted a patch to remove support for the configurations that broke, but fixing the regression first is a trivial and correct change. Reported-by: kernel test robot <lkp@intel.com> Fixes: 54f481a2308e ("ARM: remove old-style irq entry") Fixes: 52d240871760 ("irqchip: nvic: Use GENERIC_IRQ_MULTI_HANDLER") Signed-off-by: Arnd Bergmann <arnd@arndb.de> --- This patch should go into the arm/devel-stable branch that has the arm-irq-and-vmap-stacks-for-rmk patches from Ard --- arch/arm/Kconfig | 2 +- drivers/irqchip/Kconfig | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index e9975ddd5034..5f0b40bab4fb 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -60,7 +60,7 @@ config ARM select GENERIC_CPU_AUTOPROBE select GENERIC_EARLY_IOREMAP select GENERIC_IDLE_POLL_SETUP - select GENERIC_IRQ_MULTI_HANDLER if MMU + select GENERIC_IRQ_MULTI_HANDLER select GENERIC_IRQ_PROBE select GENERIC_IRQ_SHOW select GENERIC_IRQ_SHOW_LEVEL diff --git a/drivers/irqchip/Kconfig b/drivers/irqchip/Kconfig index 488eaa14d3a7..7038957f4a77 100644 --- a/drivers/irqchip/Kconfig +++ b/drivers/irqchip/Kconfig @@ -58,7 +58,6 @@ config ARM_NVIC bool select IRQ_DOMAIN_HIERARCHY select GENERIC_IRQ_CHIP - select GENERIC_IRQ_MULTI_HANDLER config ARM_VIC bool -- 2.29.2 ^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-09 14:40 [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels Arnd Bergmann @ 2022-03-09 14:40 ` Arnd Bergmann 2022-03-09 15:48 ` Robin Murphy 2022-03-10 1:19 ` [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels Linus Walleij 2022-03-12 9:14 ` Ard Biesheuvel 2 siblings, 1 reply; 14+ messages in thread From: Arnd Bergmann @ 2022-03-09 14:40 UTC (permalink / raw) To: Russell King, Linus Walleij Cc: Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, linux-arm-kernel, linux-kernel, Russell King (Oracle), Anshuman Khandual From: Arnd Bergmann <arnd@arndb.de> It is possible to build MMU-less kernels for Cortex-M base microcrontrollers as well as a couple of older platforms that have not been converted to CONFIG_ARCH_MULTIPLATFORM, specifically ep93xx, footbridge, dove, sa1100 and s3c24xx. It seems unlikely that anybody has tested those configurations in recent years, as even building them is frequently broken. A patch I submitted caused another build time regression in this configuration. I sent a patch for that, but it seems better to also remove the option entirely, leaving ARMv7-M as the only supported Arm NOMMU target for simplicity. This addresses several build failures in randconfig builds that have accumulated over the years. Cc: Vladimir Murzin <vladimir.murzin@arm.com> Cc: Russell King <linux@armlinux.org.uk> Signed-off-by: Arnd Bergmann <arnd@arndb.de> --- If there are no objections, I'd apply this patch to the soc tree for 5.18 as a cleanup. --- arch/arm/Kconfig | 34 +++++++------------ .../mach-footbridge/include/mach/hardware.h | 20 ++++------- arch/arm/mach-footbridge/include/mach/io.h | 20 ----------- arch/arm/mach-integrator/hardware.h | 5 --- 4 files changed, 20 insertions(+), 59 deletions(-) delete mode 100644 arch/arm/mach-footbridge/include/mach/io.h diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 5f0b40bab4fb..d184377ce2ae 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -304,6 +304,17 @@ config MMU Select if you want MMU-based virtualised addressing space support by paged memory management. If unsure, say 'Y'. +config ARM_SINGLE_ARMV7M + def_bool !MMU + select ARM_NVIC + select AUTO_ZRELADDR + select TIMER_OF + select COMMON_CLK + select CPU_V7M + select NO_IOPORT_MAP + select SPARSE_IRQ + select USE_OF + config ARCH_MMAP_RND_BITS_MIN default 8 @@ -318,12 +329,11 @@ config ARCH_MMAP_RND_BITS_MAX # choice prompt "ARM system type" - default ARM_SINGLE_ARMV7M if !MMU - default ARCH_MULTIPLATFORM if MMU + depends on MMU + default ARCH_MULTIPLATFORM config ARCH_MULTIPLATFORM bool "Allow multiple platforms to be selected" - depends on MMU select ARCH_FLATMEM_ENABLE select ARCH_SPARSEMEM_ENABLE select ARCH_SELECT_MEMORY_MODEL @@ -337,18 +347,6 @@ config ARCH_MULTIPLATFORM select SPARSE_IRQ select USE_OF -config ARM_SINGLE_ARMV7M - bool "ARMv7-M based platforms (Cortex-M0/M3/M4)" - depends on !MMU - select ARM_NVIC - select AUTO_ZRELADDR - select TIMER_OF - select COMMON_CLK - select CPU_V7M - select NO_IOPORT_MAP - select SPARSE_IRQ - select USE_OF - config ARCH_EP93XX bool "EP93xx-based" select ARCH_SPARSEMEM_ENABLE @@ -367,7 +365,6 @@ config ARCH_FOOTBRIDGE bool "FootBridge" select CPU_SA110 select FOOTBRIDGE - select NEED_MACH_IO_H if !MMU select NEED_MACH_MEMORY_H help Support for systems based on the DC21285 companion chip @@ -375,7 +372,6 @@ config ARCH_FOOTBRIDGE config ARCH_IOP32X bool "IOP32x-based" - depends on MMU select CPU_XSCALE select GPIO_IOP select GPIOLIB @@ -387,7 +383,6 @@ config ARCH_IOP32X config ARCH_IXP4XX bool "IXP4xx-based" - depends on MMU select ARCH_SUPPORTS_BIG_ENDIAN select ARM_PATCH_PHYS_VIRT select CPU_XSCALE @@ -418,7 +413,6 @@ config ARCH_DOVE config ARCH_PXA bool "PXA2xx/PXA3xx-based" - depends on MMU select ARCH_MTD_XIP select ARM_CPU_SUSPEND if PM select AUTO_ZRELADDR @@ -437,7 +431,6 @@ config ARCH_PXA config ARCH_RPC bool "RiscPC" - depends on MMU depends on !CC_IS_CLANG && GCC_VERSION < 90100 && GCC_VERSION >= 60000 select ARCH_ACORN select ARCH_MAY_HAVE_PC_FDC @@ -493,7 +486,6 @@ config ARCH_S3C24XX config ARCH_OMAP1 bool "TI OMAP1" - depends on MMU select ARCH_OMAP select CLKSRC_MMIO select GENERIC_IRQ_CHIP diff --git a/arch/arm/mach-footbridge/include/mach/hardware.h b/arch/arm/mach-footbridge/include/mach/hardware.h index ecaf6e7388d9..985ad3a95671 100644 --- a/arch/arm/mach-footbridge/include/mach/hardware.h +++ b/arch/arm/mach-footbridge/include/mach/hardware.h @@ -21,32 +21,26 @@ * 0xf0000000 0x80000000 16MB ISA memory */ -#ifdef CONFIG_MMU -#define MMU_IO(a, b) (a) -#else -#define MMU_IO(a, b) (b) -#endif - #define XBUS_SIZE 0x00100000 -#define XBUS_BASE MMU_IO(0xff800000, 0x40000000) +#define XBUS_BASE 0xff800000 #define ARMCSR_SIZE 0x00100000 -#define ARMCSR_BASE MMU_IO(0xfe000000, 0x42000000) +#define ARMCSR_BASE 0xfe000000 #define WFLUSH_SIZE 0x00100000 -#define WFLUSH_BASE MMU_IO(0xfd000000, 0x78000000) +#define WFLUSH_BASE 0xfd000000 #define PCIIACK_SIZE 0x00100000 -#define PCIIACK_BASE MMU_IO(0xfc000000, 0x79000000) +#define PCIIACK_BASE 0xfc000000 #define PCICFG1_SIZE 0x01000000 -#define PCICFG1_BASE MMU_IO(0xfb000000, 0x7a000000) +#define PCICFG1_BASE 0xfb000000 #define PCICFG0_SIZE 0x01000000 -#define PCICFG0_BASE MMU_IO(0xfa000000, 0x7b000000) +#define PCICFG0_BASE 0xfa000000 #define PCIMEM_SIZE 0x01000000 -#define PCIMEM_BASE MMU_IO(0xf0000000, 0x80000000) +#define PCIMEM_BASE 0xf0000000 #define XBUS_CS2 0x40012000 diff --git a/arch/arm/mach-footbridge/include/mach/io.h b/arch/arm/mach-footbridge/include/mach/io.h deleted file mode 100644 index 4e18b921373f..000000000000 --- a/arch/arm/mach-footbridge/include/mach/io.h +++ /dev/null @@ -1,20 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ -/* - * arch/arm/mach-footbridge/include/mach/io.h - * - * Copyright (C) 1997-1999 Russell King - * - * Modifications: - * 06-12-1997 RMK Created. - * 07-04-1999 RMK Major cleanup - */ -#ifndef __ASM_ARM_ARCH_IO_H -#define __ASM_ARM_ARCH_IO_H - -/* - * Translation of various i/o addresses to host addresses for !CONFIG_MMU - */ -#define PCIO_BASE 0x7c000000 -#define __io(a) ((void __iomem *)(PCIO_BASE + (a))) - -#endif diff --git a/arch/arm/mach-integrator/hardware.h b/arch/arm/mach-integrator/hardware.h index 4d6ade3dd4ee..81ce09e3ad45 100644 --- a/arch/arm/mach-integrator/hardware.h +++ b/arch/arm/mach-integrator/hardware.h @@ -16,12 +16,7 @@ #define IO_START INTEGRATOR_HDR_BASE // PA of IO /* macro to get at IO space when running virtually */ -#ifdef CONFIG_MMU #define IO_ADDRESS(x) (((x) & 0x000fffff) | (((x) >> 4) & 0x0ff00000) | IO_BASE) -#else -#define IO_ADDRESS(x) (x) -#endif - #define __io_address(n) ((void __iomem *)IO_ADDRESS(n)) /* -- 2.29.2 ^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-09 14:40 ` [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 Arnd Bergmann @ 2022-03-09 15:48 ` Robin Murphy 2022-03-09 16:17 ` Arnd Bergmann 0 siblings, 1 reply; 14+ messages in thread From: Robin Murphy @ 2022-03-09 15:48 UTC (permalink / raw) To: Arnd Bergmann, Russell King, Linus Walleij Cc: Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, linux-arm-kernel, linux-kernel, Russell King (Oracle), Anshuman Khandual On 2022-03-09 14:40, Arnd Bergmann wrote: > From: Arnd Bergmann <arnd@arndb.de> > > It is possible to build MMU-less kernels for Cortex-M base > microcrontrollers as well as a couple of older platforms that > have not been converted to CONFIG_ARCH_MULTIPLATFORM, > specifically ep93xx, footbridge, dove, sa1100 and s3c24xx. > > It seems unlikely that anybody has tested those configurations > in recent years, as even building them is frequently broken. > A patch I submitted caused another build time regression > in this configuration. I sent a patch for that, but it seems > better to also remove the option entirely, leaving ARMv7-M > as the only supported Arm NOMMU target for simplicity. In that case, it would probably make sense to garbage-collect all the configs, setup code and other stuff relating to older MMU-less CPU cores like ARM1156, ARM940, etc. at the same time. Robin. > This addresses several build failures in randconfig builds that > have accumulated over the years. > > Cc: Vladimir Murzin <vladimir.murzin@arm.com> > Cc: Russell King <linux@armlinux.org.uk> > Signed-off-by: Arnd Bergmann <arnd@arndb.de> > --- > If there are no objections, I'd apply this patch to the soc > tree for 5.18 as a cleanup. > --- > arch/arm/Kconfig | 34 +++++++------------ > .../mach-footbridge/include/mach/hardware.h | 20 ++++------- > arch/arm/mach-footbridge/include/mach/io.h | 20 ----------- > arch/arm/mach-integrator/hardware.h | 5 --- > 4 files changed, 20 insertions(+), 59 deletions(-) > delete mode 100644 arch/arm/mach-footbridge/include/mach/io.h > > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig > index 5f0b40bab4fb..d184377ce2ae 100644 > --- a/arch/arm/Kconfig > +++ b/arch/arm/Kconfig > @@ -304,6 +304,17 @@ config MMU > Select if you want MMU-based virtualised addressing space > support by paged memory management. If unsure, say 'Y'. > > +config ARM_SINGLE_ARMV7M > + def_bool !MMU > + select ARM_NVIC > + select AUTO_ZRELADDR > + select TIMER_OF > + select COMMON_CLK > + select CPU_V7M > + select NO_IOPORT_MAP > + select SPARSE_IRQ > + select USE_OF > + > config ARCH_MMAP_RND_BITS_MIN > default 8 > > @@ -318,12 +329,11 @@ config ARCH_MMAP_RND_BITS_MAX > # > choice > prompt "ARM system type" > - default ARM_SINGLE_ARMV7M if !MMU > - default ARCH_MULTIPLATFORM if MMU > + depends on MMU > + default ARCH_MULTIPLATFORM > > config ARCH_MULTIPLATFORM > bool "Allow multiple platforms to be selected" > - depends on MMU > select ARCH_FLATMEM_ENABLE > select ARCH_SPARSEMEM_ENABLE > select ARCH_SELECT_MEMORY_MODEL > @@ -337,18 +347,6 @@ config ARCH_MULTIPLATFORM > select SPARSE_IRQ > select USE_OF > > -config ARM_SINGLE_ARMV7M > - bool "ARMv7-M based platforms (Cortex-M0/M3/M4)" > - depends on !MMU > - select ARM_NVIC > - select AUTO_ZRELADDR > - select TIMER_OF > - select COMMON_CLK > - select CPU_V7M > - select NO_IOPORT_MAP > - select SPARSE_IRQ > - select USE_OF > - > config ARCH_EP93XX > bool "EP93xx-based" > select ARCH_SPARSEMEM_ENABLE > @@ -367,7 +365,6 @@ config ARCH_FOOTBRIDGE > bool "FootBridge" > select CPU_SA110 > select FOOTBRIDGE > - select NEED_MACH_IO_H if !MMU > select NEED_MACH_MEMORY_H > help > Support for systems based on the DC21285 companion chip > @@ -375,7 +372,6 @@ config ARCH_FOOTBRIDGE > > config ARCH_IOP32X > bool "IOP32x-based" > - depends on MMU > select CPU_XSCALE > select GPIO_IOP > select GPIOLIB > @@ -387,7 +383,6 @@ config ARCH_IOP32X > > config ARCH_IXP4XX > bool "IXP4xx-based" > - depends on MMU > select ARCH_SUPPORTS_BIG_ENDIAN > select ARM_PATCH_PHYS_VIRT > select CPU_XSCALE > @@ -418,7 +413,6 @@ config ARCH_DOVE > > config ARCH_PXA > bool "PXA2xx/PXA3xx-based" > - depends on MMU > select ARCH_MTD_XIP > select ARM_CPU_SUSPEND if PM > select AUTO_ZRELADDR > @@ -437,7 +431,6 @@ config ARCH_PXA > > config ARCH_RPC > bool "RiscPC" > - depends on MMU > depends on !CC_IS_CLANG && GCC_VERSION < 90100 && GCC_VERSION >= 60000 > select ARCH_ACORN > select ARCH_MAY_HAVE_PC_FDC > @@ -493,7 +486,6 @@ config ARCH_S3C24XX > > config ARCH_OMAP1 > bool "TI OMAP1" > - depends on MMU > select ARCH_OMAP > select CLKSRC_MMIO > select GENERIC_IRQ_CHIP > diff --git a/arch/arm/mach-footbridge/include/mach/hardware.h b/arch/arm/mach-footbridge/include/mach/hardware.h > index ecaf6e7388d9..985ad3a95671 100644 > --- a/arch/arm/mach-footbridge/include/mach/hardware.h > +++ b/arch/arm/mach-footbridge/include/mach/hardware.h > @@ -21,32 +21,26 @@ > * 0xf0000000 0x80000000 16MB ISA memory > */ > > -#ifdef CONFIG_MMU > -#define MMU_IO(a, b) (a) > -#else > -#define MMU_IO(a, b) (b) > -#endif > - > #define XBUS_SIZE 0x00100000 > -#define XBUS_BASE MMU_IO(0xff800000, 0x40000000) > +#define XBUS_BASE 0xff800000 > > #define ARMCSR_SIZE 0x00100000 > -#define ARMCSR_BASE MMU_IO(0xfe000000, 0x42000000) > +#define ARMCSR_BASE 0xfe000000 > > #define WFLUSH_SIZE 0x00100000 > -#define WFLUSH_BASE MMU_IO(0xfd000000, 0x78000000) > +#define WFLUSH_BASE 0xfd000000 > > #define PCIIACK_SIZE 0x00100000 > -#define PCIIACK_BASE MMU_IO(0xfc000000, 0x79000000) > +#define PCIIACK_BASE 0xfc000000 > > #define PCICFG1_SIZE 0x01000000 > -#define PCICFG1_BASE MMU_IO(0xfb000000, 0x7a000000) > +#define PCICFG1_BASE 0xfb000000 > > #define PCICFG0_SIZE 0x01000000 > -#define PCICFG0_BASE MMU_IO(0xfa000000, 0x7b000000) > +#define PCICFG0_BASE 0xfa000000 > > #define PCIMEM_SIZE 0x01000000 > -#define PCIMEM_BASE MMU_IO(0xf0000000, 0x80000000) > +#define PCIMEM_BASE 0xf0000000 > > #define XBUS_CS2 0x40012000 > > diff --git a/arch/arm/mach-footbridge/include/mach/io.h b/arch/arm/mach-footbridge/include/mach/io.h > deleted file mode 100644 > index 4e18b921373f..000000000000 > --- a/arch/arm/mach-footbridge/include/mach/io.h > +++ /dev/null > @@ -1,20 +0,0 @@ > -/* SPDX-License-Identifier: GPL-2.0-only */ > -/* > - * arch/arm/mach-footbridge/include/mach/io.h > - * > - * Copyright (C) 1997-1999 Russell King > - * > - * Modifications: > - * 06-12-1997 RMK Created. > - * 07-04-1999 RMK Major cleanup > - */ > -#ifndef __ASM_ARM_ARCH_IO_H > -#define __ASM_ARM_ARCH_IO_H > - > -/* > - * Translation of various i/o addresses to host addresses for !CONFIG_MMU > - */ > -#define PCIO_BASE 0x7c000000 > -#define __io(a) ((void __iomem *)(PCIO_BASE + (a))) > - > -#endif > diff --git a/arch/arm/mach-integrator/hardware.h b/arch/arm/mach-integrator/hardware.h > index 4d6ade3dd4ee..81ce09e3ad45 100644 > --- a/arch/arm/mach-integrator/hardware.h > +++ b/arch/arm/mach-integrator/hardware.h > @@ -16,12 +16,7 @@ > #define IO_START INTEGRATOR_HDR_BASE // PA of IO > > /* macro to get at IO space when running virtually */ > -#ifdef CONFIG_MMU > #define IO_ADDRESS(x) (((x) & 0x000fffff) | (((x) >> 4) & 0x0ff00000) | IO_BASE) > -#else > -#define IO_ADDRESS(x) (x) > -#endif > - > #define __io_address(n) ((void __iomem *)IO_ADDRESS(n)) > > /* ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-09 15:48 ` Robin Murphy @ 2022-03-09 16:17 ` Arnd Bergmann 2022-03-09 16:21 ` Vladimir Murzin 2022-03-10 1:22 ` Linus Walleij 0 siblings, 2 replies; 14+ messages in thread From: Arnd Bergmann @ 2022-03-09 16:17 UTC (permalink / raw) To: Robin Murphy Cc: Russell King, Linus Walleij, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On Wed, Mar 9, 2022 at 4:48 PM Robin Murphy <robin.murphy@arm.com> wrote: > > On 2022-03-09 14:40, Arnd Bergmann wrote: > > From: Arnd Bergmann <arnd@arndb.de> > > > > It is possible to build MMU-less kernels for Cortex-M base > > microcrontrollers as well as a couple of older platforms that > > have not been converted to CONFIG_ARCH_MULTIPLATFORM, > > specifically ep93xx, footbridge, dove, sa1100 and s3c24xx. > > > > It seems unlikely that anybody has tested those configurations > > in recent years, as even building them is frequently broken. > > A patch I submitted caused another build time regression > > in this configuration. I sent a patch for that, but it seems > > better to also remove the option entirely, leaving ARMv7-M > > as the only supported Arm NOMMU target for simplicity. > > In that case, it would probably make sense to garbage-collect all the > configs, setup code and other stuff relating to older MMU-less CPU cores > like ARM1156, ARM940, etc. at the same time. Right, good idea. These are only selected by CONFIG_ARCH_INTEGRATOR, but that in turn doesn't build for CONFIG_MMU=n because it depends on ARCH_MULTIPLATFORM. I'll send a patch for these. I also went back and forth between removing the #ifdefs in arch/arm/mm/proc-*.S for this patch, though I did not do that in the end. We may still want them at least for proc-v7.S because that is a small chance that someone will want to support Cortex-R. Arnd ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-09 16:17 ` Arnd Bergmann @ 2022-03-09 16:21 ` Vladimir Murzin 2022-03-09 16:38 ` Arnd Bergmann 2022-03-10 1:22 ` Linus Walleij 1 sibling, 1 reply; 14+ messages in thread From: Vladimir Murzin @ 2022-03-09 16:21 UTC (permalink / raw) To: Arnd Bergmann, Robin Murphy Cc: Russell King, Linus Walleij, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On 3/9/22 4:17 PM, Arnd Bergmann wrote: > On Wed, Mar 9, 2022 at 4:48 PM Robin Murphy <robin.murphy@arm.com> wrote: >> >> On 2022-03-09 14:40, Arnd Bergmann wrote: >>> From: Arnd Bergmann <arnd@arndb.de> >>> >>> It is possible to build MMU-less kernels for Cortex-M base >>> microcrontrollers as well as a couple of older platforms that >>> have not been converted to CONFIG_ARCH_MULTIPLATFORM, >>> specifically ep93xx, footbridge, dove, sa1100 and s3c24xx. >>> >>> It seems unlikely that anybody has tested those configurations >>> in recent years, as even building them is frequently broken. >>> A patch I submitted caused another build time regression >>> in this configuration. I sent a patch for that, but it seems >>> better to also remove the option entirely, leaving ARMv7-M >>> as the only supported Arm NOMMU target for simplicity. >> >> In that case, it would probably make sense to garbage-collect all the >> configs, setup code and other stuff relating to older MMU-less CPU cores >> like ARM1156, ARM940, etc. at the same time. > > Right, good idea. These are only selected by CONFIG_ARCH_INTEGRATOR, > but that in turn doesn't build for CONFIG_MMU=n because it depends on > ARCH_MULTIPLATFORM. I'll send a patch for these. > > I also went back and forth between removing the #ifdefs in > arch/arm/mm/proc-*.S for this patch, though I did not do that in the end. > We may still want them at least for proc-v7.S because that is a small > chance that someone will want to support Cortex-R. > I'd appreciate if you keep them since I run Cortex-R52... Cheers Vladimir > Arnd > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-09 16:21 ` Vladimir Murzin @ 2022-03-09 16:38 ` Arnd Bergmann 2022-03-10 1:29 ` Linus Walleij 0 siblings, 1 reply; 14+ messages in thread From: Arnd Bergmann @ 2022-03-09 16:38 UTC (permalink / raw) To: Vladimir Murzin Cc: Robin Murphy, Russell King, Linus Walleij, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On Wed, Mar 9, 2022 at 5:21 PM Vladimir Murzin <vladimir.murzin@arm.com> wrote: > On 3/9/22 4:17 PM, Arnd Bergmann wrote: > > On Wed, Mar 9, 2022 at 4:48 PM Robin Murphy <robin.murphy@arm.com> wrote: > >> > >> On 2022-03-09 14:40, Arnd Bergmann wrote: > >>> From: Arnd Bergmann <arnd@arndb.de> > >>> > >>> It is possible to build MMU-less kernels for Cortex-M base > >>> microcrontrollers as well as a couple of older platforms that > >>> have not been converted to CONFIG_ARCH_MULTIPLATFORM, > >>> specifically ep93xx, footbridge, dove, sa1100 and s3c24xx. > >>> > >>> It seems unlikely that anybody has tested those configurations > >>> in recent years, as even building them is frequently broken. > >>> A patch I submitted caused another build time regression > >>> in this configuration. I sent a patch for that, but it seems > >>> better to also remove the option entirely, leaving ARMv7-M > >>> as the only supported Arm NOMMU target for simplicity. > >> > >> In that case, it would probably make sense to garbage-collect all the > >> configs, setup code and other stuff relating to older MMU-less CPU cores > >> like ARM1156, ARM940, etc. at the same time. > > > > Right, good idea. These are only selected by CONFIG_ARCH_INTEGRATOR, > > but that in turn doesn't build for CONFIG_MMU=n because it depends on > > ARCH_MULTIPLATFORM. I'll send a patch for these. > > > > I also went back and forth between removing the #ifdefs in > > arch/arm/mm/proc-*.S for this patch, though I did not do that in the end. > > We may still want them at least for proc-v7.S because that is a small > > chance that someone will want to support Cortex-R. > > > > I'd appreciate if you keep them since I run Cortex-R52... Ok, no problem. Any opinion on removing CPU_ARM{7TDMI,740T,940T,946E}? Arnd ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-09 16:38 ` Arnd Bergmann @ 2022-03-10 1:29 ` Linus Walleij 0 siblings, 0 replies; 14+ messages in thread From: Linus Walleij @ 2022-03-10 1:29 UTC (permalink / raw) To: Arnd Bergmann Cc: Vladimir Murzin, Robin Murphy, Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On Wed, Mar 9, 2022 at 5:38 PM Arnd Bergmann <arnd@kernel.org> wrote: > Any opinion on removing CPU_ARM{7TDMI,740T,940T,946E}? 7TDMI was/is extremely prolific, it is everywhere (such as in CSR/SiRF GPS chips, SD cards, hard disks, a lot of sensors and what not). That said I have never seen one of these systems with enough memory to boot a recent Linux kernel. I think with the failure to push the kernel footprint down (due to lack of interest) they don't really have a future as Linux targets. They all run $small_os. Yours, Linus Walleij ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-09 16:17 ` Arnd Bergmann 2022-03-09 16:21 ` Vladimir Murzin @ 2022-03-10 1:22 ` Linus Walleij 2022-03-10 9:23 ` Arnd Bergmann 1 sibling, 1 reply; 14+ messages in thread From: Linus Walleij @ 2022-03-10 1:22 UTC (permalink / raw) To: Arnd Bergmann Cc: Robin Murphy, Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On Wed, Mar 9, 2022 at 5:17 PM Arnd Bergmann <arnd@kernel.org> wrote: > Robin > > In that case, it would probably make sense to garbage-collect all the > > configs, setup code and other stuff relating to older MMU-less CPU cores > > like ARM1156, ARM940, etc. at the same time. > > Right, good idea. These are only selected by CONFIG_ARCH_INTEGRATOR, > but that in turn doesn't build for CONFIG_MMU=n because it depends on > ARCH_MULTIPLATFORM. I'll send a patch for these. Just delete these, I do have these CPU tiles around but they are so obscure and I never got around to even testing to boot them. Yours, Linus Walleij ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-10 1:22 ` Linus Walleij @ 2022-03-10 9:23 ` Arnd Bergmann 2022-03-10 14:21 ` Robin Murphy 2022-03-14 23:00 ` Linus Walleij 0 siblings, 2 replies; 14+ messages in thread From: Arnd Bergmann @ 2022-03-10 9:23 UTC (permalink / raw) To: Linus Walleij Cc: Robin Murphy, Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On Thu, Mar 10, 2022 at 2:22 AM Linus Walleij <linus.walleij@linaro.org> wrote: > > On Wed, Mar 9, 2022 at 5:17 PM Arnd Bergmann <arnd@kernel.org> wrote: > > Robin > > > In that case, it would probably make sense to garbage-collect all the > > > configs, setup code and other stuff relating to older MMU-less CPU cores > > > like ARM1156, ARM940, etc. at the same time. > > > > Right, good idea. These are only selected by CONFIG_ARCH_INTEGRATOR, > > but that in turn doesn't build for CONFIG_MMU=n because it depends on > > ARCH_MULTIPLATFORM. I'll send a patch for these. > > Just delete these, I do have these CPU tiles around but they are so obscure > and I never got around to even testing to boot them. Right, of course you couldn't boot test them because it has been impossible to even select them in Kconfig for years. I've added a patch to completely remove the five v4/v5 NOMMU cores now, will send that later. There are five more cores that are only referenced by mach-integrator that are supposed to work (922T, 1020, 1020E, 1022, 1026). Have you ever tested those, or should we consider removing them as well? At some point, there was a proposal to add an arm10 based SoC to mainline, but that never happened and I'm fairly sure it won't come back now. Arnd ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-10 9:23 ` Arnd Bergmann @ 2022-03-10 14:21 ` Robin Murphy 2022-03-14 23:00 ` Linus Walleij 1 sibling, 0 replies; 14+ messages in thread From: Robin Murphy @ 2022-03-10 14:21 UTC (permalink / raw) To: Arnd Bergmann, Linus Walleij Cc: Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On 2022-03-10 09:23, Arnd Bergmann wrote: > On Thu, Mar 10, 2022 at 2:22 AM Linus Walleij <linus.walleij@linaro.org> wrote: >> >> On Wed, Mar 9, 2022 at 5:17 PM Arnd Bergmann <arnd@kernel.org> wrote: >>> Robin >>>> In that case, it would probably make sense to garbage-collect all the >>>> configs, setup code and other stuff relating to older MMU-less CPU cores >>>> like ARM1156, ARM940, etc. at the same time. >>> >>> Right, good idea. These are only selected by CONFIG_ARCH_INTEGRATOR, >>> but that in turn doesn't build for CONFIG_MMU=n because it depends on >>> ARCH_MULTIPLATFORM. I'll send a patch for these. >> >> Just delete these, I do have these CPU tiles around but they are so obscure >> and I never got around to even testing to boot them. > > Right, of course you couldn't boot test them because it has been > impossible to even select them in Kconfig for years. I've added > a patch to completely remove the five v4/v5 NOMMU cores now, > will send that later. > > There are five more cores that are only referenced by mach-integrator > that are supposed to work (922T, 1020, 1020E, 1022, 1026). Have you > ever tested those, or should we consider removing them as well? > > At some point, there was a proposal to add an arm10 based SoC > to mainline, but that never happened and I'm fairly sure it won't > come back now. FWIW I have an Integrator/CM1026 that I'd love to play with purely for giggles, but it needs some serious archaeology to find and flash some firmware for it first. I also have a couple of "real" ARM1026s in the form of Conexant Solos-based routers[1] which I've done a little hacking on, but don't see myself ever realistically having enough time or motivation to actually upstream anything. And at this point I don't see OpenWRT having any more interest in boards with only 15MB of RAM (yes, they really do boot with "mem=15M" to reserve 1MB for the modem...) Cheers, Robin. [1] https://openwrt.org/toh/linksys/wag54g2 ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-10 9:23 ` Arnd Bergmann 2022-03-10 14:21 ` Robin Murphy @ 2022-03-14 23:00 ` Linus Walleij 2022-03-15 7:27 ` Arnd Bergmann 1 sibling, 1 reply; 14+ messages in thread From: Linus Walleij @ 2022-03-14 23:00 UTC (permalink / raw) To: Arnd Bergmann Cc: Robin Murphy, Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On Thu, Mar 10, 2022 at 10:23 AM Arnd Bergmann <arnd@kernel.org> wrote: > On Thu, Mar 10, 2022 at 2:22 AM Linus Walleij <linus.walleij@linaro.org> wrote: > > Just delete these, I do have these CPU tiles around but they are so obscure > > and I never got around to even testing to boot them. > > Right, of course you couldn't boot test them because it has been > impossible to even select them in Kconfig for years. Correct, I mean never got around to the whole cycle of "let's make this thing boot" and then stumbling over things like that :D > I've added > a patch to completely remove the five v4/v5 NOMMU cores now, > will send that later. Excellent. > There are five more cores that are only referenced by mach-integrator > that are supposed to work (922T, 1020, 1020E, 1022, 1026). Have you > ever tested those, or should we consider removing them as well? Not the 10xx variants, but 920T and 922T I have tested and I still have the tiles, while my favourite tile that is usually fitted is ARM926EJ-S. Yours, Linus Walleij ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 2022-03-14 23:00 ` Linus Walleij @ 2022-03-15 7:27 ` Arnd Bergmann 0 siblings, 0 replies; 14+ messages in thread From: Arnd Bergmann @ 2022-03-15 7:27 UTC (permalink / raw) To: Linus Walleij Cc: Robin Murphy, Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, Linux ARM, Linux Kernel Mailing List, Russell King (Oracle), Anshuman Khandual On Tue, Mar 15, 2022 at 12:00 AM Linus Walleij <linus.walleij@linaro.org> wrote: > On Thu, Mar 10, 2022 at 10:23 AM Arnd Bergmann <arnd@kernel.org> wrote: > > On Thu, Mar 10, 2022 at 2:22 AM Linus Walleij <linus.walleij@linaro.org> wrote: > > > > Just delete these, I do have these CPU tiles around but they are so obscure > > > and I never got around to even testing to boot them. > > > > Right, of course you couldn't boot test them because it has been > > impossible to even select them in Kconfig for years. > > Correct, I mean never got around to the whole cycle of "let's make this > thing boot" and then stumbling over things like that :D > > > I've added > > a patch to completely remove the five v4/v5 NOMMU cores now, > > will send that later. > > Excellent. > > > There are five more cores that are only referenced by mach-integrator > > that are supposed to work (922T, 1020, 1020E, 1022, 1026). Have you > > ever tested those, or should we consider removing them as well? > > Not the 10xx variants, but 920T and 922T I have tested and I > still have the tiles, while my favourite tile that is usually fitted is > ARM926EJ-S. Ok, then I would suggest we keep 922t and 1026 (which Robin mentioned) but remove the others (1020,1020e, 1022). Arnd ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels 2022-03-09 14:40 [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels Arnd Bergmann 2022-03-09 14:40 ` [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 Arnd Bergmann @ 2022-03-10 1:19 ` Linus Walleij 2022-03-12 9:14 ` Ard Biesheuvel 2 siblings, 0 replies; 14+ messages in thread From: Linus Walleij @ 2022-03-10 1:19 UTC (permalink / raw) To: Arnd Bergmann Cc: Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Ard Biesheuvel, Andrew Morton, Mark Rutland, Vladimir Murzin, linux-arm-kernel, linux-kernel On Wed, Mar 9, 2022 at 3:41 PM Arnd Bergmann <arnd@kernel.org> wrote: > From: Arnd Bergmann <arnd@arndb.de> > > The removal of the old-style irq entry broke obscure NOMMU > configurations on machines that have an MMU: > > ld.lld: error: undefined symbol: generic_handle_arch_irq > referenced by kernel/entry-armv.o:(__irq_svc) in archive arch/arm/built-in.a > > A follow-up patch to convert nvic to the generic_handle_arch_irq() > could have fixed this by removing the Kconfig conditional, but did > it differently. > > Change the Kconfig logic so ARM machines now unconditionally > enable the feature. > > I have also submitted a patch to remove support for the configurations > that broke, but fixing the regression first is a trivial and correct > change. > > Reported-by: kernel test robot <lkp@intel.com> > Fixes: 54f481a2308e ("ARM: remove old-style irq entry") > Fixes: 52d240871760 ("irqchip: nvic: Use GENERIC_IRQ_MULTI_HANDLER") > Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Thanks for fixing this so quickly! Yours, Linus Walleij ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels 2022-03-09 14:40 [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels Arnd Bergmann 2022-03-09 14:40 ` [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 Arnd Bergmann 2022-03-10 1:19 ` [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels Linus Walleij @ 2022-03-12 9:14 ` Ard Biesheuvel 2 siblings, 0 replies; 14+ messages in thread From: Ard Biesheuvel @ 2022-03-12 9:14 UTC (permalink / raw) To: Arnd Bergmann Cc: Russell King, Arnd Bergmann, kernel test robot, Thomas Gleixner, Marc Zyngier, Linus Walleij, Andrew Morton, Mark Rutland, Vladimir Murzin, Linux ARM, Linux Kernel Mailing List On Wed, 9 Mar 2022 at 15:41, Arnd Bergmann <arnd@kernel.org> wrote: > > From: Arnd Bergmann <arnd@arndb.de> > > The removal of the old-style irq entry broke obscure NOMMU > configurations on machines that have an MMU: > > ld.lld: error: undefined symbol: generic_handle_arch_irq > referenced by kernel/entry-armv.o:(__irq_svc) in archive arch/arm/built-in.a > > A follow-up patch to convert nvic to the generic_handle_arch_irq() > could have fixed this by removing the Kconfig conditional, but did > it differently. > > Change the Kconfig logic so ARM machines now unconditionally > enable the feature. > > I have also submitted a patch to remove support for the configurations > that broke, but fixing the regression first is a trivial and correct > change. > > Reported-by: kernel test robot <lkp@intel.com> > Fixes: 54f481a2308e ("ARM: remove old-style irq entry") > Fixes: 52d240871760 ("irqchip: nvic: Use GENERIC_IRQ_MULTI_HANDLER") > Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reviewed by: Ard Biesheuvel <ardb@kernel.org> > --- > This patch should go into the arm/devel-stable branch that has > the arm-irq-and-vmap-stacks-for-rmk patches from Ard > --- > arch/arm/Kconfig | 2 +- > drivers/irqchip/Kconfig | 1 - > 2 files changed, 1 insertion(+), 2 deletions(-) > > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig > index e9975ddd5034..5f0b40bab4fb 100644 > --- a/arch/arm/Kconfig > +++ b/arch/arm/Kconfig > @@ -60,7 +60,7 @@ config ARM > select GENERIC_CPU_AUTOPROBE > select GENERIC_EARLY_IOREMAP > select GENERIC_IDLE_POLL_SETUP > - select GENERIC_IRQ_MULTI_HANDLER if MMU > + select GENERIC_IRQ_MULTI_HANDLER > select GENERIC_IRQ_PROBE > select GENERIC_IRQ_SHOW > select GENERIC_IRQ_SHOW_LEVEL > diff --git a/drivers/irqchip/Kconfig b/drivers/irqchip/Kconfig > index 488eaa14d3a7..7038957f4a77 100644 > --- a/drivers/irqchip/Kconfig > +++ b/drivers/irqchip/Kconfig > @@ -58,7 +58,6 @@ config ARM_NVIC > bool > select IRQ_DOMAIN_HIERARCHY > select GENERIC_IRQ_CHIP > - select GENERIC_IRQ_MULTI_HANDLER > > config ARM_VIC > bool > -- > 2.29.2 > ^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2022-03-15 7:28 UTC | newest] Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2022-03-09 14:40 [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels Arnd Bergmann 2022-03-09 14:40 ` [PATCH 2/2] ARM: remove support for NOMMU ARMv4/v5 Arnd Bergmann 2022-03-09 15:48 ` Robin Murphy 2022-03-09 16:17 ` Arnd Bergmann 2022-03-09 16:21 ` Vladimir Murzin 2022-03-09 16:38 ` Arnd Bergmann 2022-03-10 1:29 ` Linus Walleij 2022-03-10 1:22 ` Linus Walleij 2022-03-10 9:23 ` Arnd Bergmann 2022-03-10 14:21 ` Robin Murphy 2022-03-14 23:00 ` Linus Walleij 2022-03-15 7:27 ` Arnd Bergmann 2022-03-10 1:19 ` [PATCH 1/2] ARM: fix building NOMMU ARMv4/v5 kernels Linus Walleij 2022-03-12 9:14 ` Ard Biesheuvel
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).