openwrt/target/linux
Roland Reinl b3ce08e0b6 mediatek: filogic: Add support for D-Link AQUILA PRO AI M60
Specification:
 - MT7986 CPU using 2.4GHz and 5GHz WiFi (both AX)
 - MT7531 switch
 - 512MB RAM
 - 128MB NAND flash (MX35LF1GE4AB-Z4I) with two UBI partitions with identical size
 - 1 multi color LED (red, green, blue, white) connected via GCA230718 (Same as D-Link M30 A1)
 - 3 buttons (WPS, reset, LED on/off)
 - 1x 2.5 Gbit WAN port with Maxlinear GPY211C
 - 4x 1 Gbit LAN ports

Disassembly:
 - There are five screws at the bottom: 2 under the rubber feet, 3 under the label.
 - After removing the screws, the white plastic part can be shifted out of the blue part.
 - Be careful because the antennas are mounted on the side and the top of the white part.

Serial Interface
 - The serial interface can be connected to the 4 pin holes next to/under the antenna cables.
 - Note that there is another set of 4 pin holes on the side of the board, it's not used.
 - Pins (from front to rear):
   - 3.3V (do not connect)
   - TX
   - RX
   - GND
 - Settings: 115200, 8N1

MAC addresses:
 - MAC address is stored in partition "Odm" at offset 0x81 (for example XX:XX:XX:XX:XX:52)
 - MAC address on the device label is ODM + 1 (for example XX:XX:XX:XX:XX:53)
 - WAN MAC is the one from the ODM partition (for example XX:XX:XX:XX:XX:52)
 - LAN MAC is the one from the ODM partition + 1 (for example XX:XX:XX:XX:XX:53)
 - WLAN MAC (2.4 GHz) is the one from the ODM partition + 2 (for example (XX:XX:XX:XX:XX:54)
 - WLAN MAC (5 GHz) is the one from the ODM partition + 5 (for example (XX:XX:XX:XX:XX:57)

Flashing via OEM web interface:
 - Currently not supported because image crypto is not known

Flashing via recovery web interface:
 - This is only working if the first partition is active because recovery images are always flashed to the active partition and OpenWrt can only be executed from the first partition
 - Use a Chromium based browser, otherwise firmware upgrade might not work
 - Recovery web interface is accessible via 192.168.200.1 after keeping the reset button pressed during start of the device until the LED blinks red
 - Upload the recovery image, this will take some time. LED will continue flashing red during the update process
 - The after flashing, the recovery web interface redirects to http://192.168.0.1. This can be ignored. OpenWrt is accessible via 192.168.1.1 after flashing
 - If the first partition isn't the active partition, OpenWrt will hang during the boot process. In this case:
   - Download the recovery image from https://github.com/RolandoMagico/openwrt/releases/tag/M60-Recovery-UBI-Switch (UBI switch image)
   - Enable recovery web interface again and load the UBI switch image. This image works on the second partition of the M60
   - OpenWrt should boot now as expected. After booting, flash the normal OpenWrt sysupgrade image (for example in the OpenWrt web interface)
   - Flashing a sysupgrade image from the UBI switch image will make the first partition the active partition and from now on, default OpenWrt images can be used

Flashing via Initramfs:
- Before switching to OpenWrt, ensure that both partitions contain OEM firmware.
  - This can be achieved by re-flashing the same OEM firmware version again via the OEM web interface.
  - Flashing via OEM web interface will automatically flash the currently not active partition.
- Open router, connect serial interface
- Start a TFTP server at 192.168.200.2 and provide the initramfs image there
- When starting the router, select "7. Load Image" in U-Boot
- Settings for load address, load method can be kept as they are
- Specify host and router IP address if you use different ones than the default (Router 192.168.200.1, TFTP server 192.168.200.2)
- Enter the file name of the initramfs image
- Confirm "Run loaded data now?" question after loading the image with "Y"
- OpenWrt initramfs will start now
- Before flashing OpenWrt, create a backup of the "ubi" partition. It is required when reverting back to OEM
- Flash sysupgrade image to flash, during flashing the U-Boot variable sw_tryactive will be set to 0
  - During next boot, U-Boot tries to boot from the ubi partition. If it fails, it will switch to the ubi1 partition

Reverting back to OEM:
- Boot the initramfs image as described in "Flashing via Initramfs" above
- Copy the backed up ubi partition to /tmp (e.g. by using SCP)
- Write the backup to the UBI partition: mtd write /tmp/OpenWrt.mtd4.ubi.bin /dev/mtd4
- Reboot the device, OEM firmware will start now

Signed-off-by: Roland Reinl <reinlroland+github@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17296
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2024-12-23 23:23:18 +01:00
..
airoha kernel: bump 6.6 to 6.6.66 2024-12-19 00:38:34 +01:00
apm821xx kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
archs38 kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
armsr armsr: don't limit kmods to armsr armv8 subtarget 2024-10-29 00:07:55 +01:00
at91 kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
ath79 ath79: port buffalo WZR-450HP2 from ar71xx 2024-12-23 22:52:37 +01:00
bcm27xx kernel: bump 6.6 to 6.6.67 2024-12-20 19:34:47 +01:00
bcm47xx kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
bcm53xx kernel: bump 6.6 to 6.6.66 2024-12-19 00:38:34 +01:00
bcm4908 kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
bmips kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
d1 build: d1: add SUPPORTED_DEVICES 2024-12-22 11:40:58 +01:00
gemini kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
generic kernel: generic: netfilter: nft_set_hash: unaligned atomic read on struct nft_set_ext 2024-12-22 18:47:37 +01:00
imx kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
ipq40xx Revert "ipq40xx: use PHY to control USB GPIO" 2024-12-23 16:47:41 +01:00
ipq806x kernel: bump 6.6 to 6.6.64 2024-12-13 21:40:02 +01:00
ixp4xx kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
kirkwood kirkwood: Make the Marvell DSA switch a module 2024-12-16 22:03:05 +01:00
lantiq lantiq/xrx200: move 8M flash devices to a small flash subtarget 2024-12-16 00:59:55 +01:00
layerscape kernel: bump 6.6 to 6.6.64 2024-12-13 21:40:02 +01:00
loongarch64 kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
malta kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
mediatek mediatek: filogic: Add support for D-Link AQUILA PRO AI M60 2024-12-23 23:23:18 +01:00
mpc85xx kernel: bump 6.6 to 6.6.64 2024-12-13 21:40:02 +01:00
mvebu mvebu: rb5009: add label-mac-device 2024-12-21 12:19:13 +01:00
mxs mxs: run kernel_oldconfig 2024-11-23 16:47:53 +01:00
octeon octeon: enable AT803x PHY driver 2024-12-21 10:07:41 +01:00
omap kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
pistachio kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
qoriq kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
qualcommax ipq807x: add support for TP-Link EAP620 HD v1 2024-12-22 11:36:23 +01:00
ramips ramips: rt3050: fix wrong compatible 2024-12-22 11:35:23 +01:00
realtek realtek: merge Zyxel GS1900 firmware partitions 2024-12-22 11:09:42 +01:00
rockchip kernel: bump 6.6 to 6.6.66 2024-12-19 00:38:34 +01:00
sifiveu kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
siflower kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
starfive kernel: bump 6.6 to 6.6.66 2024-12-19 00:38:34 +01:00
stm32 stm32: Remove unnecessary kernel options 2024-11-24 22:51:14 +01:00
sunxi kernel: bump 6.6 to 6.6.61 2024-11-16 00:25:14 +01:00
tegra kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
uml uml: fix glibc-static check with GCC14 2024-06-22 22:06:06 +02:00
x86 x86: Deactivate kernel options with extra overhead 2024-11-24 20:03:59 +01:00
zynq kernel: filter out compiler opts from config 2024-11-17 14:55:16 +01:00
Makefile linux: fix missing default packages in profiles.json 2024-11-17 19:29:06 +01:00