ralink: add support for firewrt
[openwrt/openwrt.git] / target / linux / ramips / base-files / lib / upgrade / platform.sh
index 4962b8b4d080b99856e589f52f73230473a90e98..ff7126a96fcabd580f7c58391bffa0b0b19b0d05 100755 (executable)
@@ -19,6 +19,7 @@ platform_check_image() {
        3g300m | \
        a5-v11 | \
        air3gii | \
+       ai-br100 |\
        all0239-3g | \
        all0256n | \
        all5002 | \
@@ -49,14 +50,17 @@ platform_check_image() {
        f7c027 | \
        fonera20n | \
        freestation5 | \
+       firewrt |\
        hg255d | \
        hlk-rm04 | \
        ht-tm02 | \
        hw550-3g | \
        ip2202 | \
+       m2m | \
        m3 | \
        m4 | \
        mlw221 | \
+       mlwg2 | \
        mofi3500-3gn | \
        mpr-a1 | \
        mpr-a2 | \
@@ -90,7 +94,6 @@ platform_check_image() {
        whr-600d |\
        whr-1166d |\
        wsr-600 |\
-       wsr-1166 |\
        wl-330n | \
        wl-330n3g | \
        wl-351 | \
@@ -115,6 +118,13 @@ platform_check_image() {
                }
                return 0
                ;;
+       wsr-1166)
+               [ "$magic" != "48445230" ] && {
+                       echo "Invalid image type."
+                       return 1
+               }
+               return 0
+               ;;
        ar670w)
                [ "$magic" != "6d000080" ] && {
                        echo "Invalid image type."
@@ -124,7 +134,8 @@ platform_check_image() {
                ;;
        cy-swr1100 |\
        dir-610-a1 |\
-       dir-645)
+       dir-645 |\
+       dir-860l-b1)
                [ "$magic" != "5ea3a417" ] && {
                        echo "Invalid image type."
                        return 1
@@ -138,6 +149,13 @@ platform_check_image() {
                }
                return 0
                ;;
+       c20i)
+               [ "$magic" != "03000000" ] && {
+                       echo "Invalid image type."
+                       return 1
+               }
+               return 0
+               ;;
        esac
 
        echo "Sysupgrade is not yet supported on $board."