diff --git a/target/linux/ramips/dts/mt7620a_dlink_dir-810l.dts b/target/linux/ramips/dts/mt7620a_dlink_dir-810l.dts index da8d2238a..0a22eee3b 100644 --- a/target/linux/ramips/dts/mt7620a_dlink_dir-810l.dts +++ b/target/linux/ramips/dts/mt7620a_dlink_dir-810l.dts @@ -23,20 +23,20 @@ reset { label = "reset"; gpios = <&gpio0 1 GPIO_ACTIVE_LOW>; - linux,code = ; + linux,code = ; }; wps { label = "wps"; gpios = <&gpio0 2 GPIO_ACTIVE_LOW>; - linux,code = ; + linux,code = ; }; }; leds { compatible = "gpio-leds"; - led_power_green: power { + led_power_green: power_green { label = "dir-810l:green:power"; gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>; }; @@ -46,7 +46,7 @@ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>; }; - power2 { + power_orange { label = "dir-810l:orange:power"; gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>; }; @@ -56,10 +56,10 @@ &spi0 { status = "okay"; - m25p80@0 { + flash@0 { compatible = "jedec,spi-nor"; reg = <0>; - spi-max-frequency = <10000000>; + spi-max-frequency = <50000000>; partitions { compatible = "fixed-partitions"; @@ -102,9 +102,9 @@ read-only; }; - partition@e0000 { + partition@f0000 { label = "Jffs2"; - reg = <0xe0000 0x80000>; + reg = <0xf0000 0x80000>; read-only; }; @@ -119,7 +119,7 @@ &state_default { gpio { - ralink,group = "mdio", "rgmii1", "i2c", "wled", "uartf"; + ralink,group = "i2c", "uartf"; ralink,function = "gpio"; }; }; @@ -130,9 +130,10 @@ }; &gsw { - mediatek,port4 = "ephy"; pinctrl-names = "default"; pinctrl-0 = <&ephy_pins>; + + mediatek,port4 = "ephy"; }; &pcie { @@ -140,9 +141,10 @@ }; &wmac { - ralink,mtd-eeprom = <&factory 0x0>; pinctrl-names = "default"; pinctrl-0 = <&pa_pins>; + + ralink,mtd-eeprom = <&factory 0x0>; mtd-mac-address = <&factory 0x28>; }; diff --git a/target/linux/ramips/dts/mt7620a_tplink_re200-v1.dts b/target/linux/ramips/dts/mt7620a_tplink_re200-v1.dts index afc94c538..c8b279471 100644 --- a/target/linux/ramips/dts/mt7620a_tplink_re200-v1.dts +++ b/target/linux/ramips/dts/mt7620a_tplink_re200-v1.dts @@ -1,10 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "mt7620a.dtsi" - -#include -#include +#include "mt7620a_tplink_re2x0-v1.dtsi" / { compatible = "tplink,re200-v1", "ralink,mt7620a-soc"; @@ -15,11 +12,6 @@ led-failsafe = &led_power; led-running = &led_power; led-upgrade = &led_power; - label-mac-device = ðernet; - }; - - chosen { - bootargs = "console=ttyS0,57600n8"; }; leds { @@ -56,22 +48,6 @@ linux,default-trigger = "phy1tpt"; }; }; - - keys { - compatible = "gpio-keys"; - - reset { - label = "reset"; - gpios = <&gpio0 13 GPIO_ACTIVE_LOW>; - linux,code = ; - }; - - wps { - label = "wps"; - gpios = <&gpio0 12 GPIO_ACTIVE_LOW>; - linux,code = ; - }; - }; }; @@ -82,46 +58,6 @@ }; }; -&spi0 { - status = "okay"; - - flash@0 { - compatible = "jedec,spi-nor"; - reg = <0>; - spi-max-frequency = <50000000>; - - partitions { - compatible = "fixed-partitions"; - #address-cells = <1>; - #size-cells = <1>; - - uboot: partition@0 { - label = "u-boot"; - reg = <0x0 0x20000>; - read-only; - }; - - partition@20000 { - compatible = "tplink,firmware"; - label = "firmware"; - reg = <0x20000 0x7c0000>; - }; - - partition@7e0000 { - label = "userconfig"; - reg = <0x7e0000 0x10000>; - read-only; - }; - - radio: partition@7f0000 { - label = "radio"; - reg = <0x7f0000 0x10000>; - read-only; - }; - }; - }; -}; - &gpio1 { status = "okay"; }; @@ -133,26 +69,3 @@ &gpio3 { status = "okay"; }; - -ðernet { - mtd-mac-address = <&uboot 0x1fc00>; -}; - -&wmac { - ralink,mtd-eeprom = <&radio 0x0>; - mtd-mac-address = <&uboot 0x1fc00>; -}; - -&pcie { - status = "okay"; -}; - -&pcie0 { - mt76@0,0 { - reg = <0x0000 0 0 0 0>; - mediatek,mtd-eeprom = <&radio 0x8000>; - mtd-mac-address = <&uboot 0x1fc00>; - mtd-mac-address-increment = <2>; - ieee80211-freq-limit = <5000000 6000000>; - }; -}; diff --git a/target/linux/ramips/dts/mt7620a_tplink_re210-v1.dts b/target/linux/ramips/dts/mt7620a_tplink_re210-v1.dts new file mode 100644 index 000000000..49c56a8cb --- /dev/null +++ b/target/linux/ramips/dts/mt7620a_tplink_re210-v1.dts @@ -0,0 +1,95 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "mt7620a_tplink_re2x0-v1.dtsi" + +/ { + compatible = "tplink,re210-v1", "ralink,mt7620a-soc"; + model = "TP-Link RE210 v1"; + + aliases { + led-boot = &led_power; + led-failsafe = &led_power; + led-running = &led_power; + led-upgrade = &led_power; + }; + + leds { + compatible = "gpio-leds"; + + led_power: power { + label = "re210-v1:green:power"; + gpios = <&gpio1 3 GPIO_ACTIVE_LOW>; + }; + + rssi_high { + label = "re210-v1:green:rssi-high"; + gpios = <&gpio1 1 GPIO_ACTIVE_LOW>; + }; + + rssi_low { + label = "re210-v1:red:rssi-low"; + gpios = <&gpio1 2 GPIO_ACTIVE_LOW>; + }; + + wlan2g { + label = "re210-v1:green:wlan2g"; + gpios = <&gpio3 0 GPIO_ACTIVE_LOW>; + linux,default-trigger = "phy1tpt"; + }; + + wlan5g { + label = "re210-v1:green:wlan5g"; + gpios = <&gpio0 1 GPIO_ACTIVE_LOW>; + linux,default-trigger = "phy0tpt"; + }; + }; +}; + +&keys { + led_power { + label = "LED power"; + gpios = <&gpio1 0 GPIO_ACTIVE_LOW>; + linux,code = ; + }; +}; + +&state_default { + gpio { + ralink,group = "i2c", "uartf", "wled", "rgmii1"; + ralink,function = "gpio"; + }; +}; + +&gsw { + mediatek,port4 = "gmac"; +}; + +ðernet { + pinctrl-names = "default"; + pinctrl-0 = <&rgmii2_pins &mdio_pins>; + + port@4 { + status = "okay"; + + phy-handle = <&phy4>; + phy-mode = "rgmii"; + }; + + mdio-bus { + status = "okay"; + + phy4: ethernet-phy@4 { + reg = <4>; + phy-mode = "rgmii"; + }; + }; +}; + +&gpio1 { + status = "okay"; +}; + +&gpio3 { + status = "okay"; +}; diff --git a/target/linux/ramips/dts/mt7620a_tplink_re2x0-v1.dtsi b/target/linux/ramips/dts/mt7620a_tplink_re2x0-v1.dtsi new file mode 100644 index 000000000..80b47b7d7 --- /dev/null +++ b/target/linux/ramips/dts/mt7620a_tplink_re2x0-v1.dtsi @@ -0,0 +1,95 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT + +#include "mt7620a.dtsi" + +#include +#include + +/ { + aliases { + label-mac-device = ðernet; + }; + + chosen { + bootargs = "console=ttyS0,57600n8"; + }; + + keys: keys { + compatible = "gpio-keys"; + + reset { + label = "reset"; + gpios = <&gpio0 13 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + + wps { + label = "wps"; + gpios = <&gpio0 12 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + }; +}; + +&spi0 { + status = "okay"; + + flash@0 { + compatible = "jedec,spi-nor"; + reg = <0>; + spi-max-frequency = <50000000>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + uboot: partition@0 { + label = "u-boot"; + reg = <0x0 0x20000>; + read-only; + }; + + partition@20000 { + compatible = "tplink,firmware"; + label = "firmware"; + reg = <0x20000 0x7c0000>; + }; + + partition@7e0000 { + label = "config"; + reg = <0x7e0000 0x10000>; + read-only; + }; + + radio: partition@7f0000 { + label = "radio"; + reg = <0x7f0000 0x10000>; + read-only; + }; + }; + }; +}; + +ðernet { + mtd-mac-address = <&uboot 0x1fc00>; +}; + +&wmac { + ralink,mtd-eeprom = <&radio 0x0>; + mtd-mac-address = <&uboot 0x1fc00>; +}; + +&pcie { + status = "okay"; +}; + +&pcie0 { + mt76@0,0 { + reg = <0x0000 0 0 0 0>; + mediatek,mtd-eeprom = <&radio 0x8000>; + mtd-mac-address = <&uboot 0x1fc00>; + mtd-mac-address-increment = <2>; + ieee80211-freq-limit = <5000000 6000000>; + }; +}; diff --git a/target/linux/ramips/dts/mt7621_netgear_r6700-v2.dts b/target/linux/ramips/dts/mt7621_netgear_r6700-v2.dts new file mode 100644 index 000000000..6a8cd6e4e --- /dev/null +++ b/target/linux/ramips/dts/mt7621_netgear_r6700-v2.dts @@ -0,0 +1,122 @@ +// SPDX-License-Identifier: GPL-2.0 +/dts-v1/; + +#include "mt7621_netgear_sercomm_bzv.dtsi" + +/ { + compatible = "netgear,r6700-v2", "mediatek,mt7621-soc"; + model = "Netgear R6700 v2"; + + aliases { + led-boot = &led_power_white; + led-failsafe = &led_power_orange; + led-running = &led_power_white; + led-upgrade = &led_power_orange; + label-mac-device = ðernet; + }; + + leds { + compatible = "gpio-leds"; + + led_power_orange: power_orange { + gpios = <&gpio_expander 0 GPIO_ACTIVE_LOW>; + label = "r6700-v2:orange:power"; + }; + + led_power_white: power_white { + gpios = <&gpio_expander 1 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:power"; + }; + + wan_orange { + gpios = <&gpio_expander 2 GPIO_ACTIVE_LOW>; + label = "r6700-v2:orange:wan"; + }; + + wan_white { + gpios = <&gpio_expander 3 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:wan"; + }; + + wlan2g { + gpios = <&gpio_expander 4 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:wlan2g"; + linux,default-trigger = "phy0radio"; + }; + + wlan5g { + gpios = <&gpio_expander 5 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:wlan5g"; + linux,default-trigger = "phy1radio"; + }; + + guest_wifi { + gpios = <&gpio_expander 6 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:guest_wifi"; + }; + + usb3 { + gpios = <&gpio_expander 7 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:usb3"; + linux,default-trigger = "usbport"; + trigger-sources = <&xhci_ehci_port1>; + }; + + lan1_orange { + gpios = <&gpio_expander 8 GPIO_ACTIVE_LOW>; + label = "r6700-v2:orange:lan1"; + }; + + lan1_white { + gpios = <&gpio_expander 9 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:lan1"; + }; + + lan2_orange { + gpios = <&gpio_expander 10 GPIO_ACTIVE_LOW>; + label = "r6700-v2:orange:lan2"; + }; + + lan2_white { + gpios = <&gpio_expander 11 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:lan2"; + }; + + lan3_orange { + gpios = <&gpio_expander 12 GPIO_ACTIVE_LOW>; + label = "r6700-v2:orange:lan3"; + }; + + lan3_white { + gpios = <&gpio_expander 13 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:lan3"; + }; + + lan4_orange { + gpios = <&gpio_expander 14 GPIO_ACTIVE_LOW>; + label = "r6700-v2:orange:lan4"; + }; + + lan4_white { + gpios = <&gpio_expander 15 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:lan4"; + }; + + wps { + gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>; + label = "r6700-v2:white:wps"; + }; + + wlan { + gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; + label = "r6700-v2:white:wlan"; + }; + }; +}; + +&state_default { + gpio { + ralink,group = "uart3", "uart2", "jtag", "wdt"; + ralink,function = "gpio"; + }; +}; diff --git a/target/linux/ramips/dts/mt7621_netgear_r6800.dts b/target/linux/ramips/dts/mt7621_netgear_r6800.dts index 0993afe4c..fed7bbba3 100644 --- a/target/linux/ramips/dts/mt7621_netgear_r6800.dts +++ b/target/linux/ramips/dts/mt7621_netgear_r6800.dts @@ -41,27 +41,27 @@ wlan2g { gpios = <&gpio_expander 4 GPIO_ACTIVE_LOW>; label = "r6800:white:wlan2g"; - linux,default-trigger = "phy0tpt"; + linux,default-trigger = "phy0radio"; }; wlan5g { gpios = <&gpio_expander 5 GPIO_ACTIVE_LOW>; label = "r6800:white:wlan5g"; - linux,default-trigger = "phy1tpt"; + linux,default-trigger = "phy1radio"; }; usb2 { gpios = <&gpio_expander 6 GPIO_ACTIVE_LOW>; label = "r6800:white:usb2"; linux,default-trigger = "usbport"; - trigger-sources = <&hub_port2>; + trigger-sources = <&ehci_port2>; }; usb3 { gpios = <&gpio_expander 7 GPIO_ACTIVE_LOW>; label = "r6800:white:usb3"; linux,default-trigger = "usbport"; - trigger-sources = <&hub_port1>; + trigger-sources = <&xhci_ehci_port1>; }; lan1_orange { @@ -115,3 +115,10 @@ }; }; }; + +&state_default { + gpio { + ralink,group = "uart3", "uart2", "jtag", "wdt"; + ralink,function = "gpio"; + }; +}; diff --git a/target/linux/ramips/dts/mt7621_netgear_sercomm_bzv.dtsi b/target/linux/ramips/dts/mt7621_netgear_sercomm_bzv.dtsi index 500ec06e2..6538b6926 100644 --- a/target/linux/ramips/dts/mt7621_netgear_sercomm_bzv.dtsi +++ b/target/linux/ramips/dts/mt7621_netgear_sercomm_bzv.dtsi @@ -35,18 +35,6 @@ }; }; -&xhci { - hub_port1: port@1 { - reg = <1>; - #trigger-source-cells = <0>; - }; - - hub_port2: port@2 { - reg = <2>; - #trigger-source-cells = <0>; - }; -}; - &pcie { status = "okay"; }; @@ -73,13 +61,6 @@ mtd-mac-address = <&factory 0x4>; }; -&state_default { - gpio { - ralink,group = "uart3", "uart2", "jtag", "wdt"; - ralink,function = "gpio"; - }; -}; - &i2c { status = "okay"; @@ -88,19 +69,8 @@ #interrupt-cells = <2>; compatible = "semtech,sx1503q"; reg = <0x20>; - interrupt-parent = <&gic>; - interrupts = <16 0>; gpio-controller; - interrupt-controller; - - pinctrl-names = "default"; - pinctrl-0 = <&gpio4_cfg_pins>; - - gpio4_cfg_pins: gpio4-cfg { - pins = "gpio4"; - bias-pull-up; - }; }; }; diff --git a/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx-sfp.dts b/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx-sfp.dts index 06f887a37..4715cecb6 100644 --- a/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx-sfp.dts +++ b/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx-sfp.dts @@ -2,8 +2,6 @@ #include "mt7621_ubiquiti_edgerouterx.dtsi" -#include - / { model = "UBNT-ERX-SFP"; compatible = "ubiquiti,edgerouterx-sfp", "mediatek,mt7621-soc"; diff --git a/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dts b/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dts index e78fdcf10..5c1d9ec88 100644 --- a/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dts +++ b/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dts @@ -4,4 +4,5 @@ / { model = "UBNT-ERX"; + compatible = "ubiquiti,edgerouterx", "mediatek,mt7621-soc"; }; diff --git a/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dtsi b/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dtsi index d8b4aa0a0..540ef10e2 100644 --- a/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dtsi +++ b/target/linux/ramips/dts/mt7621_ubiquiti_edgerouterx.dtsi @@ -4,8 +4,6 @@ #include / { - compatible = "ubiquiti,edgerouterx", "mediatek,mt7621-soc"; - aliases { label-mac-device = ðernet; }; diff --git a/target/linux/ramips/dts/mt7621_ubnt_unifi-nanohd.dts b/target/linux/ramips/dts/mt7621_ubnt_unifi-nanohd.dts new file mode 100644 index 000000000..903cbc612 --- /dev/null +++ b/target/linux/ramips/dts/mt7621_ubnt_unifi-nanohd.dts @@ -0,0 +1,141 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "mt7621.dtsi" + +#include +#include + +/ { + compatible = "ubnt,unifi-nanohd", "mediatek,mt7621-soc"; + model = "Ubiquiti UniFi nanoHD"; + + aliases { + led-boot = &led_white; + led-failsafe = &led_white; + led-running = &led_blue; + led-upgrade = &led_blue; + + label-mac-device = ðernet; + }; + + chosen { + bootargs = "console=ttyS0,115200"; + }; + + leds { + compatible = "gpio-leds"; + + led_blue: dome_blue { + label = "nanohd:blue:dome"; + gpios = <&gpio0 3 GPIO_ACTIVE_HIGH>; + }; + + led_white: dome_white { + label = "nanohd:white:dome"; + gpios = <&gpio0 4 GPIO_ACTIVE_HIGH>; + }; + }; + + keys { + compatible = "gpio-keys"; + + reset { + label = "reset"; + gpios = <&gpio0 12 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + }; +}; + +&spi0 { + status = "okay"; + + flash@0 { + compatible = "mx25l25635f", "jedec,spi-nor"; + reg = <0>; + spi-max-frequency = <50000000>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + label = "u-boot"; + reg = <0x0 0x60000>; + read-only; + }; + + partition@60000 { + label = "u-boot-env"; + reg = <0x60000 0x10000>; + read-only; + }; + + factory: partition@70000 { + label = "factory"; + reg = <0x70000 0x10000>; + read-only; + }; + + eeprom: partition@80000 { + label = "eeprom"; + reg = <0x80000 0x10000>; + read-only; + }; + + partition@90000 { + label = "bs"; + reg = <0x90000 0x10000>; + }; + + partition@a0000 { + label = "cfg"; + reg = <0xa0000 0x100000>; + read-only; + }; + + partition@1a0000 { + compatible = "denx,uimage"; + label = "firmware"; + reg = <0x1a0000 0xf30000>; + }; + + partition@10d0000 { + label = "kernel1"; + reg = <0x10d0000 0xf30000>; + read-only; + }; + }; + }; +}; + +&pcie { + status = "okay"; +}; + +&pcie0 { + wifi@0,0 { + reg = <0x0 0 0 0 0>; + mediatek,mtd-eeprom = <&factory 0x0000>; + }; +}; + +&pcie1 { + wifi@0,0 { + reg = <0x0 0 0 0 0>; + mediatek,mtd-eeprom = <&factory 0x8000>; + }; +}; + +ðernet { + mtd-mac-address = <&eeprom 0x0>; +}; + +&state_default { + gpio { + ralink,group = "i2c", "uart2"; + ralink,function = "gpio"; + }; +}; diff --git a/target/linux/ramips/dts/mt7621_unielec_u7621-06-16m.dts b/target/linux/ramips/dts/mt7621_unielec_u7621-06-16m.dts index 603e2dd2d..dc8f88a46 100644 --- a/target/linux/ramips/dts/mt7621_unielec_u7621-06-16m.dts +++ b/target/linux/ramips/dts/mt7621_unielec_u7621-06-16m.dts @@ -36,9 +36,6 @@ #include "mt7621_unielec_u7621-06.dtsi" -#include -#include - / { compatible = "unielec,u7621-06-16m", "unielec,u7621-06", "mediatek,mt7621-soc"; model = "UniElec U7621-06 (16M flash)"; diff --git a/target/linux/ramips/dts/mt7621_unielec_u7621-06-64m.dts b/target/linux/ramips/dts/mt7621_unielec_u7621-06-64m.dts index 3498be044..511739b6c 100644 --- a/target/linux/ramips/dts/mt7621_unielec_u7621-06-64m.dts +++ b/target/linux/ramips/dts/mt7621_unielec_u7621-06-64m.dts @@ -37,9 +37,6 @@ #include "mt7621_unielec_u7621-06.dtsi" -#include -#include - / { compatible = "unielec,u7621-06-64m", "unielec,u7621-06", "mediatek,mt7621-soc"; model = "UniElec U7621-06 (64M flash)"; diff --git a/target/linux/ramips/dts/mt7628an_totolink_a3.dts b/target/linux/ramips/dts/mt7628an_totolink_a3.dts new file mode 100644 index 000000000..87dd8559b --- /dev/null +++ b/target/linux/ramips/dts/mt7628an_totolink_a3.dts @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "mt7628an_iptime.dtsi" + +/ { + compatible = "totolink,a3", "mediatek,mt7628an-soc"; + model = "TOTOLINK A3"; + + aliases { + led-boot = &led_cpu; + led-failsafe = &led_cpu; + led-running = &led_cpu; + led-upgrade = &led_cpu; + }; + + leds { + compatible = "gpio-leds"; + + led_cpu: cpu { + label = "a3:blue:cpu"; + gpios = <&gpio0 11 GPIO_ACTIVE_LOW>; + }; + + wlan { + label = "a3:blue:wlan"; + gpios = <&gpio1 14 GPIO_ACTIVE_LOW>; + linux,default-trigger = "phy0tpt"; + }; + }; +}; + +&esw { + mediatek,portmap = <0x3e>; + mediatek,portdisable = <0x32>; +}; diff --git a/target/linux/ramips/dts/mt7628an_tplink_8m-split-uboot.dtsi b/target/linux/ramips/dts/mt7628an_tplink_8m-split-uboot.dtsi index 222906034..157136bd0 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_8m-split-uboot.dtsi +++ b/target/linux/ramips/dts/mt7628an_tplink_8m-split-uboot.dtsi @@ -1,6 +1,9 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT #include "mt7628an.dtsi" +#include +#include + / { chosen { bootargs = "console=ttyS0,115200"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_8m.dtsi b/target/linux/ramips/dts/mt7628an_tplink_8m.dtsi index 5269fd668..666ff49a9 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_8m.dtsi +++ b/target/linux/ramips/dts/mt7628an_tplink_8m.dtsi @@ -1,5 +1,8 @@ #include "mt7628an.dtsi" +#include +#include + / { chosen { bootargs = "console=ttyS0,115200"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v4.dts b/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v4.dts index 3f02b7af3..9d0f6563c 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v4.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v4.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,archer-c20-v4", "mediatek,mt7628an-soc"; model = "TP-Link Archer C20 v4"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v5.dts b/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v5.dts index e01826841..9aca8429b 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v5.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_archer-c20-v5.dts @@ -3,9 +3,6 @@ #include "mt7628an_tplink_8m-split-uboot.dtsi" -#include -#include - / { compatible = "tplink,archer-c20-v5", "mediatek,mt7628an-soc"; model = "TP-Link Archer C20 v5"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v3.dts b/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v3.dts index 92f581d1e..360466d56 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v3.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v3.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,archer-c50-v3", "mediatek,mt7628an-soc"; model = "TP-Link Archer C50 v3"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v4.dts b/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v4.dts index f7a559918..8db4f2198 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v4.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_archer-c50-v4.dts @@ -3,9 +3,6 @@ #include "mt7628an_tplink_8m-split-uboot.dtsi" -#include -#include - / { compatible = "tplink,archer-c50-v4", "mediatek,mt7628an-soc"; model = "TP-Link Archer C50 v4"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_tl-mr3420-v5.dts b/target/linux/ramips/dts/mt7628an_tplink_tl-mr3420-v5.dts index 76cf0ca24..ad6054867 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_tl-mr3420-v5.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_tl-mr3420-v5.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,tl-mr3420-v5", "mediatek,mt7628an-soc"; model = "TP-Link TL-MR3420 v5"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_tl-wa801nd-v5.dts b/target/linux/ramips/dts/mt7628an_tplink_tl-wa801nd-v5.dts index 7b9033202..5485a0411 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_tl-wa801nd-v5.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_tl-wa801nd-v5.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,tl-wa801nd-v5", "mediatek,mt7628an-soc"; model = "TP-Link TL-WA801ND v5"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_tl-wr802n-v4.dts b/target/linux/ramips/dts/mt7628an_tplink_tl-wr802n-v4.dts index 3c615e606..25444b1d3 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_tl-wr802n-v4.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_tl-wr802n-v4.dts @@ -3,9 +3,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,tl-wr802n-v4", "mediatek,mt7628an-soc"; model = "TP-Link TL-WR802N v4"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_tl-wr840n-v4.dts b/target/linux/ramips/dts/mt7628an_tplink_tl-wr840n-v4.dts index 3f901d3a7..5d7035bba 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_tl-wr840n-v4.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_tl-wr840n-v4.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,tl-wr840n-v4", "mediatek,mt7628an-soc"; model = "TP-Link TL-WR840N v4"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_tl-wr841n-v13.dts b/target/linux/ramips/dts/mt7628an_tplink_tl-wr841n-v13.dts index 89e2923c9..ca25ce643 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_tl-wr841n-v13.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_tl-wr841n-v13.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,tl-wr841n-v13", "mediatek,mt7628an-soc"; model = "TP-Link TL-WR841N v13"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_tl-wr842n-v5.dts b/target/linux/ramips/dts/mt7628an_tplink_tl-wr842n-v5.dts index a0adb160d..50974fafe 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_tl-wr842n-v5.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_tl-wr842n-v5.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,tl-wr842n-v5", "mediatek,mt7628an-soc"; model = "TP-Link TL-WR842N v5"; diff --git a/target/linux/ramips/dts/mt7628an_tplink_tl-wr902ac-v3.dts b/target/linux/ramips/dts/mt7628an_tplink_tl-wr902ac-v3.dts index f4b50a37f..9d5dddbe4 100644 --- a/target/linux/ramips/dts/mt7628an_tplink_tl-wr902ac-v3.dts +++ b/target/linux/ramips/dts/mt7628an_tplink_tl-wr902ac-v3.dts @@ -2,9 +2,6 @@ #include "mt7628an_tplink_8m.dtsi" -#include -#include - / { compatible = "tplink,tl-wr902ac-v3", "mediatek,mt7628an-soc"; model = "TP-Link TL-WR902AC v3"; diff --git a/target/linux/ramips/dts/mt7628an_vocore_vocore2-lite.dts b/target/linux/ramips/dts/mt7628an_vocore_vocore2-lite.dts index fc8fc89b7..12e45be57 100644 --- a/target/linux/ramips/dts/mt7628an_vocore_vocore2-lite.dts +++ b/target/linux/ramips/dts/mt7628an_vocore_vocore2-lite.dts @@ -2,8 +2,6 @@ #include "mt7628an_vocore_vocore2.dtsi" -#include - / { compatible = "vocore,vocore2-lite", "vocore,vocore2", "mediatek,mt7628an-soc"; model = "VoCore2-Lite"; diff --git a/target/linux/ramips/dts/mt7628an_vocore_vocore2.dts b/target/linux/ramips/dts/mt7628an_vocore_vocore2.dts index 939bb0b76..2630f5261 100644 --- a/target/linux/ramips/dts/mt7628an_vocore_vocore2.dts +++ b/target/linux/ramips/dts/mt7628an_vocore_vocore2.dts @@ -2,8 +2,6 @@ #include "mt7628an_vocore_vocore2.dtsi" -#include - / { compatible = "vocore,vocore2", "mediatek,mt7628an-soc"; model = "VoCore2"; diff --git a/target/linux/ramips/dts/mt7628an_vocore_vocore2.dtsi b/target/linux/ramips/dts/mt7628an_vocore_vocore2.dtsi index a0056dced..34664bde9 100644 --- a/target/linux/ramips/dts/mt7628an_vocore_vocore2.dtsi +++ b/target/linux/ramips/dts/mt7628an_vocore_vocore2.dtsi @@ -1,5 +1,7 @@ #include "mt7628an.dtsi" +#include + / { compatible = "vocore,vocore2", "mediatek,mt7628an-soc"; diff --git a/target/linux/ramips/dts/rt3883_belkin_f9k1109v1.dts b/target/linux/ramips/dts/rt3883_belkin_f9k1109v1.dts index 98c099cec..0b4cf699b 100644 --- a/target/linux/ramips/dts/rt3883_belkin_f9k1109v1.dts +++ b/target/linux/ramips/dts/rt3883_belkin_f9k1109v1.dts @@ -3,9 +3,6 @@ #include "rt3883_belkin_f9k110x.dtsi" -#include -#include - / { compatible = "belkin,f9k1109v1", "ralink,rt3883-soc"; model = "Belkin F9K1109 Version 1.0"; diff --git a/target/linux/ramips/image/mt7620.mk b/target/linux/ramips/image/mt7620.mk index 3d601dfed..b8b07dd4e 100644 --- a/target/linux/ramips/image/mt7620.mk +++ b/target/linux/ramips/image/mt7620.mk @@ -611,6 +611,7 @@ define Device/netgear_ex2700 DEVICE_VENDOR := NETGEAR DEVICE_MODEL := EX2700 SUPPORTED_DEVICES += ex2700 + DEFAULT := n endef TARGET_DEVICES += netgear_ex2700 @@ -942,6 +943,18 @@ define Device/tplink_re200-v1 endef TARGET_DEVICES += tplink_re200-v1 +define Device/tplink_re210-v1 + $(Device/tplink-v1) + SOC := mt7620a + DEVICE_MODEL := RE210 + DEVICE_VARIANT := v1 + DEVICE_PACKAGES := kmod-mt76x0e + IMAGE_SIZE := 7936k + TPLINK_HWID := 0x02100001 + TPLINK_FLASHLAYOUT := 8Mmtk +endef +TARGET_DEVICES += tplink_re210-v1 + define Device/vonets_var11n-300 SOC := mt7620n IMAGE_SIZE := 3776k diff --git a/target/linux/ramips/image/mt7621.mk b/target/linux/ramips/image/mt7621.mk index f41457da9..aa5df49e7 100644 --- a/target/linux/ramips/image/mt7621.mk +++ b/target/linux/ramips/image/mt7621.mk @@ -309,7 +309,6 @@ define Device/gehua_ghl-r-001 DEVICE_MODEL := GHL-R-001 DEVICE_PACKAGES := kmod-mt7603 kmod-mt76x2 kmod-usb3 \ kmod-usb-ledtrig-usbport wpad-openssl - DEFAULT := n endef TARGET_DEVICES += gehua_ghl-r-001 @@ -578,7 +577,6 @@ define Device/netgear_r6220 endef TARGET_DEVICES += netgear_r6220 - define Device/netgear_r6260 $(Device/netgear_sercomm_nand) DEVICE_MODEL := R6260 @@ -603,6 +601,21 @@ define Device/netgear_r6350 endef TARGET_DEVICES += netgear_r6350 +define Device/netgear_r6700-v2 + $(Device/netgear_sercomm_nand) + DEVICE_MODEL := R6700 + DEVICE_VARIANT := v2 + DEVICE_ALT0_VENDOR := NETGEAR + DEVICE_ALT0_MODEL := Nighthawk AC2400 + SERCOMM_HWNAME := R6950 + SERCOMM_HWID := BZV + SERCOMM_HWVER := A001 + SERCOMM_SWVER := 0x1032 + IMAGE_SIZE := 40960k + DEVICE_PACKAGES += kmod-mt7615e +endef +TARGET_DEVICES += netgear_r6700-v2 + define Device/netgear_r6800 $(Device/netgear_sercomm_nand) DEVICE_MODEL := R6800 @@ -611,7 +624,7 @@ define Device/netgear_r6800 SERCOMM_HWVER := A001 SERCOMM_SWVER := 0x0062 IMAGE_SIZE := 40960k - DEVICE_PACKAGES += kmod-mt7615e kmod-pinctrl-sx150x + DEVICE_PACKAGES += kmod-mt7615e endef TARGET_DEVICES += netgear_r6800 @@ -783,6 +796,14 @@ define Device/ubiquiti_edgerouterx-sfp endef TARGET_DEVICES += ubiquiti_edgerouterx-sfp +define Device/ubnt_unifi-nanohd + DEVICE_VENDOR := Ubiquiti + DEVICE_MODEL := UniFi nanoHD + DEVICE_PACKAGES += kmod-mt7603 kmod-mt7615e wpad-openssl + IMAGE_SIZE := 15552k +endef +TARGET_DEVICES += ubnt_unifi-nanohd + define Device/unielec_u7621-06-16m IMAGE_SIZE := 16064k DEVICE_VENDOR := UniElec diff --git a/target/linux/ramips/image/mt76x8.mk b/target/linux/ramips/image/mt76x8.mk index faa2ca1c5..51f630f42 100644 --- a/target/linux/ramips/image/mt76x8.mk +++ b/target/linux/ramips/image/mt76x8.mk @@ -229,6 +229,15 @@ define Device/tama_w06 endef TARGET_DEVICES += tama_w06 +define Device/totolink_a3 + IMAGE_SIZE := 7936k + UIMAGE_NAME := za3 + DEVICE_VENDOR := TOTOLINK + DEVICE_MODEL := A3 + DEVICE_PACKAGES := kmod-mt76x2 +endef +TARGET_DEVICES += totolink_a3 + define Device/totolink_lr1200 IMAGE_SIZE := 7872k DEVICE_VENDOR := TOTOLINK diff --git a/target/linux/ramips/mt7620/base-files/etc/board.d/02_network b/target/linux/ramips/mt7620/base-files/etc/board.d/02_network index 7397ddcc2..76e1d56bd 100755 --- a/target/linux/ramips/mt7620/base-files/etc/board.d/02_network +++ b/target/linux/ramips/mt7620/base-files/etc/board.d/02_network @@ -50,8 +50,9 @@ ramips_setup_interfaces() planex,mzk-ex300np|\ planex,mzk-ex750np|\ ravpower,wd03|\ + sercomm,na930|\ tplink,re200-v1|\ - sercomm,na930) + tplink,re210-v1) ucidef_set_interface_lan "eth0" ;; asus,rp-n53) diff --git a/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds b/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds index ac73729d1..7695cb991 100755 --- a/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds +++ b/target/linux/ramips/mt7621/base-files/etc/board.d/01_leds @@ -52,6 +52,7 @@ netgear,r6850|\ netgear,wndr3700-v5) ucidef_set_led_switch "wan" "wan" "$boardname:green:wan" "switch0" "0x10" ;; +netgear,r6700-v2|\ netgear,r6800) ucidef_set_led_switch "wan" "WAN" "$boardname:white:wan" "switch0" "0x10" ucidef_set_led_switch "lan1" "LAN1" "$boardname:white:lan1" "switch0" "0x08" diff --git a/target/linux/ramips/mt7621/base-files/etc/board.d/02_network b/target/linux/ramips/mt7621/base-files/etc/board.d/02_network index 58605aca7..d4d662a96 100755 --- a/target/linux/ramips/mt7621/base-files/etc/board.d/02_network +++ b/target/linux/ramips/mt7621/base-files/etc/board.d/02_network @@ -45,6 +45,7 @@ ramips_setup_interfaces() netgear,r6220|\ netgear,r6260|\ netgear,r6350|\ + netgear,r6700-v2|\ netgear,r6800|\ netgear,r6850|\ netgear,wndr3700-v5|\ @@ -133,7 +134,8 @@ ramips_setup_interfaces() ;; netgear,ex6150|\ tplink,re350-v1|\ - tplink,re650-v1) + tplink,re650-v1|\ + ubnt,unifi-nanohd) ucidef_add_switch "switch0" \ "0:lan" "6@eth0" ;; @@ -258,6 +260,7 @@ ramips_setup_macs() ;; netgear,r6260|\ netgear,r6350|\ + netgear,r6700-v2|\ netgear,r6800|\ netgear,r6850) wan_mac=$(macaddr_add "$(mtd_get_mac_binary factory 0x4)" 2) diff --git a/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh b/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh index f6b5c8643..ad10dcbda 100755 --- a/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh +++ b/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh @@ -48,6 +48,7 @@ platform_do_upgrade() { netgear,r6220|\ netgear,r6260|\ netgear,r6350|\ + netgear,r6700-v2|\ netgear,r6800|\ netgear,r6850|\ netis,wf2881|\ diff --git a/target/linux/ramips/mt7621/config-4.14 b/target/linux/ramips/mt7621/config-4.14 index 4112cad78..2ae6afb97 100644 --- a/target/linux/ramips/mt7621/config-4.14 +++ b/target/linux/ramips/mt7621/config-4.14 @@ -236,6 +236,7 @@ CONFIG_PHYLIB=y CONFIG_PINCTRL=y CONFIG_PINCTRL_RT2880=y # CONFIG_PINCTRL_SINGLE is not set +CONFIG_PINCTRL_SX150X=y CONFIG_POWER_RESET=y CONFIG_POWER_RESET_GPIO=y CONFIG_POWER_SUPPLY=y diff --git a/target/linux/ramips/mt76x8/base-files/etc/board.d/02_network b/target/linux/ramips/mt76x8/base-files/etc/board.d/02_network index 913a0817d..523071750 100755 --- a/target/linux/ramips/mt76x8/base-files/etc/board.d/02_network +++ b/target/linux/ramips/mt76x8/base-files/etc/board.d/02_network @@ -72,7 +72,8 @@ ramips_setup_interfaces() ucidef_add_switch "switch0" \ "0:lan" "1:lan" "4:wan" "6@eth0" ;; - iptime,a3) + iptime,a3|\ + totolink,a3) ucidef_add_switch "switch0" \ "2:lan:2" "3:lan:1" "0:wan" "6@eth0" ;; @@ -166,7 +167,8 @@ ramips_setup_macs() wan_mac=$(macaddr_add "$lan_mac" 1) ;; iptime,a3|\ - iptime,a604m) + iptime,a604m|\ + totolink,a3) wan_mac=$(mtd_get_mac_binary u-boot 0x1fc40) ;; mediatek,linkit-smart-7688|\