openwrt/target/linux/mediatek/dts
Dim Fish f11e6e221e mediatek: filogic: add support for Xiaomi AX3000T
**SoC**: MediaTek MT7981B 2x A53
  **Flash**: ESMT F50L1G41LB 128MB
  **RAM**: NT52B128M16JR-FL 256MB
  **Ethernet**: 4x 10/100/1000 Mbps
  **Switch**: MediaTek MT7531AE
  **WiFi**: MediaTek MT7976C
  **Buttons**: Reset, Mesh
  **Power**: DC 12V 1A

1. Get ssh access. Supported stock firmware **1.0.47**
   ```
   curl -X POST "http://192.168.31.1/cgi-bin/luci/;stok=*******/api/misystem/arn_switch" -d "open=1&model=1&level=%0Anvram%20set%20ssh_en%3D1%0A"
   curl -X POST "http://192.168.31.1/cgi-bin/luci/;stok=*******/api/misystem/arn_switch" -d "open=1&model=1&level=%0Anvram%20commit%0A"
   curl -X POST "http://192.168.31.1/cgi-bin/luci/;stok=*******/api/misystem/arn_switch" -d "open=1&model=1&level=%0Ased%20-i%20's%2Fchannel%3D.*%2Fchannel%3D%22debug%22%2Fg'%20%2Fetc%2Finit.d%2Fdropbear%0A"
   curl -X POST "http://192.168.31.1/cgi-bin/luci/;stok=*******/api/misystem/arn_switch" -d "open=1&model=1&level=%0A%2Fetc%2Finit.d%2Fdropbear%20start%0A"
   curl -X POST "http://192.168.31.1/cgi-bin/luci/;stok=********/api/misystem/arn_switch" -d "open=1&model=1&level=%0Apasswd%20-d%20root%0A
   ```

2. Backup stock partitions
   ```
   nanddump -f /tmp/BL2.bin /dev/mtd1
   nanddump -f /tmp/Nvram.bin /dev/mtd2
   nanddump -f /tmp/Bdata.bin /dev/mtd3
   nanddump -f /tmp/Factory.bin /dev/mtd4
   nanddump -f /tmp/FIP.bin /dev/mtd5
   nanddump -f /tmp/ubi.bin /dev/mtd8
   nanddump -f /tmp/KF.bin /dev/mtd12
   ```
   Then transfer them to your computer in a safe place.

3. Get firmware information `cat /proc/cmdline`

4. Copy openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-initramfs-factory.ubi to **/tmp** and flash
   If **firmware=0**
   ```
   ubiformat /dev/mtd9 -y -f /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-initramfs-factory.ubi
   nvram set boot_wait=on
   nvram set uart_en=1
   nvram set flag_boot_rootfs=1
   nvram set flag_last_success=1
   nvram set flag_boot_success=1
   nvram set flag_try_sys1_failed=0
   nvram set flag_try_sys2_failed=0
   nvram commit
   reboot
   ```
   If **firmware=1**
   ```
   ubiformat /dev/mtd8 -y -f /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-initramfs-factory.ubi
   nvram set boot_wait=on
   nvram set uart_en=1
   nvram set flag_boot_rootfs=0
   nvram set flag_last_success=0
   nvram set flag_boot_success=1
   nvram set flag_try_sys1_failed=0
   nvram set flag_try_sys2_failed=0
   nvram commit
   reboot
   ```

   Then reboot your router, it should boot to the OpenWrt initramfs system now.

5. Flash openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-squashfs-sysupgrade.bin
   `sysupgrade -n /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-squashfs-sysupgrade.bin`

1. Flash openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-initramfs-recovery.itb
   `ubiformat /dev/mtd8 -y -f /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-initramfs-recovery.itb`

   `reboot`

2. Install kmod-mtd-rw
   `opkg update && opkg install kmod-mtd-rw`

   `insmod /lib/modules/$(uname -r)/mtd-rw.ko i_want_a_brick=1`

3. Format ubi and create new ubootenv volume
   ```
   ubidetach -p /dev/mtd8; ubiformat /dev/mtd8 -y; ubiattach -p /dev/mtd8
   ubimkvol /dev/ubi0 -n 0 -N ubootenv -s 128KiB
   ubimkvol /dev/ubi0 -n 1 -N ubootenv2 -s 128KiB
   ```

4. *(Optional **-10Mb** free space) Add recovery boot feature.*
   ```
   ubimkvol /dev/ubi0 -n 2 -N recovery -s 10MiB
   ubiupdatevol /dev/ubi0_2 /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-initramfs-recovery.itb
   ```

