X-Git-Url: http://git.ozo.com/?p=openwrt-10.03%2F.git;a=blobdiff_plain;f=target%2Flinux%2Far71xx%2Fbase-files%2Flib%2Fupgrade%2Fplatform.sh;h=67f404808638bdeb90dbb981c5fad82b54b8fb8d;hp=a1beee30160940ffe28c790cdbef2896f3aedee8;hb=d0e868b3f098b9b8af702c3af94f77667670b5f0;hpb=903cab07f2c51d95660e57d839978afed8bfd8d5 diff --git a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh index a1beee301..67f404808 100755 --- a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh +++ b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh @@ -64,11 +64,12 @@ platform_do_upgrade_combined() { platform_check_image() { local board=$(ar71xx_board_name) local magic="$(get_magic_word "$1")" + local magic_long="$(get_magic_long "$1")" [ "$ARGC" -gt 1 ] && return 1 case "$board" in - ap81 | ap83 | dir-600-a1 | dir-615-c1 | dir-825-b1 | mzk-w04nu | mzk-w300nh | tew-632brp | wrt400n | bullet-m | nano-m | rocket-m | wzr-hp-g300nh) + ap81 | ap83 | dir-600-a1 | dir-615-c1 | dir-825-b1 | mzk-w04nu | mzk-w300nh | tew-632brp | wrt400n | bullet-m | nanostation-m | rocket-m | wzr-hp-g300nh ) [ "$magic" != "2705" ] && { echo "Invalid image type." return 1 @@ -83,7 +84,14 @@ platform_check_image() { return 0 ;; wndr3700) - [ "$magic" != "3337" ] && { + [ "$magic_long" != "33373030" ] && { + echo "Invalid image type." + return 1 + } + return 0 + ;; + wndr3700v2) + [ "$magic_long" != "33373031" ] && { echo "Invalid image type." return 1 } @@ -123,7 +131,7 @@ platform_do_upgrade() { local board=$(ar71xx_board_name) case "$board" in - routerstation | routerstation-pro) + routerstation | routerstation-pro | ls-sr71) platform_do_upgrade_combined "$ARGV" ;; *)