X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=target%2Flinux%2Far71xx%2Fbase-files%2Flib%2Far71xx.sh;h=940c1c95de45456cf78d83c9f4baa4a9417eeeff;hb=098f7156cc68d07a8eed9574c76b90c7ade77026;hp=5d38555b9fcc41ce4d884581803a498d26925943;hpb=500a67a167a256002f8ab05171f49dfb86b03260;p=openwrt%2Fopenwrt.git diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh index 5d38555b9f..940c1c95de 100755 --- a/target/linux/ar71xx/base-files/lib/ar71xx.sh +++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh @@ -64,6 +64,39 @@ wndr3700_board_detect() { AR71XX_MODEL="$machine" } +ubnt_get_mtd_part_magic() { + ar71xx_get_mtd_offset_size_format EEPROM 4118 2 %02x +} + +ubnt_xm_board_detect() { + local model + local magic + + magic="$(ubnt_get_mtd_part_magic)" + case ${magic:0:3} in + "e00"|\ + "e01"|\ + "e80") # Different revisions of the NanoStation? + model="Ubiquiti NanoStation M" + ;; + "e0a") + model="Ubiquiti NanoStation loco M" + ;; + "e1b") # Rocket M5 untested + model="Ubiquiti Rocket M" + ;; + "e20"|\ + "e2d") # Bullet M Ti + model="Ubiquiti Bullet M" + ;; + "e30") + model="Ubiquiti PicoStation M" + ;; + esac + + [ -z "$model" ] || AR71XX_MODEL="${model}${magic:3:1}" +} + cybertan_get_hw_magic() { local part @@ -280,7 +313,7 @@ tplink_board_detect() { model="TP-Link TL-WDR6500" ;; "453000"*) - model="MERCURY MW4530R" + model="Mercury MW4530R" ;; "934100"*) model="NC-LINK SMART-300" @@ -449,6 +482,9 @@ ar71xx_board_detect() { *C-55) name="c-55" ;; + *C-60) + name="c-60" + ;; *CAP4200AG) name="cap4200ag" ;; @@ -503,6 +539,9 @@ ar71xx_board_detect() { *"DIR-835 rev. A1") name="dir-835-a1" ;; + *"DIR-869 rev. A1") + name="dir-869-a1" + ;; *"dLAN Hotspot") name="dlan-hotspot" ;; @@ -569,12 +608,14 @@ ar71xx_board_detect() { ;; *"Bullet M") name="bullet-m" + ubnt_xm_board_detect ;; *"Loco M XW") name="loco-m-xw" ;; *"Nanostation M") name="nanostation-m" + ubnt_xm_board_detect ;; *"Nanostation M XW") name="nanostation-m-xw" @@ -791,6 +832,7 @@ ar71xx_board_detect() { ;; *"Rocket M") name="rocket-m" + ubnt_xm_board_detect ;; *"Rocket M TI") name="rocket-m-ti" @@ -1098,6 +1140,12 @@ ar71xx_board_detect() { *WHR-HP-G300N) name="whr-hp-g300n" ;; + *Z1) + name="z1" + ;; + *ZBT-WE1526) + name="zbt-we1526" + ;; *ZCN-1523H-2) name="zcn-1523h-2" ;;