From patchwork Thu Aug 18 14:56:12 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 12947262 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 72674C00140 for ; Thu, 18 Aug 2022 14:59:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ZWL1r9Q35Xzh0MbHu4rlPbt7qwSCmJeTdE+gGFBdnZc=; b=xft3RWyR0DaE3z XLua88uE3u5WDAP2kfUhiPBFwfZwgzhm/trpG/7PIulmi8NmeI60zBeZH8UkHitsr7LYmSCM9gDPk Eb6Uivb6pZu05KVzKrFbkwco0jOKWjn3c11JPS9Cg7rz162+YDjIfeTDzvldaWlsuQP+jbUFaa7VN SksIi0o/lQEjVfS7/MDIG3audpV9IFgdKSJI1QigtFSbJwm6wplyulsTAf1E2/FTIWQzG0A6i7bxL 01yRiX+o69cyjsmZsyapGPHTTCLkKbDnhsvZ3VQP2C9rp5/+FnZiZ8+aJ3dVw19hgN/P95E/VbATA UpS+S5suPSZknU5Tw6Dw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgxw-006LGH-Ku; Thu, 18 Aug 2022 14:57:49 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgwp-006KZS-7C for linux-arm-kernel@lists.infradead.org; Thu, 18 Aug 2022 14:56:42 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id A97226131C; Thu, 18 Aug 2022 14:56:38 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C9317C433D6; Thu, 18 Aug 2022 14:56:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1660834598; bh=8EZFeDNWmKrvsacQqIwuZ/oUAfUGitD4UpNlh/cjBZA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=gJMiWOYBXDYqg3yoM2J1o/Qfvt2yTaRYNdhnpS55u+9zO54jW+Hks7Jl/f7Ni5S0+ ksaATPcDLR6+nSAG8AfTUiDnQ4bUwn3vIAf3VqFJuVYir33wQGgy6cd8paTLBhUI0/ GXvyxWOfftXEX2vYvhs1+S1Vngml7fqDzguZMcnagKsi/63Rph9ipVIgz4FxQ8Ou8T O46j7a+bKGjsIlVouXMo+3uftRA74kfYWkS2Hm46/Y3Qo2KeuYC/JzwP9+O8Hr6IZ7 xJSt1a6W2P/nGLEOyLzO4PGj3jK38J+G5a9zv7CRJxS9+0Oi3Zq9ansSTvDIuDGD5L AsHVJbA6Ubc7Q== From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, Arnd Bergmann , Russell King , Linus Walleij , Geert Uytterhoeven , Krzysztof Kozlowski , Ard Biesheuvel , Sekhar Nori , Bartosz Golaszewski , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth Subject: [PATCH 1/5] ARM: remove obsolete Makefile.boot infrastructure Date: Thu, 18 Aug 2022 16:56:12 +0200 Message-Id: <20220818145616.3156379-2-arnd@kernel.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20220818145616.3156379-1-arnd@kernel.org> References: <20220818145616.3156379-1-arnd@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220818_075639_440317_77B65468 X-CRM114-Status: GOOD ( 24.52 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Arnd Bergmann There are a number of old Makefile.boot files that remain from the multiplatform conversion, and three that are still in use. These provide the "ZRELADDR", "PARAMS_PHYS" and "INITRD_PHYS" values that are platform specific. It turns out that we can generally just derive this from information that is available elsewhere: - ZRELADDR is normally detected at runtime with the CONFIG_AUTO_ZRELADDR flag, but also needed to be passed to for 'make uImage'. In a multiplatform kernel, one always has to pass this as the $(LOADADDR) variable, but in the StrongARM kernels we can derive it from the sum of $(CONFIG_PHYS_OFFSET) and $(TEXT_OFFSET) that are already known. - PARAMS_PHYS and INITRD_PHYS are only used for bootpImage, which in turn is only used for the pre-ATAGS 'param_struct' based boot interface on StrongARM based machines with old boot loaders. They can both be derived from CONFIG_PHYS_OFFSET and a machine specific offset for the initrd, so all of the logic for these can be part of arch/arm/boot/bootp/Makefile. Signed-off-by: Arnd Bergmann Acked-by: Krzysztof Kozlowski # s3c --- arch/arm/Kconfig | 2 +- arch/arm/Makefile | 4 +-- arch/arm/boot/Makefile | 27 ++++++-------------- arch/arm/boot/bootp/Makefile | 35 ++++++++++++++++++++++++-- arch/arm/mach-at91/Makefile.boot | 4 --- arch/arm/mach-davinci/Makefile.boot | 8 ------ arch/arm/mach-dove/Makefile.boot | 4 --- arch/arm/mach-ep93xx/Makefile.boot | 2 -- arch/arm/mach-footbridge/Makefile.boot | 5 ---- arch/arm/mach-imx/Makefile.boot | 0 arch/arm/mach-iop32x/Makefile.boot | 4 --- arch/arm/mach-lpc18xx/Makefile.boot | 4 --- arch/arm/mach-lpc32xx/Makefile.boot | 4 --- arch/arm/mach-omap1/Makefile.boot | 4 --- arch/arm/mach-rpc/Makefile.boot | 5 ---- arch/arm/mach-s3c/Makefile.boot | 9 ------- arch/arm/mach-sa1100/Makefile.boot | 9 ------- arch/arm/mach-stm32/Makefile.boot | 4 --- arch/arm/mach-versatile/Makefile.boot | 4 --- arch/arm/mach-vt8500/Makefile.boot | 4 --- 20 files changed, 43 insertions(+), 99 deletions(-) delete mode 100644 arch/arm/mach-at91/Makefile.boot delete mode 100644 arch/arm/mach-davinci/Makefile.boot delete mode 100644 arch/arm/mach-dove/Makefile.boot delete mode 100644 arch/arm/mach-ep93xx/Makefile.boot delete mode 100644 arch/arm/mach-footbridge/Makefile.boot delete mode 100644 arch/arm/mach-imx/Makefile.boot delete mode 100644 arch/arm/mach-iop32x/Makefile.boot delete mode 100644 arch/arm/mach-lpc18xx/Makefile.boot delete mode 100644 arch/arm/mach-lpc32xx/Makefile.boot delete mode 100644 arch/arm/mach-omap1/Makefile.boot delete mode 100644 arch/arm/mach-rpc/Makefile.boot delete mode 100644 arch/arm/mach-s3c/Makefile.boot delete mode 100644 arch/arm/mach-sa1100/Makefile.boot delete mode 100644 arch/arm/mach-stm32/Makefile.boot delete mode 100644 arch/arm/mach-versatile/Makefile.boot delete mode 100644 arch/arm/mach-vt8500/Makefile.boot diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 87badeae3181..6894b4758bfb 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -274,7 +274,7 @@ config NEED_MACH_MEMORY_H config PHYS_OFFSET hex "Physical address of main memory" if MMU - depends on !ARM_PATCH_PHYS_VIRT + depends on !ARM_PATCH_PHYS_VIRT || !AUTO_ZRELADDR default DRAM_BASE if !MMU default 0x00000000 if ARCH_FOOTBRIDGE default 0x10000000 if ARCH_OMAP1 || ARCH_RPC diff --git a/arch/arm/Makefile b/arch/arm/Makefile index 56f655deebb1..369490d5f18a 100644 --- a/arch/arm/Makefile +++ b/arch/arm/Makefile @@ -310,7 +310,7 @@ bootpImage uImage: zImage zImage: Image $(BOOT_TARGETS): vmlinux - $(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $(boot)/$@ + $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ @$(kecho) ' Kernel: $(boot)/$@ is ready' $(INSTALL_TARGETS): KBUILD_IMAGE = $(boot)/$(patsubst %install,%Image,$@) @@ -324,7 +324,7 @@ ifeq ($(CONFIG_VDSO),y) endif # My testing targets (bypasses dependencies) -bp:; $(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $(boot)/bootpImage +bp:; $(Q)$(MAKE) $(build)=$(boot) $(boot)/bootpImage define archhelp diff --git a/arch/arm/boot/Makefile b/arch/arm/boot/Makefile index 54a09f9464fb..abd6a2889fd0 100644 --- a/arch/arm/boot/Makefile +++ b/arch/arm/boot/Makefile @@ -10,22 +10,16 @@ # # Copyright (C) 1995-2002 Russell King # - OBJCOPYFLAGS :=-O binary -R .comment -S -ifneq ($(MACHINE),) -include $(MACHINE)/Makefile.boot -endif - -# Note: the following conditions must always be true: # ZRELADDR == virt_to_phys(PAGE_OFFSET + TEXT_OFFSET) -# PARAMS_PHYS must be within 4MB of ZRELADDR -# INITRD_PHYS must be in RAM -ZRELADDR := $(zreladdr-y) -PARAMS_PHYS := $(params_phys-y) -INITRD_PHYS := $(initrd_phys-y) +ifdef CONFIG_PHYS_OFFSET +add_hex = $(shell printf 0x%x $$(( $(1) + $(2) )) ) +ZRELADDR := $(call add_hex, $(CONFIG_PHYS_OFFSET), $(TEXT_OFFSET)) +endif -export ZRELADDR INITRD_PHYS PARAMS_PHYS +PHYS_OFFSET := $(CONFIG_PHYS_OFFSET) +export ZRELADDR PARAMS_PHYS PHYS_OFFSET targets := Image zImage xipImage bootpImage uImage @@ -90,17 +84,10 @@ $(obj)/uImage: $(obj)/zImage FORCE @$(check_for_multiple_loadaddr) $(call if_changed,uimage) -$(obj)/bootp/bootp: $(obj)/zImage initrd FORCE +$(obj)/bootp/bootp: $(obj)/zImage FORCE $(Q)$(MAKE) $(build)=$(obj)/bootp $@ $(obj)/bootpImage: $(obj)/bootp/bootp FORCE $(call if_changed,objcopy) -PHONY += initrd -initrd: - @test "$(INITRD_PHYS)" != "" || \ - (echo This machine does not support INITRD; exit -1) - @test "$(INITRD)" != "" || \ - (echo You must specify INITRD; exit -1) - subdir- := bootp compressed dts diff --git a/arch/arm/boot/bootp/Makefile b/arch/arm/boot/bootp/Makefile index 981a8d03f064..a2934e6fd89a 100644 --- a/arch/arm/boot/bootp/Makefile +++ b/arch/arm/boot/bootp/Makefile @@ -5,9 +5,40 @@ # This file is included by the global makefile so that you can add your own # architecture-specific flags and dependencies. # - GCOV_PROFILE := n +ifdef PHYS_OFFSET +add_hex = $(shell printf 0x%x $$(( $(1) + $(2) )) ) + +# If PHYS_OFFSET is set, INITRD_PHYS and PARAMS_PHYS can be derived, +# otherwise they must be passed on the command line. +# +# Note: the following conditions must always be true: +# PARAMS_PHYS must be within 4MB of ZRELADDR +# INITRD_PHYS must be in RAM + +PARAMS_PHYS := $(call add_hex, $(PHYS_OFFSET), 0x100) + +# guess an initrd location if possible +initrd_offset-$(CONFIG_ARCH_FOOTBRIDGE) += 0x00800000 +initrd_offset-$(CONFIG_ARCH_SA1100) += 0x00800000 +initrd_offset-$(CONFIG_ARCH_RPC) += 0x08000000 +INITRD_OFFSET := $(initrd_offset-y) +ifdef INITRD_OFFSET +INITRD_PHYS := $(call add_hex, $(PHYS_OFFSET), $(INITRD_OFFSET)) +endif + +endif + +PHONY += initrd +initrd: + @test "$(PARAMS_PHYS)" != "" || \ + (echo bootpImage: You must specify PHYS_OFFSET of PARAMS_PHYS ; exit -1) + @test "$(INITRD_PHYS)" != "" || \ + (echo bootpImage: You must specify INITRD_OFFSET or INITRD_PHYS ; exit -1) + @test "$(INITRD)" != "" || \ + (echo bootpImage: You must specify INITRD; exit -1) + LDFLAGS_bootp := --no-undefined -X \ --defsym initrd_phys=$(INITRD_PHYS) \ --defsym params_phys=$(PARAMS_PHYS) -T @@ -24,6 +55,6 @@ $(obj)/bootp: $(src)/bootp.lds $(addprefix $(obj)/,init.o kernel.o initrd.o) FOR $(obj)/kernel.o: arch/arm/boot/zImage FORCE -$(obj)/initrd.o: $(INITRD) FORCE +$(obj)/initrd.o: initrd $(INITRD) FORCE PHONY += $(INITRD) diff --git a/arch/arm/mach-at91/Makefile.boot b/arch/arm/mach-at91/Makefile.boot deleted file mode 100644 index 5dde7328a7a9..000000000000 --- a/arch/arm/mach-at91/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only -# Empty file waiting for deletion once Makefile.boot isn't needed any more. -# Patch waits for application at -# https://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=7889/1 . diff --git a/arch/arm/mach-davinci/Makefile.boot b/arch/arm/mach-davinci/Makefile.boot deleted file mode 100644 index d36b251f325b..000000000000 --- a/arch/arm/mach-davinci/Makefile.boot +++ /dev/null @@ -1,8 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 -zreladdr-$(CONFIG_ARCH_DAVINCI_DA8XX) += 0xc0008000 -params_phys-$(CONFIG_ARCH_DAVINCI_DA8XX) := 0xc0000100 -initrd_phys-$(CONFIG_ARCH_DAVINCI_DA8XX) := 0xc0800000 - -zreladdr-$(CONFIG_ARCH_DAVINCI_DMx) += 0x80008000 -params_phys-$(CONFIG_ARCH_DAVINCI_DMx) := 0x80000100 -initrd_phys-$(CONFIG_ARCH_DAVINCI_DMx) := 0x80800000 diff --git a/arch/arm/mach-dove/Makefile.boot b/arch/arm/mach-dove/Makefile.boot deleted file mode 100644 index e4dd1d26038f..000000000000 --- a/arch/arm/mach-dove/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only - zreladdr-y += 0x00008000 -params_phys-y := 0x00000100 -initrd_phys-y := 0x00800000 diff --git a/arch/arm/mach-ep93xx/Makefile.boot b/arch/arm/mach-ep93xx/Makefile.boot deleted file mode 100644 index 4c0a039a5027..000000000000 --- a/arch/arm/mach-ep93xx/Makefile.boot +++ /dev/null @@ -1,2 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only -# Empty file waiting for deletion once Makefile.boot isn't needed any more. diff --git a/arch/arm/mach-footbridge/Makefile.boot b/arch/arm/mach-footbridge/Makefile.boot deleted file mode 100644 index e4313e912cac..000000000000 --- a/arch/arm/mach-footbridge/Makefile.boot +++ /dev/null @@ -1,5 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only - zreladdr-y += 0x00008000 -params_phys-y := 0x00000100 -initrd_phys-y := 0x00800000 - diff --git a/arch/arm/mach-imx/Makefile.boot b/arch/arm/mach-imx/Makefile.boot deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/arch/arm/mach-iop32x/Makefile.boot b/arch/arm/mach-iop32x/Makefile.boot deleted file mode 100644 index 5c3af01c4000..000000000000 --- a/arch/arm/mach-iop32x/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only - zreladdr-y += 0xa0008000 -params_phys-y := 0xa0000100 -initrd_phys-y := 0xa0800000 diff --git a/arch/arm/mach-lpc18xx/Makefile.boot b/arch/arm/mach-lpc18xx/Makefile.boot deleted file mode 100644 index cec195d4fcba..000000000000 --- a/arch/arm/mach-lpc18xx/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only -# Empty file waiting for deletion once Makefile.boot isn't needed any more. -# Patch waits for application at -# http://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=7889/1 . diff --git a/arch/arm/mach-lpc32xx/Makefile.boot b/arch/arm/mach-lpc32xx/Makefile.boot deleted file mode 100644 index 37d09ddb27f8..000000000000 --- a/arch/arm/mach-lpc32xx/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only - zreladdr-y += 0x80008000 -params_phys-y := 0x80000100 -initrd_phys-y := 0x82000000 diff --git a/arch/arm/mach-omap1/Makefile.boot b/arch/arm/mach-omap1/Makefile.boot deleted file mode 100644 index 2c771515a606..000000000000 --- a/arch/arm/mach-omap1/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only - zreladdr-y += 0x10008000 -params_phys-y := 0x10000100 -initrd_phys-y := 0x10800000 diff --git a/arch/arm/mach-rpc/Makefile.boot b/arch/arm/mach-rpc/Makefile.boot deleted file mode 100644 index 0ed8e8fbde99..000000000000 --- a/arch/arm/mach-rpc/Makefile.boot +++ /dev/null @@ -1,5 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only - zreladdr-y += 0x10008000 -params_phys-y := 0x10000100 -initrd_phys-y := 0x18000000 - diff --git a/arch/arm/mach-s3c/Makefile.boot b/arch/arm/mach-s3c/Makefile.boot deleted file mode 100644 index 7f19e226035e..000000000000 --- a/arch/arm/mach-s3c/Makefile.boot +++ /dev/null @@ -1,9 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0 - -ifeq ($(CONFIG_PM_H1940),y) - zreladdr-y += 0x30108000 - params_phys-y := 0x30100100 -else - zreladdr-y += 0x30008000 - params_phys-y := 0x30000100 -endif diff --git a/arch/arm/mach-sa1100/Makefile.boot b/arch/arm/mach-sa1100/Makefile.boot deleted file mode 100644 index 9d8246f2cab4..000000000000 --- a/arch/arm/mach-sa1100/Makefile.boot +++ /dev/null @@ -1,9 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only -ifeq ($(CONFIG_SA1111),y) - zreladdr-y += 0xc0208000 -else - zreladdr-y += 0xc0008000 -endif -params_phys-y := 0xc0000100 -initrd_phys-y := 0xc0800000 - diff --git a/arch/arm/mach-stm32/Makefile.boot b/arch/arm/mach-stm32/Makefile.boot deleted file mode 100644 index 5dde7328a7a9..000000000000 --- a/arch/arm/mach-stm32/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only -# Empty file waiting for deletion once Makefile.boot isn't needed any more. -# Patch waits for application at -# https://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=7889/1 . diff --git a/arch/arm/mach-versatile/Makefile.boot b/arch/arm/mach-versatile/Makefile.boot deleted file mode 100644 index cec195d4fcba..000000000000 --- a/arch/arm/mach-versatile/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only -# Empty file waiting for deletion once Makefile.boot isn't needed any more. -# Patch waits for application at -# http://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=7889/1 . diff --git a/arch/arm/mach-vt8500/Makefile.boot b/arch/arm/mach-vt8500/Makefile.boot deleted file mode 100644 index 883985f4b6c1..000000000000 --- a/arch/arm/mach-vt8500/Makefile.boot +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-only - zreladdr-y += 0x00008000 -params_phys-y := 0x00000100 -initrd_phys-y := 0x01000000 From patchwork Thu Aug 18 14:56:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 12947263 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6A15CC00140 for ; Thu, 18 Aug 2022 14:59:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=LzwY9fJLQoQiV9vZXs9GAPIRoJ2DH0mDqaWsBm1yDOk=; b=k1gFJQMivoYQXz C9jIKWlyFpTAXIflJ25eNVbiLM71PA6zp3YVXaXYt+BpI6ep0aophMFOfkv4Z6R5PGzJJJtgli84X h7GYPQGGcGOolS8d/rFpz56F0pXwOR+AZWlvqBcCSMc/pgm4v/anGo6M1o90+BdI7cpOKAJeUQxQr zgRIo4o1OgqCh6pyZxOkpxSofWUnaaWPZpgY5QI8TUw1m5UdTmZFORO4QZXXzervLmvM1lNwbsvHD 89fU2VDKskvjaiOA/8dtAYxpv7wekJzeResVQRPooolceyfxYCIO0BkA9OwsELWl9RtdULzqraqro QgQ1bj8FIxfIMMX4sy9g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgyk-006Lg0-Hn; Thu, 18 Aug 2022 14:58:39 +0000 Received: from ams.source.kernel.org ([2604:1380:4601:e00::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgwv-006Kbw-LF for linux-arm-kernel@lists.infradead.org; Thu, 18 Aug 2022 14:56:47 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 2C0F8B821C8; Thu, 18 Aug 2022 14:56:44 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 92F33C433C1; Thu, 18 Aug 2022 14:56:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1660834601; bh=mtTReuzBuhhaSHPjJxbyPhffXjHDxEYyfjlRUGyAxjE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Cgbc8jG5hSZ/+L6U1fhAkVcOG0njXZcSzWxm9FClB55jk9ro16GAyk5mPoZRtc0b+ iyiiTmdaOF+38CYFuyZ55PdPBkylw+DDbJivQKmDISta/vYDnt0xB6muNUl3Q1/6Kc Jqgzn7IBPIzbRAQ7MTJ0DCEfEFoChhlasZGSND9yxqhJ2YgNJSVD0DBiEEjgRDbAwt sGUm6a1ooH+MqCYrhNcMrK0wTriGDKAkX2aiX9MaZMs/9fWB+n/3P/zN1jpJCn15lF 4dPFz+Id5xcJuVBPP+5WiybLKeUN5bAebSGXSkc3w9DSuhypPgRAFYq8tFZofRQ1G4 STr6PmUCp6ORw== From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, Arnd Bergmann , Russell King , Linus Walleij , Geert Uytterhoeven , Krzysztof Kozlowski , Ard Biesheuvel , Sekhar Nori , Bartosz Golaszewski , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth Subject: [PATCH 2/5] ARM: simplify machdirs/platdirs handling Date: Thu, 18 Aug 2022 16:56:13 +0200 Message-Id: <20220818145616.3156379-3-arnd@kernel.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20220818145616.3156379-1-arnd@kernel.org> References: <20220818145616.3156379-1-arnd@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220818_075646_070485_C63FF6ED X-CRM114-Status: GOOD ( 13.95 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Arnd Bergmann There is only one plat-* directory left, and the MACHINE variable is only used for the mach/*.h header path. Simplify this by removing the checks for ARCH_MULTIPLATFORM and ARM_SINGLE_ARMV7M, and just adding the include directories for the remaining three platforms manually. Signed-off-by: Arnd Bergmann --- arch/arm/Makefile | 36 ++++++++++-------------------------- 1 file changed, 10 insertions(+), 26 deletions(-) diff --git a/arch/arm/Makefile b/arch/arm/Makefile index 369490d5f18a..2623d6e25bdb 100644 --- a/arch/arm/Makefile +++ b/arch/arm/Makefile @@ -224,40 +224,24 @@ machine-$(CONFIG_ARCH_ZYNQ) += zynq machine-$(CONFIG_PLAT_VERSATILE) += versatile machine-$(CONFIG_PLAT_SPEAR) += spear -# Platform directory name. This list is sorted alphanumerically -# by CONFIG_* macro name. -plat-$(CONFIG_PLAT_ORION) += orion +# legacy platforms provide their own mach/*.h headers globally, +# these three are mutually exclusive +machdirs-$(CONFIG_ARCH_FOOTBRIDGE) += arch/arm/mach-footbridge +machdirs-$(CONFIG_ARCH_RPC) += arch/arm/mach-rpc +machdirs-$(CONFIG_ARCH_SA1100) += arch/arm/mach-sa1100 +KBUILD_CPPFLAGS += $(patsubst %,-I$(srctree)/%/include,$(machdirs-y)) # The byte offset of the kernel image in RAM from the start of RAM. TEXT_OFFSET := $(textofs-y) -# The first directory contains additional information for the boot setup code -ifneq ($(machine-y),) -MACHINE := arch/arm/mach-$(word 1,$(machine-y))/ -else -MACHINE := -endif -ifeq ($(CONFIG_ARCH_MULTIPLATFORM),y) -MACHINE := -endif - -machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y)) -platdirs := $(patsubst %,arch/arm/plat-%/,$(sort $(plat-y))) - -ifneq ($(CONFIG_ARCH_MULTIPLATFORM),y) -ifneq ($(CONFIG_ARM_SINGLE_ARMV7M),y) -KBUILD_CPPFLAGS += $(patsubst %,-I$(srctree)/%include,$(machdirs) $(platdirs)) -endif -endif - export TEXT_OFFSET GZFLAGS MMUEXT # If we have a machine-specific directory, then include it in the build. -core-y += $(machdirs) $(platdirs) - +core-y += $(patsubst %,arch/arm/mach-%/,$(machine-y)) # For cleaning -core- += $(patsubst %,arch/arm/mach-%/, $(machine-)) -core- += $(patsubst %,arch/arm/plat-%/, $(plat-)) +core- += $(patsubst %,arch/arm/mach-%/,$(machine-)) + +core-$(CONFIG_PLAT_ORION) += arch/arm/plat-orion/ libs-y := arch/arm/lib/ $(libs-y) From patchwork Thu Aug 18 14:56:14 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 12947264 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 62E5CC2BB41 for ; Thu, 18 Aug 2022 15:00:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=jBa/SGqxxYFyfWIz+Ab6NZ7tKUY/C3j8SAUDhp/r/vQ=; b=V6agRgXSbQUr7D DPfokCCMEGvZZcXp5QenuPB1Eey3d5Q2I6GNww7/rZ49YU2vz2K9nP1hO5l7rxwowS7Z1zgHKAaR0 U8YOBtSZETJUDJhJ1ygQ9EemrTHdQ1IJo/lOW2TZ7PczRKSre701NR/VIsGEmjTXmwmbk4cx1eFpb BB0M8vAsjSSnLDYsK4z8MOaYqkL2hGaj8DBN+oP5bUpWKViekpAxddYNc88oQXZIenTfkesO96CUg s6MAODzVe2/R1dZt7D4LSDTn/6i3x9gMqk69s2xIqZnODqnTnKM5/CRWc1eGGHRYps0iv93WG81jc LK2+Rrv+wqoYIUgKYSTg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgza-006M4i-5N; Thu, 18 Aug 2022 14:59:30 +0000 Received: from ams.source.kernel.org ([2604:1380:4601:e00::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgwy-006Kee-Qa for linux-arm-kernel@lists.infradead.org; Thu, 18 Aug 2022 14:56:51 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 10C97B821C6; Thu, 18 Aug 2022 14:56:47 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5AC7BC43142; Thu, 18 Aug 2022 14:56:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1660834605; bh=gXkTI0r2TAql0FBkVhgbbck3bOmCndCtXNOnUhl0JeQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=MXzui0ohxXPCEvKzLE0zGZNn9zdv01Tuh+1/dRp9oDwGyJRr89zhfUeaPrFFa2aqX vdiP1bKIsIpgXP3QEmMVd4tIk3jXuuCx73toV4ulqJ2wgL1PPa3rBhMwQ9q7Pu5z/k YpyAJOjrXRjL9J4VwJ0rzY/G9WqnspjVt8vRDtnf3QAEBN2pxJ0zG0bUL9Rx4CvbHj A3IzSS1Iv82hSIs5VO9maO9rc7g20ZZEOE/2ROq8ueJ60Rer6IuHC3tbP+Pnb/bQ8s Gxj3hdi4jlpdRRmynT8FlA32yZY6OC2SvoZWSRlf/T6nWNIWrXj0WZ+uRa5EY/u0Qn hsdgKn6CAwmgA== From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, Arnd Bergmann , Russell King , Linus Walleij , Geert Uytterhoeven , Krzysztof Kozlowski , Ard Biesheuvel , Sekhar Nori , Bartosz Golaszewski , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth Subject: [PATCH 3/5] ARM: Kconfig: clean up platform selection Date: Thu, 18 Aug 2022 16:56:14 +0200 Message-Id: <20220818145616.3156379-4-arnd@kernel.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20220818145616.3156379-1-arnd@kernel.org> References: <20220818145616.3156379-1-arnd@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220818_075649_222406_CCB24F92 X-CRM114-Status: GOOD ( 21.40 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Arnd Bergmann The top-level platform selection is mostly meaningless these days after almost everything is sorted below the CONFIG_ARCH_MULTIPLATFORM, with the only exception being the 20+ year old StrongARM based machines. Make this more consistent by removing the entire choice statement and moving the StrongARM specific options into regular platform specific Kconfig files. The three platforms (footbridge, rpc and sa1100) are still mutually exclusive and cannot coexist with other ARMv4/v5 machines, but since there are only three of them and we will not add more, this can be expressed using Kconfig 'depends on' statements. Signed-off-by: Arnd Bergmann --- arch/arm/Kconfig | 114 ++++---------------------- arch/arm/Kconfig.debug | 7 +- arch/arm/configs/assabet_defconfig | 2 + arch/arm/configs/badge4_defconfig | 2 + arch/arm/configs/cerfcube_defconfig | 2 + arch/arm/configs/collie_defconfig | 2 + arch/arm/configs/footbridge_defconfig | 2 + arch/arm/configs/h3600_defconfig | 2 + arch/arm/configs/hackkit_defconfig | 2 + arch/arm/configs/jornada720_defconfig | 2 + arch/arm/configs/lart_defconfig | 2 + arch/arm/configs/neponset_defconfig | 2 + arch/arm/configs/netwinder_defconfig | 2 + arch/arm/configs/pleb_defconfig | 2 + arch/arm/configs/rpc_defconfig | 2 + arch/arm/configs/shannon_defconfig | 2 + arch/arm/configs/simpad_defconfig | 2 + arch/arm/mach-footbridge/Kconfig | 19 ++++- arch/arm/mach-imx/Kconfig | 2 +- arch/arm/mach-nspire/Kconfig | 2 +- arch/arm/mach-rpc/Kconfig | 21 +++++ arch/arm/mach-sa1100/Kconfig | 25 ++++-- 22 files changed, 109 insertions(+), 111 deletions(-) create mode 100644 arch/arm/mach-rpc/Kconfig diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 6894b4758bfb..3066ce82cffc 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -28,7 +28,6 @@ config ARM select ARCH_HAS_GCOV_PROFILE_ALL select ARCH_KEEP_MEMBLOCK select ARCH_MIGHT_HAVE_PC_PARPORT - select ARCH_NO_SG_CHAIN if !ARM_HAS_SG_CHAIN select ARCH_OPTIONAL_KERNEL_RWX if ARCH_HAS_STRICT_KERNEL_RWX select ARCH_OPTIONAL_KERNEL_RWX_DEFAULT if CPU_V7 select ARCH_SUPPORTS_ATOMIC_RMW @@ -42,6 +41,7 @@ config ARM select ARCH_WANT_LD_ORPHAN_WARN select BINFMT_FLAT_ARGVP_ENVP_ON_STACK select BUILDTIME_TABLE_SORT if MMU + select COMMON_CLK if !(ARCH_RPC || ARCH_FOOTBRIDGE) select CLONE_BACKWARDS select CPU_PM if SUSPEND || CPU_IDLE select DCACHE_WORD_ACCESS if HAVE_EFFICIENT_UNALIGNED_ACCESS @@ -110,6 +110,7 @@ config ARM select HAVE_MOD_ARCH_SPECIFIC select HAVE_NMI select HAVE_OPTPROBES if !THUMB2_KERNEL + select HAVE_PCI select HAVE_PERF_EVENTS select HAVE_PERF_REGS select HAVE_PERF_USER_STACK_DUMP @@ -126,13 +127,17 @@ config ARM select OF_EARLY_FLATTREE if OF select OLD_SIGACTION select OLD_SIGSUSPEND3 + select PCI_DOMAINS_GENERIC if PCI select PCI_SYSCALL if PCI select PERF_USE_VMALLOC select RTC_LIB + select SPARSE_IRQ if !(ARCH_FOOTBRIDGE || ARCH_RPC) select SYS_SUPPORTS_APM_EMULATION select THREAD_INFO_IN_TASK + select TIMER_OF if OF select HAVE_ARCH_VMAP_STACK if MMU && ARM_HAS_GROUP_RELOCS select TRACE_IRQFLAGS_SUPPORT if !CPU_V7M + select USE_OF if !(ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100) # Above selects are sorted alphabetically; please add new ones # according to that. Thanks. help @@ -154,12 +159,8 @@ config ARM_HAS_GROUP_RELOCS which is usually sufficient, but not for allyesconfig, so we disable this feature when doing compile testing. -config ARM_HAS_SG_CHAIN - bool - config ARM_DMA_USE_IOMMU bool - select ARM_HAS_SG_CHAIN select NEED_SG_DMA_LENGTH if ARM_DMA_USE_IOMMU @@ -307,13 +308,8 @@ config MMU 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 @@ -323,94 +319,19 @@ config ARCH_MMAP_RND_BITS_MAX default 15 if PAGE_OFFSET=0x80000000 default 16 -# -# The "ARM system type" choice list is ordered alphabetically by option -# text. Please add new entries in the option alphabetic order. -# -choice - prompt "ARM system type" - depends on MMU - default ARCH_MULTIPLATFORM - config ARCH_MULTIPLATFORM - bool "Allow multiple platforms to be selected" - select ARCH_FLATMEM_ENABLE - select ARCH_SPARSEMEM_ENABLE - select ARCH_SELECT_MEMORY_MODEL - select ARM_HAS_SG_CHAIN - select ARM_PATCH_PHYS_VIRT - select AUTO_ZRELADDR - select TIMER_OF - select COMMON_CLK - select HAVE_PCI - select PCI_DOMAINS_GENERIC if PCI - select SPARSE_IRQ - select USE_OF - -config ARCH_FOOTBRIDGE - bool "FootBridge" - depends on CPU_LITTLE_ENDIAN - depends on ATAGS - select CPU_SA110 - select FOOTBRIDGE - select NEED_MACH_MEMORY_H - help - Support for systems based on the DC21285 companion chip - ("FootBridge"), such as the Simtec CATS and the Rebel NetWinder. - -config ARCH_RPC - bool "RiscPC" - depends on !CC_IS_CLANG && GCC_VERSION < 90100 && GCC_VERSION >= 60000 - depends on CPU_LITTLE_ENDIAN - depends on ATAGS - select ARCH_ACORN - select ARCH_MAY_HAVE_PC_FDC - select ARCH_SPARSEMEM_ENABLE - select ARM_HAS_SG_CHAIN - select CPU_SA110 - select FIQ - select HAVE_PATA_PLATFORM - select ISA_DMA_API - select LEGACY_TIMER_TICK - select NEED_MACH_IO_H - select NEED_MACH_MEMORY_H - select NO_IOPORT_MAP - help - On the Acorn Risc-PC, Linux can support the internal IDE disk and - CD-ROM interface, serial and parallel port, and the floppy drive. - -config ARCH_SA1100 - bool "SA1100-based" - depends on CPU_LITTLE_ENDIAN - depends on ATAGS - select ARCH_MTD_XIP - select ARCH_SPARSEMEM_ENABLE - select CLKSRC_MMIO - select CLKSRC_PXA - select TIMER_OF if OF - select COMMON_CLK - select CPU_FREQ - select CPU_SA1100 - select GPIOLIB - select IRQ_DOMAIN - select ISA - select NEED_MACH_MEMORY_H - select SPARSE_IRQ - help - Support for StrongARM 11x0 based boards. + def_bool MMU && !(ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100) -endchoice - -menu "Multiple platform selection" - depends on ARCH_MULTIPLATFORM +menu "Platform selection" + depends on MMU comment "CPU Core family selection" config ARCH_MULTI_V4 - bool "ARMv4 based platforms (FA526)" + bool "ARMv4 based platforms (FA526, StrongARM)" depends on !ARCH_MULTI_V6_V7 select ARCH_MULTI_V4_V5 - select CPU_FA526 + select CPU_FA526 if !(CPU_SA110 || CPU_SA1100) config ARCH_MULTI_V4T bool "ARMv4T based platforms (ARM720T, ARM920T, ...)" @@ -472,7 +393,6 @@ config ARCH_AIROHA select ARM_GIC_V3 select ARM_PSCI select HAVE_ARM_ARCH_TIMER - select COMMON_CLK help Support for Airoha EN7523 SoCs @@ -573,6 +493,8 @@ source "arch/arm/mach-rda/Kconfig" source "arch/arm/mach-realtek/Kconfig" +source "arch/arm/mach-rpc/Kconfig" + source "arch/arm/mach-rockchip/Kconfig" source "arch/arm/mach-s3c/Kconfig" @@ -638,7 +560,6 @@ config ARCH_ACORN config PLAT_ORION bool select CLKSRC_MMIO - select COMMON_CLK select GENERIC_IRQ_CHIP select IRQ_DOMAIN @@ -1358,13 +1279,13 @@ config OABI_COMPAT at all). If in doubt say N. config ARCH_SELECT_MEMORY_MODEL - bool + def_bool y config ARCH_FLATMEM_ENABLE - bool + def_bool !(ARCH_RPC || ARCH_SA1100) config ARCH_SPARSEMEM_ENABLE - bool + def_bool !ARCH_FOOTBRIDGE select SPARSEMEM_STATIC if SPARSEMEM config HIGHMEM @@ -1772,7 +1693,8 @@ config CRASH_DUMP For more details see Documentation/admin-guide/kdump/kdump.rst config AUTO_ZRELADDR - bool "Auto calculation of the decompressed kernel image address" + bool "Auto calculation of the decompressed kernel image address" if !ARCH_MULTIPLATFORM + default !(ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100) help ZRELADDR is the physical address where the decompressed kernel image will be placed. If AUTO_ZRELADDR is selected, the address diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug index 792796a348c3..655f84ada30f 100644 --- a/arch/arm/Kconfig.debug +++ b/arch/arm/Kconfig.debug @@ -1904,7 +1904,7 @@ config DEBUG_UART_8250_PALMCHIP config DEBUG_UNCOMPRESS bool "Enable decompressor debugging via DEBUG_LL output" - depends on ARCH_MULTIPLATFORM || PLAT_SAMSUNG || ARM_SINGLE_ARMV7M + depends on !(ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100) depends on DEBUG_LL && !DEBUG_OMAP2PLUS_UART && \ (!DEBUG_TEGRA_UART || !ZBOOT_ROM) && \ !DEBUG_BRCMSTB_UART && !DEBUG_SEMIHOSTING @@ -1921,9 +1921,8 @@ config DEBUG_UNCOMPRESS config UNCOMPRESS_INCLUDE string - default "debug/uncompress.h" if ARCH_MULTIPLATFORM || ARCH_MSM || \ - PLAT_SAMSUNG || ARM_SINGLE_ARMV7M - default "mach/uncompress.h" + default "mach/uncompress.h" if ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100 + default "debug/uncompress.h" config EARLY_PRINTK bool "Early printk" diff --git a/arch/arm/configs/assabet_defconfig b/arch/arm/configs/assabet_defconfig index 801383e4135d..8ba8eb7a4adf 100644 --- a/arch/arm/configs/assabet_defconfig +++ b/arch/arm/configs/assabet_defconfig @@ -1,6 +1,8 @@ CONFIG_SYSVIPC=y CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_ASSABET=y CONFIG_CMDLINE="mem=32M console=ttySA0,38400n8 initrd=0xc0800000,3M root=/dev/ram" diff --git a/arch/arm/configs/badge4_defconfig b/arch/arm/configs/badge4_defconfig index 506f3378da07..b12752fd45cb 100644 --- a/arch/arm/configs/badge4_defconfig +++ b/arch/arm/configs/badge4_defconfig @@ -1,5 +1,7 @@ CONFIG_LOG_BUF_SHIFT=14 CONFIG_EXPERT=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_BADGE4=y CONFIG_UNUSED_BOARD_FILES=y diff --git a/arch/arm/configs/cerfcube_defconfig b/arch/arm/configs/cerfcube_defconfig index 7e6f7dfa3023..9ada868e2648 100644 --- a/arch/arm/configs/cerfcube_defconfig +++ b/arch/arm/configs/cerfcube_defconfig @@ -1,6 +1,8 @@ CONFIG_SYSVIPC=y CONFIG_BSD_PROCESS_ACCT=y CONFIG_LOG_BUF_SHIFT=14 +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_CERF=y CONFIG_SA1100_CERF_FLASH_16MB=y diff --git a/arch/arm/configs/collie_defconfig b/arch/arm/configs/collie_defconfig index d35cc59ce847..2a2d2cb3ce2e 100644 --- a/arch/arm/configs/collie_defconfig +++ b/arch/arm/configs/collie_defconfig @@ -5,6 +5,8 @@ CONFIG_BLK_DEV_INITRD=y CONFIG_EXPERT=y # CONFIG_BASE_FULL is not set # CONFIG_EPOLL is not set +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_COLLIE=y CONFIG_CMDLINE="noinitrd root=/dev/mtdblock2 rootfstype=jffs2 fbcon=rotate:1" diff --git a/arch/arm/configs/footbridge_defconfig b/arch/arm/configs/footbridge_defconfig index 504070812ad0..55bf8a6383e2 100644 --- a/arch/arm/configs/footbridge_defconfig +++ b/arch/arm/configs/footbridge_defconfig @@ -4,6 +4,8 @@ CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y CONFIG_EXPERT=y # CONFIG_HOTPLUG is not set +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_FOOTBRIDGE=y CONFIG_ARCH_EBSA285_HOST=y CONFIG_ARCH_NETWINDER=y diff --git a/arch/arm/configs/h3600_defconfig b/arch/arm/configs/h3600_defconfig index 5bd1ec539610..4e272875c797 100644 --- a/arch/arm/configs/h3600_defconfig +++ b/arch/arm/configs/h3600_defconfig @@ -4,6 +4,8 @@ CONFIG_HIGH_RES_TIMERS=y CONFIG_PREEMPT=y CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_H3600=y # CONFIG_CPU_FREQ_STAT is not set diff --git a/arch/arm/configs/hackkit_defconfig b/arch/arm/configs/hackkit_defconfig index b9327b2eacd3..a28fb396afc4 100644 --- a/arch/arm/configs/hackkit_defconfig +++ b/arch/arm/configs/hackkit_defconfig @@ -1,6 +1,8 @@ CONFIG_SYSVIPC=y CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_HACKKIT=y CONFIG_UNUSED_BOARD_FILES=y diff --git a/arch/arm/configs/jornada720_defconfig b/arch/arm/configs/jornada720_defconfig index 3dcf89d3e1f1..283c81812e18 100644 --- a/arch/arm/configs/jornada720_defconfig +++ b/arch/arm/configs/jornada720_defconfig @@ -1,6 +1,8 @@ CONFIG_SYSVIPC=y CONFIG_LOG_BUF_SHIFT=14 CONFIG_SYSFS_DEPRECATED_V2=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_JORNADA720=y CONFIG_SA1100_JORNADA720_SSP=y diff --git a/arch/arm/configs/lart_defconfig b/arch/arm/configs/lart_defconfig index 0c2f19d756c0..b0eb488de9bc 100644 --- a/arch/arm/configs/lart_defconfig +++ b/arch/arm/configs/lart_defconfig @@ -1,6 +1,8 @@ CONFIG_SYSVIPC=y CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_LART=y CONFIG_UNUSED_BOARD_FILES=y diff --git a/arch/arm/configs/neponset_defconfig b/arch/arm/configs/neponset_defconfig index 907403529e30..79da67d37be9 100644 --- a/arch/arm/configs/neponset_defconfig +++ b/arch/arm/configs/neponset_defconfig @@ -1,6 +1,8 @@ CONFIG_SYSVIPC=y CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_ASSABET=y CONFIG_ASSABET_NEPONSET=y diff --git a/arch/arm/configs/netwinder_defconfig b/arch/arm/configs/netwinder_defconfig index cf7bbcf9d98a..17fe4126c5de 100644 --- a/arch/arm/configs/netwinder_defconfig +++ b/arch/arm/configs/netwinder_defconfig @@ -1,5 +1,7 @@ CONFIG_SYSVIPC=y CONFIG_LOG_BUF_SHIFT=14 +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_FOOTBRIDGE=y CONFIG_ARCH_NETWINDER=y CONFIG_DEPRECATED_PARAM_STRUCT=y diff --git a/arch/arm/configs/pleb_defconfig b/arch/arm/configs/pleb_defconfig index d87263336cb2..fd2667873273 100644 --- a/arch/arm/configs/pleb_defconfig +++ b/arch/arm/configs/pleb_defconfig @@ -4,6 +4,8 @@ CONFIG_BLK_DEV_INITRD=y CONFIG_EXPERT=y # CONFIG_HOTPLUG is not set # CONFIG_SHMEM is not set +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_PLEB=y CONFIG_UNUSED_BOARD_FILES=y diff --git a/arch/arm/configs/rpc_defconfig b/arch/arm/configs/rpc_defconfig index 16d74a1f027a..71bfbd5d811c 100644 --- a/arch/arm/configs/rpc_defconfig +++ b/arch/arm/configs/rpc_defconfig @@ -4,6 +4,8 @@ CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y CONFIG_MODULES=y CONFIG_MODULE_UNLOAD=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_RPC=y CONFIG_CPU_SA110=y CONFIG_FPE_NWFPE=y diff --git a/arch/arm/configs/shannon_defconfig b/arch/arm/configs/shannon_defconfig index 42252e85ee49..dfcea70b8034 100644 --- a/arch/arm/configs/shannon_defconfig +++ b/arch/arm/configs/shannon_defconfig @@ -1,6 +1,8 @@ CONFIG_SYSVIPC=y CONFIG_LOG_BUF_SHIFT=14 CONFIG_BLK_DEV_INITRD=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_SHANNON=y CONFIG_UNUSED_BOARD_FILES=y diff --git a/arch/arm/configs/simpad_defconfig b/arch/arm/configs/simpad_defconfig index cc451728f6d9..4e00a4c2c287 100644 --- a/arch/arm/configs/simpad_defconfig +++ b/arch/arm/configs/simpad_defconfig @@ -5,6 +5,8 @@ CONFIG_LOG_BUF_SHIFT=14 CONFIG_EXPERT=y CONFIG_KALLSYMS_ALL=y CONFIG_KALLSYMS_EXTRA_PASS=y +CONFIG_ARCH_MULTI_V4=y +# CONFIG_ARCH_MULTI_V7 is not set CONFIG_ARCH_SA1100=y CONFIG_SA1100_SIMPAD=y CONFIG_UNUSED_BOARD_FILES=y diff --git a/arch/arm/mach-footbridge/Kconfig b/arch/arm/mach-footbridge/Kconfig index acc10b1caa69..1c9eae26e6ac 100644 --- a/arch/arm/mach-footbridge/Kconfig +++ b/arch/arm/mach-footbridge/Kconfig @@ -1,7 +1,20 @@ # SPDX-License-Identifier: GPL-2.0-only -if ARCH_FOOTBRIDGE +menuconfig ARCH_FOOTBRIDGE + bool "FootBridge Implementations" + depends on ARCH_MULTI_V4 && !(ARCH_MULTI_V4T || ARCH_MULTI_V5) + depends on !(ARCH_MOXART || ARCH_GEMINI || ARCH_SA1100) + depends on ATAGS + depends on CPU_LITTLE_ENDIAN + depends on MMU + select ARCH_NO_SG_CHAIN + select CPU_SA110 + select FOOTBRIDGE + select NEED_MACH_MEMORY_H + help + Support for systems based on the DC21285 companion chip + ("FootBridge"), such as the Simtec CATS and the Rebel NetWinder. -menu "Footbridge Implementations" +if ARCH_FOOTBRIDGE config ARCH_CATS bool "CATS" @@ -57,8 +70,6 @@ config ARCH_NETWINDER Saying N will reduce the size of the Footbridge kernel. -endmenu - # Footbridge support config FOOTBRIDGE select ARCH_HAS_PHYS_TO_DMA diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig index 77e435df8dfe..ab767f059929 100644 --- a/arch/arm/mach-imx/Kconfig +++ b/arch/arm/mach-imx/Kconfig @@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0-only menuconfig ARCH_MXC bool "Freescale i.MX family" - depends on (ARCH_MULTI_V4_V5 && CPU_LITTLE_ENDIAN) || \ + depends on ((ARCH_MULTI_V4T || ARCH_MULTI_V5) && CPU_LITTLE_ENDIAN) || \ ARCH_MULTI_V6_V7 || ARM_SINGLE_ARMV7M select CLKSRC_IMX_GPT select GENERIC_IRQ_CHIP diff --git a/arch/arm/mach-nspire/Kconfig b/arch/arm/mach-nspire/Kconfig index eb9916233dea..b7a3871876d7 100644 --- a/arch/arm/mach-nspire/Kconfig +++ b/arch/arm/mach-nspire/Kconfig @@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0-only config ARCH_NSPIRE bool "TI-NSPIRE based" - depends on ARCH_MULTI_V4_V5 + depends on ARCH_MULTI_V4T depends on CPU_LITTLE_ENDIAN select CPU_ARM926T select GENERIC_IRQ_CHIP diff --git a/arch/arm/mach-rpc/Kconfig b/arch/arm/mach-rpc/Kconfig new file mode 100644 index 000000000000..55f6d829b677 --- /dev/null +++ b/arch/arm/mach-rpc/Kconfig @@ -0,0 +1,21 @@ +config ARCH_RPC + bool "RiscPC" + depends on ARCH_MULTI_V4 && !(ARCH_MULTI_V4T || ARCH_MULTI_V5) + depends on !(ARCH_FOOTBRIDGE || ARCH_SA1100 || ARCH_MOXART || ARCH_GEMINI) + depends on !CC_IS_CLANG && GCC_VERSION < 90100 && GCC_VERSION >= 60000 + depends on CPU_LITTLE_ENDIAN + depends on ATAGS + depends on MMU + select ARCH_ACORN + select ARCH_MAY_HAVE_PC_FDC + select CPU_SA110 + select FIQ + select HAVE_PATA_PLATFORM + select ISA_DMA_API + select LEGACY_TIMER_TICK + select NEED_MACH_IO_H + select NEED_MACH_MEMORY_H + select NO_IOPORT_MAP + help + On the Acorn Risc-PC, Linux can support the internal IDE disk and + CD-ROM interface, serial and parallel port, and the floppy drive. diff --git a/arch/arm/mach-sa1100/Kconfig b/arch/arm/mach-sa1100/Kconfig index 7e0161cb1c1f..fb9cd10705de 100644 --- a/arch/arm/mach-sa1100/Kconfig +++ b/arch/arm/mach-sa1100/Kconfig @@ -1,7 +1,25 @@ # SPDX-License-Identifier: GPL-2.0-only -if ARCH_SA1100 +menuconfig ARCH_SA1100 + bool "SA11x0 Implementations" + depends on ARCH_MULTI_V4 && !(ARCH_MULTI_V4T || ARCH_MULTI_V5) + depends on !(ARCH_MOXART || ARCH_GEMINI) + depends on ATAGS + depends on CPU_LITTLE_ENDIAN + depends on MMU + select ARCH_NO_SG_CHAIN + select ARCH_MTD_XIP + select CLKSRC_MMIO + select CLKSRC_PXA + select CPU_FREQ + select CPU_SA1100 + select GPIOLIB + select IRQ_DOMAIN + select ISA + select NEED_MACH_MEMORY_H + help + Support for StrongARM 11x0 based boards. -menu "SA11x0 Implementations" +if ARCH_SA1100 config SA1100_ASSABET bool "Assabet" @@ -179,7 +197,4 @@ config SA1100_SSP This isn't for audio support, but for attached sensors and other devices, eg for BadgePAD 4 sensor support. -endmenu - endif - From patchwork Thu Aug 18 14:56:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 12947265 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 59B05C00140 for ; Thu, 18 Aug 2022 15:01:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=0W+gU5enUvdBWX96GQXqwsAd6VUsvRH6Sxh2rfNV4/k=; b=C1owxG4WM/vYRT CtzUjti/KsAq0CS9av6672avm8hZF2677ugjmR+YI59mV5Q5GNqqcd1p90T786H30aWmQLUc5DMw4 OBB0UV827KVAvzmoKPuqAGayO1/ymr7PDgvJLZitMuUcU/oGu0BaDCqTnRKRaePgDt8ZgDYBgLj7j W+QLcZO9QabPApGDzkZP/YGdBc+4ReU2AjOYUjP5KWcCYJhSR+CZOcsKWOo6i+7UOm644Bh8FFw6r NO+aD1OND9NCu1Qrgc4XAug9omQXjOc3Onljb/JgwyP6hlaw3chukPfIIlzC4GMVCuncAOB19hyrS TdxK8QfXYAw4zOU8WXGQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOh0F-006MMI-7u; Thu, 18 Aug 2022 15:00:13 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgx0-006KgO-PU for linux-arm-kernel@lists.infradead.org; Thu, 18 Aug 2022 14:56:52 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 3AFD2612AF; Thu, 18 Aug 2022 14:56:50 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4D519C43470; Thu, 18 Aug 2022 14:56:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1660834609; bh=RlvIHjnFmvmSJ2Sj9XCES+dsJBYvTPzMIPgDbH08k5E=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ICT3toaNk/oHDQKBfW01iuipifxP+CV77V0ELUgSduNyT+8gvtSCw90om68kyv4V9 FCyNVZiTMCH8uB9CmGBFkXGEvvoBh5R+Z6rqltTPEuDbvnExjLuLyXZlViM9pas96d okW6ameFgTn3ynwtOTKLUkZQtcwjFDwG88Us9fNGXj2Peu6/7b3pvR7IsYJx1PO0sj VIi5l9bCVrtHLzVDU71E+q6SadVoKAspRKy1aFsH0CZKpejrFv4B4CqFUs3C43A4EJ i+BoTAznr94FEShmCTEUv+VyM1anlTJZp7UxpDyld1v502sD7pVkcM1VTuis+SQvfV 56W9AKtOe53LA== From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, Arnd Bergmann , Russell King , Linus Walleij , Geert Uytterhoeven , Krzysztof Kozlowski , Ard Biesheuvel , Sekhar Nori , Bartosz Golaszewski , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth Subject: [PATCH 4/5] ARM: fix CPU_V6 dependencies Date: Thu, 18 Aug 2022 16:56:15 +0200 Message-Id: <20220818145616.3156379-5-arnd@kernel.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20220818145616.3156379-1-arnd@kernel.org> References: <20220818145616.3156379-1-arnd@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220818_075650_913124_48FEA71E X-CRM114-Status: GOOD ( 12.84 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Arnd Bergmann CONFIG_XIP_KERNEL must not be combined with CONFIG_SMP_ON_UP because the patching of read-only data does not work. Signed-off-by: Arnd Bergmann --- arch/arm/mach-imx/Kconfig | 1 + arch/arm/mach-omap2/Kconfig | 1 + arch/arm/mach-versatile/Kconfig | 2 ++ 3 files changed, 4 insertions(+) diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig index ab767f059929..9308e9894be5 100644 --- a/arch/arm/mach-imx/Kconfig +++ b/arch/arm/mach-imx/Kconfig @@ -41,6 +41,7 @@ comment "ARM1136 platforms" config SOC_IMX31 bool "i.MX31 support" + depends on !SMP || !XIP_KERNEL # for SMP_ON_UP select CPU_V6 select MXC_AVIC help diff --git a/arch/arm/mach-omap2/Kconfig b/arch/arm/mach-omap2/Kconfig index 3b53dda9ec79..f2ce262958c4 100644 --- a/arch/arm/mach-omap2/Kconfig +++ b/arch/arm/mach-omap2/Kconfig @@ -8,6 +8,7 @@ config OMAP_HWMOD config ARCH_OMAP2 bool "TI OMAP2" depends on ARCH_MULTI_V6 + depends on !SMP || !XIP_KERNEL # for SMP_ON_UP select ARCH_OMAP2PLUS select CPU_V6 select OMAP_HWMOD diff --git a/arch/arm/mach-versatile/Kconfig b/arch/arm/mach-versatile/Kconfig index 2ef226194c3a..25723b0c63dd 100644 --- a/arch/arm/mach-versatile/Kconfig +++ b/arch/arm/mach-versatile/Kconfig @@ -21,6 +21,7 @@ menuconfig ARCH_INTEGRATOR bool "ARM Ltd. Integrator family" depends on ARCH_MULTI_V4T || ARCH_MULTI_V5 || ARCH_MULTI_V6 depends on CPU_LITTLE_ENDIAN || ARCH_MULTI_V6 + depends on !SMP || !XIP_KERNEL # for SMP_ON_UP select ARM_AMBA select CMA select DMA_CMA @@ -146,6 +147,7 @@ endif menuconfig ARCH_REALVIEW bool "ARM Ltd. RealView family" depends on (CPU_LITTLE_ENDIAN && ARCH_MULTI_V5) || ARCH_MULTI_V6 || ARCH_MULTI_V7 + depends on !SMP || !XIP_KERNEL # for SMP_ON_UP select ARM_AMBA select ARM_GIC select ARM_TIMER_SP804 From patchwork Thu Aug 18 14:56:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 12947279 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5C37EC00140 for ; Thu, 18 Aug 2022 15:02:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=eosWPC0tJm7UEt+gvCIceUds/FcY1JB7vf74wm9gtDU=; b=1BWS/gtaOKi9y2 RP7teNQAGeKYNHp6QIiMjI6qqhv+8j/g6wnPCkyiRzggl8M6qXXla8WKxTI4mi4a2MJSilmDv5Jcm nSVX1SJLSKFq2GikGb3scsWMU9T+HriTwWR97JUC6qW86XkLz6RlMQhY0sWf6XcgYEHGT8sNxmrxE 4Z2oDXQ3GqgvTcstLsM1Jd0BBQ73QPlscMc2THeO6pEikS4cDgUjMuNn1TofnNff4BlM8EPIAGsph A3/yts1lyYad6W5XoNnwmxDbanw4OnmZetk4M+OHxitNPBt0Paud83nPzB/RoRkAsXociKwYwkgdm zUK1SG7od54xmLp3oSGw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOh1A-006Mzr-GT; Thu, 18 Aug 2022 15:01:08 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oOgx4-006Kj1-NF for linux-arm-kernel@lists.infradead.org; Thu, 18 Aug 2022 14:56:56 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 4229560C95; Thu, 18 Aug 2022 14:56:54 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2F85CC433D7; Thu, 18 Aug 2022 14:56:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1660834613; bh=ezX5UU1asPXPTgpHCHPVGm4xP/s54A8YsDjVnU6X4vM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QagzPj3DbZBasCuAInN1YxC1ZjhQ03z5N84MC95qF+eCsEtEvOf2S0PcNGJzAMfTG /3Y0O07XKHmewILZ3JopAB6dLRUWYd1HyWjaYphBs+05ozODmWgk+eX9RKpiw6QkcF PsrbtFpL8QPegKQAz4cVnTbE7avW8B8gXlA6WjUcFjhLguzTx4euY5zIcuZ/VLxdzl 7LfzAwLjGxCFLngyjlOR50RKyrsF6Awt/lKqvPZkpl8zuleS2mILewHru5K8Qq0nfl W1SrO0ObLpLawYrmhz/vhlHWWSjmEj8Oiu4SOPNoR8FdyfSx5q1MLxZl5UH+TJF3Xp 3ZUUCh8VquRLg== From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, Arnd Bergmann , Russell King , Linus Walleij , Geert Uytterhoeven , Krzysztof Kozlowski , Ard Biesheuvel , Sekhar Nori , Bartosz Golaszewski , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth Subject: [PATCH 5/5] ARM: make ARCH_MULTIPLATFORM user-visible Date: Thu, 18 Aug 2022 16:56:16 +0200 Message-Id: <20220818145616.3156379-6-arnd@kernel.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20220818145616.3156379-1-arnd@kernel.org> References: <20220818145616.3156379-1-arnd@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220818_075654_884772_D97981E0 X-CRM114-Status: GOOD ( 20.23 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Arnd Bergmann Some options like CONFIG_DEBUG_UNCOMPRESS and CONFIG_CMDLINE_FORCE are fundamentally incompatible with portable kernels but are currently allowed in all configurations. Other options like XIP_KERNEL are essentially useless after the completion of the multiplatform conversion. Repurpose the existing CONFIG_ARCH_MULTIPLATFORM option to decide whether the resulting kernel image is meant to be portable or not, and using this to guard all of the known incompatible options. This is similar to how the RISC-V kernel handles the CONFIG_NONPORTABLE option (with the opposite polarity). A few references to CONFIG_ARCH_MULTIPLATFORM were left behind by earlier clanups and have to be removed now up. Signed-off-by: Arnd Bergmann --- arch/arm/Kconfig | 15 ++++++++++++++- arch/arm/Kconfig.debug | 1 + arch/arm/kernel/devtree.c | 2 -- arch/arm/mach-dove/Makefile | 2 +- arch/arm/mach-mv78xx0/Makefile | 2 +- arch/arm/mach-mvebu/Makefile | 2 +- arch/arm/mach-orion5x/Makefile | 2 +- 7 files changed, 19 insertions(+), 7 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 3066ce82cffc..9cbac5bf8b3a 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -320,7 +320,19 @@ config ARCH_MMAP_RND_BITS_MAX default 16 config ARCH_MULTIPLATFORM - def_bool MMU && !(ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100) + bool "Require kernel to be portable to multiple machines" if EXPERT + depends on MMU && !(ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100) + default y + help + In general, all Arm machines can be supported in a single + kernel image, covering either Armv4/v5 or Armv6/v7. + + However, some configuration options require hardcoding machine + specific physical addresses or enable errata workarounds that may + break other machines. + + Selecting N here allows using those options, including + DEBUG_UNCOMPRESS, XIP_KERNEL and ZBOOT_ROM. If unsure, say Y. menu "Platform selection" depends on MMU @@ -1609,6 +1621,7 @@ config CMDLINE_EXTEND config CMDLINE_FORCE bool "Always use the default kernel command string" + depends on !ARCH_MULTIPLATFORM help Always use the default kernel command string, even if the boot loader passes other arguments to the kernel. diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug index 655f84ada30f..c345775f035b 100644 --- a/arch/arm/Kconfig.debug +++ b/arch/arm/Kconfig.debug @@ -1904,6 +1904,7 @@ config DEBUG_UART_8250_PALMCHIP config DEBUG_UNCOMPRESS bool "Enable decompressor debugging via DEBUG_LL output" + depends on !ARCH_MULTIPLATFORM depends on !(ARCH_FOOTBRIDGE || ARCH_RPC || ARCH_SA1100) depends on DEBUG_LL && !DEBUG_OMAP2PLUS_UART && \ (!DEBUG_TEGRA_UART || !ZBOOT_ROM) && \ diff --git a/arch/arm/kernel/devtree.c b/arch/arm/kernel/devtree.c index 02839d8b6202..264827281113 100644 --- a/arch/arm/kernel/devtree.c +++ b/arch/arm/kernel/devtree.c @@ -194,14 +194,12 @@ const struct machine_desc * __init setup_machine_fdt(void *dt_virt) { const struct machine_desc *mdesc, *mdesc_best = NULL; -#if defined(CONFIG_ARCH_MULTIPLATFORM) || defined(CONFIG_ARM_SINGLE_ARMV7M) DT_MACHINE_START(GENERIC_DT, "Generic DT based system") .l2c_aux_val = 0x0, .l2c_aux_mask = ~0x0, MACHINE_END mdesc_best = &__mach_desc_GENERIC_DT; -#endif if (!dt_virt || !early_init_dt_verify(dt_virt)) return NULL; diff --git a/arch/arm/mach-dove/Makefile b/arch/arm/mach-dove/Makefile index e83f6492834d..da373a5768ba 100644 --- a/arch/arm/mach-dove/Makefile +++ b/arch/arm/mach-dove/Makefile @@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)/arch/arm/plat-orion/include obj-y += common.o obj-$(CONFIG_DOVE_LEGACY) += irq.o mpp.o diff --git a/arch/arm/mach-mv78xx0/Makefile b/arch/arm/mach-mv78xx0/Makefile index a839e960b8c6..50aff70065f2 100644 --- a/arch/arm/mach-mv78xx0/Makefile +++ b/arch/arm/mach-mv78xx0/Makefile @@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)/arch/arm/plat-orion/include obj-y += common.o mpp.o irq.o pcie.o obj-$(CONFIG_MACH_DB78X00_BP) += db78x00-bp-setup.o diff --git a/arch/arm/mach-mvebu/Makefile b/arch/arm/mach-mvebu/Makefile index cb106899dd7c..c21733cbb4fa 100644 --- a/arch/arm/mach-mvebu/Makefile +++ b/arch/arm/mach-mvebu/Makefile @@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)/arch/arm/plat-orion/include AFLAGS_coherency_ll.o := -Wa,-march=armv7-a CFLAGS_pmsu.o := -march=armv7-a diff --git a/arch/arm/mach-orion5x/Makefile b/arch/arm/mach-orion5x/Makefile index 1a585a62d5e6..572c3520f7fe 100644 --- a/arch/arm/mach-orion5x/Makefile +++ b/arch/arm/mach-orion5x/Makefile @@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)/arch/arm/plat-orion/include obj-y += common.o pci.o irq.o mpp.o obj-$(CONFIG_MACH_DB88F5281) += db88f5281-setup.o