5. Flash Openwrt U-Boot
   ```
   mtd write /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-preloader.bin BL2
   mtd write /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-bl31-uboot.fip FIP
   ```

6. Flash openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-squashfs-sysupgrade.itb
   `sysupgrade -n /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-squashfs-sysupgrade.itb`

1. Force flash openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-initramfs-recovery.itb
   `sysupgrade -F -n /tmp/openwrt-mediatek-filogic-xiaomi_mi-router-ax3000t-ubootmod-initramfs-recovery.itb`

2. Format ubi and Nvram
   ```
   ubidetach -p /dev/mtd8; ubiformat /dev/mtd8 -y; ubiattach -p /dev/mtd8
   mtd erase Nvram
   ```

3. Install kmod-mtd-rw
   `opkg update && opkg install kmod-mtd-rw`

   `insmod /lib/modules/$(uname -r)/mtd-rw.ko i_want_a_brick=1`

4. Flash stock images from backup
   ```
   mtd write /tmp/BL2.bin BL2
   mtd write /tmp/FIP.bin FIP
   mtd write /tmp/ubi.bin ubi
   ```
   Then reboot your router, waiting it finished rollback in minutes.

   `ubiformat /dev/mtd7 -y -f /tmp/ubi.bin`
   Then reboot your router, waiting it finished rollback in minutes.

