|
@@ -1,101 +0,0 @@
|
|
|
-From 77c038d93769c92ef54cdbb50388564d1b37987b Mon Sep 17 00:00:00 2001
|
|
|
-From: Greg Ungerer <gerg@kernel.org>
|
|
|
-Date: Fri, 23 Sep 2016 13:37:34 +1000
|
|
|
-Subject: [PATCH] ARM: versatile: support configuring versatile machine for no-MMU
|
|
|
-
|
|
|
-Allow the arm versatile machine to be configured for no-MMU operation.
|
|
|
-
|
|
|
-Older kernels had the ability to build the versatile machine with the MMU
|
|
|
-disabled (!CONFIG_MMU). Recent changes to convert the versatile machine
|
|
|
-to device tree lost this ability. (Although older kernels could be built
|
|
|
-they did not run due to a bug in the IO_ADDRESS() mapping on this machine).
|
|
|
-
|
|
|
-The motivation for this is that the versatile machine is well supported
|
|
|
-in qemu. And this provides an excellent platform for development and
|
|
|
-testing no-MMU support on ARM in general.
|
|
|
-
|
|
|
-This patch adds a versatile platform selection in the upper level arm
|
|
|
-system type menu - where it appeared in older kernel versions - when
|
|
|
-configuring for the no-MMU case. There is no visible change to the way
|
|
|
-versatile is selected for the MMU enabled case.
|
|
|
-
|
|
|
-Signed-off-by: Greg Ungerer <gerg@kernel.org>
|
|
|
----
|
|
|
- arch/arm/Kconfig | 13 ++++++++++++-
|
|
|
- arch/arm/include/asm/mach/map.h | 1 +
|
|
|
- arch/arm/mach-versatile/Kconfig | 2 +-
|
|
|
- arch/arm/mach-versatile/versatile.c | 4 ++++
|
|
|
- 4 files changed, 18 insertions(+), 2 deletions(-)
|
|
|
-
|
|
|
-diff --git a/arch/arm/mach-versatile/versatile.c b/arch/arm/mach-versatile/versatile.c
|
|
|
-index 02ba68abe533..835b51bc597b 100644
|
|
|
---- a/arch/arm/mach-versatile/versatile.c
|
|
|
-+++ b/arch/arm/mach-versatile/versatile.c
|
|
|
-@@ -22,7 +22,11 @@
|
|
|
- #include <asm/mach/map.h>
|
|
|
-
|
|
|
- /* macro to get at MMIO space when running virtually */
|
|
|
-+#ifdef CONFIG_MMU
|
|
|
- #define IO_ADDRESS(x) (((x) & 0x0fffffff) + (((x) >> 4) & 0x0f000000) + 0xf0000000)
|
|
|
-+#else
|
|
|
-+#define IO_ADDRESS(x) (x)
|
|
|
-+#endif
|
|
|
- #define __io_address(n) ((void __iomem __force *)IO_ADDRESS(n))
|
|
|
-
|
|
|
- /*
|
|
|
-diff --git a/arch/arm/include/asm/mach/map.h b/arch/arm/include/asm/mach/map.h
|
|
|
-index 2b8970d8e5a2..41844ab6aec5 100644
|
|
|
---- a/arch/arm/include/asm/mach/map.h
|
|
|
-+++ b/arch/arm/include/asm/mach/map.h
|
|
|
-@@ -60,6 +60,7 @@ extern int ioremap_page(unsigned long virt, unsigned long phys,
|
|
|
- #else
|
|
|
- #define iotable_init(map,num) do { } while (0)
|
|
|
- #define vm_reserve_area_early(a,s,c) do { } while (0)
|
|
|
-+#define debug_ll_io_init() do { } while (0)
|
|
|
- #endif
|
|
|
-
|
|
|
- #endif
|
|
|
-diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
|
|
|
-index e24a9820e12f..342e1efa583a 100644
|
|
|
---- a/arch/arm/Kconfig
|
|
|
-+++ b/arch/arm/Kconfig
|
|
|
-@@ -307,12 +307,23 @@ config MMU
|
|
|
- Select if you want MMU-based virtualised addressing space
|
|
|
- support by paged memory management. If unsure, say 'Y'.
|
|
|
-
|
|
|
-+choice
|
|
|
-+ prompt "ARM system type"
|
|
|
-+ depends on !MMU
|
|
|
-+ default ARM_SINGLE_ARMV7M
|
|
|
-+
|
|
|
- config ARM_SINGLE_ARMV7M
|
|
|
-- def_bool !MMU
|
|
|
-+ bool "ARMv7-M based platforms (Cortex-M0/M3/M4)"
|
|
|
- select ARM_NVIC
|
|
|
- select CPU_V7M
|
|
|
- select NO_IOPORT_MAP
|
|
|
-
|
|
|
-+config ARM_SINGLE_ARM926
|
|
|
-+ bool "ARM926 based platforms"
|
|
|
-+ select CPU_ARM926T
|
|
|
-+
|
|
|
-+endchoice
|
|
|
-+
|
|
|
- config ARCH_MMAP_RND_BITS_MIN
|
|
|
- default 8
|
|
|
-
|
|
|
-diff --git a/arch/arm/mach-versatile/Kconfig b/arch/arm/mach-versatile/Kconfig
|
|
|
-index b1519b4dc03a..2f1bf95daeb0 100644
|
|
|
---- a/arch/arm/mach-versatile/Kconfig
|
|
|
-+++ b/arch/arm/mach-versatile/Kconfig
|
|
|
-@@ -1,7 +1,7 @@
|
|
|
- # SPDX-License-Identifier: GPL-2.0
|
|
|
- config ARCH_VERSATILE
|
|
|
- bool "ARM Ltd. Versatile family"
|
|
|
-- depends on ARCH_MULTI_V5
|
|
|
-+ depends on ARCH_MULTI_V5 || ARM_SINGLE_ARM926
|
|
|
- depends on CPU_LITTLE_ENDIAN
|
|
|
- select ARM_AMBA
|
|
|
- select ARM_TIMER_SP804
|
|
|
---
|
|
|
-2.25.1
|