Home - MarvellEmbeddedProcessors/openwrt-dd GitHub Wiki

Armada 8K/7K/37xx

Warning
compat-wireless package has been updated recently.
Please update both openwrt-kernel and openwrt-dd repositories to get the latest patches and avoid build failures!

Prerequisites

Before we start, make sure you have installed the additional packages required to build the OpenWrt/LEDE:

subversion build-essential libncurses5-dev zlib1g-dev gawk git ccache gettext libssl-dev xsltproc file

Packages should be available for the installation with your default distribution package manager.

You can also check a complete list of dependencies here.

Bootloader

IMPORTANT: In order to provide the full device funtionality, you will have to reflash the u-boot version to match the version of the OpenWrt release you are planning to use.

For example:

U-Boot 2017.03-armada-17.10.1-00489-ge7c0ff4 for the OpenWrt 17.10 release.

To check the current version of u-boot (platform independent), connect the device over serial port and power on the board. You should see the relevant informations in the first few lines:

WTMI-armada-17.10.1-af63f95
ENTER init_ddrgen
DDR_TOPOLOGY is 0 :	DDR3, 1CS 512M
WTMI_CLOCK=3

Fill memory before self refresh...done

Now in Self-refresh Mode
Restore CAS Read and Write Latency
Restore termination values to original values
Exited self-refresh ...

DLL TUNING
==============
   DLL 0xc0001050[21:16]: [0,2d,16]
   DLL 0xc0001050[29:24]: [0,35,1a]
   DLL 0xc0001054[21:16]: [0,2b,15]
   DLL 0xc0001054[29:24]: [3,38,1d]
   DLL 0xc0001074[21:16]: [0,3f,1f]
   DLL 0xc0001074NOTICE:  Booting Trusted Firmware
NOTICE:  BL1: v1.3(release):armada-17.10.3:bc3abfd
NOTICE:  BL1: Built : 11:49:48, Oct  3 2NOTICE:  BL2: v1.3(release):armada-17.10.3:bc3abfd
NOTICE:  BL2: Built : 11:49:50, Oct  3 20NOTICE:  BL31: v1.3(release):armada-17.10.3:bc3abfd
NOTICE:  BL31:

U-Boot 2017.03-armada-17.10.1-00489-ge7c0ff4 (Oct 03 2017 - 11:49:25 +0000), Build: a37xx-ga-17.10.1

Model: Marvell Armada 3720 Development Board DB-88F3720-DDR3-V2
       CPU    @ 1200 [MHz]
       L2     @ 800 [MHz]
       TClock @ 200 [MHz]
       DDR    @ 750 [MHz]
DRAM:  512 MiB
...

Alternatively, press any key to stop the booting procedure, and type version in the u-boot prompt:

Marvell>> version

U-Boot 2017.03-armada-17.10.1-00489-ge7c0ff4 (Oct 03 2017 - 11:49:25 +0000)
aarch64-linux-gnu-gcc (Linaro GCC 5.3-2016.05) 5.3.1 20160412
GNU ld (Linaro_Binutils-2016.05) 2.25.0 Linaro 2016_02

Appropriate versions of u-boot can be obtained from Extranet.

Obtaining Kernel

The kernel we will use is Marvell’s LSP with additional distribution patches on top of it.
Create a kernel directory if it doesn’t exist already:

mkdir -p /opt/kernel && cd /opt/kernel
Tip
You may have to need to set the correct permission for the directory:
sudo chown -R $(whoami):$(id -gn) /opt/kernel

Change working directory:

cd /opt/kernel

Choose one of the following commands to obtain kernel depending on the release version/distribution you want to use:

OpenWrt 17.02 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-kernel.git -b openwrt_17.02_release openwrt-kernel

OpenWrt 17.06 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-kernel.git -b openwrt_17.06_release openwrt-kernel

OpenWrt 17.10 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-kernel.git -b openwrt_17.10_release openwrt-kernel

LEDE 17.02 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-kernel.git -b lede_17.02_release lede-kernel

LEDE 17.06 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-kernel.git -b lede_17.06_release lede-kernel

Get distribution

The assumed working subdirectory will be: /opt/openwrt

mkdir -p /opt/openwrt
Tip
You may have to need to set the correct permission for the directory:
sudo chown -R $(whoami):$(id -gn) /opt/openwrt

Change the working directory:

cd /opt/openwrt/

OpenWrt

Use one of the following commands depending on OpenWrt release you want.

OpenWrt 17.02 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-dd.git -b openwrt_17.02_release openwrt

OpenWrt 17.06 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-dd.git -b openwrt_17.06_release openwrt

OpenWrt 17.10 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-dd.git -b openwrt_17.10_release openwrt

LEDE

Use one of the following commands depending on LEDE release you want.

LEDE 17.02 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-dd.git -b lede_17.02_release lede

LEDE 17.06 release:

git clone [email protected]:MarvellEmbeddedProcessors/openwrt-dd.git -b lede_17.06_release lede

Distribution working directory

In the further documentation, distribution working directory will refer to the location where you cloned the repositories. Depending on the choices above, we will assume location for these is either:

  • /opt/openwrt/openwrt - For OpenWrt releases

  • /opt/openwrt/lede - For LEDE releases

Build environment

In most cases, the (stable) GNU/Linux distribution of your choice should be sufficient for building the OpenWrt image.

However if you are using the testing repositories, bleeding-edge distro or the latest/unstable development packages, you could encounter problems with building the OpenWrt’s cross-toolchain and/or compiler.

If this is the case, we advise use of the Docker container with one of the stable images,
e.g Ubuntu 16.04

⚠️ **GitHub.com Fallback** ⚠️