Differences between revisions 18 and 19
Revision 18 as of 2016-12-20 22:43:21
Size: 4482
Editor: ?UweKleine-König
Comment: removing the wifi being broken was too optimistic
Revision 19 as of 2016-12-21 04:36:16
Size: 4574
Editor: PaulWise
Comment: add note
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
/!\ This page should be rebased on the [[InstallingDebianOn/ComputerTemplate|template]].

/!\ This page should be rebased on the template.

Installing Debian On The Turris Omnia Router

The Turris Omnia is an ARM-based (mostly) open hardware router board developed by Project Turris of CZ.NIC. It was kickstarted at Indiegogo and is available in a few shops now.

By default it runs an OpenWRT derivative called TurrisOS, but Debian armhf userland can run on it, too. For now it though needs a custom (read non-Debian) kernel as well as some additional scripts to get all the features. The custom kernel is based on some Linux 4.x branch and is maintained on Github. (Update: it is unclear if that repository is the official one. The official repository is the OpenWRT fork and has a different set of patches.)

Installing vanilla Debian

There is no support in the Debian Installer yet, but the only critical part missing is the device tree. The following works fine after connecting the WAN port to a dhcp managed network:

   1 wget https://d-i.debian.org/daily-images/armhf/daily/netboot/vmlinuz
   2 wget https://d-i.debian.org/daily-images/armhf/daily/netboot/initrd.gz
   3 wget https://www.kleine-koenig.org/tmp/armada-385-turris-omnia.dtb

Then install a tftp server, put the above files in /srv/tftp and on the serial console enter the following in U-Boot:

mw 0xf1020300 0x403 #disable watchdog
setenv serverip <your_tftp_server_legacy_ip_address>
tftpboot 0x01000000 vmlinuz
tftpboot 0x02000000 armada-385-turris-omnia.dtb
tftpboot 0x03000000 initrd.gz
bootz 0x01000000 0x03000000:$filesize 0x02000000

If this fails for you with

Wrong Ramdisk Image Format
Ramdisk image is corrupt or invalid

your U-Boot needs an update. The U-Boot images that are about to be released by cz.nic are fixed, you can find them at https://api.turris.cz/openwrt-repo/omnia-test/nor_fw/. Update as follows after downloading the image to your tftp directory:

tftpboot 0x1000000 uboot-turris-omnia-spl.kwb
sf probe
sf update 0x1000000 0 $filesize

I recommend to use btrfs as rootfs, as U-Boot can handle that and TurrisOS also makes use of it. Before ending the installation put the dtb into the rootfs as /boot/dtb. Then you can boot into your linux using:

setenv mmcboot btrload mmc 0 0x01000000 boot/vmlinuz\; btrload mmc 0 0x02000000 boot/dtb\; btrload mmc 0 0x03000000 boot/initrd.img\; bootz 0x01000000 0x03000000:$filesize 0x02000000
setenv bootargs console=ttyS0,115200 rootfstype=btrfs rootdelay=2 root=/dev/mmcblk0p1 rootflags=commit=5 rw

There are some missing parts yet, so the SFP and switch port doesn't work. With the Debian kernel the wifi driver fails to probe, while this works with a monolithic (vanilla) kernel compiled for mvebu + ath10k.

Watchdog handling

The bootloader enables the watchdog of the SoC. To handle this you either have to disable it again in the bootloader (see above) or pet it regularly. For the latter just add


to /etc/systemd/system.conf.

MAC address

U-Boot doesn't provide the mac addresses to be used in the device tree. To make the Debian system use the right ones I did:

cat > /etc/systemd/network/00-eth0.link

and the same for eth1 (platform-f1030000.ethernet) and eth2 (platform-f1034000.ethernet).

The mac address reserved for your machine is saved in the crypto chip. To find out the base check U-Boot's ethaddr variable. You "own" this and the two following addresses.


The in-SoC RTC isn't working properly. It is somewhat working after doing

mw 0xf10184a0 0xfd4d4cfa

in U-Boot. If you don't do this, the driver only reads 2016-12-19 22:00:34 from it.

Installing with self-build kernel

For an alternative installation using a self compiled kernel (instead of a debian kernel as above) see the omnia-debian wiki. If you follow this one, you're not keen on cross-compiling and accept to trust images downloaded unencrypted from the internet, you can find an ready-made image on http://aule.elfove.cz/%7Ebrill/omnia-debian/.