2 REQUIRE_IMAGE_METADATA=1
4 RAMFS_COPY_BIN='fw_printenv fw_setenv'
5 RAMFS_COPY_DATA='/etc/fw_env.config /var/lock/fw_printenv.lock'
7 platform_check_image() {
8 case "$(board_name)" in
11 local ubidev=$(nand_find_ubi $CI_UBIPART)
12 local asus_root=$(nand_find_volume $ubidev jffs2)
14 [ -n "$asus_root" ] || return 0
17 jffs2 partition is still present.
18 There's probably no space left
19 to install the filesystem.
21 You need to delete the jffs2 partition first:
22 # ubirmvol /dev/ubi0 --name=jffs2
24 Once this is done. Retry.
35 local board_dir=$(tar tf $tar_file | grep -m 1 '^sysupgrade-.*/$')
36 board_dir=${board_dir%/}
38 tar Oxf $tar_file ${board_dir}/root | mtd write - rootfs
46 local board_dir=$(tar tf $tar_file | grep -m 1 '^sysupgrade-.*/$')
47 board_dir=${board_dir%/}
49 tar Oxf $tar_file ${board_dir}/kernel | mtd write - kernel
51 if [ -n "$UPGRADE_BACKUP" ]; then
52 tar Oxf $tar_file ${board_dir}/root | mtd -j "$UPGRADE_BACKUP" write - rootfs
54 tar Oxf $tar_file ${board_dir}/root | mtd write - rootfs
58 platform_do_upgrade() {
59 case "$(board_name)" in
65 avm,fritzrepeater-1200 |\
66 avm,fritzrepeater-3000 |\
67 cilab,meshpoint-one |\
69 mobipromo,cm520-79f |\
73 alfa-network,ap120c-ac)
74 part="$(awk -F 'ubi.mtd=' '{printf $2}' /proc/cmdline | sed -e 's/ .*$//')"
75 if [ "$part" = "rootfs1" ]; then
76 fw_setenv active 2 || exit 1
79 fw_setenv active 1 || exit 1
102 platform_do_upgrade_linksys "$1"
105 CI_KERNPART="part.safe"
111 platform_do_upgrade_openmesh "$1"
114 zyxel_do_upgrade "$1"
117 default_do_upgrade "$1"