ath79: add Senao 'failsafe' sysupgrade procedure
[openwrt/openwrt.git] / target / linux / ath79 / tiny / base-files / lib / upgrade / platform.sh
1 #
2 # Copyright (C) 2011 OpenWrt.org
3 #
4
5 PART_NAME=firmware
6 REQUIRE_IMAGE_METADATA=1
7
8 RAMFS_COPY_BIN='fw_setenv'
9 RAMFS_COPY_DATA='/etc/fw_env.config'
10
11 platform_check_image() {
12 return 0
13 }
14
15 platform_do_upgrade() {
16 local board=$(board_name)
17
18 case "$board" in
19 engenius,eap350-v1|\
20 engenius,ecb350-v1|\
21 engenius,enh202-v1)
22 IMAGE_LIST="tar tzf $1"
23 IMAGE_CMD="tar xzOf $1"
24 KERNEL_PART="loader"
25 ROOTFS_PART="fwconcat0"
26 KERNEL_FILE="uImage-lzma.bin"
27 ROOTFS_FILE="root.squashfs"
28 platform_do_upgrade_failsafe_datachk "$1"
29 ;;
30 *)
31 default_do_upgrade "$1"
32 ;;
33 esac
34 }