diff options
Diffstat (limited to 'target')
-rw-r--r-- | target/arm/Makefile | 8 | ||||
-rw-r--r-- | target/arm/kernel/qemu-arm-versatilepb-nommu | 2 | ||||
-rw-r--r-- | target/config/Config.in.archopts | 6 | ||||
-rw-r--r-- | target/linux/Config.in.kernelversion | 5 | ||||
-rw-r--r-- | target/linux/patches/4.14.30/arm-nommu.patch | 81 | ||||
-rw-r--r-- | target/linux/patches/4.15.13/arm-nommu.patch | 81 | ||||
-rw-r--r-- | target/linux/patches/4.9.88/arm-nommu.patch | 80 |
7 files changed, 245 insertions, 18 deletions
diff --git a/target/arm/Makefile b/target/arm/Makefile index 0965f60be..3be194688 100644 --- a/target/arm/Makefile +++ b/target/arm/Makefile @@ -33,11 +33,7 @@ ifeq ($(ADK_TARGET_SYSTEM_QEMU_ARM_REALVIEW_EB_MPCORE),y) QEMU_ARGS+=-M realview-eb-mpcore -net user -net nic endif ifeq ($(ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB)$(ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU),y) -ifeq ($(ADK_TARGET_WITH_DEVICETREE),y) QEMU_ARGS+=-M versatilepb -net user -net nic,model=smc91c111 -dtb $(FW_DIR)/versatile-pb.dtb -else -QEMU_ARGS+=-M versatilepb -net user -net nic,model=smc91c111 -endif endif ifeq ($(ADK_TARGET_SYSTEM_QEMU_ARM_VEXPRESS_A9),y) QEMU_ARGS+=-M vexpress-a9 -cpu cortex-a9 -m 256 -net user -net nic,model=lan9118 -dtb $(FW_DIR)/vexpress-v2p-ca9.dtb @@ -168,7 +164,6 @@ ifeq ($(ADK_TARGET_FS),squashfs) endif dtb-install: -ifeq ($(ADK_TARGET_WITH_DEVICETREE),y) ifeq ($(ADK_TARGET_SYSTEM_QEMU_ARM_XILINX_ZYNQ),y) env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \ dtbs $(MAKE_TRACE) @@ -179,7 +174,7 @@ ifeq ($(ADK_TARGET_SYSTEM_QEMU_ARM_VEXPRESS_A9),y) endif ifeq ($(ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB)$(ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU),y) env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \ - dtbs $(MAKE_TRACE) + versatile-pb.dtb $(MAKE_TRACE) endif ifeq ($(ADK_TARGET_SYSTEM_PHYTEC_WEGA),y) env $(KERNEL_MAKE_ENV) $(MAKE) -C "${LINUX_DIR}" $(KERNEL_MAKE_OPTS) \ @@ -224,7 +219,6 @@ endif [[ -e "$$x" ]] && cp $(LINUX_DIR)/arch/arm/boot/dts/*.dtb $(FW_DIR); \ break; \ done -endif # filesystem specific targets ifeq ($(ADK_TARGET_FS),archive) diff --git a/target/arm/kernel/qemu-arm-versatilepb-nommu b/target/arm/kernel/qemu-arm-versatilepb-nommu index 3d7b851e4..74717d283 100644 --- a/target/arm/kernel/qemu-arm-versatilepb-nommu +++ b/target/arm/kernel/qemu-arm-versatilepb-nommu @@ -1,4 +1,5 @@ CONFIG_ARM=y +CONFIG_ARM_SINGLE_ARCH_VERSATILE=y CONFIG_ARCH_VERSATILE=y CONFIG_KUSER_HELPERS=y CONFIG_ATAGS=y @@ -8,7 +9,6 @@ CONFIG_DRAM_BASE=0x00000000 CONFIG_DRAM_SIZE=0x08000000 CONFIG_ARCH_VERSATILE_PB=y CONFIG_MACH_VERSATILE_AB=y -# CONFIG_MACH_VERSATILE_DT is not set CONFIG_PLAT_VERSATILE_CLOCK=y CONFIG_PLAT_VERSATILE_SCHED_CLOCK=y CONFIG_PLAT_VERSATILE=y diff --git a/target/config/Config.in.archopts b/target/config/Config.in.archopts index aa4926c2a..e6d5cf00e 100644 --- a/target/config/Config.in.archopts +++ b/target/config/Config.in.archopts @@ -35,9 +35,3 @@ config ADK_TARGET_NAN_MODE string default "legacy" if ADK_TARGET_ARCH_MIPS_WITH_NAN_LEGACY default "2008" if ADK_TARGET_ARCH_MIPS_WITH_NAN_2008 - -config ADK_TARGET_WITH_DEVICETREE - bool - depends on ADK_TARGET_ARCH_ARM - default y if !ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU - default n diff --git a/target/linux/Config.in.kernelversion b/target/linux/Config.in.kernelversion index 3990481cf..c2af39396 100644 --- a/target/linux/Config.in.kernelversion +++ b/target/linux/Config.in.kernelversion @@ -15,7 +15,6 @@ default ADK_TARGET_LINUX_KERNEL_VERSION_GIT if ADK_TARGET_ARCH_LM32 default ADK_TARGET_LINUX_KERNEL_VERSION_4_4 if ADK_TARGET_ARCH_CRIS default ADK_TARGET_LINUX_KERNEL_VERSION_4_4 if ADK_TARGET_ARCH_H8300 default ADK_TARGET_LINUX_KERNEL_VERSION_4_4 if ADK_TARGET_ARCH_METAG -default ADK_TARGET_LINUX_KERNEL_VERSION_4_4 if ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU default ADK_TARGET_LINUX_KERNEL_VERSION_4_4 if ADK_TARGET_SYSTEM_QEMU_ARM_REALVIEW_EB_MPCORE default ADK_TARGET_LINUX_KERNEL_VERSION_4_15 if ADK_TARGET_ARCH_RISCV32 default ADK_TARGET_LINUX_KERNEL_VERSION_4_15 if ADK_TARGET_ARCH_RISCV64 @@ -38,7 +37,6 @@ config ADK_TARGET_LINUX_KERNEL_VERSION_4_15 depends on !ADK_TARGET_ARCH_CSKY depends on !ADK_TARGET_ARCH_METAG depends on !ADK_TARGET_ARCH_NDS32 - depends on !ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU depends on !ADK_TARGET_SYSTEM_QEMU_ARM_REALVIEW_EB_MPCORE config ADK_TARGET_LINUX_KERNEL_VERSION_4_14 @@ -50,7 +48,6 @@ config ADK_TARGET_LINUX_KERNEL_VERSION_4_14 depends on !ADK_TARGET_ARCH_NDS32 depends on !ADK_TARGET_ARCH_RISCV32 depends on !ADK_TARGET_ARCH_RISCV64 - depends on !ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU depends on !ADK_TARGET_SYSTEM_QEMU_ARM_REALVIEW_EB_MPCORE config ADK_TARGET_LINUX_KERNEL_VERSION_4_9 @@ -62,7 +59,6 @@ config ADK_TARGET_LINUX_KERNEL_VERSION_4_9 depends on !ADK_TARGET_ARCH_OR1K depends on !ADK_TARGET_ARCH_RISCV32 depends on !ADK_TARGET_ARCH_RISCV64 - depends on !ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU depends on !ADK_TARGET_SYSTEM_QEMU_ARM_REALVIEW_EB_MPCORE depends on !ADK_TARGET_SYSTEM_ORANGE_PI0 @@ -78,6 +74,7 @@ config ADK_TARGET_LINUX_KERNEL_VERSION_4_4 depends on !ADK_TARGET_CPU_MIPS64_MIPS64R6 depends on !ADK_TARGET_SYSTEM_NUMATO_MIMASV2 depends on !ADK_TARGET_SYSTEM_ORANGE_PI0 + depends on !ADK_TARGET_SYSTEM_QEMU_ARM_VERSATILEPB_NOMMU config ADK_TARGET_LINUX_KERNEL_VERSION_4_1 bool "4.1.50" diff --git a/target/linux/patches/4.14.30/arm-nommu.patch b/target/linux/patches/4.14.30/arm-nommu.patch new file mode 100644 index 000000000..b91aaf712 --- /dev/null +++ b/target/linux/patches/4.14.30/arm-nommu.patch @@ -0,0 +1,81 @@ +diff -Nur linux-4.14.30.orig/arch/arm/Kconfig linux-4.14.30/arch/arm/Kconfig +--- linux-4.14.30.orig/arch/arm/Kconfig 2018-03-24 11:01:30.000000000 +0100 ++++ linux-4.14.30/arch/arm/Kconfig 2018-04-01 04:14:15.989043313 +0100 +@@ -363,6 +363,17 @@ + select SPARSE_IRQ + select USE_OF + ++config ARM_SINGLE_ARCH_VERSATILE ++ bool "ARM Ltd. Versatile family" ++ depends on !MMU ++ select AUTO_ZRELADDR ++ select CLKSRC_OF ++ select COMMON_CLK ++ select GENERIC_CLOCKEVENTS ++ select GPIOLIB ++ select SPARSE_IRQ ++ select USE_OF ++ + config ARCH_EBSA110 + bool "EBSA-110" + select ARCH_USES_GETTIMEOFFSET +diff -Nur linux-4.14.30.orig/arch/arm/Kconfig.debug linux-4.14.30/arch/arm/Kconfig.debug +--- linux-4.14.30.orig/arch/arm/Kconfig.debug 2018-03-24 11:01:30.000000000 +0100 ++++ linux-4.14.30/arch/arm/Kconfig.debug 2018-04-01 04:14:15.990043300 +0100 +@@ -1777,7 +1777,8 @@ + config UNCOMPRESS_INCLUDE + string + default "debug/uncompress.h" if ARCH_MULTIPLATFORM || ARCH_MSM || \ +- PLAT_SAMSUNG || ARM_SINGLE_ARMV7M ++ PLAT_SAMSUNG || ARM_SINGLE_ARMV7M || \ ++ ARM_SINGLE_ARCH_VERSATILE + default "mach/uncompress.h" + + config EARLY_PRINTK +diff -Nur linux-4.14.30.orig/arch/arm/include/asm/mach/map.h linux-4.14.30/arch/arm/include/asm/mach/map.h +--- linux-4.14.30.orig/arch/arm/include/asm/mach/map.h 2018-03-24 11:01:30.000000000 +0100 ++++ linux-4.14.30/arch/arm/include/asm/mach/map.h 2018-04-01 04:14:15.991043288 +0100 +@@ -62,6 +62,7 @@ + #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 -Nur linux-4.14.30.orig/arch/arm/mach-versatile/Kconfig linux-4.14.30/arch/arm/mach-versatile/Kconfig +--- linux-4.14.30.orig/arch/arm/mach-versatile/Kconfig 2018-03-24 11:01:30.000000000 +0100 ++++ linux-4.14.30/arch/arm/mach-versatile/Kconfig 2018-04-01 04:14:15.992043275 +0100 +@@ -1,7 +1,8 @@ + # SPDX-License-Identifier: GPL-2.0 + config ARCH_VERSATILE +- bool "ARM Ltd. Versatile family" +- depends on ARCH_MULTI_V5 ++ bool "ARM Ltd. Versatile family" if ARCH_MULTI_V5 ++ depends on ARCH_MULTI_V5 || ARM_SINGLE_ARCH_VERSATILE ++ default y if ARM_SINGLE_ARCH_VERSATILE + select ARM_AMBA + select ARM_TIMER_SP804 + select ARM_VIC +diff -Nur linux-4.14.30.orig/arch/arm/mach-versatile/Makefile.boot linux-4.14.30/arch/arm/mach-versatile/Makefile.boot +--- linux-4.14.30.orig/arch/arm/mach-versatile/Makefile.boot 1970-01-01 01:00:00.000000000 +0100 ++++ linux-4.14.30/arch/arm/mach-versatile/Makefile.boot 2018-04-01 04:14:15.992043275 +0100 +@@ -0,0 +1,3 @@ ++# 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 -Nur linux-4.14.30.orig/arch/arm/mach-versatile/versatile_dt.c linux-4.14.30/arch/arm/mach-versatile/versatile_dt.c +--- linux-4.14.30.orig/arch/arm/mach-versatile/versatile_dt.c 2018-03-24 11:01:30.000000000 +0100 ++++ linux-4.14.30/arch/arm/mach-versatile/versatile_dt.c 2018-04-01 04:14:15.992043275 +0100 +@@ -37,7 +37,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/target/linux/patches/4.15.13/arm-nommu.patch b/target/linux/patches/4.15.13/arm-nommu.patch new file mode 100644 index 000000000..2480b5169 --- /dev/null +++ b/target/linux/patches/4.15.13/arm-nommu.patch @@ -0,0 +1,81 @@ +diff -Nur linux-4.15.13.orig/arch/arm/Kconfig linux-4.15.13/arch/arm/Kconfig +--- linux-4.15.13.orig/arch/arm/Kconfig 2018-03-24 11:02:53.000000000 +0100 ++++ linux-4.15.13/arch/arm/Kconfig 2018-04-01 03:47:33.415078244 +0100 +@@ -355,6 +355,17 @@ + select SPARSE_IRQ + select USE_OF + ++config ARM_SINGLE_ARCH_VERSATILE ++ bool "ARM Ltd. Versatile family" ++ depends on !MMU ++ select AUTO_ZRELADDR ++ select CLKSRC_OF ++ select COMMON_CLK ++ select GENERIC_CLOCKEVENTS ++ select GPIOLIB ++ select SPARSE_IRQ ++ select USE_OF ++ + config ARCH_EBSA110 + bool "EBSA-110" + select ARCH_USES_GETTIMEOFFSET +diff -Nur linux-4.15.13.orig/arch/arm/Kconfig.debug linux-4.15.13/arch/arm/Kconfig.debug +--- linux-4.15.13.orig/arch/arm/Kconfig.debug 2018-03-24 11:02:53.000000000 +0100 ++++ linux-4.15.13/arch/arm/Kconfig.debug 2018-04-01 03:47:33.416078232 +0100 +@@ -1795,7 +1795,8 @@ + config UNCOMPRESS_INCLUDE + string + default "debug/uncompress.h" if ARCH_MULTIPLATFORM || ARCH_MSM || \ +- PLAT_SAMSUNG || ARM_SINGLE_ARMV7M ++ PLAT_SAMSUNG || ARM_SINGLE_ARMV7M || \ ++ ARM_SINGLE_ARCH_VERSATILE + default "mach/uncompress.h" + + config EARLY_PRINTK +diff -Nur linux-4.15.13.orig/arch/arm/include/asm/mach/map.h linux-4.15.13/arch/arm/include/asm/mach/map.h +--- linux-4.15.13.orig/arch/arm/include/asm/mach/map.h 2018-03-24 11:02:53.000000000 +0100 ++++ linux-4.15.13/arch/arm/include/asm/mach/map.h 2018-04-01 03:47:17.587276119 +0100 +@@ -62,6 +62,7 @@ + #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 -Nur linux-4.15.13.orig/arch/arm/mach-versatile/Kconfig linux-4.15.13/arch/arm/mach-versatile/Kconfig +--- linux-4.15.13.orig/arch/arm/mach-versatile/Kconfig 2018-03-24 11:02:53.000000000 +0100 ++++ linux-4.15.13/arch/arm/mach-versatile/Kconfig 2018-04-01 03:47:33.417078219 +0100 +@@ -1,7 +1,8 @@ + # SPDX-License-Identifier: GPL-2.0 + config ARCH_VERSATILE +- bool "ARM Ltd. Versatile family" +- depends on ARCH_MULTI_V5 ++ bool "ARM Ltd. Versatile family" if ARCH_MULTI_V5 ++ depends on ARCH_MULTI_V5 || ARM_SINGLE_ARCH_VERSATILE ++ default y if ARM_SINGLE_ARCH_VERSATILE + select ARM_AMBA + select ARM_TIMER_SP804 + select ARM_VIC +diff -Nur linux-4.15.13.orig/arch/arm/mach-versatile/Makefile.boot linux-4.15.13/arch/arm/mach-versatile/Makefile.boot +--- linux-4.15.13.orig/arch/arm/mach-versatile/Makefile.boot 1970-01-01 01:00:00.000000000 +0100 ++++ linux-4.15.13/arch/arm/mach-versatile/Makefile.boot 2018-04-01 03:47:25.644175394 +0100 +@@ -0,0 +1,3 @@ ++# 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 -Nur linux-4.15.13.orig/arch/arm/mach-versatile/versatile_dt.c linux-4.15.13/arch/arm/mach-versatile/versatile_dt.c +--- linux-4.15.13.orig/arch/arm/mach-versatile/versatile_dt.c 2018-03-24 11:02:53.000000000 +0100 ++++ linux-4.15.13/arch/arm/mach-versatile/versatile_dt.c 2018-04-01 03:47:10.913359555 +0100 +@@ -37,7 +37,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/target/linux/patches/4.9.88/arm-nommu.patch b/target/linux/patches/4.9.88/arm-nommu.patch new file mode 100644 index 000000000..a9e80f197 --- /dev/null +++ b/target/linux/patches/4.9.88/arm-nommu.patch @@ -0,0 +1,80 @@ +diff -Nur linux-4.9.88.orig/arch/arm/Kconfig linux-4.9.88/arch/arm/Kconfig +--- linux-4.9.88.orig/arch/arm/Kconfig 2018-03-18 11:18:56.000000000 +0100 ++++ linux-4.9.88/arch/arm/Kconfig 2018-04-01 04:36:26.415410694 +0100 +@@ -362,6 +362,17 @@ + help + Support for the Cortina Systems Gemini family SoCs + ++config ARM_SINGLE_ARCH_VERSATILE ++ bool "ARM Ltd. Versatile family" ++ depends on !MMU ++ select AUTO_ZRELADDR ++ select CLKSRC_OF ++ select COMMON_CLK ++ select GENERIC_CLOCKEVENTS ++ select GPIOLIB ++ select SPARSE_IRQ ++ select USE_OF ++ + config ARCH_EBSA110 + bool "EBSA-110" + select ARCH_USES_GETTIMEOFFSET +diff -Nur linux-4.9.88.orig/arch/arm/Kconfig.debug linux-4.9.88/arch/arm/Kconfig.debug +--- linux-4.9.88.orig/arch/arm/Kconfig.debug 2018-03-18 11:18:56.000000000 +0100 ++++ linux-4.9.88/arch/arm/Kconfig.debug 2018-04-01 04:36:26.415410694 +0100 +@@ -1712,7 +1712,8 @@ + config UNCOMPRESS_INCLUDE + string + default "debug/uncompress.h" if ARCH_MULTIPLATFORM || ARCH_MSM || \ +- PLAT_SAMSUNG || ARM_SINGLE_ARMV7M ++ PLAT_SAMSUNG || ARM_SINGLE_ARMV7M || \ ++ ARM_SINGLE_ARCH_VERSATILE + default "mach/uncompress.h" + + config EARLY_PRINTK +diff -Nur linux-4.9.88.orig/arch/arm/include/asm/mach/map.h linux-4.9.88/arch/arm/include/asm/mach/map.h +--- linux-4.9.88.orig/arch/arm/include/asm/mach/map.h 2018-03-18 11:18:56.000000000 +0100 ++++ linux-4.9.88/arch/arm/include/asm/mach/map.h 2018-04-01 04:36:26.416410682 +0100 +@@ -62,6 +62,7 @@ + #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 -Nur linux-4.9.88.orig/arch/arm/mach-versatile/Kconfig linux-4.9.88/arch/arm/mach-versatile/Kconfig +--- linux-4.9.88.orig/arch/arm/mach-versatile/Kconfig 2018-03-18 11:18:56.000000000 +0100 ++++ linux-4.9.88/arch/arm/mach-versatile/Kconfig 2018-04-01 04:37:41.424472952 +0100 +@@ -1,6 +1,7 @@ + config ARCH_VERSATILE +- bool "ARM Ltd. Versatile family" +- depends on ARCH_MULTI_V5 ++ bool "ARM Ltd. Versatile family" if ARCH_MULTI_V5 ++ depends on ARCH_MULTI_V5 || ARM_SINGLE_ARCH_VERSATILE ++ default y if ARM_SINGLE_ARCH_VERSATILE + select ARM_AMBA + select ARM_TIMER_SP804 + select ARM_VIC +diff -Nur linux-4.9.88.orig/arch/arm/mach-versatile/Makefile.boot linux-4.9.88/arch/arm/mach-versatile/Makefile.boot +--- linux-4.9.88.orig/arch/arm/mach-versatile/Makefile.boot 1970-01-01 01:00:00.000000000 +0100 ++++ linux-4.9.88/arch/arm/mach-versatile/Makefile.boot 2018-04-01 04:36:26.417410669 +0100 +@@ -0,0 +1,3 @@ ++# 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 -Nur linux-4.9.88.orig/arch/arm/mach-versatile/versatile_dt.c linux-4.9.88/arch/arm/mach-versatile/versatile_dt.c +--- linux-4.9.88.orig/arch/arm/mach-versatile/versatile_dt.c 2018-03-18 11:18:56.000000000 +0100 ++++ linux-4.9.88/arch/arm/mach-versatile/versatile_dt.c 2018-04-01 04:36:26.417410669 +0100 +@@ -37,7 +37,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)) + + /* |