mvebu: add support for Turris MOX
authorTomáš Macholda <[email protected]>
Thu, 18 Sep 2025 11:08:52 +0000 (13:08 +0200)
committerHauke Mehrtens <[email protected]>
Sun, 30 Nov 2025 23:32:14 +0000 (00:32 +0100)
commitea6ee930601cfc260e6477f573513850f1806012
tree9414708faa26e996fb0aa55f8eee58c80f90e84e
parentcfb976d1d72ddf3c6ae35bac40939b14adfdef15
mvebu: add support for Turris MOX

Adds support for Turris MOX, a modular router extendable by board modules (MOX B-G).

You can explore the idea behind the modules at: https://mox-configurator.turris.cz/

More information about Turris MOX can be found here: https://docs.turris.cz/hw/mox/intro/

Also works with Turris Shield (Turris MOX A and C with a simplified OS UI).

Specifications:
-----------------------

MOX A
- SoC: Marvell Armada 3720
- RAM: 512/1024 MB, DDR3
- Memory:
    - 8 MB SPI NOR Flash for U-Boot and rescue system
    - SD card slot
- 1x RJ-45, 1Gbps
- 1x USB 3.0
- 1x activity LED
- 1x reset button
- SDIO header
- misc pin header (UART, GPIO, JTAG, ...)

MOX B, G
- 1x mPCIe slot
- 1x SIM slot

MOX C
- 4x RJ-45, 1Gbps

MOX D
- SFP, 2.5Gbps

MOX E
- 8x RJ-45, 1Gbps

MOX F
- 4x USB 3.0

Module support:
-----------------------

Additional packages are needed for some modules.

MOX A (core)
- works as is

MOX B, G (mPCIe, mPCIe passthrough)
- works as is

MOX C, E (4x, 8x RJ-45)
- kmod-dsa
- kmod-dsa-mv88e6xxx

MOX D (SFP)
- kmod-sfp
- kmod-phy-marvell-10g

MOX F (4x USB 3.0)
- works as is

Wi-Fi 5, 3x3 card (WLE900VX)
- kmod-ath10k
- ath10k-board-qca988x
- ath10k-firmware-qca988x

Wi-Fi 6, DBDC, 2x2 card (MT7915DAN)
- kmod-mt7915e
- kmod-mt7915-firmware

Interface naming:
-----------------------

- MOX A's RJ-45 is assigned to `eth0`.
- MOX C, E (4x, 8x RJ-45) are assigned to `lan<number>@eth1`
- If MOX D (SFP) is connected directly to MOX A, the resulting interface
  is `eth1`. If it's connected through MOX E (8x RJ-45), the resulting
  interface is `sfp@eth1`.

Quirks:
-----------------------

- MOX is sensitive to the order of connected modules. Verify that the
  confguration is valid at: https://mox-configurator.turris.cz/
- `CONFIG_MOXTET` and `CONFIG_GPIO_MOXTET` need to be enabled in kernel
  config. Moxtet is a bus protocol needed to discover and configure MOX
  modules. It must be compiled into the kernel for the modules to work.
  Though it's very small so it won't bloat up the kernel image.

Flashing instructions:
-----------------------

1. Download `openwrt-*-ext4-sdcard.img.gz` and `gunzip` it.
2. Insert an SD card and flash the image to it using dd:
   dd if=openwrt-*-ext4-sdcard.img.gz of=/dev/mmcblk0 bs=4096 conv=fsync
3. Plug the SD card into MOX.

Troubleshooting:
-----------------------

- https://docs.turris.cz/hw/serial/#turris-mox
- https://docs.turris.cz/hw/mox/rescue-modes/

Signed-off-by: Tomáš Macholda <[email protected]>
Link: https://github.com/openwrt/openwrt/pull/20356
Signed-off-by: Hauke Mehrtens <[email protected]>
package/boot/uboot-mvebu/Makefile
target/linux/mvebu/cortexa53/base-files/etc/board.d/01_leds
target/linux/mvebu/cortexa53/base-files/etc/board.d/02_network
target/linux/mvebu/cortexa53/config-6.12
target/linux/mvebu/image/cortexa53.mk
target/linux/mvebu/image/turris-mox.bootscript [new file with mode: 0644]