aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/mediatek/mt7622/base-files/etc/board.d/02_network
diff options
context:
space:
mode:
authorLanghua Ye <y1248289414@outlook.com>2022-03-04 21:41:46 +0800
committerHauke Mehrtens <hauke@hauke-m.de>2022-03-05 21:06:35 +0100
commitce8a33b021a703b1933f627835f6cdc88c0ecdd3 (patch)
tree6b62d616706a0df5b04802b068f81b11b5ac76d5 /target/linux/mediatek/mt7622/base-files/etc/board.d/02_network
parentdf1383f7964527b2e7178ae744cd167a2c230f9f (diff)
downloadupstream-ce8a33b021a703b1933f627835f6cdc88c0ecdd3.tar.gz
upstream-ce8a33b021a703b1933f627835f6cdc88c0ecdd3.tar.bz2
upstream-ce8a33b021a703b1933f627835f6cdc88c0ecdd3.zip
mediatek: add support for Ruijie RG-EW3200GX PRO
X32 Pro is another product name for it in the Chinese market. Specifications: - SoC: MT7622B - RAM: 256MB - Flash: XMC XM25QH128C or Winbond WQ25Q128JVSQ 16MB SPI NOR - Ethernet: 5x1GbE - Switch: MT7531BE - WiFi: 2.4G: MT7622 5G: MT7915AN+MT7975AN - 3LEDs: System LED(blue) + Mesh LED(green) + Mesh LED(red) - 2Keys: Mesh button + Reset button - UART: Marked J19 on board. 3.3v, 115200n1 - Power: 12V 2.5A MAC addresses as verified by OEM firmware: use address source WAN *:F4 ethaddr@product_info LAN *:F5 5g *:F6 2g *:F7 Flash instruction: 1. Serve the initramfs.img using a TFTP server with address 10.10.10.3. 2. Interrupt the uboot startup process via UART. 3. Select "System Load Linux to SDRAM via TFTP" item. 4. (important) Back up firmware(mtd7) partitions with: dd if=/dev/mtd7 of=/tmp/firmware.bin and then download the firmware.bin image via SCP. 5. Flash the OpenWrt sysupgrade firmware. Recovery stock firmware: 1. Transfer the firmware.bin image to the device. 2. Flash the image with: mtd write firmware.bin firmware Signed-off-by: Langhua Ye <y1248289414@outlook.com>
Diffstat (limited to 'target/linux/mediatek/mt7622/base-files/etc/board.d/02_network')
-rw-r--r--target/linux/mediatek/mt7622/base-files/etc/board.d/02_network18
1 files changed, 17 insertions, 1 deletions
diff --git a/target/linux/mediatek/mt7622/base-files/etc/board.d/02_network b/target/linux/mediatek/mt7622/base-files/etc/board.d/02_network
index 7b454314cf..4649d0dc57 100644
--- a/target/linux/mediatek/mt7622/base-files/etc/board.d/02_network
+++ b/target/linux/mediatek/mt7622/base-files/etc/board.d/02_network
@@ -12,7 +12,8 @@ mediatek_setup_interfaces()
linksys,e8450|\
linksys,e8450-ubi|\
mediatek,mt7622-rfb1|\
- mediatek,mt7622-rfb1-ubi)
+ mediatek,mt7622-rfb1-ubi|\
+ ruijie,rg-ew3200gx-pro)
ucidef_set_interfaces_lan_wan "lan1 lan2 lan3 lan4" wan
;;
buffalo,wsr-2533dhp2)
@@ -30,9 +31,24 @@ mediatek_setup_interfaces()
esac
}
+mediatek_setup_macs()
+{
+ local board="$1"
+ local lan_mac=""
+
+ case $board in
+ ruijie,rg-ew3200gx-pro)
+ lan_mac=$(macaddr_add $(get_mac_label) 1)
+ ;;
+ esac
+
+ [ -n "$lan_mac" ] && ucidef_set_interface_macaddr "lan" $lan_mac
+}
+
board_config_update
board=$(board_name)
mediatek_setup_interfaces $board
+mediatek_setup_macs $board
board_config_flush
exit 0