<div dir="ltr"><br>Today, Lenovo released a new product,an 11ac wireless router base MTK's mt7620a + mt7612e evaluation board.<br>It has Two GE ports(RTL8211E) and 4 FE ports(Internal switch),256MByte DDR2, 3xUSB 2.0.<br>
This patch will make openwrt support it.<br><br>Sorry for my pool english,tks at all.<br><br>Regards, Lintel<br><br>Signed-off-by:Lintel<<a href="mailto:lintel.huang@gmail.com">lintel.huang@gmail.com</a>><br><br>diff --git a/target/linux/ramips/base-files/etc/diag.sh b/target/linux/ramips/base-files/etc/diag.sh<br>
index 908547e..edebed8 100755<br>--- a/target/linux/ramips/base-files/etc/diag.sh<br>+++ b/target/linux/ramips/base-files/etc/diag.sh<br>@@ -182,6 +182,9 @@ get_status_led() {<br> na930)<br> status_led="na930:blue:power"<br>
;;<br>+ ac1200)<br>+ status_led="lenovo:blue:power"<br>+ ;;<br> esac<br> }<br> <br>diff --git a/target/linux/ramips/base-files/etc/uci-defaults/02_network b/target/linux/ramips/base-files/etc/uci-defaults/02_network<br>
index b372893..b862d9c 100755<br>--- a/target/linux/ramips/base-files/etc/uci-defaults/02_network<br>+++ b/target/linux/ramips/base-files/etc/uci-defaults/02_network<br>@@ -172,6 +172,12 @@ ramips_setup_interfaces()<br> ucidef_add_switch_vlan "switch0" "2" "4 6t"<br>
;;<br> <br>+ ac1200)<br>+ ucidef_set_interfaces_lan_wan "eth0.1" "eth0.2"<br>+ ucidef_add_switch "switch0" "1" "1"<br>+ ucidef_add_switch_vlan "switch0" "1" "1 2 3 4 5 6t"<br>
+ ucidef_add_switch_vlan "switch0" "2" "0 6t"<br>+ ;;<br> d105 | \<br> na930 | \<br> omni-emb-hpm|\<br>@@ -254,7 +260,8 @@ ramips_setup_macs()<br> wan_mac=$(macaddr_add "$lan_mac" 1)<br>
;;<br> <br>- wr8305rt)<br>+ wr8305rt | \<br>+ ac1200)<br> lan_mac=$(mtd_get_mac_binary factory 4)<br> wan_mac=$(macaddr_add "$lan_mac" 1)<br> ;;<br>diff --git a/target/linux/ramips/base-files/lib/ramips.sh b/target/linux/ramips/base-files/lib/ramips.sh<br>
index f9ab1e3..9a339b1 100755<br>--- a/target/linux/ramips/base-files/lib/ramips.sh<br>+++ b/target/linux/ramips/base-files/lib/ramips.sh<br>@@ -313,6 +313,9 @@ ramips_board_detect() {<br> *"ZBT WR8305RT")<br>
name="wr8305rt"<br> ;;<br>+ *"Lenovo AC1200")<br>+ name="ac1200"<br>+ ;;<br> *)<br> name="generic"<br> ;;<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 8ada58b..a5a63ae 100755<br>--- a/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>+++ b/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>@@ -93,7 +93,8 @@ platform_check_image() {<br> wrtnode |\<br>
x5 |\<br> x8 |\<br>- zbt-wa05)<br>+ zbt-wa05 |\<br>+ ac1200)<br> [ "$magic" != "27051956" ] && {<br> echo "Invalid image type."<br> return 1<br>
diff --git a/target/linux/ramips/image/Makefile b/target/linux/ramips/image/Makefile<br>index ef019ef..79e1787 100644<br>--- a/target/linux/ramips/image/Makefile<br>+++ b/target/linux/ramips/image/Makefile<br>@@ -716,6 +716,7 @@ Image/Build/Profile/DIR-810L=$(call BuildFirmware/CustomFlash/$(1),$(1),dir-810l<br>
na930_mtd_size=20971520<br> Image/Build/Profile/NA930=$(call BuildFirmware/CustomFlash/$(1),$(1),na930,NA930,$(na930_mtd_size))<br> Image/Build/Profile/MZK-750DHP=$(call BuildFirmware/Default8M/$(1),$(1),mzk-750dhp,MZK-750DHP)<br>
+Image/Build/Profile/AC1200=$(call BuildFirmware/Default16M/$(1),$(1),ac1200,AC1200)<br> <br> ifeq ($(SUBTARGET),mt7620a)<br> define Image/Build/Profile/Default<br>@@ -730,6 +731,7 @@ define Image/Build/Profile/Default<br>
$(call Image/Build/Profile/WHR1166D,$(1))<br> $(call Image/Build/Profile/MZK-750DHP,$(1))<br> $(call Image/Build/Profile/NA930,$(1))<br>+ $(call Image/Build/Profile/AC1200,$(1))<br> endef<br> endif<br> <br>
diff --git a/target/linux/ramips/mt7620a/config-3.10 b/target/linux/ramips/mt7620a/config-3.10<br>index 6805dd9..50e0a55 100644<br>--- a/target/linux/ramips/mt7620a/config-3.10<br>+++ b/target/linux/ramips/mt7620a/config-3.10<br>
@@ -1,6 +1,7 @@<br> CONFIG_ARCH_BINFMT_ELF_RANDOMIZE_PIE=y<br> CONFIG_ARCH_DISCARD_MEMBLOCK=y<br> CONFIG_ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE=y<br>+CONFIG_ARCH_HAS_RESET_CONTROLLER=y<br> CONFIG_ARCH_HAVE_CUSTOM_GPIO_H=y<br> CONFIG_ARCH_HIBERNATION_POSSIBLE=y<br>
CONFIG_ARCH_REQUIRE_GPIOLIB=y<br>@@ -78,6 +79,7 @@ CONFIG_HAVE_PERF_EVENTS=y<br> CONFIG_HW_HAS_PCI=y<br> CONFIG_HW_RANDOM=m<br> CONFIG_HZ_PERIODIC=y<br>+CONFIG_ICPLUS_PHY=y<br> CONFIG_IMAGE_CMDLINE_HACK=y<br> CONFIG_INET_LRO=y<br>
CONFIG_INITRAMFS_SOURCE=""<br>@@ -88,6 +90,7 @@ CONFIG_IRQ_FORCED_THREADING=y<br> CONFIG_IRQ_INTC=y<br> CONFIG_IRQ_WORK=y<br> CONFIG_M25PXX_USE_FAST_READ=y<br>+CONFIG_MARVELL_PHY=y<br> CONFIG_MDIO_BOARDINFO=y<br>
# CONFIG_MII is not set<br> CONFIG_MIPS=y<br>@@ -138,7 +141,9 @@ CONFIG_PINMUX=y<br> CONFIG_RALINK=y<br> CONFIG_RALINK_USBPHY=y<br> CONFIG_RALINK_WDT=y<br>+CONFIG_RA_NAT_NONE=y<br> # CONFIG_RCU_STALL_COMMON is not set<br>
+CONFIG_REALTEK_PHY=y<br> CONFIG_RESET_CONTROLLER=y<br> # CONFIG_SAMSUNG_USB2PHY is not set<br> # CONFIG_SAMSUNG_USB3PHY is not set<br><br></div>