Commit Graph

5 Commits (2e5a0b81ec29a897fde5ca30b0dc95fd28b9d4fb)

Author SHA1 Message Date
Tomasz Maciej Nowak 2e5a0b81ec mvebu: sysupgrade: sdcard: keep user added partitons
Currently sysupgrade overwrites whole disk and destroys partitions added
by user. Sync the sysupgrade code with the one present in x86 target to
remedy this behaviour.

Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
5 years ago
Tomasz Maciej Nowak 4e8345ff68 mvebu: base-files: autodetect upgrade device
Since some boards could be also booted from other mediums than SD card,
lets make the upgrade block device autodetected.

Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
5 years ago
Rosen Penev e1fe4a93de mvebu: Get rid of RTC hack for Turris Omnia.
As Solidrun's RTC patch got merged, this hack is no longer needed.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
6 years ago
Ryan Mounce 9f3f61a0d9 mvebu: add support for Turris Omnia
Adds support for the Turris Omnia and builds an eMMC sysupgrade image in
the same format as the SolidRun ClearFog.

An initramfs image in the simple yet Omnia-specific 'medkit' image format
is also built in order to ease the initial flashing process.

Notable hardware support omissions are support for switching between SFP
cage and copper PHY, and RGB LED control.

Due to a current limitation of DSA, only 1/2 CPU switch uplinks are used.

Specifications:
- Marvell Armada 385 1.6GHz dual-core ARMv7 CPU
- 1GB DDR3 RAM
- 8GB eMMC Flash
- 5x Gigabit LAN via Marvell 88E6176 Switch (2x RGMII CPU ports)
- 1x switchable RJ45 (88E1514 PHY) / SFP SGMII WAN
- 2x USB 3.0
- 12x dimmable RGB LEDs controlled by independent MCU
- 3x Mini PCIe slots
- Optional Compex WLE200N2 Mini PCIe AR9287 2x2 802.11b/g/n (2.4GHz)
- Optional Compex WLE900VX Mini PCIe QCA9880 3x3 802.11ac (2.4 / 5GHz)
- Optional Quectel EC20 Mini PCIe LTE modem

Flash instructions:
If the U-Boot environment has been modified previously (likely manually via
serial console), first use serial to reset the default environment.
=> env default -a
=> saveenv

Method 1 - USB 'medkit' image w/o serial
- Copy openwrt-mvebu-turris-omnia-sysupgrade.img.gz and
omnia-medkit-openwrt-mvebu-turris-omnia-initramfs.tar.gz to the root of a
USB flash drive formatted with FAT32 / ext2/3/4 / btrfs / XFS.
Note that the medkit MUST be named omnia-medkit*.tar.gz
- Disconnect other USB devices from the Omnia and connect the flash drive
to either USB port.
- Power on the Omnia and hold down the rear reset button until 4 LEDs are
illuminated, then release.
- Wait approximately 2 minutes for the Turris Omnia to flash itself with
the temporary image, during which LEDs will change multiple times.
- Connect a computer to a LAN port of the Turris Omnia with a DHCP client
- (if necessary) ssh-keygen -R 192.168.1.1
- ssh root@192.168.1.1
$ mount /dev/sda1 /mnt
$ sysupgrade /mnt/openwrt-mvebu-turris-omnia-sysupgrade.img.gz
- Wait another minute for the final OpenWrt image to be flashed. The Turris
Omnia will reboot itself and you can remove the flash drive.

Method 2 - TFTP w/ serial
- Extract omnia-medkit-openwrt-mvebu-turris-omnia-initramfs.tar.gz and copy
dtb + zImage to your TFTP server (rename if desired)
- Connect Turris Omnia WAN port to DHCP-enabled network with TFTP server
- Connect serial console and interrupt U-Boot
=> dhcp
=> setenv serverip <tftp_server_ip_here>
=> tftpboot 0x01000000 zImage
=> tftpboot 0x02000000 dtb
=> bootz 0x01000000 - 0x02000000
- OpenWrt will now boot from ramdisk
- Download openwrt-mvebu-turris-omnia-sysupgrade.img.gz to /tmp/
$ sysupgrade /tmp/openwrt-mvebu-turris-omnia-sysupgrade.img.gz
- Wait another minute for the final OpenWrt image to be flashed. The Turris
Omnia will reboot itself.

Signed-off-by: Ryan Mounce <ryan@mounce.com.au>
6 years ago
Tomasz Maciej Nowak d29a2814b7 mvebu: rename clearfog sysupgrade script and functions
Cosmetic name change of ClearFog sysupgrade script and its functions to
more generic sdcard. This way it won't be confusing for other future
device additions.

Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
6 years ago