<div dir="ltr">Hi!<div><br></div><div>Although it looks like the Asus RT-AC85P and the Asus RT-AC65P models are identical, but I have separated them into two dts and have introduced the HW version into the names (for the new versions in the future).</div><div><br></div><div>I have an alternative installation method via SSH:</div><br>Note: The user/password for SSH is identical with the one used in the Web-interface.<br><br>1. Complete the initial setup wizard.<br>2. Activate SSH under "Administration" -> "System".<br>3. Transfer the OpenWrt factory image via scp:<br> > scp openwrt-ramips-mt7621-asus_rt-ac65p-r01-squashfs-factory.bin admin@192.168.50.1:/tmp<br>4. Connect via SSH to the router.<br> > ssh <a href="mailto:admin@192.168.50.1">admin@192.168.50.1</a><br>5. Write the OpenWrt image to flash.<br> > mtd-write -i /tmp/openwrt-ramips-mt7621-asus_rt-ac65p-r01-squashfs-factory.bin -d linux<br>6. Reboot the router<br> > reboot<div><br></div><div>Another thing: I don't know, if it's good method to replace the second firmware partition with OpenWrt image during sysupgrade. When we don't do that, than we have always a factory firmware on the secondary firmware partition, so the back to the factory firmware would be much easier.</div><div><br></div><div>So, the new patch for the separated models:</div><div><br></div><div>diff --git a/target/linux/ramips/base-files/etc/board.d/02_network b/target/linux/ramips/base-files/etc/board.d/02_network<br>index c0de9d4e50..110e921f38 100755<br>--- a/target/linux/ramips/base-files/etc/board.d/02_network<br>+++ b/target/linux/ramips/base-files/etc/board.d/02_network<br>@@ -300,6 +300,8 @@ ramips_setup_interfaces()<br> ucidef_add_switch "switch0" \<br> "0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "4:wan:5" "6@eth0"<br> ;;<br>+ asus,rt-ac65p-r01|\<br>+ asus,rt-ac85p-r01|\<br> dlink,dir-860l-b1|\<br> elecom,wrc-1167ghbk2-s|\<br> elecom,wrc-1900gst|\<br>@@ -537,6 +539,10 @@ ramips_setup_macs()<br> lan_mac=$(mtd_get_mac_binary factory 0xe000)<br> wan_mac=$(mtd_get_mac_binary factory 0xe006)<br> ;;<br>+ asus,rt-ac65p-r01|\<br>+ asus,rt-ac85p-r01)<br>+ wan_mac=$(mtd_get_mac_ascii u-boot-env et1macaddr)<br>+ ;;<br> asus,rt-n56u)<br> lan_mac=$(macaddr_setbit_la "$(cat /sys/class/net/eth0/address)")<br> wan_mac=$(mtd_get_mac_binary factory 0x8004)<br>diff --git a/target/linux/ramips/base-files/lib/upgrade/platform.sh b/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>index a65492a309..7a50c61b1d 100755<br>--- a/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>+++ b/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>@@ -18,9 +18,18 @@ platform_do_upgrade() {<br> mikrotik,rbm33g)<br> [ -z "$(rootfs_type)" ] && mtd erase firmware<br> ;;<br>+ asus,rt-ac65p-r01|\<br>+ asus,rt-ac85p-r01)<br>+ echo "Backing up firmware"<br>+ dd if=/dev/mtd4 bs=1024 count=4096 > /tmp/backup_firmware.bin<br>+ dd if=/dev/mtd5 bs=1024 count=52224 >> /tmp/backup_firmware.bin<br>+ mtd -e firmware2 write /tmp/backup_firmware.bin firmware2<br>+ ;;<br> esac<br> <br> case "$board" in<br>+ asus,rt-ac65p-r01|\<br>+ asus,rt-ac85p-r01|\<br> hiwifi,hc5962|\<br> netgear,r6220|\<br> netgear,r6350|\<br>diff --git a/target/linux/ramips/dts/mt7621_asus_rt-ac65p-r01.dts b/target/linux/ramips/dts/mt7621_asus_rt-ac65p-r01.dts<br>new file mode 100644<br>index 0000000000..3d2d1bfe6d<br>--- /dev/null<br>+++ b/target/linux/ramips/dts/mt7621_asus_rt-ac65p-r01.dts<br>@@ -0,0 +1,9 @@<br>+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT<br>+/dts-v1/;<br>+<br>+#include "mt7621_asus_rt-ac85p.dtsi"<br>+<br>+/ {<br>+ compatible = "asus,rt-ac65p-r01", "mediatek,mt7621-soc";<br>+ model = "Asus RT-AC65P R01";<br>+};<br>diff --git a/target/linux/ramips/dts/mt7621_asus_rt-ac85p-r01.dts b/target/linux/ramips/dts/mt7621_asus_rt-ac85p-r01.dts<br>new file mode 100644<br>index 0000000000..115d52c71c<br>--- /dev/null<br>+++ b/target/linux/ramips/dts/mt7621_asus_rt-ac85p-r01.dts<br>@@ -0,0 +1,9 @@<br>+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT<br>+/dts-v1/;<br>+<br>+#include "mt7621_asus_rt-ac85p.dtsi"<br>+<br>+/ {<br>+ compatible = "asus,rt-ac85p-r01", "mediatek,mt7621-soc";<br>+ model = "Asus RT-AC85P R01";<br>+};<br>diff --git a/target/linux/ramips/dts/mt7621_asus_rt-ac85p.dtsi b/target/linux/ramips/dts/mt7621_asus_rt-ac85p.dtsi<br>new file mode 100644<br>index 0000000000..aa1229ab03<br>--- /dev/null<br>+++ b/target/linux/ramips/dts/mt7621_asus_rt-ac85p.dtsi<br>@@ -0,0 +1,161 @@<br>+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT<br>+/dts-v1/;<br>+<br>+#include "mt7621.dtsi"<br>+<br>+#include <dt-bindings/gpio/gpio.h><br>+#include <dt-bindings/input/input.h><br>+<br>+/ {<br>+ aliases {<br>+ led-boot = &led_power;<br>+ led-failsafe = &led_power;<br>+ led-running = &led_power;<br>+ led-upgrade = &led_power;<br>+ };<br>+<br>+ chosen {<br>+ bootargs = "console=ttyS0,57600";<br>+ };<br>+<br>+ palmbus: palmbus@1E000000 {<br>+ i2c@900 {<br>+ status = "okay";<br>+ };<br>+ };<br>+<br>+ keys {<br>+ compatible = "gpio-keys";<br>+<br>+ reset {<br>+ label = "reset";<br>+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;<br>+ linux,code = <KEY_RESTART>;<br>+ };<br>+<br>+ wps {<br>+ label = "wps";<br>+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;<br>+ linux,code = <KEY_WPS_BUTTON>;<br>+ };<br>+ };<br>+<br>+ leds {<br>+ compatible = "gpio-leds";<br>+<br>+ led_power: power {<br>+ label = "rt-ac85p:blue:power";<br>+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;<br>+ linux,default-trigger = "phy0tpt";<br>+ };<br>+ wlan2g {<br>+ label = "rt-ac85p:blue:wlan2g";<br>+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;<br>+ linux,default-trigger = "phy0radio";<br>+ };<br>+<br>+ wlan5g {<br>+ label = "rt-ac85p:blue:wlan5g";<br>+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;<br>+ linux,default-trigger = "phy1radio";<br>+ };<br>+ };<br>+};<br>+<br>+&sdhci {<br>+ status = "okay";<br>+};<br>+<br>+&nand {<br>+ status = "okay";<br>+<br>+ partitions {<br>+ compatible = "fixed-partitions";<br>+ #address-cells = <1>;<br>+ #size-cells = <1>;<br>+<br>+ partition@0 {<br>+ label = "u-boot";<br>+ reg = <0x0 0xe0000>;<br>+ read-only;<br>+ };<br>+<br>+ partition@e0000 {<br>+ label = "u-boot-env";<br>+ reg = <0xe0000 0x100000>;<br>+ read-only;<br>+ };<br>+<br>+ factory: partition@1e0000 {<br>+ label = "factory";<br>+ reg = <0x1e0000 0x100000>;<br>+ read-only;<br>+ };<br>+<br>+ factory2: partition@2e0000 {<br>+ label = "factory2";<br>+ reg = <0x2e0000 0x100000>;<br>+ read-only;<br>+ };<br>+<br>+ partition@3e0000 {<br>+ label = "kernel";<br>+ reg = <0x3e0000 0x400000>;<br>+ };<br>+<br>+ partition@7e0000 {<br>+ label = "ubi";<br>+ reg = <0x7e0000 0x2e00000>;<br>+ };<br>+<br>+ partition@35e0000 {<br>+ label = "firmware2";<br>+ reg = <0x35e0000 0x3200000>;<br>+ };<br>+ };<br>+};<br>+<br>+&pcie {<br>+ status = "okay";<br>+};<br>+<br>+&pcie0 {<br>+ wifi0: wifi@0,0 {<br>+ compatible = "pci14c3,7603";<br>+ reg = <0x0000 0 0 0 0>;<br>+ mediatek,mtd-eeprom = <&factory 0x0000>;<br>+ ieee80211-freq-limit = <2400000 2500000>;<br>+ mtd-mac-address = <&factory 0x4>;<br>+ };<br>+};<br>+<br>+&pcie1 {<br>+ wifi1: wifi@0,0 {<br>+ compatible = "pci14c3,7662";<br>+ reg = <0x0000 0 0 0 0>;<br>+ mediatek,mtd-eeprom = <&factory 0x8000>;<br>+ ieee80211-freq-limit = <5000000 6000000>;<br>+ mtd-mac-address = <&factory 0x8004>;<br>+ };<br>+};<br>+<br>+ðernet {<br>+ mtd-mac-address = <&factory 0xe000>;<br>+ mediatek,portmap = "wllll";<br>+ port@5 {<br>+ status = "disabled";<br>+ };<br>+};<br>+<br>+&i2c {<br>+ status = "disabled";<br>+};<br>+<br>+&pinctrl {<br>+ state_default: pinctrl0 {<br>+ gpio {<br>+ ralink,group = "uart2", "uart3", "i2c";<br>+ ralink,function = "gpio";<br>+ };<br>+ };<br>+};<br>diff --git a/target/linux/ramips/image/<a href="http://mt7621.mk">mt7621.mk</a> b/target/linux/ramips/image/<a href="http://mt7621.mk">mt7621.mk</a><br>index d32feb7eab..7efe2cdc7f 100644<br>--- a/target/linux/ramips/image/<a href="http://mt7621.mk">mt7621.mk</a><br>+++ b/target/linux/ramips/image/<a href="http://mt7621.mk">mt7621.mk</a><br>@@ -115,6 +115,40 @@ define Device/asus_rt-ac57u<br> endef<br> TARGET_DEVICES += asus_rt-ac57u<br> <br>+define Device/asus_rt-ac65p-r01<br>+ MTK_SOC := mt7621<br>+ DEVICE_VENDOR := ASUS<br>+ DEVICE_MODEL := RT-AC65P<br>+ DEVICE_VARIANT := R01<br>+ IMAGE_SIZE := 51200k<br>+ UBINIZE_OPTS := -E 5<br>+ BLOCKSIZE := 128k<br>+ PAGESIZE := 2048<br>+ KERNEL_SIZE := 4096k<br>+ IMAGES += factory.bin<br>+ IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata<br>+ IMAGE/factory.bin := append-kernel | pad-to $$(KERNEL_SIZE) | append-ubi | check-size $$$$(IMAGE_SIZE)<br>+ DEVICE_PACKAGES := kmod-usb3 kmod-mt7615e wpad-basic uboot-envtools<br>+endef<br>+TARGET_DEVICES += asus_rt-ac65p-r01<br>+<br>+define Device/asus_rt-ac85p-r01<br>+ MTK_SOC := mt7621<br>+ DEVICE_VENDOR := ASUS<br>+ DEVICE_MODEL := RT-AC85P<br>+ DEVICE_VARIANT := R01<br>+ IMAGE_SIZE := 51200k<br>+ UBINIZE_OPTS := -E 5<br>+ BLOCKSIZE := 128k<br>+ PAGESIZE := 2048<br>+ KERNEL_SIZE := 4096k<br>+ IMAGES += factory.bin<br>+ IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata<br>+ IMAGE/factory.bin := append-kernel | pad-to $$(KERNEL_SIZE) | append-ubi | check-size $$$$(IMAGE_SIZE)<br>+ DEVICE_PACKAGES := kmod-usb3 kmod-mt7615e wpad-basic uboot-envtools<br>+endef<br>+TARGET_DEVICES += asus_rt-ac85p-r01<br>+<br> define Device/buffalo_wsr-1166dhp<br> MTK_SOC := mt7621<br> IMAGE/sysupgrade.bin := trx | pad-rootfs | append-metadata<br>diff --git a/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch b/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch<br>index d50e689110..d2d69b4ff4 100644<br>--- a/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch<br>+++ b/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch<br>@@ -4256,7 +4256,7 @@ Signed-off-by: John Crispin <<a href="mailto:blogic@openwrt.org">blogic@openwrt.org</a>><br> +#endif /* __NAND_DEF_H__ */<br> --- /dev/null<br> +++ b/drivers/mtd/nand/nand_device_list.h<br>-@@ -0,0 +1,59 @@<br>+@@ -0,0 +1,60 @@<br> +/* Copyright Statement:<br> + *<br> + * This software/firmware and related documentation ("MediaTek Software") are<br>@@ -4308,6 +4308,7 @@ Signed-off-by: John Crispin <<a href="mailto:blogic@openwrt.org">blogic@openwrt.org</a>><br> + {0xC8DC, 0x909554, 5, 8, 512, 128, 2048, 64, 0x30C77fff, "F59L4G81A", 0},<br> + {0xECD3, 0x519558, 5, 8, 1024, 128, 2048, 64, 0x44333, "K9K8G8000", 0},<br> + {0xC2F1, 0x801DC2, 4, 8, 128, 128, 2048, 64, 0x30C77fff, "MX30LF1G08AA", 0},<br>++ {0xC2F1, 0x809502, 4, 8, 128, 128, 2048, 64, 0x30C77fff, "MX30LF1G18AC", 0},<br> + {0x98D3, 0x902676, 5, 8, 1024, 256, 4096, 224, 0x00C25332, "TC58NVG3S0F", 0},<br> + {0x01DA, 0x909546, 5, 8, 256, 128, 2048, 128, 0x30C77fff, "S34ML02G200TF", 0},<br> + {0x01DC, 0x909556, 5, 8, 512, 128, 2048, 128, 0x30C77fff, "S34ML04G200TF", 0},<br><div><br></div><div><br></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Birger Koblitz <<a href="mailto:mail@birger-koblitz.de">mail@birger-koblitz.de</a>> ezt írta (időpont: 2019. aug. 4., V, 6:46):<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">ramips: add Asus RT-AC85P<br>
<br>
SoC: MediaTek MT7621AT dual-core @ 880MHz<br>
RAM: 256M (Winbond W632GG6KB-1)<br>
FLASH: 128MB (Macronix MX30LF1G18AC-TI)<br>
WiFi: - 2.4GHz MediaTek MT7615N bgn<br>
- 5GHz MediaTek MT7615N nac<br>
Switch: SoC integrated Gigabit Switch (4 x LAN, 1 x WAN)<br>
USB: 1 x USB 3.1 (Gen 1)<br>
BTN: Reset, WPS<br>
LED: - Power (blue)<br>
- 5Ghz (blue)<br>
- 2.4GHz (blue)<br>
- Internet (blue)<br>
- 4x LAN (blue)<br>
(LAN/WAN leds are not controllable by GPIOs)<br>
UART: UART is present as Pads marked J4 on the PCB.<br>
3.3V - TX - RX - GND / 57600-8N1<br>
3.3V is the square pad<br>
MAC: The MAC address on the router-label matches the MAC of<br>
the 2.4 GHz WiFi.<br>
LAN and WAN MAC are identical: MAC_LABEL+4<br>
5 GHz WiFi MAC: also MAC_LABEL+4<br>
<br>
<br>
Installation<br>
------------<br>
Via U-Boot tftpd:<br>
Switch on device, within 2s press reset button and keep pressed<br>
until power LED starts blinking slowly.<br>
Upload factory image via tftp put, the router's ip is 192.168.1.1<br>
and expects the client on 192.168.1.75.<br>
<br>
The images also work on the Asus RT-AC65P models as tested by Gabor.<br>
<br>
Signed-off-by: Birger Koblitz <<a href="mailto:mail@birger-koblitz.de" target="_blank">mail@birger-koblitz.de</a>><br>
Tested-by: Gabor Varga <<a href="mailto:vargagab@gmail.com" target="_blank">vargagab@gmail.com</a>><br>
<br>
---<br>
<br>
v2: Corrected sorting of entries in 02_network<br>
Model name corrected in .dts<br>
Whitespace fixes in .dts<br>
wifi0/1 labels added to wifi nodes in .dts<br>
Device name capitalized in <a href="http://mt7621.mk" rel="noreferrer" target="_blank">mt7621.mk</a><br>
<br>
v3: Added firmware backup to firmware2 partition before sysupgrade<br>
Corrected modules included in image<br>
<br>
diff --git a/target/linux/ramips/base-files/etc/board.d/02_network<br>
b/target/linux/ramips/base-files/etc/board.d/02_network<br>
index 2f9a02256e..ab90041d92 100755<br>
--- a/target/linux/ramips/base-files/etc/board.d/02_network<br>
+++ b/target/linux/ramips/base-files/etc/board.d/02_network<br>
@@ -231,6 +231,17 @@ ramips_setup_interfaces()<br>
ucidef_add_switch "switch0" \<br>
"0:lan" "1:wan" "6@eth0"<br>
;;<br>
+ asus,rt-ac85p|\<br>
+ dlink,dir-860l-b1|\<br>
+ elecom,wrc-1167ghbk2-s|\<br>
+ elecom,wrc-1900gst|\<br>
+ elecom,wrc-2533gst|\<br>
+ huawei,hg255d|\<br>
+ iodata,wn-ax1167gr|\<br>
+ iodata,wn-gx300gr)<br>
+ ucidef_add_switch "switch0" \<br>
+ "1:lan:4" "2:lan:3" "3:lan:2" "4:lan:1" "0:wan" "6@eth0"<br>
+ ;;<br>
asus,rt-n15|\<br>
belkin,f9k1109v1|\<br>
sitecom,wl-351)<br>
@@ -298,16 +309,6 @@ ramips_setup_interfaces()<br>
ucidef_add_switch "switch0" \<br>
"0:lan:4" "1:lan:3" "2:lan:2" "3:lan:1" "4:wan:5" "6@eth0"<br>
;;<br>
- dlink,dir-860l-b1|\<br>
- elecom,wrc-1167ghbk2-s|\<br>
- elecom,wrc-1900gst|\<br>
- elecom,wrc-2533gst|\<br>
- huawei,hg255d|\<br>
- iodata,wn-ax1167gr|\<br>
- iodata,wn-gx300gr)<br>
- ucidef_add_switch "switch0" \<br>
- "1:lan:4" "2:lan:3" "3:lan:2" "4:lan:1" "0:wan" "6@eth0"<br>
- ;;<br>
dlink,dwr-118-a1)<br>
ucidef_add_switch "switch0" \<br>
"1:lan:2" "2:lan:3" "3:lan:1" "4:lan:0" "5:wan" "6@eth0"<br>
@@ -531,6 +532,9 @@ ramips_setup_macs()<br>
lan_mac=$(mtd_get_mac_binary factory 57344)<br>
wan_mac=$(mtd_get_mac_binary factory 57350)<br>
;;<br>
+ asus,rt-ac85p)<br>
+ wan_mac=$(mtd_get_mac_ascii u-boot-env et1macaddr)<br>
+ ;;<br>
asus,rt-n56u)<br>
lan_mac=$(macaddr_setbit_la "$(cat /sys/class/net/eth0/address)")<br>
wan_mac=$(mtd_get_mac_binary factory 32772)<br>
diff --git a/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
b/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
index a65492a309..cd9d8ae650 100755<br>
--- a/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
+++ b/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
@@ -18,9 +18,16 @@ platform_do_upgrade() {<br>
mikrotik,rbm33g)<br>
[ -z "$(rootfs_type)" ] && mtd erase firmware<br>
;;<br>
+ asus,rt-ac85p)<br>
+ echo "Backing up firmware"<br>
+ dd if=/dev/mtd4 bs=1024 count=4096 > /tmp/backup_firmware.bin<br>
+ dd if=/dev/mtd5 bs=1024 count=52224 >> /tmp/backup_firmware.bin<br>
+ mtd -e firmware2 write /tmp/backup_firmware.bin firmware2<br>
+ ;;<br>
esac<br>
<br>
case "$board" in<br>
+ asus,rt-ac85p|\<br>
hiwifi,hc5962|\<br>
netgear,r6220|\<br>
netgear,r6350|\<br>
diff --git a/target/linux/ramips/dts/mt7621_asus_rt-ac85p.dts<br>
b/target/linux/ramips/dts/mt7621_asus_rt-ac85p.dts<br>
new file mode 100644<br>
index 0000000000..7aea207fad<br>
--- /dev/null<br>
+++ b/target/linux/ramips/dts/mt7621_asus_rt-ac85p.dts<br>
@@ -0,0 +1,164 @@<br>
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT<br>
+/dts-v1/;<br>
+<br>
+#include "mt7621.dtsi"<br>
+<br>
+#include <dt-bindings/gpio/gpio.h><br>
+#include <dt-bindings/input/input.h><br>
+<br>
+/ {<br>
+ compatible = "asus,rt-ac85p", "mediatek,mt7621-soc";<br>
+ model = "Asus RT-AC85P";<br>
+<br>
+ aliases {<br>
+ led-boot = &led_power;<br>
+ led-failsafe = &led_power;<br>
+ led-running = &led_power;<br>
+ led-upgrade = &led_power;<br>
+ };<br>
+<br>
+ chosen {<br>
+ bootargs = "console=ttyS0,57600";<br>
+ };<br>
+<br>
+ palmbus: palmbus@1E000000 {<br>
+ i2c@900 {<br>
+ status = "okay";<br>
+ };<br>
+ };<br>
+<br>
+ keys {<br>
+ compatible = "gpio-keys";<br>
+<br>
+ reset {<br>
+ label = "reset";<br>
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;<br>
+ linux,code = <KEY_RESTART>;<br>
+ };<br>
+<br>
+ wps {<br>
+ label = "wps";<br>
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;<br>
+ linux,code = <KEY_WPS_BUTTON>;<br>
+ };<br>
+ };<br>
+<br>
+ leds {<br>
+ compatible = "gpio-leds";<br>
+<br>
+ led_power: power {<br>
+ label = "rt-ac85p:blue:power";<br>
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;<br>
+ linux,default-trigger = "phy0tpt";<br>
+ };<br>
+ wlan2g {<br>
+ label = "rt-ac85p:blue:wlan2g";<br>
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;<br>
+ linux,default-trigger = "phy0radio";<br>
+ };<br>
+<br>
+ wlan5g {<br>
+ label = "rt-ac85p:blue:wlan5g";<br>
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;<br>
+ linux,default-trigger = "phy1radio";<br>
+ };<br>
+ };<br>
+};<br>
+<br>
+&sdhci {<br>
+ status = "okay";<br>
+};<br>
+<br>
+&nand {<br>
+ status = "okay";<br>
+<br>
+ partitions {<br>
+ compatible = "fixed-partitions";<br>
+ #address-cells = <1>;<br>
+ #size-cells = <1>;<br>
+<br>
+ partition@0 {<br>
+ label = "u-boot";<br>
+ reg = <0x0 0xe0000>;<br>
+ read-only;<br>
+ };<br>
+<br>
+ partition@e0000 {<br>
+ label = "u-boot-env";<br>
+ reg = <0xe0000 0x100000>;<br>
+ read-only;<br>
+ };<br>
+<br>
+ factory: partition@1e0000 {<br>
+ label = "factory";<br>
+ reg = <0x1e0000 0x100000>;<br>
+ read-only;<br>
+ };<br>
+<br>
+ factory2: partition@2e0000 {<br>
+ label = "factory2";<br>
+ reg = <0x2e0000 0x100000>;<br>
+ read-only;<br>
+ };<br>
+<br>
+ partition@3e0000 {<br>
+ label = "kernel";<br>
+ reg = <0x3e0000 0x400000>;<br>
+ };<br>
+<br>
+ partition@7e0000 {<br>
+ label = "ubi";<br>
+ reg = <0x7e0000 0x2e00000>;<br>
+ };<br>
+<br>
+ partition@35e0000 {<br>
+ label = "firmware2";<br>
+ reg = <0x35e0000 0x3200000>;<br>
+ };<br>
+ };<br>
+};<br>
+<br>
+&pcie {<br>
+ status = "okay";<br>
+};<br>
+<br>
+&pcie0 {<br>
+ wifi0: wifi@0,0 {<br>
+ compatible = "pci14c3,7603";<br>
+ reg = <0x0000 0 0 0 0>;<br>
+ mediatek,mtd-eeprom = <&factory 0x0000>;<br>
+ ieee80211-freq-limit = <2400000 2500000>;<br>
+ mtd-mac-address = <&factory 0x4>;<br>
+ };<br>
+};<br>
+<br>
+&pcie1 {<br>
+ wifi1: wifi@0,0 {<br>
+ compatible = "pci14c3,7662";<br>
+ reg = <0x0000 0 0 0 0>;<br>
+ mediatek,mtd-eeprom = <&factory 0x8000>;<br>
+ ieee80211-freq-limit = <5000000 6000000>;<br>
+ mtd-mac-address = <&factory 0x8004>;<br>
+ };<br>
+};<br>
+<br>
+ðernet {<br>
+ mtd-mac-address = <&factory 0xe000>;<br>
+ mediatek,portmap = "wllll";<br>
+ port@5 {<br>
+ status = "disabled";<br>
+ };<br>
+};<br>
+<br>
+&i2c {<br>
+ status = "disabled";<br>
+};<br>
+<br>
+&pinctrl {<br>
+ state_default: pinctrl0 {<br>
+ gpio {<br>
+ ralink,group = "uart2", "uart3", "i2c";<br>
+ ralink,function = "gpio";<br>
+ };<br>
+ };<br>
+};<br>
diff --git a/target/linux/ramips/image/<a href="http://mt7621.mk" rel="noreferrer" target="_blank">mt7621.mk</a><br>
b/target/linux/ramips/image/<a href="http://mt7621.mk" rel="noreferrer" target="_blank">mt7621.mk</a><br>
index d86eb8cc34..c036a1c308 100644<br>
--- a/target/linux/ramips/image/<a href="http://mt7621.mk" rel="noreferrer" target="_blank">mt7621.mk</a><br>
+++ b/target/linux/ramips/image/<a href="http://mt7621.mk" rel="noreferrer" target="_blank">mt7621.mk</a><br>
@@ -115,6 +115,22 @@ define Device/asus_rt-ac57u<br>
endef<br>
TARGET_DEVICES += asus_rt-ac57u<br>
<br>
+define Device/asus_rt-ac85p<br>
+ MTK_SOC := mt7621<br>
+ DEVICE_VENDOR := ASUS<br>
+ DEVICE_MODEL := RT-AC85P<br>
+ IMAGE_SIZE := 51200k<br>
+ UBINIZE_OPTS := -E 5<br>
+ BLOCKSIZE := 128k<br>
+ PAGESIZE := 2048<br>
+ KERNEL_SIZE := 4096k<br>
+ IMAGES += factory.bin<br>
+ IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata<br>
+ IMAGE/factory.bin := append-kernel | pad-to $$(KERNEL_SIZE) |<br>
append-ubi | check-size $$$$(IMAGE_SIZE)<br>
+ DEVICE_PACKAGES := kmod-usb3 kmod-mt7615e wpad-basic uboot-envtools<br>
+endef<br>
+TARGET_DEVICES += asus_rt-ac85p<br>
+<br>
define Device/buffalo_wsr-1166dhp<br>
MTK_SOC := mt7621<br>
IMAGE/sysupgrade.bin := trx | pad-rootfs | append-metadata<br>
diff --git<br>
a/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch<br>
b/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch<br>
index d50e689110..d2d69b4ff4 100644<br>
---<br>
a/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch<br>
+++<br>
b/target/linux/ramips/patches-4.14/0039-mtd-add-mt7621-nand-support.patch<br>
@@ -4256,7 +4256,7 @@ Signed-off-by: John Crispin <<a href="mailto:blogic@openwrt.org" target="_blank">blogic@openwrt.org</a>><br>
+#endif /* __NAND_DEF_H__ */<br>
--- /dev/null<br>
+++ b/drivers/mtd/nand/nand_device_list.h<br>
-@@ -0,0 +1,59 @@<br>
+@@ -0,0 +1,60 @@<br>
+/* Copyright Statement:<br>
+ *<br>
+ * This software/firmware and related documentation ("MediaTek<br>
Software") are<br>
@@ -4308,6 +4308,7 @@ Signed-off-by: John Crispin <<a href="mailto:blogic@openwrt.org" target="_blank">blogic@openwrt.org</a>><br>
+ {0xC8DC, 0x909554, 5, 8, 512, 128, 2048, 64, 0x30C77fff,<br>
"F59L4G81A", 0},<br>
+ {0xECD3, 0x519558, 5, 8, 1024, 128, 2048, 64, 0x44333,<br>
"K9K8G8000", 0},<br>
+ {0xC2F1, 0x801DC2, 4, 8, 128, 128, 2048, 64, 0x30C77fff,<br>
"MX30LF1G08AA", 0},<br>
++ {0xC2F1, 0x809502, 4, 8, 128, 128, 2048, 64, 0x30C77fff,<br>
"MX30LF1G18AC", 0},<br>
+ {0x98D3, 0x902676, 5, 8, 1024, 256, 4096, 224, 0x00C25332,<br>
"TC58NVG3S0F", 0},<br>
+ {0x01DA, 0x909546, 5, 8, 256, 128, 2048, 128, 0x30C77fff,<br>
"S34ML02G200TF", 0},<br>
+ {0x01DC, 0x909556, 5, 8, 512, 128, 2048, 128, 0x30C77fff,<br>
"S34ML04G200TF", 0},<br>
<br>
<br>
_______________________________________________<br>
openwrt-devel mailing list<br>
<a href="mailto:openwrt-devel@lists.openwrt.org" target="_blank">openwrt-devel@lists.openwrt.org</a><br>
<a href="https://lists.openwrt.org/mailman/listinfo/openwrt-devel" rel="noreferrer" target="_blank">https://lists.openwrt.org/mailman/listinfo/openwrt-devel</a><br>
</blockquote></div>