aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux
diff options
context:
space:
mode:
authorDamir Samardzic <damir.samardzic@sartura.hr>2018-03-26 09:37:58 +0000
committerHauke Mehrtens <hauke@hauke-m.de>2018-03-31 16:13:19 +0200
commit2534141322b0541daa627a516280638c12a262fe (patch)
tree97e133471b59000fbf8b44801a1864a6677009da /target/linux
parentdff904a955ee59b1495b82f765884f787d24d540 (diff)
downloadupstream-2534141322b0541daa627a516280638c12a262fe.tar.gz
upstream-2534141322b0541daa627a516280638c12a262fe.tar.bz2
upstream-2534141322b0541daa627a516280638c12a262fe.zip
mvebu: add support for MACCHIATObin (cortex-a72)
Add initial support for Marvell MACCHIATObin, cortex-a72 based Marvell ARMADA 8040 Community board. Comes in two forms: Single Shot and Double Shot. Specifications: - Quad core Cortex-A72 (up to 2GHz) - DDR4 DIMM slot with optional ECC and single/dual chip select support - Dual 10GbE (1/2.5/10GbE) via copper or SFP 2.5GbE (1/2.5GbE) via SFP 1GbE via copper - SPI Flash - 3 X SATA 3.0 connectors - MicroSD connector - eMMC - PCI x4 3.0 slot - USB 2.0 Headers (Internal) - USB 3.0 connector - Console port (UART) over microUSB connector - 20-pin Connector for CPU JTAG debugger - 2 X UART Headers - 12V input via DC Jack - ATX type power connector - Form Factor: Mini-ITX (170 mm x 170 mm) More details at http://macchiatobin.net Booting from micro SD card: 1. reset U-Boot environment: env default -a saveenv 2. prepare U-Boot with boot script: setenv bootcmd "load mmc 1:1 0x4d00000 boot.scr; source 0x4d00000" saveenv or manually: setenv fdt_name armada-8040-mcbin.dtb setenv image_name Image setenv bootcmd 'mmc dev 1; ext4load mmc 1:1 $kernel_addr $image_name;ext4load mmc 1:1 $fdt_addr $fdt_name;setenv bootargs $console root=/dev/mmcblk1p2 rw rootwait; booti $kernel_addr - $fdt_addr' saveenv Signed-off-by: Damir Samardzic <damir.samardzic@sartura.hr>
Diffstat (limited to 'target/linux')
-rw-r--r--target/linux/mvebu/Makefile2
-rwxr-xr-xtarget/linux/mvebu/base-files/etc/board.d/02_network3
-rwxr-xr-xtarget/linux/mvebu/base-files/lib/mvebu.sh3
-rwxr-xr-xtarget/linux/mvebu/base-files/lib/upgrade/platform.sh4
-rw-r--r--target/linux/mvebu/cortexa72/config-default120
-rw-r--r--target/linux/mvebu/cortexa72/target.mk15
-rw-r--r--target/linux/mvebu/image/Makefile1
-rw-r--r--target/linux/mvebu/image/armada-macchiatobin.bootscript10
-rw-r--r--target/linux/mvebu/image/cortex-a72.mk16
9 files changed, 171 insertions, 3 deletions
diff --git a/target/linux/mvebu/Makefile b/target/linux/mvebu/Makefile
index 0afc5771c2..ee76c0b776 100644
--- a/target/linux/mvebu/Makefile
+++ b/target/linux/mvebu/Makefile
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
BOARD:=mvebu
BOARDNAME:=Marvell EBU Armada
FEATURES:=fpu usb pci pcie gpio nand squashfs ramdisk
-SUBTARGETS:=cortexa9 cortexa53
+SUBTARGETS:=cortexa9 cortexa53 cortexa72
MAINTAINER:=Imre Kaloz <kaloz@openwrt.org>
KERNEL_PATCHVER:=4.14
diff --git a/target/linux/mvebu/base-files/etc/board.d/02_network b/target/linux/mvebu/base-files/etc/board.d/02_network
index 28cdc22b28..8e57e8e1ce 100755
--- a/target/linux/mvebu/base-files/etc/board.d/02_network
+++ b/target/linux/mvebu/base-files/etc/board.d/02_network
@@ -45,6 +45,9 @@ armada-xp-gp)
globalscale,espressobin)
ucidef_set_interfaces_lan_wan "lan0 lan1" "wan"
;;
+marvell,armada8040-mcbin)
+ ucidef_set_interfaces_lan_wan "eth0 eth1 eth3" "eth2"
+ ;;
*)
ucidef_set_interface_lan "eth0"
;;
diff --git a/target/linux/mvebu/base-files/lib/mvebu.sh b/target/linux/mvebu/base-files/lib/mvebu.sh
index 707ceb18ef..840cc1ca2a 100755
--- a/target/linux/mvebu/base-files/lib/mvebu.sh
+++ b/target/linux/mvebu/base-files/lib/mvebu.sh
@@ -20,6 +20,9 @@ mvebu_board_detect() {
*"Globalscale Marvell ESPRESSOBin Board")
name="globalscale,espressobin"
;;
+ *"Marvell 8040 MACHIATOBin")
+ name="marvell,armada8040-mcbin"
+ ;;
*"Globalscale Mirabox")
name="mirabox"
;;
diff --git a/target/linux/mvebu/base-files/lib/upgrade/platform.sh b/target/linux/mvebu/base-files/lib/upgrade/platform.sh
index 3915bfdb7c..15c5433792 100755
--- a/target/linux/mvebu/base-files/lib/upgrade/platform.sh
+++ b/target/linux/mvebu/base-files/lib/upgrade/platform.sh
@@ -16,7 +16,7 @@ platform_do_upgrade() {
armada-385-linksys-caiman|armada-385-linksys-cobra|armada-385-linksys-rango|armada-385-linksys-shelby|armada-xp-linksys-mamba)
platform_do_upgrade_linksys "$ARGV"
;;
- armada-385-turris-omnia|armada-388-clearfog-base|armada-388-clearfog-pro|globalscale,espressobin)
+ armada-385-turris-omnia|armada-388-clearfog-base|armada-388-clearfog-pro|globalscale,espressobin|marvell,armada8040-mcbin)
platform_do_upgrade_sdcard "$ARGV"
;;
*)
@@ -29,7 +29,7 @@ platform_copy_config() {
armada-385-linksys-caiman|armada-385-linksys-cobra|armada-385-linksys-rango|armada-385-linksys-shelby|armada-xp-linksys-mamba)
platform_copy_config_linksys
;;
- armada-385-turris-omnia|armada-388-clearfog-base|armada-388-clearfog-pro|globalscale,espressobin)
+ armada-385-turris-omnia|armada-388-clearfog-base|armada-388-clearfog-pro|globalscale,espressobin|marvell,armada8040-mcbin)
platform_copy_config_sdcard "$ARGV"
;;
esac
diff --git a/target/linux/mvebu/cortexa72/config-default b/target/linux/mvebu/cortexa72/config-default
new file mode 100644
index 0000000000..c793f7c5e8
--- /dev/null
+++ b/target/linux/mvebu/cortexa72/config-default
@@ -0,0 +1,120 @@
+CONFIG_64BIT=y
+# CONFIG_ACPI is not set
+CONFIG_ARCH_DMA_ADDR_T_64BIT=y
+CONFIG_ARCH_HAS_CACHE_LINE_SIZE=y
+CONFIG_ARCH_HAS_FORTIFY_SOURCE=y
+CONFIG_ARCH_HAS_HOLES_MEMORYMODEL=y
+CONFIG_ARCH_HAS_KCOV=y
+CONFIG_ARCH_MMAP_RND_BITS=18
+CONFIG_ARCH_MMAP_RND_BITS_MAX=24
+CONFIG_ARCH_MMAP_RND_BITS_MIN=18
+CONFIG_ARCH_MMAP_RND_COMPAT_BITS_MIN=11
+# CONFIG_ARCH_OPTIONAL_KERNEL_RWX is not set
+# CONFIG_ARCH_OPTIONAL_KERNEL_RWX_DEFAULT is not set
+CONFIG_ARCH_PHYS_ADDR_T_64BIT=y
+CONFIG_ARCH_PROC_KCORE_TEXT=y
+CONFIG_ARCH_SELECT_MEMORY_MODEL=y
+CONFIG_ARCH_SPARSEMEM_DEFAULT=y
+CONFIG_ARCH_SPARSEMEM_ENABLE=y
+CONFIG_ARCH_SUPPORTS_DEBUG_PAGEALLOC=y
+CONFIG_ARCH_SUPPORTS_MEMORY_FAILURE=y
+CONFIG_ARCH_SUPPORTS_NUMA_BALANCING=y
+CONFIG_ARCH_WANT_COMPAT_IPC_PARSE_VERSION=y
+CONFIG_ARCH_WANT_FRAME_POINTERS=y
+CONFIG_ARCH_WANT_HUGE_PMD_SHARE=y
+CONFIG_ARM64=y
+# CONFIG_ARM64_16K_PAGES is not set
+CONFIG_ARM64_4K_PAGES=y
+# CONFIG_ARM64_64K_PAGES is not set
+CONFIG_ARM64_CONT_SHIFT=4
+# CONFIG_ARM64_CRYPTO is not set
+# CONFIG_ARM64_HW_AFDBM is not set
+# CONFIG_ARM64_LSE_ATOMICS is not set
+CONFIG_ARM64_PAGE_SHIFT=12
+# CONFIG_ARM64_PAN is not set
+# CONFIG_ARM64_PMEM is not set
+# CONFIG_ARM64_PTDUMP_CORE is not set
+# CONFIG_ARM64_PTDUMP_DEBUGFS is not set
+# CONFIG_ARM64_RANDOMIZE_TEXT_OFFSET is not set
+# CONFIG_ARM64_SW_TTBR0_PAN is not set
+# CONFIG_ARM64_UAO is not set
+CONFIG_ARM64_VA_BITS=39
+CONFIG_ARM64_VA_BITS_39=y
+# CONFIG_ARM64_VA_BITS_48 is not set
+# CONFIG_ARM64_VHE is not set
+CONFIG_ARMADA_AP806_SYSCON=y
+CONFIG_ARMADA_CP110_SYSCON=y
+CONFIG_ARM_AMBA=y
+CONFIG_ARM_ARCH_TIMER=y
+CONFIG_ARM_ARCH_TIMER_EVTSTREAM=y
+CONFIG_ARM_GIC_V2M=y
+CONFIG_ARM_GIC_V3=y
+CONFIG_ARM_GIC_V3_ITS=y
+# CONFIG_ARM_PL172_MPMC is not set
+CONFIG_ARM_PSCI_FW=y
+# CONFIG_ARM_SP805_WATCHDOG is not set
+CONFIG_AUDIT_ARCH_COMPAT_GENERIC=y
+# CONFIG_COMPAT is not set
+# CONFIG_DEBUG_ALIGN_RODATA is not set
+CONFIG_FRAME_POINTER=y
+CONFIG_GENERIC_BUG_RELATIVE_POINTERS=y
+CONFIG_GENERIC_CSUM=y
+CONFIG_GENERIC_IRQ_MIGRATION=y
+CONFIG_GENERIC_PINCONF=y
+CONFIG_GENERIC_TIME_VSYSCALL=y
+CONFIG_HAVE_ALIGNED_STRUCT_PAGE=y
+CONFIG_HAVE_ARCH_HUGE_VMAP=y
+CONFIG_HAVE_ARCH_KASAN=y
+CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
+CONFIG_HAVE_ARCH_VMAP_STACK=y
+CONFIG_HAVE_CMPXCHG_DOUBLE=y
+CONFIG_HAVE_CMPXCHG_LOCAL=y
+CONFIG_HAVE_DEBUG_BUGVERBOSE=y
+CONFIG_HAVE_GENERIC_GUP=y
+CONFIG_HAVE_MEMORY_PRESENT=y
+CONFIG_HAVE_PATA_PLATFORM=y
+CONFIG_HAVE_RCU_TABLE_FREE=y
+# CONFIG_HUGETLBFS is not set
+CONFIG_I2C_MUX_PCA954x=y
+CONFIG_ILLEGAL_POINTER_VALUE=0xdead000000000000
+CONFIG_MFD_SYSCON=y
+CONFIG_MMC_SDHCI_XENON=y
+CONFIG_MODULES_USE_ELF_RELA=y
+CONFIG_MV_XOR_V2=y
+CONFIG_MVEBU_GICP=y
+CONFIG_MVEBU_ICU=y
+CONFIG_MVEBU_ODMI=y
+CONFIG_MVEBU_PIC=y
+CONFIG_NEED_SG_DMA_LENGTH=y
+CONFIG_NET_DSA=y
+CONFIG_NET_DSA_MV88E6XXX=y
+CONFIG_NET_DSA_MV88E6XXX_GLOBAL2=y
+# CONFIG_NET_DSA_SMSC_LAN9303_I2C is not set
+CONFIG_NET_DSA_TAG_DSA=y
+CONFIG_NET_DSA_TAG_EDSA=y
+CONFIG_NET_SWITCHDEV=y
+# CONFIG_NUMA is not set
+CONFIG_PARTITION_PERCPU=y
+CONFIG_PCIEAER=y
+CONFIG_PCIE_ARMADA_8K=y
+# CONFIG_PCI_AARDVARK is not set
+CONFIG_PCI_BUS_ADDR_T_64BIT=y
+CONFIG_PGTABLE_LEVELS=3
+CONFIG_PHY_MVEBU_CP110_COMPHY=y
+CONFIG_PHYS_ADDR_T_64BIT=y
+CONFIG_PINCTRL_ARMADA_AP806=y
+CONFIG_PINCTRL_ARMADA_CP110=y
+CONFIG_POWER_RESET=y
+CONFIG_POWER_SUPPLY=y
+# CONFIG_RANDOMIZE_BASE is not set
+CONFIG_REGULATOR_GPIO=y
+# CONFIG_SERIAL_AMBA_PL011 is not set
+CONFIG_SPARSEMEM=y
+CONFIG_SPARSEMEM_EXTREME=y
+CONFIG_SPARSEMEM_MANUAL=y
+CONFIG_SPARSEMEM_VMEMMAP=y
+CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y
+CONFIG_SYSCTL_EXCEPTION_TRACE=y
+CONFIG_SYS_SUPPORTS_HUGETLBFS=y
+CONFIG_THREAD_INFO_IN_TASK=y
+CONFIG_VMAP_STACK=y
diff --git a/target/linux/mvebu/cortexa72/target.mk b/target/linux/mvebu/cortexa72/target.mk
new file mode 100644
index 0000000000..670c402a56
--- /dev/null
+++ b/target/linux/mvebu/cortexa72/target.mk
@@ -0,0 +1,15 @@
+#
+# Copyright (C) 2018 Sartura Ltd.
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+ARCH:=aarch64
+BOARDNAME:=Marvell Armada 7k/8k (ARM64)
+CPU_TYPE:=cortex-a72
+FEATURES+=ext4
+
+KERNELNAME:=Image dtbs
diff --git a/target/linux/mvebu/image/Makefile b/target/linux/mvebu/image/Makefile
index 4f6d8f529e..be01623e86 100644
--- a/target/linux/mvebu/image/Makefile
+++ b/target/linux/mvebu/image/Makefile
@@ -125,5 +125,6 @@ endef
include cortex-a9.mk
include cortex-a53.mk
+include cortex-a72.mk
$(eval $(call BuildImage))
diff --git a/target/linux/mvebu/image/armada-macchiatobin.bootscript b/target/linux/mvebu/image/armada-macchiatobin.bootscript
new file mode 100644
index 0000000000..ae9fdca92d
--- /dev/null
+++ b/target/linux/mvebu/image/armada-macchiatobin.bootscript
@@ -0,0 +1,10 @@
+setenv bootargs "root=PARTUUID=@ROOT@-02 rw rootwait"
+
+if test -n "${console}"; then
+ setenv bootargs "${bootargs} ${console}"
+fi
+
+load mmc 1:1 ${fdt_addr} armada-8040-mcbin.dtb
+load mmc 1:1 ${kernel_addr} Image
+
+booti ${kernel_addr} - ${fdt_addr}
diff --git a/target/linux/mvebu/image/cortex-a72.mk b/target/linux/mvebu/image/cortex-a72.mk
new file mode 100644
index 0000000000..ac9cb50a85
--- /dev/null
+++ b/target/linux/mvebu/image/cortex-a72.mk
@@ -0,0 +1,16 @@
+ifeq ($(SUBTARGET),cortexa72)
+
+define Device/armada-macchiatobin
+ KERNEL_NAME := Image
+ KERNEL := kernel-bin
+ DEVICE_TITLE := MACCHIATObin (SolidRun Armada 8040 Community Board)
+ DEVICE_PACKAGES := e2fsprogs ethtool mkf2fs kmod-fs-vfat kmod-mmc
+ IMAGES := sdcard.img.gz
+ IMAGE/sdcard.img.gz := boot-scr | boot-img-ext4 | sdcard-img-ext4 | gzip | append-metadata
+ DEVICE_DTS := armada-8040-mcbin
+ DTS_DIR := $(DTS_DIR)/marvell
+ SUPPORTED_DEVICES := marvell,armada8040-mcbin
+endef
+TARGET_DEVICES += armada-macchiatobin
+
+endif