Signed-off-by: Dim Fish <dimfish@gmail.com>
(cherry picked from commit 7dbcc1215a)
2024-05-23 21:50:00 +02:00
..
mt7622-buffalo-wsr-2533dhp2.dts mediatek: separate dts/dtsi for Buffalo WSR series 2024-02-27 17:42:30 +00:00
mt7622-buffalo-wsr-3200ax4s.dts mediatek: add support for Buffalo WSR-3200AX4S 2024-02-27 17:42:30 +00:00
mt7622-buffalo-wsr.dtsi mediatek: separate dts/dtsi for Buffalo WSR series 2024-02-27 17:42:30 +00:00
mt7622-dlink-eagle-pro-ai-m32-a1.dts mediatek: Add support for D-Link EAGLE PRO AI M32 2024-02-27 17:42:30 +00:00
mt7622-elecom-wrc-2533gent.dts mediatek: add an upstreamed spi-nand driver 2022-04-28 18:06:00 +08:00
mt7622-elecom-wrc-x3200gst3.dts treewide: remove label = "cpu" from DSA dt-binding 2023-02-26 22:22:48 +01:00
mt7622-linksys-e8450-ubi.dts mediatek: convert mtd-mac-address to nvmem implementation 2021-07-19 14:51:22 +02:00
mt7622-linksys-e8450.dts mediatek: convert mtd-mac-address to nvmem implementation 2021-07-19 14:51:22 +02:00
mt7622-linksys-e8450.dtsi mediatek: mt7622: linksys-e8450: set driving strength for SPI-NAND 2024-03-20 16:32:25 +00:00
mt7622-netgear-wax206.dts mediatek: no longer hard-code WAN PHY of Netgear WAX206 2023-04-30 17:27:00 +01:00
mt7622-reyee-ax3200-e5.dts mediatek: also move &slot0 from dtsi down to board dts 2022-12-07 01:45:14 +00:00
mt7622-rfb1-ubi.dts mediatek: add an upstreamed spi-nand driver 2022-04-28 18:06:00 +08:00
mt7622-ruijie-rg-ew3200.dtsi treewide: remove label = "cpu" from DSA dt-binding 2023-02-26 22:22:48 +01:00
mt7622-ruijie-rg-ew3200gx-pro.dts mediatek: also move &slot0 from dtsi down to board dts 2022-12-07 01:45:14 +00:00
mt7622-totolink-a8000ru.dts mediatek: mt7622: add missing vbus regulator node to totolink-a8000ru dts 2022-07-07 00:22:23 +01:00
mt7622-ubnt-unifi-6-lr-v1-ubootmod.dts mediatek: mt7622: fix DTS compatible of UniFi 6 LR variants 2022-09-03 02:27:59 +01:00
mt7622-ubnt-unifi-6-lr-v1.dts mediatek: mt7622: fix DTS compatible of UniFi 6 LR variants 2022-09-03 02:27:59 +01:00
mt7622-ubnt-unifi-6-lr-v1.dtsi mediatek: add support for Ubiquiti UniFi 6 LR v3 2023-09-04 23:00:34 +01:00
mt7622-ubnt-unifi-6-lr-v2-ubootmod.dts mediatek: mt7622: fix DTS compatible of UniFi 6 LR variants 2022-09-03 02:27:59 +01:00
mt7622-ubnt-unifi-6-lr-v2.dts mediatek: add Ubiquiti UniFi 6 LR v2 targets 2022-06-11 19:51:33 +01:00
mt7622-ubnt-unifi-6-lr-v2.dtsi mediatek: add support for Ubiquiti UniFi 6 LR v3 2023-09-04 23:00:34 +01:00
mt7622-ubnt-unifi-6-lr-v3-ubootmod.dts mediatek: add support for Ubiquiti UniFi 6 LR v3 2023-09-04 23:00:34 +01:00
mt7622-ubnt-unifi-6-lr-v3.dts mediatek: add support for Ubiquiti UniFi 6 LR v3 2023-09-04 23:00:34 +01:00
mt7622-ubnt-unifi-6-lr-v3.dtsi mediatek: add support for Ubiquiti UniFi 6 LR v3 2023-09-04 23:00:34 +01:00
mt7622-ubnt-unifi-6-lr.dtsi mediatek: add support for Ubiquiti UniFi 6 LR v3 2023-09-04 23:00:34 +01:00
mt7622-xiaomi-redmi-router-ax6s.dts treewide: remove label = "cpu" from DSA dt-binding 2023-02-26 22:22:48 +01:00
mt7623a-unielec-u7623-02-emmc-512m.dts mediatek: u7623-02: enable early console also in legacy image 2022-01-31 00:10:38 +00:00
mt7623a-unielec-u7623-02.dts mediatek: mt7623: rework images for U7623-02 board 2022-01-23 20:20:37 +00:00
mt7623a-unielec-u7623-02.dtsi treewide: remove label = "cpu" from DSA dt-binding 2023-02-26 22:22:48 +01:00
mt7629-iptime-a6004mx.dts treewide: remove label = "cpu" from DSA dt-binding 2023-02-26 22:22:48 +01:00
mt7629-netgear-ex6250-v2.dts mediatek: add support for Netgear EX6250v2 series 2023-07-13 12:05:28 +01:00
mt7629-tplink_eap225-v5.dts mediatek: Add support for TP-Link EAP225v5 2024-02-27 17:42:30 +00:00
mt7981a-ubnt-unifi-6-plus.dts mediatek: filogic: add support for Ubiquiti UniFi 6 Plus (U6+) 2023-12-07 09:45:33 +01:00
mt7981b-cetron-ct3003.dts mediatek: Cetron CT3003: fixes typo for spi properties 2024-02-27 17:42:30 +00:00
mt7981b-cmcc-rax3000m-emmc.dtso mediatek: add CMCC RAX3000M support 2023-11-07 00:46:00 +01:00
mt7981b-cmcc-rax3000m-nand.dtso mediatek: add CMCC RAX3000M support 2023-11-07 00:46:00 +01:00
mt7981b-cmcc-rax3000m.dts mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7981b-confiabits-mt7981.dts mediatek: add SPDX header for Confiabits MT7981 DTS 2023-12-18 08:34:10 +01:00
mt7981b-cudy-re3000-v1.dts mediatek: filogic: add support for Cudy RE3000 v1 2024-03-07 22:14:32 +01:00
mt7981b-cudy-wr3000-v1.dts mediatek: filogic: Cudy WR3000 v1 wps button fix 2024-02-27 12:46:06 +01:00
mt7981b-glinet-gl-mt3000.dts mediatek: fix the name of buswidth to bus-width 2023-12-12 09:54:51 +01:00
mt7981b-h3c-magic-nx30-pro.dts mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7981b-jcg-q30-pro.dts mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7981b-qihoo-360t7.dts mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7981b-routerich-ax3000.dts mediatek: add support for Routerich AX3000 2024-01-04 21:47:43 +01:00
mt7981b-unielec-u7981-01-emmc.dts mediatek: filogic: add Unielec U7981-01 support 2024-03-31 20:45:20 +02:00
mt7981b-unielec-u7981-01-nand.dts mediatek: filogic: add Unielec U7981-01 support 2024-03-31 20:45:20 +02:00
mt7981b-unielec-u7981-01.dtsi mediatek: filogic: add Unielec U7981-01 support 2024-03-31 20:45:20 +02:00
mt7981b-xiaomi-mi-router-ax3000t-ubootmod.dts mediatek: filogic: add support for Xiaomi AX3000T 2024-05-23 21:50:00 +02:00
mt7981b-xiaomi-mi-router-ax3000t.dts mediatek: filogic: add support for Xiaomi AX3000T 2024-05-23 21:50:00 +02:00
mt7981b-xiaomi-mi-router-ax3000t.dtsi mediatek: filogic: add support for Xiaomi AX3000T 2024-05-23 21:50:00 +02:00
mt7981b-xiaomi-mi-router-common.dtsi mediatek: filogic: add support for Xiaomi AX3000T 2024-05-23 21:50:00 +02:00
mt7981b-xiaomi-mi-router-wr30u-112m-nmbm.dts mediatek: filogic: add specific layout for WR30U 2023-08-07 16:31:27 +01:00
mt7981b-xiaomi-mi-router-wr30u-stock.dts mediatek: filogic: add support for Xiaomi WR30U 2023-08-07 16:31:27 +01:00
mt7981b-xiaomi-mi-router-wr30u-ubootmod.dts mediatek: filogic: add support for Xiaomi WR30U 2023-08-07 16:31:27 +01:00
mt7981b-xiaomi-mi-router-wr30u.dtsi mediatek: filogic: add support for Xiaomi AX3000T 2024-05-23 21:50:00 +02:00
mt7981b-zbtlink-zbt-z8102ax.dts mediatek: add support for Zbtlink ZBT-Z8102AX 2023-12-09 13:39:53 +01:00
mt7981b-zyxel-nwa50ax-pro.dts mediatek: fix the name of buswidth to bus-width 2023-12-12 09:54:51 +01:00
mt7986a-acelink-ew-7886cax.dts mediatek: filogic: add Acelink EW-7886CAX support 2023-12-12 11:02:39 +01:00
mt7986a-acer-predator-w6.dts mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7986a-asus-rt-ax59u.dts mediatek: filogic: add support ASUS RT-AX59U 2024-01-20 19:07:15 +01:00
mt7986a-asus-tuf-ax4200.dts mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7986a-asus-tuf-ax6000.dts mediatek: filogic: Asus TUF AX6000 fix inverted LED for 2.5Gb LAN port 2024-03-15 23:28:14 +01:00
mt7986a-glinet-gl-mt6000.dts mediatek: GL-MT6000: Change LED colors 2024-01-15 17:34:30 +01:00
mt7986a-tplink-tl-xdr4288.dts mediatek: sync MT7986 device trees with upstream 2023-06-09 19:23:03 +01:00
mt7986a-tplink-tl-xdr6086.dts mediatek: sync MT7986 device trees with upstream 2023-06-09 19:23:03 +01:00
mt7986a-tplink-tl-xdr6088.dts mediatek: sync MT7986 device trees with upstream 2023-06-09 19:23:03 +01:00
mt7986a-tplink-tl-xdr-common.dtsi mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7986a-xiaomi-redmi-router-ax6000-stock.dts mediatek: add new layout for Xiaomi Redmi Router AX6000 for OpenWrt U-Boot 2022-12-29 03:00:31 +00:00
mt7986a-xiaomi-redmi-router-ax6000-ubootmod.dts mediatek: add new layout for Xiaomi Redmi Router AX6000 for OpenWrt U-Boot 2022-12-29 03:00:31 +00:00
mt7986a-xiaomi-redmi-router-ax6000.dtsi mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7986a-zyxel-ex5601-t0-common.dtsi mediatek: add Zyxel EX5601-T0 with uboot custom partition 2024-02-27 17:42:30 +00:00
mt7986a-zyxel-ex5601-t0-stock.dts mediatek: add Zyxel EX5601-T0 with uboot custom partition 2024-02-27 17:42:30 +00:00
mt7986a-zyxel-ex5601-t0-ubootmod.dts mediatek: add Zyxel EX5601-T0 with uboot custom partition 2024-02-27 17:42:30 +00:00
mt7986a-zyxel-ex5700-telenor.dts mediatek: fix the name of buswidth to bus-width 2023-12-12 09:54:51 +01:00
mt7986b-mercusys-mr90x-v1.dts mediatek: fiilogic: device tree switch@1f fix 2023-12-12 09:54:52 +01:00
mt7986b-netgear-wax220.dts mediatek: fix the name of buswidth to bus-width 2023-12-12 09:54:51 +01:00