Page MenuHomeFreeBSD

D17955.diff
No OneTemporary

D17955.diff

This file is larger than 256 KB, so syntax highlighting was skipped.
Index: sys/gnu/dts/mips/11ACNAS.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/11ACNAS.dts
@@ -0,0 +1,27 @@
+/dts-v1/;
+
+#include "W2914NSV2.dtsi"
+
+/ {
+ compatible = "wevo,11acnas", "wevo,w2914ns-v2", "mediatek,mt7621-soc";
+ model = "WeVO 11AC NAS Router";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ // Only USB LED is connected to GPIO.
+ // All of other LEDs are connected directly to
+ // switch, WiFi chip, Vcc, so they are not controllable
+ // via GPIO
+
+ usb {
+ label = "11acnas:green:usb";
+ gpios = <&gpio0 27 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/3G-6200N.dts
===================================================================
--- sys/gnu/dts/mips/3G-6200N.dts
+++ sys/gnu/dts/mips/3G-6200N.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "3G-6200N", "ralink,rt3050-soc";
+ compatible = "edimax,3g-6200n", "ralink,rt3050-soc";
model = "Edimax 3g-6200n";
cfi@1f000000 {
@@ -49,17 +52,17 @@
power {
label = "3g-6200n:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan {
label = "3g-6200n:amber:wlan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
3g {
label = "3g-6200n:blue:3g";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
};
@@ -69,16 +72,16 @@
#size-cells = <0>;
poll-interval = <20>;
- wps {
- label = "wps";
- gpios = <&gpio0 12 1>;
- linux,code = <0x211>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
- wlanswitch {
+ rfkill {
label = "wlanswitch";
- gpios = <&gpio0 13 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
};
};
Index: sys/gnu/dts/mips/3G-6200NL.dts
===================================================================
--- sys/gnu/dts/mips/3G-6200NL.dts
+++ sys/gnu/dts/mips/3G-6200NL.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "3G-6200NL", "ralink,rt3050-soc";
+ compatible = "edimax,3g-6200nl", "ralink,rt3050-soc";
model = "Edimax 3g-6200nl";
cfi@1f000000 {
@@ -47,9 +50,14 @@
gpio-leds {
compatible = "gpio-leds";
+ internet {
+ label = "3g-6200nl:green:internet";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ };
+
wlan {
- label = "3g-6200nl:amber:wlan";
- gpios = <&gpio0 14 1>;
+ label = "3g-6200nl:green:wlan";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -59,10 +67,10 @@
#size-cells = <0>;
poll-interval = <20>;
- wps {
- label = "wps";
- gpios = <&gpio0 12 1>;
- linux,code = <0x211>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -81,7 +89,7 @@
};
&esw {
- mediatek,portmap = <0x2f>;
+ mediatek,portdisable = <0x37>;
};
&wmac {
Index: sys/gnu/dts/mips/3G150B.dts
===================================================================
--- sys/gnu/dts/mips/3G150B.dts
+++ sys/gnu/dts/mips/3G150B.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "3G150B", "ralink,rt5350-soc";
+ compatible = "tenda,3g150b", "ralink,rt5350-soc";
model = "Tenda 3G150B";
gpio-leds {
@@ -11,12 +14,12 @@
ap {
label = "3g150b:blue:ap";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
3g {
label = "3g150b:blue:3g";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -40,7 +43,7 @@
usb {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -53,7 +56,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/3G300M.dts
===================================================================
--- sys/gnu/dts/mips/3G300M.dts
+++ sys/gnu/dts/mips/3G300M.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "3G300M", "ralink,rt3052-soc";
+ compatible = "tenda,3g300m", "ralink,rt3052-soc";
model = "Tenda 3G300M";
gpio-leds {
@@ -11,32 +14,32 @@
3grouter {
label = "3g300m:blue:3grouter";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
ap {
label = "3g300m:blue:ap";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wisprouter {
label = "3g300m:blue:wisprouter";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wirelessrouter {
label = "3g300m:blue:wirelessrouter";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
3g {
label = "3g300m:blue:3g";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wpsreset {
label = "3g300m:blue:wpsreset";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -48,14 +51,14 @@
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
mode {
label = "mode";
- gpios = <&gpio0 10 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
@@ -68,7 +71,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/A5-V11.dts
===================================================================
--- sys/gnu/dts/mips/A5-V11.dts
+++ sys/gnu/dts/mips/A5-V11.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "A5-V11", "ralink,rt5350-soc";
+ compatible = "unbranded,a5-v11", "ralink,rt5350-soc";
model = "A5-V11";
gpio-leds {
@@ -11,12 +14,12 @@
system {
label = "a5-v11:blue:system";
- gpios = <&gpio0 20 1>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
power {
label = "a5-v11:red:power";
- gpios = <&gpio0 17 1>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -40,13 +43,13 @@
usb {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio0 7 0>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
root_hub {
gpio-export,name = "root_hub";
gpio-export,output = <1>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -59,7 +62,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "pm25lq032";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/AC1200RM.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/AC1200RM.dts
@@ -0,0 +1,176 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright (C) 2018 Piotr Dymacz <pepe2k@gmail.com>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the names of the copyright holders nor the names of any
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "alfa-network,ac1200rm", "ralink,mt7620a-soc";
+ model = "ALFA Network AC1200RM";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio2 15 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ wlan2g {
+ label = "ac1200rm:green:wlan2g";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "ac1200rm:green:wps";
+ gpios = <&gpio1 14 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+ mediatek,portmap = "llllw";
+ pinctrl-names = "default";
+ pinctrl-0 = <&ephy_pins>;
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&gsw {
+ mediatek,port4 = "ephy";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+
+ led {
+ led-sources = <2>;
+ led-active-low;
+ };
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "nd_sd", "spi refclk", "wled";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x1000>;
+ };
+
+ partition@031000 {
+ label = "config";
+ reg = <0x31000 0xf000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
Index: sys/gnu/dts/mips/AI-BR100.dts
===================================================================
--- sys/gnu/dts/mips/AI-BR100.dts
+++ sys/gnu/dts/mips/AI-BR100.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "AI-BR100", "ralink,mt7620a-soc";
+ compatible = "aigale,ai-br100", "ralink,mt7620a-soc";
model = "Aigale Ai-BR100";
gpio-leds {
@@ -11,12 +14,12 @@
wan {
label = "ai-br100:blue:wan";
- gpios = <&gpio2 4 1>;
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
};
wlan {
label = "ai-br100:blue:wlan";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
reset {
label = "reset";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -50,7 +53,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0 0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -96,8 +98,6 @@
};
&ethernet {
- pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "llllw";
};
Index: sys/gnu/dts/mips/AIR3GII.dts
===================================================================
--- sys/gnu/dts/mips/AIR3GII.dts
+++ sys/gnu/dts/mips/AIR3GII.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "AIR3GII", "ralink,rt5350-soc";
+ compatible = "airlive,air3gii", "ralink,rt5350-soc";
model = "AirLive Air3GII";
gpio-leds {
@@ -11,12 +14,12 @@
wlan {
label = "air3gii:green:wlan";
- gpios = <&gpio0 8 0>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
};
mobile {
label = "air3gii:green:mobile";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
wps {
label = "wps";
- gpios = <&gpio0 7 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -46,7 +49,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q32b";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/ALL0239-3G.dts
===================================================================
--- sys/gnu/dts/mips/ALL0239-3G.dts
+++ sys/gnu/dts/mips/ALL0239-3G.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ALL0239-3G", "ralink,rt3052-soc";
+ compatible = "allnet,all0239-3g", "ralink,rt3052-soc";
model = "Allnet ALL0239-3G";
@@ -44,22 +47,22 @@
usb {
label = "all0239-3g:green:usb";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
3g {
label = "all0239-3g:green:3g";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
status {
label = "all0239-3g:green:status";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "all0239-3g:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -71,20 +74,20 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
connect {
label = "connect";
- gpios = <&gpio0 7 1>;
- linux,code = <0xda>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_CONNECT>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/ALL0256N-4M.dts
===================================================================
--- sys/gnu/dts/mips/ALL0256N-4M.dts
+++ sys/gnu/dts/mips/ALL0256N-4M.dts
@@ -1,46 +1,10 @@
/dts-v1/;
-#include "rt3050.dtsi"
+#include "ALL0256N.dtsi"
/ {
- compatible = "ALL0256N", "ralink,rt3050-soc";
- model = "Allnet ALL0256N";
-
- gpio-leds {
- compatible = "gpio-leds";
-
- rssilow {
- label = "all0256n:green:rssilow";
- gpios = <&gpio0 14 1>;
- };
-
- rssimed {
- label = "all0256n:green:rssimed";
- gpios = <&gpio0 12 1>;
- };
-
- rssihigh {
- label = "all0256n:green:rssihigh";
- gpios = <&gpio0 13 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
- };
- };
-};
-
-&gpio0 {
- status = "okay";
+ compatible = "allnet,all0256n-4m", "allnet,all0256n", "ralink,rt3050-soc";
+ model = "Allnet ALL0256N (4M)";
};
&spi0 {
@@ -51,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -78,24 +41,3 @@
};
};
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x28>;
-};
-
-&esw {
- mediatek,portmap = <0x3f>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
Index: sys/gnu/dts/mips/ALL0256N-8M.dts
===================================================================
--- sys/gnu/dts/mips/ALL0256N-8M.dts
+++ sys/gnu/dts/mips/ALL0256N-8M.dts
@@ -1,46 +1,10 @@
/dts-v1/;
-#include "rt3050.dtsi"
+#include "ALL0256N.dtsi"
/ {
- compatible = "ALL0256N", "ralink,rt3050-soc";
- model = "Allnet ALL0256N";
-
- gpio-leds {
- compatible = "gpio-leds";
-
- rssilow {
- label = "all0256n:green:rssilow";
- gpios = <&gpio0 14 1>;
- };
-
- rssimed {
- label = "all0256n:green:rssimed";
- gpios = <&gpio0 12 1>;
- };
-
- rssihigh {
- label = "all0256n:green:rssihigh";
- gpios = <&gpio0 13 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
- };
- };
-};
-
-&gpio0 {
- status = "okay";
+ compatible = "allnet,all0256n-8m", "allnet,all0256n", "ralink,rt3050-soc";
+ model = "Allnet ALL0256N (8M)";
};
&spi0 {
@@ -51,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -78,24 +41,3 @@
};
};
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x28>;
-};
-
-&esw {
- mediatek,portmap = <0x3f>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
Index: sys/gnu/dts/mips/ALL0256N.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ALL0256N.dtsi
@@ -0,0 +1,65 @@
+#include "rt3050.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "allnet,all0256n", "ralink,rt3050-soc";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ rssilow {
+ label = "all0256n:green:rssilow";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ rssimed {
+ label = "all0256n:green:rssimed";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ };
+
+ rssihigh {
+ label = "all0256n:green:rssihigh";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+};
+
+&gpio0 {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&esw {
+ mediatek,portmap = <0x3f>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
Index: sys/gnu/dts/mips/ALL5002.dts
===================================================================
--- sys/gnu/dts/mips/ALL5002.dts
+++ sys/gnu/dts/mips/ALL5002.dts
@@ -2,13 +2,19 @@
#include "rt3352.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ALL5002", "ralink,rt3352-soc";
+ compatible = "allnet,all5002", "ralink,rt3352-soc";
model = "Allnet ALL5002";
i2c-gpio {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
compatible = "i2c-gpio";
- gpios = <&gpio0 1 0 &gpio0 2 0>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH &gpio0 2 GPIO_ACTIVE_HIGH>;
i2c-gpio,delay-us = <10>;
pcf0: iexp@38 {
@@ -29,12 +35,12 @@
ld1 {
label = "all5002:green:ld1";
- gpios = <&pcf0 0 1>;
+ gpios = <&pcf0 0 GPIO_ACTIVE_LOW>;
};
ld2 {
label = "all5002:green:ld2";
- gpios = <&pcf0 1 1>;
+ gpios = <&pcf0 1 GPIO_ACTIVE_LOW>;
};
};
};
@@ -51,7 +57,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l25635e";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/ALL5003.dts
===================================================================
--- sys/gnu/dts/mips/ALL5003.dts
+++ sys/gnu/dts/mips/ALL5003.dts
@@ -2,13 +2,19 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ALL5003", "ralink,rt5350-soc";
+ compatible = "allnet,all5003", "ralink,rt5350-soc";
model = "Allnet ALL5003";
i2c-gpio {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
compatible = "i2c-gpio";
- gpios = <&gpio0 1 0 &gpio0 2 0>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH &gpio0 2 GPIO_ACTIVE_HIGH>;
i2c-gpio,delay-us = <10>;
pcf0: iexp@38 {
@@ -29,12 +35,12 @@
ld1 {
label = "all5003:green:ld1";
- gpios = <&pcf0 0 1>;
+ gpios = <&pcf0 0 GPIO_ACTIVE_LOW>;
};
ld2 {
label = "all5003:green:ld2";
- gpios = <&pcf0 1 1>;
+ gpios = <&pcf0 1 GPIO_ACTIVE_LOW>;
};
};
};
@@ -51,7 +57,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l25635e";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/AP-MT7621A-V60.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/AP-MT7621A-V60.dts
@@ -0,0 +1,127 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+/ {
+ compatible = "mediatek,ap-mt7621a-v60", "mediatek,mt7621-soc";
+ model = "Mediatek AP-MT7621A-V60 EVB";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
+
+ sound {
+ compatible = "simple-audio-card";
+ simple-audio-card,name = "Audio-I2S";
+ simple-audio-card,format = "i2s";
+ simple-audio-card,bitclock-master = <&dailink0_master>;
+ simple-audio-card,frame-master = <&dailink0_master>;
+ simple-audio-card,widgets =
+ "Microphone", "Microphone Jack",
+ "Headphone", "Headphone Jack";
+ simple-audio-card,routing =
+ "LINPUT1", "Microphone Jack",
+ "RINPUT1", "Microphone Jack",
+ "Headphone Jack", "HP_L",
+ "Headphone Jack", "HP_R";
+ simple-audio-card,mclk-fs = <256>;
+
+ simple-audio-card,cpu {
+ sound-dai = <&i2s>;
+ };
+
+ dailink0_master: simple-audio-card,codec {
+ sound-dai = <&codec>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "uart2", "rgmii2";
+ ralink,function = "gpio";
+ };
+ };
+ i2s_pins: i2s {
+ i2s {
+ ralink,group = "uart3";
+ ralink,function = "i2s";
+ };
+ };
+};
+
+&i2c {
+ status = "okay";
+
+ codec: wm8960@1a {
+ #sound-dai-cells = <0>;
+ compatible = "wlf,wm8960";
+ reg = <0x1a>;
+ wlf,shared-lrclk;
+ };
+};
+
+&gdma {
+ status = "okay";
+};
+
+&i2s {
+ #sound-dai-cells = <0>;
+ status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2s_pins>;
+};
+
+&spi0 {
+ status = "okay";
+
+ mx25l6405d@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "mx25l6405d","jedec,spi-nor";
+ reg = <0 0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x7b0000>;
+ };
+ };
+};
+
+&sdhci {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x5>;
+};
+
+&pcie {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/AR670W.dts
===================================================================
--- sys/gnu/dts/mips/AR670W.dts
+++ sys/gnu/dts/mips/AR670W.dts
@@ -2,8 +2,11 @@
#include "rt2880.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "AR670W", "ralink,rt2880-soc";
+ compatible = "airlink101,ar670w", "ralink,rt2880-soc";
model = "Airlink101 AR670W";
cfi@bdc00000 {
@@ -36,12 +39,12 @@
status {
label = "ar670w:green:power";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wpsblue {
label = "ar670w:blue:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -53,14 +56,14 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 9 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/AR725W.dts
===================================================================
--- sys/gnu/dts/mips/AR725W.dts
+++ sys/gnu/dts/mips/AR725W.dts
@@ -2,8 +2,11 @@
#include "rt2880.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "AR725W", "ralink,rt2880-soc";
+ compatible = "airlink101,ar725w", "ralink,rt2880-soc";
model = "Airlink101 AR725W";
cfi@bdc00000 {
@@ -41,17 +44,17 @@
status {
label = "ar725w:green:power";
- gpios = <&gpio0 7 0>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
wpsred {
label = "ar725w:red:wps";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
wpsblue {
label = "ar725w:blue:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -63,14 +66,14 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 9 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/ASL26555-16M.dts
===================================================================
--- sys/gnu/dts/mips/ASL26555-16M.dts
+++ sys/gnu/dts/mips/ASL26555-16M.dts
@@ -1,77 +1,10 @@
/dts-v1/;
-#include "rt3050.dtsi"
+#include "ASL26555.dtsi"
/ {
- compatible = "ASL26555", "ralink,rt3050-soc";
- model = "Alpha ASL26555";
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 10 0>;
- linux,code = <0x198>;
- };
-
- wps {
- label = "wps";
- gpios = <&gpio0 12 0>;
- linux,code = <0x211>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- eth {
- label = "asl26555:green:eth";
- gpios = <&gpio0 0 1>;
- };
-
- wan-red {
- label = "asl26555:red:wan";
- gpios = <&gpio0 1 0>;
- };
-
- wan-green {
- label = "asl26555:green:wan";
- gpios = <&gpio0 2 0>;
- };
-
- wlan {
- label = "asl26555:green:wlan";
- gpios = <&gpio0 7 0>;
- };
-
- power-green {
- label = "asl26555:green:power";
- gpios = <&gpio0 8 0>;
- };
-
- power-red {
- label = "asl26555:red:power";
- gpios = <&gpio0 9 0>;
- };
-
- 3g-green {
- label = "asl26555:green:3g";
- gpios = <&gpio0 14 1>;
- };
-
- 3g-red {
- label = "asl26555:red:3g";
- gpios = <&gpio0 17 1>;
- };
- };
-};
-
-&gpio0 {
- status = "okay";
+ compatible = "alphanetworks,asl26555-16m", "alphanetworks,asl26555", "ralink,rt3050-soc";
+ model = "Alpha ASL26555 (16M)";
};
&spi0 {
@@ -82,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25sl12801";
spi-max-frequency = <10000000>;
partition@0 {
@@ -127,28 +59,3 @@
};
};
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&devdata 0x4004>;
-};
-
-&esw {
- mediatek,portmap = <0x1e>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&devdata 0x4000>;
-};
-
-&otg {
- status = "okay";
-};
Index: sys/gnu/dts/mips/ASL26555-8M.dts
===================================================================
--- sys/gnu/dts/mips/ASL26555-8M.dts
+++ sys/gnu/dts/mips/ASL26555-8M.dts
@@ -1,77 +1,10 @@
/dts-v1/;
-#include "rt3050.dtsi"
+#include "ASL26555.dtsi"
/ {
- compatible = "ASL26555", "ralink,rt3050-soc";
- model = "Alpha ASL26555";
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 10 0>;
- linux,code = <0x198>;
- };
-
- wps {
- label = "wps";
- gpios = <&gpio0 12 0>;
- linux,code = <0x211>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- eth {
- label = "asl26555:green:eth";
- gpios = <&gpio0 0 1>;
- };
-
- wan-red {
- label = "asl26555:red:wan";
- gpios = <&gpio0 1 0>;
- };
-
- wan-green {
- label = "asl26555:green:wan";
- gpios = <&gpio0 2 0>;
- };
-
- wlan {
- label = "asl26555:green:wlan";
- gpios = <&gpio0 7 0>;
- };
-
- power-green {
- label = "asl26555:green:power";
- gpios = <&gpio0 8 0>;
- };
-
- power-red {
- label = "asl26555:red:power";
- gpios = <&gpio0 9 0>;
- };
-
- 3g-green {
- label = "asl26555:green:3g";
- gpios = <&gpio0 14 1>;
- };
-
- 3g-red {
- label = "asl26555:red:3g";
- gpios = <&gpio0 17 1>;
- };
- };
-};
-
-&gpio0 {
- status = "okay";
+ compatible = "alphanetworks,asl26555-8m", "alphanetworks,asl26555", "ralink,rt3050-soc";
+ model = "Alpha ASL26555 (8M)";
};
&spi0 {
@@ -82,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25sl064p";
spi-max-frequency = <10000000>;
partition@0 {
@@ -91,7 +23,7 @@
read-only;
};
- ubootenv: partition@30000 {
+ devdata: partition@30000 {
label = "uboot-env";
reg = <0x30000 0x10000>;
read-only;
@@ -121,28 +53,3 @@
};
};
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&ubootenv 0x4004>;
-};
-
-&esw {
- mediatek,portmap = <0x1e>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&ubootenv 0x4000>;
-};
-
-&otg {
- status = "okay";
-};
Index: sys/gnu/dts/mips/ASL26555.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ASL26555.dtsi
@@ -0,0 +1,100 @@
+#include "rt3050.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "alphanetworks,asl26555", "ralink,rt3050-soc";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ eth {
+ label = "asl26555:green:eth";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ };
+
+ wan-red {
+ label = "asl26555:red:wan";
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ };
+
+ wan-green {
+ label = "asl26555:green:wan";
+ gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+ };
+
+ wlan {
+ label = "asl26555:green:wlan";
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
+ };
+
+ power-green {
+ label = "asl26555:green:power";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ };
+
+ power-red {
+ label = "asl26555:red:power";
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
+ };
+
+ 3g-green {
+ label = "asl26555:green:3g";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ 3g-red {
+ label = "asl26555:red:3g";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&gpio0 {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&devdata 0x4004>;
+};
+
+&esw {
+ mediatek,portmap = <0x1e>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&devdata 0x4000>;
+};
+
+&otg {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/ATP-52B.dts
===================================================================
--- sys/gnu/dts/mips/ATP-52B.dts
+++ sys/gnu/dts/mips/ATP-52B.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ATP-52B", "ralink,rt3052-soc";
+ compatible = "argus,atp-52b", "ralink,rt3052-soc";
model = "Argus ATP-52B";
cfi@1f000000 {
@@ -41,12 +44,12 @@
run {
label = "atp-52b:green:run";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
net {
label = "atp-52b:amber:net";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -58,14 +61,14 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/AWAPN2403.dts
===================================================================
--- sys/gnu/dts/mips/AWAPN2403.dts
+++ sys/gnu/dts/mips/AWAPN2403.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "AWAPN2403", "ralink,rt3052-soc";
+ compatible = "asiarf,awapn2403", "ralink,rt3052-soc";
model = "AsiaRF AWAPN2403";
gpio-leds {
@@ -11,7 +14,7 @@
link {
label = "awapn2403:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -23,8 +26,8 @@
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -37,7 +40,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/AWM002-4M.dtsi
===================================================================
--- sys/gnu/dts/mips/AWM002-4M.dtsi
+++ /dev/null
@@ -1,11 +0,0 @@
-#include "AWM002.dtsi"
-
-/ {
- compatible = "AWM002", "ralink,rt5350-soc";
- model = "AsiaRF AWM002";
-};
-
-&m25p80 {
- compatible = "jedec,spi-nor";
- linux,modalias = "m25p80", "mx25l3205d";
-};
Index: sys/gnu/dts/mips/AWM002-8M.dtsi
===================================================================
--- sys/gnu/dts/mips/AWM002-8M.dtsi
+++ /dev/null
@@ -1,11 +0,0 @@
-#include "AWM002.dtsi"
-
-/ {
- compatible = "AWM002", "ralink,rt5350-soc";
- model = "AsiaRF AWM002";
-};
-
-&m25p80 {
- compatible = "jedec,spi-nor";
- linux,modalias = "m25p80", "mx25l6405d";
-};
Index: sys/gnu/dts/mips/AWM002-EVB-4M.dts
===================================================================
--- sys/gnu/dts/mips/AWM002-EVB-4M.dts
+++ sys/gnu/dts/mips/AWM002-EVB-4M.dts
@@ -1,53 +1,43 @@
/dts-v1/;
-#include "AWM002-4M.dtsi"
+#include "AWM002-EVB.dtsi"
/ {
- model = "AsiaRF AWM002 EVB";
+ compatible = "asiarf,awm002-evb-4m", "ralink,rt5350-soc";
+ model = "AsiaRF AWM002 EVB (4M)";
+};
- gpio-leds {
- compatible = "gpio-leds";
+&spi0 {
+ status = "okay";
- tx {
- label = "awm002-evb:green:tx";
- gpios = <&gpio0 15 1>;
+ m25p80: m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ reg = <0>;
+ compatible = "jedec,spi-nor";
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
};
- rx {
- label = "awm002-evb:green:rx";
- gpios = <&gpio0 16 1>;
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
};
- wps {
- label = "awm002-evb:green:wps";
- gpios = <&gpio0 21 1>;
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
};
- };
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset_wps {
- label = "reset_wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
- };
-
- mode {
- label = "mode";
- gpios = <&gpio0 20 1>;
- linux,code = <0x32>;
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x3b0000>;
};
};
};
-
-&ethernet {
- mtd-mac-address = <&factory 0x28>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
Index: sys/gnu/dts/mips/AWM002-EVB-8M.dts
===================================================================
--- sys/gnu/dts/mips/AWM002-EVB-8M.dts
+++ sys/gnu/dts/mips/AWM002-EVB-8M.dts
@@ -1,53 +1,43 @@
/dts-v1/;
-#include "AWM002-8M.dtsi"
+#include "AWM002-EVB.dtsi"
/ {
- model = "AsiaRF AWM002 EVB";
+ compatible = "asiarf,awm002-evb-8m", "ralink,rt5350-soc";
+ model = "AsiaRF AWM002 EVB (8M)";
+};
- gpio-leds {
- compatible = "gpio-leds";
+&spi0 {
+ status = "okay";
- tx {
- label = "awm002-evb:green:tx";
- gpios = <&gpio0 15 1>;
+ m25p80: m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ reg = <0>;
+ compatible = "jedec,spi-nor";
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
};
- rx {
- label = "awm002-evb:green:rx";
- gpios = <&gpio0 16 1>;
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
};
- wps {
- label = "awm002-evb:green:wps";
- gpios = <&gpio0 21 1>;
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
};
- };
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset_wps {
- label = "reset_wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
- };
-
- mode {
- label = "mode";
- gpios = <&gpio0 20 1>;
- linux,code = <0x32>;
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x7b0000>;
};
};
};
-
-&ethernet {
- mtd-mac-address = <&factory 0x28>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
Index: sys/gnu/dts/mips/AWM002-EVB.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/AWM002-EVB.dtsi
@@ -0,0 +1,75 @@
+#include "rt5350.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "asiarf,awm002-evb", "ralink,rt5350-soc";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ tx {
+ label = "awm002-evb:green:tx";
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
+ };
+
+ rx {
+ label = "awm002-evb:green:rx";
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "awm002-evb:green:wps";
+ gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset_wps {
+ label = "reset_wps";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ mode {
+ label = "mode";
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "jtag";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&esw {
+ mediatek,portmap = <0x3f>;
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/AWM002.dtsi
===================================================================
--- sys/gnu/dts/mips/AWM002.dtsi
+++ /dev/null
@@ -1,76 +0,0 @@
-#include "rt5350.dtsi"
-
-/ {
- compatible = "AWM002", "ralink,rt5350-soc";
- model = "AsiaRF AWM002";
-
- gpio-leds {
- compatible = "gpio-leds";
-
- ld1 {
- label = "awm002:green:ld1";
- gpios = <&gpio0 0 1>;
- };
-
- ld2 {
- label = "awm002:green:ld2";
- gpios = <&gpio0 1 1>;
- };
- };
-};
-
-&spi0 {
- status = "okay";
-
- m25p80: m25p80@0 {
- #address-cells = <1>;
- #size-cells = <1>;
- reg = <0>;
- compatible = "jedec,spi-nor";
- spi-max-frequency = <10000000>;
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- partition@30000 {
- label = "u-boot-env";
- reg = <0x30000 0x10000>;
- read-only;
- };
-
- factory: partition@40000 {
- label = "factory";
- reg = <0x40000 0x10000>;
- read-only;
- };
-
- partition@50000 {
- label = "firmware";
- reg = <0x50000 0x1fb0000>;
- };
- };
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag";
- ralink,function = "gpio";
- };
- };
-};
-
-&esw {
- mediatek,portmap = <0x3f>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
Index: sys/gnu/dts/mips/AWM003-EVB.dts
===================================================================
--- sys/gnu/dts/mips/AWM003-EVB.dts
+++ /dev/null
@@ -1,64 +0,0 @@
-/dts-v1/;
-
-#include "AWM002-8M.dtsi"
-
-/ {
- compatible = "AWM003", "ralink,rt5350-soc";
- model = "AsiaRF AWM003 EVB";
-
- memory@0 {
- device_type = "memory";
- reg = <0x0 0x4000000>;
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- tx {
- label = "awm003-evb:green:tx";
- gpios = <&gpio0 15 1>;
- };
-
- rx {
- label = "awm003-evb:green:rx";
- gpios = <&gpio0 16 1>;
- };
-
- wps {
- label = "awm003-evb:green:wps";
- gpios = <&gpio0 21 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset_wps {
- label = "reset_wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
- };
-
- mode {
- label = "mode";
- gpios = <&gpio0 20 1>;
- linux,code = <0x32>;
- };
- };
-};
-
-&m25p80 {
- compatible = "jedec,spi-nor";
- linux,modalias = "m25p80", "mx25l6405d";
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x28>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
Index: sys/gnu/dts/mips/AWUSFREE1.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/AWUSFREE1.dts
@@ -0,0 +1,164 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright (C) 2018 Piotr Dymacz <pepe2k@gmail.com>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the names of the copyright holders nor the names of any
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/dts-v1/;
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "alfa-network,awusfree1", "mediatek,mt7628an-soc";
+ model = "ALFA Network AWUSFREE1";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ system {
+ label = "awusfree1:orange:system";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "awusfree1:blue:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
+};
+
+&ehci {
+ status = "disabled";
+};
+
+&esw {
+ mediatek,portdisable = <0x1e>;
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x2e>;
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&ohci {
+ status = "disabled";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "p0led_an", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+
+ ext_lna {
+ ralink,group = "uart1";
+ ralink,function = "sw_r";
+ };
+
+ ext_pa {
+ ralink,group = "i2s";
+ ralink,function = "antenna";
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x1000>;
+ };
+
+ partition@031000 {
+ label = "config";
+ reg = <0x31000 0xf000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x7b0000>;
+ };
+ };
+};
+
+&wmac {
+ status = "okay";
+ mediatek,mtd-eeprom = <&factory 0x0>;
+};
Index: sys/gnu/dts/mips/ArcherC20i.dts
===================================================================
--- sys/gnu/dts/mips/ArcherC20i.dts
+++ sys/gnu/dts/mips/ArcherC20i.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "tplink,c20i", "ralink,mt7620a-soc";
model = "TP-Link Archer C20i";
chosen {
@@ -12,20 +15,57 @@
gpio-leds {
compatible = "gpio-leds";
+ lan {
+ label = "c20i:blue:lan";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ };
+ usb {
+ label = "c20i:blue:usb";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+ wps {
+ label = "c20i:blue:wps";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
+ };
+ wan {
+ label = "c20i:blue:wan";
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
+ };
+ wlan {
+ label = "c20i:blue:wlan";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
};
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
+ gpio-keys {
+ compatible = "gpio-keys";
#address-cells = <1>;
#size-cells = <0>;
- poll-interval = <20>;
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+ reset_wps {
+ label = "reset_wps";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
};
};
+&gpio1 {
+ status = "okay";
+};
+
&gpio2 {
status = "okay";
};
+&gpio3 {
+ status = "okay";
+};
+
&spi0 {
status = "okay";
@@ -34,7 +74,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -73,7 +112,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
+ ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd", "ephy", "spi refclk";
ralink,function = "gpio";
};
};
@@ -81,7 +120,6 @@
&ethernet {
pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&rom 0xf100>;
mediatek,portmap = "wllll";
};
@@ -110,7 +148,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&radio 32768>;
- mediatek,2ghz = <0>;
};
};
};
Index: sys/gnu/dts/mips/ArcherC20v1.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ArcherC20v1.dts
@@ -0,0 +1,188 @@
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "tplink,c20-v1", "ralink,mt7620a-soc";
+ model = "TP-Link Archer C20 v1";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "c20-v1:blue:lan";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "c20-v1:blue:power";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ default-state = "keep";
+ };
+
+ usb {
+ label = "c20-v1:blue:usb";
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "c20-v1:blue:wan";
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
+ };
+
+ wan_orange {
+ label = "c20-v1:orange:wan";
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
+ };
+
+ wlan5g {
+ label = "c20-v1:blue:wlan5g";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan2g {
+ label = "c20-v1:blue:wlan2g";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "c20-v1:blue:wps";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x20000>;
+ read-only;
+ };
+
+ partition@20000 {
+ label = "firmware";
+ reg = <0x20000 0x7a0000>;
+ };
+
+ partition@7c0000 {
+ label = "config";
+ reg = <0x7c0000 0x10000>;
+ read-only;
+ };
+
+ rom: partition@7d0000 {
+ label = "rom";
+ reg = <0x7d0000 0x10000>;
+ read-only;
+ };
+
+ partition@7e0000 {
+ label = "romfile";
+ reg = <0x7e0000 0x10000>;
+ read-only;
+ };
+
+ radio: partition@7f0000 {
+ label = "radio";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartf", "wled", "ephy", "spi refclk", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ pinctrl-names = "default";
+ mtd-mac-address = <&rom 0xf100>;
+ mediatek,portmap = "wllll";
+ };
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&gsw {
+ mediatek,port4 = "ephy";
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&radio 0>;
+ mtd-mac-address = <&rom 0xf100>;
+ mtd-mac-address-increment = <(-2)>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&radio 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ mtd-mac-address = <&rom 0xf100>;
+ mtd-mac-address-increment = <(-1)>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/ArcherC20v4.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ArcherC20v4.dts
@@ -0,0 +1,101 @@
+/dts-v1/;
+
+#include "TPLINK-8M.dtsi"
+
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "tplink,c20-v4", "mediatek,mt7628an-soc";
+ model = "TP-Link Archer C20 v4";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "c20-v4:green:lan";
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "c20-v4:green:power";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "c20-v4:green:wan";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_orange {
+ label = "c20-v4:orange:wan";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan5g {
+ label = "c20-v4:green:wlan5g";
+ gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan2g {
+ label = "c20-v4:green:wlan2g";
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "c20-v4:green:wps";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+};
+
+&wmac {
+ mtd-mac-address-increment = <(-2)>;
+};
+
+&ethernet {
+ mediatek,portmap = "wllll";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2s", "refclk", "p0led_an", "p1led_an", "p2led_an", "p3led_an", "p4led_an", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x28000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ mtd-mac-address = <&factory 0xf100>;
+ mtd-mac-address-increment = <(-1)>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/ArcherC50.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ArcherC50.dts
@@ -0,0 +1,187 @@
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "tplink,c50", "ralink,mt7620a-soc";
+ model = "TP-Link Archer C50";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "c50:green:lan";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "c50:green:power";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ default-state = "on";
+ };
+
+ usb {
+ label = "c50:green:usb";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "c50:green:wan";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_orange {
+ label = "c50:orange:wan";
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan5g {
+ label = "c50:green:wlan5g";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan2g {
+ label = "c50:green:wlan2g";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "c50:green:wps";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ }; };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x20000>;
+ read-only;
+ };
+
+ partition@20000 {
+ label = "firmware";
+ reg = <0x20000 0x7a0000>;
+ };
+
+ partition@7c0000 {
+ label = "config";
+ reg = <0x7c0000 0x10000>;
+ read-only;
+ };
+
+ rom: partition@7d0000 {
+ label = "rom";
+ reg = <0x7d0000 0x10000>;
+ read-only;
+ };
+
+ partition@7e0000 {
+ label = "romfile";
+ reg = <0x7e0000 0x10000>;
+ read-only;
+ };
+
+ radio: partition@7f0000 {
+ label = "radio";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "ephy", "spi refclk", "mdio", "wdt", "nd_sd";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ pinctrl-names = "default";
+ mtd-mac-address = <&rom 0xf100>;
+ mediatek,portmap = "wllll";
+ };
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&gsw {
+ mediatek,port4 = "ephy";
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&radio 0>;
+ mtd-mac-address = <&rom 0xf100>;
+ mtd-mac-address-increment = <(-2)>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&radio 32768>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ mtd-mac-address = <&rom 0xf100>;
+ mtd-mac-address-increment = <(-1)>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/ArcherC50V3.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ArcherC50V3.dts
@@ -0,0 +1,94 @@
+/dts-v1/;
+
+#include "TPLINK-8M.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,c50-v3", "mediatek,mt7628an-soc";
+ model = "TP-Link Archer C50 v3";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "c50-v3:green:lan";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "c50-v3:green:power";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "c50-v3:green:wan";
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_orange {
+ label = "c50-v3:orange:wan";
+ gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "c50-v3:green:wlan2g";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan5 {
+ label = "c50-v3:green:wlan5g";
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "c50-v3:green:wps";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "gpio", "p0led_an", "p1led_an", "p2led_an",
+ "p3led_an", "p4led_an", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x28000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ mtd-mac-address = <&factory 0xf100>;
+ mtd-mac-address-increment = <(-1)>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/ArcherMR200.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ArcherMR200.dts
@@ -0,0 +1,194 @@
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,mr200", "ralink,mt7620a-soc";
+ model = "TP-Link Archer MR200";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "mr200:white:lan";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "mr200:white:wan";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "mr200:white:power";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ };
+
+ 4g {
+ label = "mr200:white:4g";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "mr200:white:wps";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
+ };
+
+ signal1 {
+ label = "mr200:white:signal1";
+ gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
+ };
+
+ signal2 {
+ label = "mr200:white:signal2";
+ gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
+ };
+
+ signal3 {
+ label = "mr200:white:signal3";
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
+ };
+
+ signal4 {
+ label = "mr200:white:signal4";
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "mr200:white:wlan";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys {
+ compatible = "gpio-keys";
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ power_usb {
+ gpio-export,name = "power_usb1";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x20000>;
+ read-only;
+ };
+
+ partition@20000 {
+ label = "firmware";
+ reg = <0x20000 0x7b0000>;
+ };
+
+ rom: partition@7d0000 {
+ label = "rom";
+ reg = <0x7d0000 0x10000>;
+ read-only;
+ };
+
+ partition@7e0000 {
+ label = "romfile";
+ reg = <0x7e0000 0x10000>;
+ read-only;
+ };
+
+ radio: partition@7f0000 {
+ label = "radio";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd", "ephy", "spi refclk";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&rom 0xf100>;
+ mediatek,portmap = "llll";
+ };
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&gsw {
+ mediatek,port4 = "ephy";
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&radio 0>;
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&radio 32768>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/BC2.dts
===================================================================
--- sys/gnu/dts/mips/BC2.dts
+++ sys/gnu/dts/mips/BC2.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "BC2", "ralink,rt3052-soc";
+ compatible = "nexaira,bc2", "ralink,rt3052-soc";
model = "NexAira BC2";
cfi@1f000000 {
@@ -43,7 +46,7 @@
usb {
label = "bc2:blue:usb";
- gpios = <&gpio0 20 1>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
};
@@ -55,8 +58,8 @@
reset {
label = "reset";
- gpios = <&gpio0 17 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/BOCCO.dts
===================================================================
--- sys/gnu/dts/mips/BOCCO.dts
+++ sys/gnu/dts/mips/BOCCO.dts
@@ -2,29 +2,12 @@
#include "mt7620a.dtsi"
-/ {
- compatible = "ralink,mt7620a-soc";
- model = "Planex CS-QR10";
-
- sound {
- compatible = "mediatek,mt7620-audio-wm8960";
- model = "mt7620-wm8960";
- i2s-controller = <&i2s>;
- audio-routing =
- "Ext Spk", "SPK_LP",
- "Ext Spk", "SPK_LN",
- "Ext Spk", "SPK_RP",
- "Ext Spk", "SPK_RN";
- };
-
- gpio-leds {
- compatible = "gpio-leds";
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
- power {
- label = "cs-qr10:red:power";
- gpios = <&gpio1 4 1>;
- };
- };
+/ {
+ compatible = "planex,cs-qr10", "ralink,mt7620a-soc";
+ model = "YUKAI Engineering BOCCO";
gpio-keys-polled {
compatible = "gpio-keys-polled";
@@ -32,16 +15,46 @@
#size-cells = <0>;
poll-interval = <20>;
- s1 {
+ reset {
label = "reset";
- gpios = <&gpio1 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+ s1 {
+ gpio-export,name = "rec";
+ gpios = <&gpio1 8 GPIO_ACTIVE_HIGH>;
+ };
s2 {
- label = "wps";
- gpios = <&gpio1 3 1>;
- linux,code = <0x211>;
+ gpio-export,name = "play";
+ gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+ sound {
+ compatible = "simple-audio-card";
+ simple-audio-card,name = "Audio-I2S";
+ simple-audio-card,format = "i2s";
+ simple-audio-card,bitclock-master = <&dailink0_master>;
+ simple-audio-card,frame-master = <&dailink0_master>;
+ simple-audio-card,widgets =
+ "Headphone", "Headphones";
+ simple-audio-card,routing =
+ "Headphones", "HP_L",
+ "Headphones", "HP_R";
+ simple-audio-card,mclk-fs = <256>;
+
+ simple-audio-card,cpu {
+ sound-dai = <&i2s>;
+ };
+
+ dailink0_master: simple-audio-card,codec {
+ sound-dai = <&codec>;
};
};
};
@@ -64,9 +77,18 @@
&i2c {
status = "okay";
+
+ codec: wm8960@1a {
+ #sound-dai-cells = <0>;
+ compatible = "wlf,wm8960";
+ reg = <0x1a>;
+
+ wlf,shared-lrclk;
+ };
};
&i2s {
+ #sound-dai-cells = <0>;
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&pcm_i2s_pins>;
@@ -80,7 +102,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -122,10 +143,6 @@
ralink,group = "spi refclk", "rgmii1";
ralink,function = "gpio";
};
- wdt {
- ralink,group = "wdt";
- ralink,function = "wdt refclk";
- };
};
};
@@ -140,22 +157,6 @@
ralink,port4 = "ephy";
};
-&sdhci {
- status = "okay";
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
-
-&pcie {
- status = "okay";
-};
Index: sys/gnu/dts/mips/BR-6425.dts
===================================================================
--- sys/gnu/dts/mips/BR-6425.dts
+++ /dev/null
@@ -1,71 +0,0 @@
-/dts-v1/;
-
-#include "rt3050.dtsi"
-
-/ {
- compatible = "BR-6425", "ralink,rt3052-soc";
- model = "Edimax BR-6425";
-
- cfi@1f000000 {
- compatible = "cfi-flash";
- reg = <0x1f000000 0x800000>;
- bank-width = <2>;
- device-width = <2>;
- #address-cells = <1>;
- #size-cells = <1>;
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- power {
- label = "br-6425:green:power";
- gpios = <&gpio0 9 1>;
- };
-
- wlan {
- label = "br-6425:orange:wlan";
- gpios = <&gpio0 14 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset_wps {
- label = "reset_wps";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
- };
-
- rfkill {
- label = "RFKILL switch";
- gpios = <&gpio0 13 1>;
- linux,code = <0xf7>;
- };
- };
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
-/* mtd-mac-address = <&factory 0x4>; */
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
-};
-
-&wmac {
-/* ralink,mtd-eeprom = <&factory 0>; */
-};
Index: sys/gnu/dts/mips/BR-6475ND.dts
===================================================================
--- sys/gnu/dts/mips/BR-6475ND.dts
+++ sys/gnu/dts/mips/BR-6475ND.dts
@@ -2,8 +2,11 @@
#include "rt3883.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "BR-6475ND", "ralink,rt3883-soc";
+ compatible = "edimax,br-6475nd", "ralink,rt3883-soc";
model = "Edimax BR-6475nD";
gpio-keys-polled {
@@ -14,15 +17,15 @@
reset {
label = "reset";
- gpios = <&gpio0 7 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
rfkill {
label = "rfkill";
- gpios = <&gpio0 9 1>;
- linux,input-type = <5>;
- linux,code = <0xf7>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,input-type = <EV_SW>;
+ linux,code = <KEY_RFKILL>;
};
};
@@ -31,17 +34,17 @@
power {
label = "br-6475nd:green:power";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
wlan {
label = "br-6475nd:amber:wlan";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
wlan_5ghz {
label = "br-6475nd:amber:wlan_5ghz";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -80,17 +83,12 @@
reg = <0x00070000 0x00790000>;
label = "firmware";
};
-
- partition@170000 {
- reg = <0x00270000 0x00590000>;
- label = "rootfs";
- };
};
rtl8367 {
compatible = "realtek,rtl8367";
- gpio-sda = <&gpio0 5 0>;
- gpio-sck = <&gpio0 4 0>;
+ gpio-sda = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 4 GPIO_ACTIVE_HIGH>;
realtek,extif0 = <1 0 1 1 1 1 1 1 2>;
};
@@ -105,7 +103,7 @@
usb {
gpio-export,name="usb";
gpio-export,output=<0>;
- gpios = <&gpio0 19 0>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
};
*/
@@ -162,11 +160,11 @@
pci-bridge@1 {
status = "okay";
- wmac@0,0 {
+ wifi@0,0 {
+ compatible = "pci0,0";
+ reg = <0x10000 0 0 0 0>;
ralink,5ghz = <0>;
- compatible = "ralink,rt2880-pci", "pciclass060400", "pciclass0604";
- reg = < 0x10000 0 0 0 0 >;
- ralink,eeprom = "rt2x00pci_1_0.eeprom";
+ ralink,mtd-eeprom = <&factory 0x8000>;
};
};
};
Index: sys/gnu/dts/mips/BROADWAY.dts
===================================================================
--- sys/gnu/dts/mips/BROADWAY.dts
+++ sys/gnu/dts/mips/BROADWAY.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "BROADWAY", "ralink,rt3052-soc";
+ compatible = "hauppauge,broadway", "ralink,rt3052-soc";
model = "Hauppauge Broadway";
cfi@1f000000 {
@@ -43,12 +46,12 @@
diskmounted {
label = "broadway:red:diskmounted";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps_active {
label = "broadway:red:wps_active";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -60,8 +63,8 @@
factory {
label = "Factory Reset button";
- gpios = <&gpio0 13 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/C108.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/C108.dts
@@ -0,0 +1,177 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "hnet,c108", "ralink,mt7620a-soc";
+ model = "HNET C108";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ power_modem {
+ gpio-export,name = "power_modem";
+ gpio-export,output = <1>;
+ gpios = <&gpio2 2 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ sdcard {
+ label = "c108:green:sdcard";
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
+ };
+
+ modem_green {
+ label = "c108:green:modem";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ };
+
+ modem_red {
+ label = "c108:red:modem";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
+ };
+
+ lan_red {
+ label = "c108:red:lan";
+ gpios = <&gpio2 3 GPIO_ACTIVE_HIGH>;
+ };
+
+ lan_green {
+ label = "c108:green:lan";
+ gpios = <&gpio2 4 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ en25q128@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
+
+&sdhci {
+ status = "okay";
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "i2c", "uartf", "spi refclk", "ephy";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/CARAMBOLA.dts
===================================================================
--- sys/gnu/dts/mips/CARAMBOLA.dts
+++ sys/gnu/dts/mips/CARAMBOLA.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "CARAMBOLA", "ralink,rt3050-soc";
+ compatible = "8devices,carambola", "ralink,rt3050-soc";
model = "8devices Carambola";
chosen {
@@ -44,7 +47,7 @@
i2c-gpio {
compatible = "i2c-gpio";
- gpios = <&gpio0 1 0 &gpio0 2 0>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH &gpio0 2 GPIO_ACTIVE_HIGH>;
i2c-gpio,delay-us = <10>;
};
};
Index: sys/gnu/dts/mips/CF-WR800N.dts
===================================================================
--- sys/gnu/dts/mips/CF-WR800N.dts
+++ sys/gnu/dts/mips/CF-WR800N.dts
@@ -2,8 +2,11 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "cf-wr800n", "ralink,mt7620n-soc";
+ compatible = "comfast,cf-wr800n", "ralink,mt7620n-soc";
model = "Comfast CF-WR800N";
chosen {
@@ -15,17 +18,17 @@
ethernet {
label = "cf-wr800n:white:ethernet";
- gpios = <&gpio2 4 1>;
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
};
wifi {
label = "cf-wr800n:white:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wps {
label = "cf-wr800n:white:wps";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
};
@@ -37,8 +40,8 @@
reset {
label = "reset";
- gpios = <&gpio0 2 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -67,7 +70,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q64";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/CS-QR10.dts
===================================================================
--- sys/gnu/dts/mips/CS-QR10.dts
+++ sys/gnu/dts/mips/CS-QR10.dts
@@ -2,27 +2,19 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "planex,cs-qr10", "ralink,mt7620a-soc";
model = "Planex CS-QR10";
- sound {
- compatible = "mediatek,mt7620-audio-wm8960";
- model = "mt7620-wm8960";
- i2s-controller = <&i2s>;
- audio-routing =
- "Ext Spk", "SPK_LP",
- "Ext Spk", "SPK_LN",
- "Ext Spk", "SPK_RP",
- "Ext Spk", "SPK_RN";
- };
-
gpio-leds {
compatible = "gpio-leds";
power {
label = "cs-qr10:red:power";
- gpios = <&gpio1 4 1>;
+ gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
};
};
@@ -34,14 +26,14 @@
s1 {
label = "reset";
- gpios = <&gpio1 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
s2 {
label = "wps";
- gpios = <&gpio1 3 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 3 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -80,7 +72,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/CY-SWR1100.dts
===================================================================
--- sys/gnu/dts/mips/CY-SWR1100.dts
+++ sys/gnu/dts/mips/CY-SWR1100.dts
@@ -2,8 +2,11 @@
#include "rt3883.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "CY-SWR1100", "ralink,rt3883-soc";
+ compatible = "samsung,cy-swr1100", "ralink,rt3883-soc";
model = "Samsung CY-SWR1100";
nor-flash@1c000000 {
@@ -50,8 +53,8 @@
rtl8367 {
compatible = "realtek,rtl8367";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
realtek,extif0 = <1 0 1 1 1 1 1 1 2>;
};
@@ -63,14 +66,14 @@
reset {
label = "reset";
- gpios = <&gpio0 6 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 3 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -79,12 +82,12 @@
wps {
label = "cy-swr1100:blue:wps";
- gpios = <&gpio0 0 1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
};
usb {
label = "cy-swr1100:blue:usb";
- gpios = <&gpio1 1 1>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
};
};
};
@@ -125,11 +128,11 @@
pci-bridge@1 {
status = "okay";
- wmac@0,0 {
+ wifi@0,0 {
+ compatible = "pci0,0";
+ reg = <0x10000 0 0 0 0>;
ralink,5ghz = <0>;
- compatible = "ralink,rt2880-pci", "pciclass060400", "pciclass0604";
- reg = < 0x10000 0 0 0 0 >;
- ralink,eeprom = "rt2x00pci_1_0.eeprom";
+ ralink,mtd-eeprom = <&factory 0x2000>;
};
};
};
Index: sys/gnu/dts/mips/D105.dts
===================================================================
--- sys/gnu/dts/mips/D105.dts
+++ sys/gnu/dts/mips/D105.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "D105", "ralink,rt3050-soc";
+ compatible = "huawei,d105", "ralink,rt3050-soc";
model = "Huawei D105";
cfi@1f000000 {
@@ -43,12 +46,12 @@
power {
label = "d105:red:power";
- gpios = <&gpio0 0 1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
};
wps {
label = "d105:green:usb";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -60,8 +63,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/D240.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/D240.dts
@@ -0,0 +1,179 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "sanlinking,d240", "ralink,mt7620a-soc";
+ model = "Sanlinking Technologies D240";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ power_mpcie2 {
+ gpio-export,name = "power_mpcie2";
+ gpio-export,output = <1>;
+ gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
+ };
+
+ power_mpcie1 {
+ gpio-export,name = "power_mpcie1";
+ gpio-export,output = <1>;
+ gpios = <&gpio2 6 GPIO_ACTIVE_HIGH>;
+ };
+
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "d240:blue:power";
+ gpios = <&gpio1 14 GPIO_ACTIVE_HIGH>;
+ };
+
+ usb {
+ label = "d240:blue:usb";
+ gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
+ };
+
+ air {
+ label = "d240:blue:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ en25q128@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
+
+&sdhci {
+ status = "okay";
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x4>;
+ mediatek,portmap = "wllll";
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "i2c", "uartf", "wled", "spi refclk", "pa", "nd_sd";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/DAP-1350.dts
===================================================================
--- sys/gnu/dts/mips/DAP-1350.dts
+++ sys/gnu/dts/mips/DAP-1350.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DAP-1350", "ralink,rt3052-soc";
+ compatible = "dlink,dap-1350", "ralink,rt3052-soc";
model = "D-Link DAP-1350";
chosen {
@@ -53,17 +56,17 @@
power {
label = "dap-1350:blue:power";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
power2 {
label = "dap-1350:red:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps {
label = "dap-1350:blue:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -75,26 +78,26 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
rt {
label = "rt";
- gpios = <&gpio0 11 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
ap {
label = "ap";
- gpios = <&gpio0 7 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
Index: sys/gnu/dts/mips/DAP-1522-A1.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/DAP-1522-A1.dts
@@ -0,0 +1,139 @@
+/dts-v1/;
+
+#include "rt2880.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "dlink,dap-1522-a1", "ralink,rt2880-soc";
+ model = "D-Link DAP-1522 A1";
+
+ cfi@bc400000 {
+ compatible = "cfi-flash";
+ reg = <0xbc400000 0x800000>;
+ bank-width = <2>;
+ device-width = <2>;
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ partition@0 {
+ label = "uboot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ factory: partition@30000 {
+ label = "factory";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ partition@40000 {
+ label = "firmware";
+ reg = <0x40000 0x3a0000>;
+ };
+ };
+
+ rtl8366s {
+ compatible = "realtek,rtl8366s";
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <100>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio2 16 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ ap {
+ label = "ap";
+ gpios = <&gpio2 13 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
+ };
+
+ bridge {
+ label = "bridge";
+ gpios = <&gpio2 14 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
+ linux,input-type = <EV_SW>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ wps {
+ label = "dap-1522-a1:blue:wps";
+ gpios = <&gpio2 17 GPIO_ACTIVE_LOW>;
+ };
+
+ ap {
+ label = "dap-1522-a1:blue:ap";
+ gpios = <&gpio2 18 GPIO_ACTIVE_LOW>;
+ };
+
+ sta {
+ label = "dap-1522-a1:red:sta";
+ gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
+ };
+
+ status {
+ label = "dap-1522-a1:blue:status";
+ gpios = <&gpio2 20 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&gpio0 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartlite", "pci";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ status = "okay";
+ mtd-mac-address = <&factory 0x2004>;
+
+ port@0 {
+ mediatek,fixed-link = <1000 1 1 1>;
+ };
+
+ mdio-bus {
+ status = "okay";
+
+ phy0: ethernet-phy@0 {
+ phy-mode = "mii";
+ reg = <0>;
+ };
+ };
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0x2000>;
+};
Index: sys/gnu/dts/mips/DB-WRT01.dts
===================================================================
--- sys/gnu/dts/mips/DB-WRT01.dts
+++ sys/gnu/dts/mips/DB-WRT01.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "planex,db-wrt01", "ralink,mt7620a-soc";
model = "Planex DB-WRT01";
gpio-leds {
@@ -11,7 +14,7 @@
power {
label = "db-wrt01:orange:power";
- gpios = <&gpio1 1 1>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
};
};
@@ -23,8 +26,8 @@
s1 {
label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -41,7 +44,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/DCH-M225.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/DCH-M225.dts
@@ -0,0 +1,180 @@
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "dlink,dch-m225", "ralink,mt7620a-soc";
+ model = "D-Link DCH-M225";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <100>;
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "dch-m225:green:power";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ };
+
+ status {
+ label = "dch-m225:red:status";
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ sound {
+ compatible = "simple-audio-card";
+ simple-audio-card,name = "Audio-I2S";
+ simple-audio-card,format = "i2s";
+ simple-audio-card,bitclock-master = <&dailink0_master>;
+ simple-audio-card,frame-master = <&dailink0_master>;
+ simple-audio-card,widgets =
+ "Headphone", "Headphones";
+ simple-audio-card,routing =
+ "Headphones", "HP_L",
+ "Headphones", "HP_R";
+ simple-audio-card,mclk-fs = <256>;
+ simple-audio-card,hp-det-gpio = <&gpio0 14 GPIO_ACTIVE_LOW>;
+
+ simple-audio-card,cpu {
+ sound-dai = <&i2s>;
+ };
+
+ dailink0_master: simple-audio-card,codec {
+ sound-dai = <&codec>;
+ };
+ };
+};
+
+&gpio0 {
+ status = "okay";
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&i2c {
+ status = "okay";
+
+ codec: wm8960@1a {
+ #sound-dai-cells = <0>;
+ compatible = "wlf,wm8960";
+ reg = <0x1a>;
+
+ wlf,shared-lrclk;
+ };
+};
+
+&i2s {
+ #sound-dai-cells = <0>;
+ status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&mdio_refclk_pins>;
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <80000000>;
+ m25p,fast-read;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x4000>;
+ read-only;
+ };
+
+ factory: partition@34000 {
+ label = "factory";
+ reg = <0x34000 0x4000>;
+ read-only;
+ };
+
+ nvram: partition@38000 {
+ label = "nvram";
+ reg = <0x38000 0x8000>;
+ read-only;
+ };
+
+ partition@40000 {
+ label = "devconf";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "upgrade_rec";
+ reg = <0x50000 0x100000>;
+ read-only;
+ };
+
+ partition@150000 {
+ label = "firmware";
+ reg = <0x150000 0x6b0000>;
+ };
+ };
+};
+
+&gdma {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "wdt", "rgmii1";
+ ralink,function = "gpio";
+ };
+
+ gpio_i2s {
+ ralink,group = "uartf";
+ ralink,function = "gpio i2s";
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x4>;
+};
+
+&gsw {
+ ralink,port4 = "ephy";
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
+};
Index: sys/gnu/dts/mips/DCS-930.dts
===================================================================
--- sys/gnu/dts/mips/DCS-930.dts
+++ sys/gnu/dts/mips/DCS-930.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DCS-930", "ralink,rt3050-soc";
+ compatible = "dlink,dcs-930", "ralink,rt3050-soc";
model = "D-Link DCS-930";
cfi@1f000000 {
@@ -53,17 +56,17 @@
wifi {
label = "dcs-930:red:alert";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
power {
label = "dcs-930:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps {
label = "dcs-930:blue:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -75,14 +78,14 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/DCS-930L-B1.dts
===================================================================
--- sys/gnu/dts/mips/DCS-930L-B1.dts
+++ sys/gnu/dts/mips/DCS-930L-B1.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DCS-930L-B1", "ralink,rt5350-soc";
+ compatible = "dlink,dcs-930l-b1", "ralink,rt5350-soc";
model = "D-Link DCS-930L B1";
gpio-leds {
@@ -11,12 +14,12 @@
power {
label = "dcs-930l-b1:red:power";
- gpios = <&gpio0 17 1>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
};
wps {
label = "dcs-930l-b1:blue:wps";
- gpios = <&gpio0 19 1>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
};
@@ -28,14 +31,14 @@
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 20 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -48,7 +51,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/DIR-300-B1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-300-B1.dts
+++ sys/gnu/dts/mips/DIR-300-B1.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-300-B1", "ralink,rt3050-soc";
+ compatible = "dlink,dir-300-b1", "ralink,rt3050-soc";
model = "D-Link DIR-300 B1";
cfi@1f000000 {
@@ -46,14 +49,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -62,27 +65,27 @@
status {
label = "dir-300-b1:amber:status";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
status2 {
label = "dir-300-b1:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wan {
label = "dir-300-b1:amber:wan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wan2 {
label = "dir-300-b1:green:wan";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-300-b1:blue:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/DIR-300-B7.dts
===================================================================
--- sys/gnu/dts/mips/DIR-300-B7.dts
+++ sys/gnu/dts/mips/DIR-300-B7.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-300-B7", "ralink,rt5350-soc";
+ compatible = "dlink,dir-300-b7", "ralink,rt5350-soc";
model = "D-Link DIR-300 B7";
gpio-leds {
@@ -11,12 +14,12 @@
status {
label = "dir-300-b7:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-300-b7:blue:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -28,14 +31,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -48,7 +51,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/DIR-320-B1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-320-B1.dts
+++ sys/gnu/dts/mips/DIR-320-B1.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-320-B1", "ralink,rt5350-soc";
+ compatible = "dlink,dir-320-b1", "ralink,rt5350-soc";
model = "D-Link DIR-320 B1";
gpio-leds {
@@ -11,17 +14,17 @@
status {
label = "dir-320-b1:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
usb {
label = "dir-320-b1:green:usb";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-320-b1:green:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -33,14 +36,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -51,13 +54,13 @@
usb {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio0 7 0>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
root_hub {
gpio-export,name = "root_hub";
gpio-export,output = <1>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -70,7 +73,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/DIR-600-B1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-600-B1.dts
+++ sys/gnu/dts/mips/DIR-600-B1.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-600-B1", "ralink,rt3050-soc";
+ compatible = "dlink,dir-600-b1", "ralink,rt3050-soc";
model = "D-Link DIR-600 B1";
cfi@1f000000 {
@@ -46,14 +49,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -62,27 +65,27 @@
status {
label = "dir-600-b1:amber:status";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
status2 {
label = "dir-600-b1:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wan {
label = "dir-600-b1:amber:wan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wan2 {
label = "dir-600-b1:green:wan";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-600-b1:blue:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/DIR-600-B2.dts
===================================================================
--- sys/gnu/dts/mips/DIR-600-B2.dts
+++ /dev/null
@@ -1,105 +0,0 @@
-/dts-v1/;
-
-#include "rt3050.dtsi"
-
-/ {
- compatible = "DIR-600-B2", "ralink,rt3050-soc";
- model = "D-Link DIR-600 B2";
-
- cfi@1f000000 {
- compatible = "cfi-flash";
- reg = <0x1f000000 0x800000>;
- bank-width = <2>;
- device-width = <2>;
- #address-cells = <1>;
- #size-cells = <1>;
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- devdata: partition@30000 {
- label = "devdata";
- reg = <0x30000 0x10000>;
- read-only;
- };
-
- partition@40000 {
- label = "devconf";
- reg = <0x40000 0x10000>;
- read-only;
- };
-
- partition@50000 {
- label = "firmware";
- reg = <0x50000 0x3b0000>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
-
- wps {
- label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- status {
- label = "dir-600-b2:amber:status";
- gpios = <&gpio0 8 1>;
- };
-
- status2 {
- label = "dir-600-b2:green:status";
- gpios = <&gpio0 9 1>;
- };
-
- wan {
- label = "dir-600-b2:amber:wan";
- gpios = <&gpio0 14 1>;
- };
-
- wan2 {
- label = "dir-600-b2:green:wan";
- gpios = <&gpio0 12 1>;
- };
-
- wps {
- label = "dir-600-b2:blue:wps";
- gpios = <&gpio0 13 1>;
- };
- };
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "spi", "jtag", "mdio", "rgmii", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&devdata 0x4000>;
-};
Index: sys/gnu/dts/mips/DIR-610-A1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-610-A1.dts
+++ sys/gnu/dts/mips/DIR-610-A1.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-610-A1", "ralink,rt5350-soc";
+ compatible = "dlink,dir-610-a1", "ralink,rt5350-soc";
model = "D-Link DIR-610 A1";
gpio-leds {
@@ -11,12 +14,12 @@
status {
label = "dir-610-a1:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-610-a1:green:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -28,14 +31,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -48,7 +51,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/DIR-615-D.dts
===================================================================
--- sys/gnu/dts/mips/DIR-615-D.dts
+++ sys/gnu/dts/mips/DIR-615-D.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-615-D", "ralink,rt3050-soc";
+ compatible = "dlink,dir-615-d1", "ralink,rt3050-soc";
model = "D-Link DIR-615 D";
cfi@1f000000 {
@@ -46,14 +49,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -62,27 +65,27 @@
status {
label = "dir-615-d:amber:status";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
status2 {
label = "dir-615-d:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wan {
label = "dir-615-d:amber:wan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wan2 {
label = "dir-615-d:green:wan";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-615-d:blue:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/DIR-615-H1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-615-H1.dts
+++ sys/gnu/dts/mips/DIR-615-H1.dts
@@ -2,8 +2,11 @@
#include "rt3352.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-615-H1", "ralink,rt3352-soc";
+ compatible = "dlink,dir-615-h1", "ralink,rt3352-soc";
model = "D-Link DIR-615 H1";
gpio-leds {
@@ -11,27 +14,27 @@
status {
label = "dir-615-h1:amber:status";
- gpios = <&gpio0 7 0>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
status2 {
label = "dir-615-h1:green:status";
- gpios = <&gpio0 9 0>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
};
wan {
label = "dir-615-h1:amber:wan";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wan2 {
label = "dir-615-h1:green:wan";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-615-h1:blue:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -43,14 +46,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -63,7 +66,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -97,21 +99,13 @@
ralink,group = "i2c", "jtag", "uartf";
ralink,function = "gpio";
};
-
- rgmii {
- ralink,group = "rgmii";
- ralink,function = "rgmii";
- };
-
- mdio {
- ralink,group = "mdio";
- ralink,function = "mdio";
- };
};
};
&ethernet {
mtd-mac-address = <&factory 0x28>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&rgmii_pins &mdio_pins>;
};
&esw {
Index: sys/gnu/dts/mips/DIR-620-A1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-620-A1.dts
+++ sys/gnu/dts/mips/DIR-620-A1.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-620-A1", "ralink,rt3050-soc";
+ compatible = "dlink,dir-620-a1", "ralink,rt3050-soc";
model = "D-Link DIR-620 A1";
cfi@1f000000 {
@@ -46,14 +49,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -62,32 +65,32 @@
status {
label = "dir-620-a1:amber:status";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
status2 {
label = "dir-620-a1:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wan {
label = "dir-620-a1:amber:wan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wan2 {
label = "dir-620-a1:green:wan";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-620-a1:blue:wps";
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
wps2 {
label = "dir-620-a1:amber:wps";
- gpios = <&gpio0 11 0>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
};
};
};
Index: sys/gnu/dts/mips/DIR-620-D1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-620-D1.dts
+++ sys/gnu/dts/mips/DIR-620-D1.dts
@@ -2,8 +2,11 @@
#include "rt3352.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-620-D1", "ralink,rt3352-soc";
+ compatible = "dlink,dir-620-d1", "ralink,rt3352-soc";
model = "D-Link DIR-620 D1";
gpio-leds {
@@ -11,12 +14,12 @@
status {
label = "dir-620-d1:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wifi {
label = "dir-620-d1:green:wifi";
- gpios = <&gpio0 17 1>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
reset_wps {
label = "reset_wps";
- gpios = <&gpio0 7 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -42,7 +45,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -76,21 +78,13 @@
ralink,group = "i2c", "jtag", "uartf";
ralink,function = "gpio";
};
-
- rgmii {
- ralink,group = "rgmii";
- ralink,function = "rgmii";
- };
-
- mdio {
- ralink,group = "mdio";
- ralink,function = "mdio";
- };
};
};
&ethernet {
mtd-mac-address = <&factory 0x4>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&rgmii_pins &mdio_pins>;
};
&esw {
Index: sys/gnu/dts/mips/DIR-645.dts
===================================================================
--- sys/gnu/dts/mips/DIR-645.dts
+++ sys/gnu/dts/mips/DIR-645.dts
@@ -2,14 +2,17 @@
#include "rt3883.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "DIR-645", "ralink,rt3883-soc";
+ compatible = "dlink,dir-645", "ralink,rt3883-soc";
model = "D-Link DIR-645";
rtl8367b {
compatible = "realtek,rtl8367b";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
realtek,extif1 = <1 0 1 1 1 1 1 1 2>;
};
@@ -21,14 +24,14 @@
reset {
label = "reset";
- gpios = <&gpio0 9 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 14 0>;
- linux,code = <0x211>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -37,12 +40,12 @@
inet {
label = "dir-645:green:inet";
- gpios = <&gpio0 0 1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
};
wps {
label = "dir-645:green:wps";
- gpios = <&gpio1 2 0>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
};
};
@@ -53,7 +56,7 @@
usb {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio1 6 0>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -70,7 +73,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <25000000>;
partition@0 {
Index: sys/gnu/dts/mips/DIR-810L.dts
===================================================================
--- sys/gnu/dts/mips/DIR-810L.dts
+++ sys/gnu/dts/mips/DIR-810L.dts
@@ -2,6 +2,9 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "dlink,dir-810l", "ralink,mt7620a-soc";
model = "D-Link DIR-810L";
@@ -14,14 +17,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
wps {
label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
@@ -30,17 +33,17 @@
power {
label = "dir-810l:green:power";
- gpios = <&gpio0 9 0>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
};
wan {
label = "dir-810l:orange:wan";
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
status {
label = "dir-810l:orange:power";
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -53,7 +56,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/DIR-860L-B1.dts
===================================================================
--- sys/gnu/dts/mips/DIR-860L-B1.dts
+++ sys/gnu/dts/mips/DIR-860L-B1.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7621-eval-board", "ralink,mt7621-soc";
+ compatible = "dlink,dir-860l-b1", "mediatek,mt7621-soc";
model = "D-Link DIR-860L B1";
memory@0 {
@@ -20,22 +23,22 @@
power {
label = "dir-860l-b1:orange:power";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
power2 {
label = "dir-860l-b1:green:power";
- gpios = <&gpio0 15 1>;
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
};
net {
label = "dir-860l-b1:orange:net";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
net2 {
label = "dir-860l-b1:green:net";
- gpios = <&gpio0 16 1>;
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
};
};
@@ -44,6 +47,18 @@
#address-cells = <1>;
#size-cells = <0>;
poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
};
};
@@ -55,8 +70,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -103,7 +118,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&radio 0x2000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -112,7 +127,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&radio 0>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
Index: sys/gnu/dts/mips/DUZUN-DM06.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/DUZUN-DM06.dts
@@ -0,0 +1,143 @@
+/dts-v1/;
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "duzun,dm06", "mediatek,mt7628an-soc";
+ model = "DuZun DM06";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <100>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+
+ sound {
+ compatible = "simple-audio-card";
+ simple-audio-card,name = "Audio-I2S";
+ simple-audio-card,format = "i2s";
+ simple-audio-card,bitclock-master = <&dailink0_master>;
+ simple-audio-card,frame-master = <&dailink0_master>;
+ simple-audio-card,widgets =
+ "Headphone", "Headphones";
+ simple-audio-card,routing =
+ "Headphones", "HP_L",
+ "Headphones", "HP_R";
+ simple-audio-card,mclk-fs = <256>;
+
+ simple-audio-card,cpu {
+ sound-dai = <&i2s>;
+ };
+
+ dailink0_master: simple-audio-card,codec {
+ sound-dai = <&codec>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "wdt", "uart1";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&i2c {
+ status = "okay";
+
+ codec: wm8960@1a {
+ #sound-dai-cells = <0>;
+ compatible = "wlf,wm8960";
+ reg = <0x1a>;
+
+ wlf,shared-lrclk;
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x4>;
+};
+
+&esw {
+ mediatek,portmap = <0x3>;
+ mediatek,portdisable = <0x3c>;
+};
+
+&i2s {
+ #sound-dai-cells = <0>;
+ status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2s_pins>, <&refclk_pins>;
+};
+
+&sdhci {
+ status = "okay";
+};
+
+&gdma {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <60000000>;
+ m25p,chunked-io = <32>;
+ m25p,fast-read;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x7b0000>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/DWR-116-A1.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/DWR-116-A1.dts
@@ -0,0 +1,104 @@
+/dts-v1/;
+
+#include "mt7620n.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "dlink,dwr-116-a1", "ralink,mt7620n-soc";
+ model = "D-Link DWR-116 A1/A2";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status {
+ label = "dwr-116-a1:green:status";
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
+ };
+
+ wifi {
+ label = "dwr-116-a1:green:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <50000000>;
+
+ partition@0 {
+ label = "jboot";
+ reg = <0x0 0x10000>;
+ read-only;
+ };
+
+ partition@10000 {
+ label = "firmware";
+ reg = <0x10000 0x7e0000>;
+ };
+
+ config: partition@7f0000 {
+ label = "config";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "i2c", "wled";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ mediatek,portmap = "llllw";
+ pinctrl-names = "default";
+ pinctrl-0 = <&ephy_pins>;
+};
Index: sys/gnu/dts/mips/DWR-512-B.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/DWR-512-B.dts
@@ -0,0 +1,139 @@
+/dts-v1/;
+
+#include "rt5350.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "dlink,dwr-512-b", "ralink,rt5350-soc";
+ model = "D-Link DWR-512 B";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ sms {
+ label = "dwr-512-b:green:sms";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ };
+ status {
+ label = "dwr-512-b:green:status";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ };
+ 2g {
+ label = "dwr-512-b:green:2g";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ };
+ 3g {
+ label = "dwr-512-b:green:3g";
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
+ };
+ sstrengthr {
+ label = "dwr-512-b:red:sigstrength";
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
+ };
+ sstrengthg {
+ label = "dwr-512-b:green:sigstrength";
+ gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ slic_int {
+ gpio-export,name = "slic_int";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ };
+ modem3g_enable {
+ gpio-export,name = "modem3g_enable";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ mx25l6405d@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <30000000>;
+ m25p,fast-read;
+
+ partition@0 {
+ label = "jboot";
+ reg = <0x0 0x10000>;
+ read-only;
+ };
+
+ partition@10000 {
+ label = "firmware";
+ reg = <0x10000 0x7e0000>;
+ };
+
+ config: partition@7f0000 {
+ label = "config";
+ reg = <0x7f0000 0x10000>;
+ };
+ };
+};
+
+&spi1 {
+ status = "okay";
+
+ spidev@1 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "siliconlabs,si3210";
+
+ reg = <0>;
+ spi-max-frequency = <1000000>;
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "jtag", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&esw {
+ mediatek,portmap = <0x2f>;
+};
+
+&ethernet {
+ mtd-mac-address = <&config 0xe07e>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&config 0xe08a>;
+ ralink,led-polarity = <1>;
+ mtd-mac-address = <&config 0xe07e>;
+};
Index: sys/gnu/dts/mips/DWR-921-C1.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/DWR-921-C1.dts
@@ -0,0 +1,144 @@
+/dts-v1/;
+
+#include "mt7620n.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "dlink,dwr-921-c1", "ralink,mt7620n-soc";
+ model = "D-Link DWR-921 C1";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ sms {
+ label = "dwr-921-c1:green:sms";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ };
+
+ lan {
+ label = "dwr-921-c1:green:lan";
+ gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
+ };
+
+ sstrengthg {
+ label = "dwr-921-c1:green:sigstrength";
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
+ };
+
+ sstrengthr {
+ label = "dwr-921-c1:red:sigstrength";
+ gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
+ };
+
+ 4g {
+ label = "dwr-921-c1:green:4g";
+ gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
+ };
+
+ 3g {
+ label = "dwr-921-c1:green:3g";
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
+ };
+
+ wifi {
+ label = "dwr-921-c1:green:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ lte_modem_enable {
+ gpio-export,name = "lte_modem_enable";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "jboot";
+ reg = <0x0 0x10000>;
+ read-only;
+ };
+
+ partition@10000 {
+ label = "firmware";
+ reg = <0x10000 0xfe0000>;
+ };
+
+ config: partition@ff0000 {
+ label = "config";
+ reg = <0xff0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&ethernet {
+ port@4 {
+ status = "okay";
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "spi refclk", "i2c", "ephy", "wled";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/E1700.dts
===================================================================
--- sys/gnu/dts/mips/E1700.dts
+++ sys/gnu/dts/mips/E1700.dts
@@ -12,6 +12,9 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "linksys,e1700", "ralink,mt7620a-soc";
model = "Linksys E1700";
@@ -24,14 +27,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 2 0>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -40,12 +43,12 @@
power {
label = "e1700:green:power";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
wan {
label = "e1700:green:wps";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
};
};
@@ -58,7 +61,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/ESR-9753.dts
===================================================================
--- sys/gnu/dts/mips/ESR-9753.dts
+++ sys/gnu/dts/mips/ESR-9753.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ESR-9753", "ralink,rt3052-soc";
+ compatible = "engenius,esr-9753", "ralink,rt3052-soc";
model = "Senao / EnGenius ESR-9753";
cfi@1f000000 {
@@ -43,12 +46,12 @@
power {
label = "esr-9753:orange:power";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
wps {
label = "esr-9753:orange:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -60,14 +63,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/EW1200.dts
===================================================================
--- sys/gnu/dts/mips/EW1200.dts
+++ sys/gnu/dts/mips/EW1200.dts
@@ -2,27 +2,24 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "ZBT-WG3526";
+ compatible = "afoundry,ew1200", "mediatek,mt7621-soc";
+ model = "EW1200";
memory@0 {
device_type = "memory";
- reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
+ reg = <0x0 0x8000000>;
};
chosen {
- bootargs = "console=ttyS0,115200";
+ bootargs = "console=ttyS0,57600";
};
palmbus: palmbus@1E000000 {
i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
status = "okay";
};
};
@@ -35,8 +32,8 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -44,8 +41,13 @@
compatible = "gpio-leds";
status {
- label = "zbt-wg3526:green:status";
- gpios = <&gpio0 24 1>;
+ label = "ew1200:green:run";
+ gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+ };
+
+ usb {
+ label = "ew1200:green:usb";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
};
};
};
@@ -62,8 +64,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -97,8 +99,8 @@
mt76@0,0 {
reg = <0x0000 0 0 0 0>;
device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -106,8 +108,8 @@
mt76@1,0 {
reg = <0x0000 0 0 0 0>;
device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x0000>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
@@ -119,7 +121,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "wdt rst", "jtag", "mdio";
+ ralink,group = "wdt", "rgmii2", "jtag", "mdio";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/EX2700.dts
===================================================================
--- sys/gnu/dts/mips/EX2700.dts
+++ sys/gnu/dts/mips/EX2700.dts
@@ -12,8 +12,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "netgear,ex2700", "ralink,mt7620a-soc";
model = "Netgear EX2700";
chosen {
@@ -25,38 +28,38 @@
power_g {
label = "ex2700:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
default-state = "on";
};
power_r {
label = "ex2700:red:power";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
device_g {
label = "ex2700:green:device";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
device_r {
label = "ex2700:red:device";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
router_g {
label = "ex2700:green:router";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
router_r {
label = "ex2700:red:router";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wps {
label = "ex2700:green:wps";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
};
@@ -68,14 +71,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -96,7 +99,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -129,15 +131,13 @@
};
&wmac {
+ mtd-mac-address = <&art 0x6>;
ralink,mtd-eeprom = <&art 0x1000>;
};
&pinctrl {
state_default: pinctrl0 {
default {
- // spi refclk: pins 37, 38, 39
- // uartf: pins 8, 9, 10, 11, 12, 13, 14
- // i2c: pins 1, 2
ralink,group = "i2c", "uartf", "spi refclk";
ralink,function = "gpio";
};
Index: sys/gnu/dts/mips/EX3700.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/EX3700.dts
@@ -0,0 +1,162 @@
+/* This file is released into the public domain */
+
+/dts-v1/;
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+#include "mt7620a.dtsi"
+
+/ {
+ compatible = "netgear,ex3700", "ralink,mt7620a-soc";
+ model = "Netgear EX3700/EX3800";
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power_g {
+ label = "ex3700:green:power";
+ gpios = <&gpio2 23 GPIO_ACTIVE_LOW>;
+ default-state = "on";
+ };
+
+ power_a {
+ label = "ex3700:amber:power";
+ gpios = <&gpio2 28 GPIO_ACTIVE_LOW>;
+ default-state = "off";
+ };
+
+ router_g {
+ label = "ex3700:green:router";
+ gpios = <&gpio2 25 GPIO_ACTIVE_LOW>;
+ };
+
+ router_r {
+ label = "ex3700:red:router";
+ gpios = <&gpio2 24 GPIO_ACTIVE_LOW>;
+ };
+
+ device_g {
+ label = "ex3700:green:device";
+ gpios = <&gpio2 20 GPIO_ACTIVE_LOW>;
+ };
+
+ device_r {
+ label = "ex3700:red:device";
+ gpios = <&gpio2 21 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "ex3700:green:wps";
+ gpios = <&gpio2 27 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio2 26 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+};
+
+&gpio0 {
+ status = "okay";
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "config";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x790000>;
+ };
+
+ partition@7e0000 {
+ label = "board_data";
+ reg = <0x7e0000 0x10000>;
+ read-only;
+ };
+
+ partition@7f0000 {
+ label = "nvram";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0 >;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0x0>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "i2c", "rgmii2", "spi refclk";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/F5D8235_V1.dts
===================================================================
--- sys/gnu/dts/mips/F5D8235_V1.dts
+++ sys/gnu/dts/mips/F5D8235_V1.dts
@@ -2,15 +2,22 @@
#include "rt2880.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "F5D8235_V1", "ralink,rt2880-soc";
+ compatible = "belkin,f5d8235-v1", "ralink,rt2880-soc";
model = "Belkin F5D8235 v1";
+ pci@440000 {
+ status = "ok";
+ };
+
cfi@1f000000 {
compatible = "cfi-flash";
- reg = <0x1f000000 0x800000>;
+ reg = <0xbc400000 0x800000>;
bank-width = <2>;
device-width = <2>;
#address-cells = <1>;
@@ -35,15 +42,56 @@
};
partition@50000 {
- label = "linux";
- reg = <0x50000 0x3b0000>;
+ label = "firmware";
+ reg = <0x50000 0x7b0000>;
};
};
rtl8366s {
compatible = "realtek,rtl8366s";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+
+ realtek,initvals = <
+ 0x0242 0x02BF
+ 0x0245 0x02BF
+ 0x0248 0x02BF
+ 0x024B 0x02BF
+ 0x024E 0x02BF
+ 0x0251 0x02BF
+ 0x0254 0x0A3F
+ 0x0256 0x0A3F
+ 0x0258 0x0A3F
+ 0x025A 0x0A3F
+ 0x025C 0x0A3F
+ 0x025E 0x0A3F
+ 0x0263 0x007C
+ 0x0100 0x0004
+ 0xBE5B 0x3500
+ 0x800E 0x200F
+ 0xBE1D 0x0F00
+ 0x8001 0x5011
+ 0x800A 0xA2F4
+ 0x800B 0x17A3
+ 0xBE4B 0x17A3
+ 0xBE41 0x5011
+ 0xBE17 0x2100
+ 0x8000 0x8304
+ 0xBE40 0x8304
+ 0xBE4A 0xA2F4
+ 0x800C 0xA8D5
+ 0x8014 0x5500
+ 0x8015 0x0004
+ 0xBE4C 0xA8D5
+ 0xBE59 0x0008
+ 0xBE09 0x0E00
+ 0xBE36 0x1036
+ 0xBE37 0x1036
+ 0x800D 0x00FF
+ 0xBE4D 0x00FF
+ >;
+
+ realtek,green-ethernet-features;
};
gpio-keys-polled {
@@ -54,28 +102,83 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 9 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
gpio-leds {
compatible = "gpio-leds";
+ internet {
+ label = "f5d8235-v1:blue:internet";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ };
+
+ internet2 {
+ label = "f5d8235-v1:amber:internet";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ };
+
+ modem {
+ label = "f5d8235-v1:blue:modem";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+
+ modem2 {
+ label = "f5d8235-v1:amber:modem";
+ gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
+ };
+
+ router {
+ label = "f5d8235-v1:blue:router";
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
+ };
+
storage {
label = "f5d8235-v1:blue:storage";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
storage2 {
- label = "f5d8235-v1:orange:storage";
- gpios = <&gpio0 8 1>;
+ label = "f5d8235-v1:amber:storage";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ };
+
+ security {
+ label = "f5d8235-v1:blue:security";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ security2 {
+ label = "f5d8235-v1:amber:security";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wired {
+ label = "f5d8235-v1:blue:wired";
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
+ };
+
+ wired2 {
+ label = "f5d8235-v1:amber:wired";
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
+ };
+
+ wireless {
+ label = "f5d8235-v1:blue:wireless";
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+ };
+
+ wireless2 {
+ label = "f5d8235-v1:amber:wireless";
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
};
};
@@ -87,7 +190,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "spi", "i2c", "jtag", "mdio", "uartlite";
ralink,function = "gpio";
};
};
@@ -102,10 +205,7 @@
};
};
-/* FIXME: no u-boot partition and 0x40000@uboot is out of boundaries */
-/*&wmac {
+&wmac {
status = "okay";
- ralink,mtd-eeprom = <&u-boot 0x40000>;
+ ralink,mtd-eeprom = <&factory 0x0>;
};
-*/
-
Index: sys/gnu/dts/mips/F5D8235_V2.dts
===================================================================
--- sys/gnu/dts/mips/F5D8235_V2.dts
+++ sys/gnu/dts/mips/F5D8235_V2.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "F5D8235_V2", "ralink,rt3052-soc";
+ compatible = "belkin,f5d8235-v2", "ralink,rt3052-soc";
model = "Belkin F5D8235 v2";
cfi@1f000000 {
@@ -37,9 +40,9 @@
};
rtl8366rb {
- compatible = "rtl8366rb";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ compatible = "realtek,rtl8366rb";
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
};
gpio-leds {
@@ -47,47 +50,47 @@
internet {
label = "f5d8235-v2:blue:internet";
- gpios = <&gpio0 5 1>;
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
};
internet2 {
label = "f5d8235-v2:amber:internet";
- gpios = <&gpio0 6 1>;
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
};
modem {
label = "f5d8235-v2:blue:modem";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
modem2 {
label = "f5d8235-v2:amber:modem";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
router {
label = "f5d8235-v2:blue:router";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
storage {
label = "f5d8235-v2:blue:storage";
- gpios = <&gpio0 23 1>;
+ gpios = <&gpio0 23 GPIO_ACTIVE_LOW>;
};
storage2 {
label = "f5d8235-v2:amber:storage";
- gpios = <&gpio0 22 1>;
+ gpios = <&gpio0 22 GPIO_ACTIVE_LOW>;
};
security {
label = "f5d8235-v2:blue:security";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
security2 {
label = "f5d8235-v2:amber:security";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/F7C027.dts
===================================================================
--- sys/gnu/dts/mips/F7C027.dts
+++ sys/gnu/dts/mips/F7C027.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "F7C027", "ralink,rt5350-soc";
+ compatible = "belkin,f7c027", "ralink,rt5350-soc";
model = "Belkin F7C027";
gpio-leds {
@@ -11,22 +14,22 @@
status {
label = "f7c027:blue:status";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
power {
label = "f7c027:blue:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
orange {
label = "f7c027:orange:status";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
relay {
label = "f7c027:device:relay";
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
};
@@ -37,21 +40,21 @@
poll-interval = <20>;
top {
- label = "top";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ label = "restore";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
power {
label = "power";
- gpios = <&gpio0 12 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
sensor {
label = "sensor";
- gpios = <&gpio0 14 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
@@ -64,7 +67,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l12805d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/FIREWRT.dts
===================================================================
--- sys/gnu/dts/mips/FIREWRT.dts
+++ sys/gnu/dts/mips/FIREWRT.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
+ compatible = "firefly,firewrt", "mediatek,mt7621-soc";
model = "Firefly FireWRT";
memory@0 {
@@ -20,7 +23,7 @@
power {
label = "firewrt:green:power";
- gpios = <&gpio0 22 1>;
+ gpios = <&gpio0 22 GPIO_ACTIVE_LOW>;
};
};
@@ -32,14 +35,14 @@
wps {
label = "wps";
- gpios = <&gpio0 18 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
power {
label = "power";
- gpios = <&gpio0 23 1>;
- linux,code = <116>;
+ gpios = <&gpio0 23 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_POWER>;
};
};
};
@@ -56,8 +59,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -92,7 +95,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -101,7 +104,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
Index: sys/gnu/dts/mips/FONERA20N.dts
===================================================================
--- sys/gnu/dts/mips/FONERA20N.dts
+++ sys/gnu/dts/mips/FONERA20N.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "FONERA20N", "ralink,rt3052-soc";
+ compatible = "fon,fonera20n", "ralink,rt3052-soc";
model = "La Fonera 2.0N";
cfi@1f000000 {
@@ -43,17 +46,17 @@
wifi {
label = "fonera20n:orange:wifi";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
power {
label = "fonera20n:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
usb {
label = "fonera20n:orange:usb";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -65,15 +68,15 @@
reset {
label = "reset";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
switch {
label = "switch";
- gpios = <&gpio0 13 1>;
- linux,code = <0xf7>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ linux,input-type = <EV_SW>;
};
};
};
Index: sys/gnu/dts/mips/FREESTATION5.dts
===================================================================
--- sys/gnu/dts/mips/FREESTATION5.dts
+++ sys/gnu/dts/mips/FREESTATION5.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "FREESTATION5", "ralink,rt3050-soc";
+ compatible = "arcwireless,freestation5", "ralink,rt3050-soc";
model = "ARC FreeStation5";
chosen {
@@ -50,7 +53,7 @@
poe {
gpio-export,name = "poe-passthrough";
gpio-export,output = <1>; // OUT_INIT_HIGH
- gpios = <&gpio0 11 1>; // GPIO 11, ACTIVE_LOW
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>; // GPIO 11, ACTIVE_LOW
};
};
@@ -61,17 +64,17 @@
// not present in the Freestation5 device.
wifi {
label = "freestation5:unknown:wifi";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
powerg {
label = "freestation5:unknown:powerg";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
usb {
label = "freestation5:unknown:usb";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/GB-PC1.dts
===================================================================
--- sys/gnu/dts/mips/GB-PC1.dts
+++ sys/gnu/dts/mips/GB-PC1.dts
@@ -2,9 +2,12 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "Firefly FireWRT";
+ compatible = "gnubee,gb-pc1", "mediatek,mt7621-soc";
+ model = "GB-PC1";
memory@0 {
device_type = "memory";
@@ -15,31 +18,40 @@
bootargs = "console=ttyS0,57600";
};
- gpio-leds {
- compatible = "gpio-leds";
-
- power {
- label = "firewrt:green:power";
- gpios = <&gpio0 22 1>;
- };
- };
-
gpio-keys-polled {
compatible = "gpio-keys-polled";
#address-cells = <1>;
#size-cells = <0>;
poll-interval = <20>;
- wps {
- label = "wps";
- gpios = <&gpio0 18 1>;
- linux,code = <0x211>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ system {
+ label = "gb-pc1:green:system";
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
};
- power {
- label = "power";
- gpios = <&gpio0 23 1>;
- linux,code = <116>;
+ status {
+ label = "gb-pc1:green:status";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ };
+
+ lan1 {
+ label = "gb-pc1:green:lan1";
+ gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
+ };
+
+ lan2 {
+ label = "gb-pc1:green:lan2";
+ gpios = <&gpio0 25 GPIO_ACTIVE_LOW>;
};
};
};
@@ -56,8 +68,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -79,31 +91,18 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0xfb0000>;
+ reg = <0x50000 0x1fb0000>;
};
};
};
+&cpuclock {
+ compatible = "fixed-clock";
+ clock-frequency = <900000000>;
+};
+
&pcie {
status = "okay";
-
- pcie0 {
- mt76@0,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
- };
- };
-
- pcie1 {
- mt76@1,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
- };
- };
};
&ethernet {
@@ -113,7 +112,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2";
+ ralink,group = "jtag", "rgmii2", "uart3", "wdt";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/GB-PC2.dts
===================================================================
--- sys/gnu/dts/mips/GB-PC2.dts
+++ sys/gnu/dts/mips/GB-PC2.dts
@@ -2,9 +2,12 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "ZBT-WG3526";
+ compatible = "gnubee,gb-pc2", "mediatek,mt7621-soc";
+ model = "GB-PC2";
memory@0 {
device_type = "memory";
@@ -12,19 +15,7 @@
};
chosen {
- bootargs = "console=ttyS0,115200";
- };
-
- palmbus: palmbus@1E000000 {
- i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
- status = "okay";
- };
+ bootargs = "console=ttyS0,57600";
};
gpio-keys-polled {
@@ -35,23 +26,52 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
gpio-leds {
compatible = "gpio-leds";
+ system {
+ label = "gb-pc2:green:system";
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+ };
+
status {
- label = "zbt-wg3526:green:status";
- gpios = <&gpio0 24 1>;
+ label = "gb-pc2:green:status";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
+
+ lan1 {
+ label = "gb-pc2:green:lan1";
+ gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
+ };
+
+ lan2 {
+ label = "gb-pc2:green:lan2";
+ gpios = <&gpio0 25 GPIO_ACTIVE_LOW>;
+ };
+
+ lan3-yellow {
+ label = "gb-pc2:yellow:lan3";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+
+ lan3-green {
+ label = "gb-pc2:green:lan3";
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
+ };
+
};
};
&sdhci {
status = "okay";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&sdhci_pins>;
};
&spi0 {
@@ -62,8 +82,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -85,31 +105,18 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0xfb0000>;
+ reg = <0x50000 0x1fb0000>;
};
};
};
+&cpuclock {
+ compatible = "fixed-clock";
+ clock-frequency = <900000000>;
+};
+
&pcie {
status = "okay";
-
- pcie0 {
- mt76@0,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
- };
- };
-
- pcie1 {
- mt76@1,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
- };
- };
};
&ethernet {
@@ -119,8 +126,9 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "wdt rst", "jtag", "mdio";
+ ralink,group = "jtag", "rgmii3", "uart3", "wdt";
ralink,function = "gpio";
};
};
};
+
Index: sys/gnu/dts/mips/GL-MT300A.dts
===================================================================
--- sys/gnu/dts/mips/GL-MT300A.dts
+++ sys/gnu/dts/mips/GL-MT300A.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "GL-MT300A", "ralink,mt7620a-soc";
+ compatible = "glinet,gl-mt300a", "ralink,mt7620a-soc";
model = "GL-MT300A";
chosen {
@@ -15,22 +18,22 @@
wan {
label = "gl-mt300a:wan";
- gpios = <&gpio2 0 1>;
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
};
lan {
label = "gl-mt300a:lan";
- gpios = <&gpio2 1 1>;
+ gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
};
wlan {
label = "gl-mt300a:wlan";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
usb {
label = "gl-mt300a:usb";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
};
@@ -42,20 +45,20 @@
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 13 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
BTN_0 {
label = "BTN_0";
- gpios = <&gpio0 1 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
BTN_1 {
label = "BTN_1";
- gpios = <&gpio0 2 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
@@ -82,9 +85,8 @@
m25p80@0 {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "w25q128";
+ compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -129,29 +131,14 @@
};
&ethernet {
- pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4000>;
- ralink,port-map = "wllll";
+ mediatek,portmap = "wllll";
};
&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
-&pcie {
- status = "okay";
-
- pcie-bridge {
- mt76@0,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
- };
- };
-};
-
&pinctrl {
state_default: pinctrl0 {
gpio {
Index: sys/gnu/dts/mips/GL-MT300N-V2.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/GL-MT300N-V2.dts
@@ -0,0 +1,143 @@
+/dts-v1/;
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/{
+ compatible = "glinet,gl-mt300n-v2", "ralink,mt7620an-soc";
+ model = "GL-MT300N-V2";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "gl-mt300n-v2:green:power";
+ default-state = "on";
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "gl-mt300n-v2:blue:wan";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "gl-mt300n-v2:red:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ BTN_0 {
+ label = "BTN_0";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ };
+
+ BTN_1 {
+ label = "BTN_1";
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ usb {
+ gpio-export,name = "usb";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "wdt", "gpio", "wled_an", "p0led_an", "p1led_an", "i2s";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x4>;
+};
+
+&wmac {
+ status = "okay";
+ ralink,mtd-eeprom = <&factory 0x0>;
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
+
+&uart1 {
+ status = "okay";
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/GL-MT300N.dts
===================================================================
--- sys/gnu/dts/mips/GL-MT300N.dts
+++ sys/gnu/dts/mips/GL-MT300N.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "GL-MT300N", "ralink,mt7620a-soc";
+ compatible = "glinet,gl-mt300n", "ralink,mt7620a-soc";
model = "GL-MT300N";
chosen {
@@ -15,17 +18,17 @@
wan {
label = "gl-mt300n:wan";
- gpios = <&gpio2 0 1>;
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
};
lan {
label = "gl-mt300n:lan";
- gpios = <&gpio2 1 1>;
+ gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
};
wlan {
label = "gl-mt300n:wlan";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -37,20 +40,20 @@
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
BTN_0 {
label = "BTN_0";
- gpios = <&gpio2 2 1>;
- linux,code = <0x100>;
+ gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
BTN_1 {
label = "BTN_1";
- gpios = <&gpio2 3 1>;
- linux,code = <0x101>;
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
@@ -77,9 +80,8 @@
m25p80@0 {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "w25q128";
+ compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -121,26 +123,13 @@
&ethernet {
mtd-mac-address = <&factory 0x4000>;
- ralink,port-map = "wllll";
+ mediatek,portmap = "wllll";
};
&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
-&pcie {
- status = "okay";
-
- pcie-bridge {
- mt76@0,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
- };
- };
-};
-
&pinctrl {
state_default: pinctrl0 {
gpio {
Index: sys/gnu/dts/mips/GL-MT750.dts
===================================================================
--- sys/gnu/dts/mips/GL-MT750.dts
+++ sys/gnu/dts/mips/GL-MT750.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "GL-MT750", "ralink,mt7620a-soc";
+ compatible = "glinet,gl-mt750", "ralink,mt7620a-soc";
model = "GL-MT750";
chosen {
@@ -15,17 +18,17 @@
wan {
label = "gl-mt750:wan";
- gpios = <&gpio2 0 1>;
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
};
lan {
label = "gl-mt750:lan";
- gpios = <&gpio2 1 1>;
+ gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
};
wlan {
label = "gl-mt750:wlan";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -37,20 +40,20 @@
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 13 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
BTN_0 {
label = "BTN_0";
- gpios = <&gpio2 2 1>;
- linux,code = <0x100>;
+ gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
BTN_1 {
label = "BTN_1";
- gpios = <&gpio2 3 1>;
- linux,code = <0x101>;
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
@@ -77,9 +80,8 @@
m25p80@0 {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "w25q128";
+ compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -124,10 +126,8 @@
};
&ethernet {
- pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4000>;
- ralink,port-map = "llllw";
+ mediatek,portmap = "llllw";
};
&wmac {
@@ -142,7 +142,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
};
};
};
Index: sys/gnu/dts/mips/HC5661.dts
===================================================================
--- sys/gnu/dts/mips/HC5661.dts
+++ sys/gnu/dts/mips/HC5661.dts
@@ -1,9 +1,9 @@
/dts-v1/;
-#include "HC5XXX.dtsi"
+#include "HC5X61.dtsi"
/ {
- compatible = "HC5661", "ralink,mt7620a-soc";
+ compatible = "hiwifi,hc5661", "hiwifi,hc5x61", "ralink,mt7620a-soc";
model = "HiWiFi HC5661";
gpio-leds {
@@ -11,22 +11,22 @@
system {
label = "hc5661:blue:system";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
internet {
label = "hc5661:blue:internet";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
wlan2g {
label = "hc5661:blue:wlan2g";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wlan5g {
label = "hc5661:blue:wlan5g";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/HC5661A.dts
===================================================================
--- sys/gnu/dts/mips/HC5661A.dts
+++ sys/gnu/dts/mips/HC5661A.dts
@@ -1,11 +1,41 @@
-#include "mt7620a.dtsi"
+/dts-v1/;
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
+ compatible = "hiwifi,hc5661a", "mediatek,mt7628an-soc";
+ model = "HiWiFi HC5661A";
+
chosen {
bootargs = "console=ttyS0,115200";
};
- gpio-keys-polled {
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ system {
+ label = "hc5661a:blue:system";
+ gpios = <&gpio1 5 GPIO_ACTIVE_HIGH>;
+ };
+ internet {
+ label = "hc5661a:blue:internet";
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ };
+ wlan2g {
+ label = "hc5661a:blue:wlan2g";
+ gpios = <&gpio1 12 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+ gpio-keys {
compatible = "gpio-keys-polled";
#address-cells = <1>;
#size-cells = <0>;
@@ -13,41 +43,21 @@
reset {
label = "reset";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
+};
- gpio_export {
- compatible = "gpio-export";
- #size-cells = <0>;
-
- usbpower {
- gpio-export,name = "usbpower";
- gpio-export,output = <1>;
- gpios = <&gpio0 13 0>;
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "refclk", "wled_an";
+ ralink,function = "gpio";
};
};
};
-&sysc {
- ralink,gpiomux = "i2c", "jtag";
- ralink,uartmux = "gpio";
- ralink,wdtmux = <1>;
-};
-
-&gpio0 {
- status = "okay";
-};
-
-&gpio2 {
- status = "okay";
-};
-
-&gpio3 {
- status = "okay";
-};
-
&spi0 {
status = "okay";
@@ -58,14 +68,16 @@
reg = <0>;
linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
reg = <0x0 0x30000>;
+ read-only;
};
partition@30000 {
- label = "u-boot-env";
+ label = "hw_panic";
reg = <0x30000 0x10000>;
read-only;
};
@@ -73,67 +85,39 @@
factory: partition@40000 {
label = "factory";
reg = <0x40000 0x10000>;
+ read-only;
};
partition@50000 {
label = "firmware";
- reg = <0x50000 0xf80000>;
+ reg = <0x50000 0xf70000>;
};
- partition@fd0000 {
- label = "hwf_config";
- reg = <0xfd0000 0x10000>;
+ partition@fc0000 {
+ label = "oem";
+ reg = <0xfc0000 0x20000>;
+ read-only;
};
bdinfo: partition@fe0000 {
label = "bdinfo";
reg = <0xfe0000 0x10000>;
+ read-only;
};
partition@ff0000 {
label = "backup";
reg = <0xff0000 0x10000>;
+ read-only;
};
};
};
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
&ethernet {
- pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "wllll";
};
-&sdhci {
- status = "okay";
-};
-
&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&pcie {
status = "okay";
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "uartf", "wled", "nd_sd";
- ralink,function = "gpio";
- };
-
- pa {
- ralink,group = "pa";
- ralink,function = "pa";
- };
- };
-};
Index: sys/gnu/dts/mips/HC5761.dts
===================================================================
--- sys/gnu/dts/mips/HC5761.dts
+++ sys/gnu/dts/mips/HC5761.dts
@@ -1,9 +1,9 @@
/dts-v1/;
-#include "HC5XXX.dtsi"
+#include "HC5X61.dtsi"
/ {
- compatible = "HC5761", "ralink,mt7620a-soc";
+ compatible = "hiwifi,hc5761", "hiwifi,hc5x61", "ralink,mt7620a-soc";
model = "HiWiFi HC5761";
gpio-leds {
@@ -11,22 +11,22 @@
system {
label = "hc5761:blue:system";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
internet {
label = "hc5761:blue:internet";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
wlan2g {
label = "hc5761:blue:wlan2g";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wlan5g {
label = "hc5761:blue:wlan5g";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/HC5861.dts
===================================================================
--- sys/gnu/dts/mips/HC5861.dts
+++ sys/gnu/dts/mips/HC5861.dts
@@ -1,9 +1,9 @@
/dts-v1/;
-#include "HC5XXX.dtsi"
+#include "HC5X61.dtsi"
/ {
- compatible = "HC5861", "ralink,mt7620a-soc";
+ compatible = "hiwifi,hc5861", "hiwifi,hc5x61", "ralink,mt7620a-soc";
model = "HiWiFi HC5861";
gpio-leds {
@@ -11,27 +11,27 @@
system {
label = "hc5861:blue:system";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan2g {
label = "hc5861:blue:wlan2g";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
internet {
label = "hc5861:blue:internet";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wlan5g {
label = "hc5861:blue:wlan5g";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
turbo {
label = "hc5861:blue:turbo";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
};
@@ -42,13 +42,13 @@
usbpower {
gpio-export,name = "usbpower";
gpio-export,output = <0>;
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
sdpower {
gpio-export,name = "sdpower";
gpio-export,output = <0>;
- gpios = <&gpio0 8 0>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/HC5962.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/HC5962.dts
@@ -0,0 +1,148 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "hiwifi,hc5962", "mediatek,mt7621-soc";
+ model = "HiWiFi HC5962";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status {
+ label = "hc5962:white:status";
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+ };
+
+ system {
+ label = "hc5962:red:system";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+};
+
+&nand {
+ status = "okay";
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x80000>;
+ read-only;
+ };
+
+ partition@80000 {
+ label = "debug";
+ reg = <0x80000 0x80000>;
+ read-only;
+ };
+
+ factory: partition@100000 {
+ label = "factory";
+ reg = <0x100000 0x40000>;
+ read-only;
+ };
+
+ partition@140000 {
+ label = "kernel";
+ reg = <0x140000 0x200000>;
+ };
+
+ partition@340000 {
+ label = "ubi";
+ reg = <0x340000 0x1E00000>;
+ };
+
+ partition@2140000 {
+ label = "hw_panic";
+ reg = <0x2140000 0x80000>;
+ read-only;
+ };
+
+ partition@21c0000 {
+ label = "bdinfo";
+ reg = <0x21c0000 0x80000>;
+ read-only;
+ };
+
+ partition@2240000 {
+ label = "backup";
+ reg = <0x2240000 0x80000>;
+ read-only;
+ };
+
+ partition@22c0000 {
+ label = "overly";
+ reg = <0x22c0000 0x1000000>;
+ };
+
+ partition@32c0000 {
+ label = "firmware_backup";
+ reg = <0x32c0000 0x2000000>;
+ };
+
+ partition@52c0000 {
+ label = "oem";
+ reg = <0x52c0000 0x200000>;
+ };
+
+ partition@54c0000 {
+ label = "opt";
+ reg = <0x54c0000 0x2ac0000>;
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie0 {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x0000>;
+ ieee80211-freq-limit = <2400000 2500000>;
+ };
+ };
+
+ pcie1 {
+ mt76@1,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "uart3", "jtag";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/HC5X61.dtsi
===================================================================
--- sys/gnu/dts/mips/HC5X61.dtsi
+++ sys/gnu/dts/mips/HC5X61.dtsi
@@ -1,6 +1,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
+ compatible = "hiwifi,hc5x61", "ralink,mt7620a-soc";
+
chosen {
bootargs = "console=ttyS0,115200";
};
@@ -13,8 +18,8 @@
reset {
label = "reset";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -25,7 +30,7 @@
usbpower {
gpio-export,name = "usbpower";
gpio-export,output = <1>;
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -56,7 +61,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -118,6 +122,8 @@
&wmac {
ralink,mtd-eeprom = <&factory 0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
};
&pcie {
@@ -130,10 +136,5 @@
ralink,group = "uartf", "wled", "nd_sd";
ralink,function = "gpio";
};
-
- pa {
- ralink,group = "pa";
- ralink,function = "pa";
- };
};
};
Index: sys/gnu/dts/mips/HG255D.dts
===================================================================
--- sys/gnu/dts/mips/HG255D.dts
+++ sys/gnu/dts/mips/HG255D.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "HG255D", "ralink,rt3052-soc";
+ compatible = "huawei,hg255d", "ralink,rt3052-soc";
model = "HuaWei HG255D";
cfi@1f000000 {
@@ -49,32 +52,32 @@
power {
label = "hg255d:green:power";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
internet {
label = "hg255d:green:internet";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
wifi {
label = "hg255d:green:wlan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
usb {
label = "hg255d:green:usb";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps {
label = "hg255d:green:wps";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
voice {
label = "hg255d:green:voice";
- gpios = <&gpio0 5 1>;
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
};
};
@@ -86,20 +89,20 @@
reset {
label = "reset";
- gpios = <&gpio0 4 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
rfkill {
label = "rfkill";
- gpios = <&gpio0 0 1>;
- linux,code = <0xf7>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
};
};
Index: sys/gnu/dts/mips/HLKRM04.dts
===================================================================
--- sys/gnu/dts/mips/HLKRM04.dts
+++ sys/gnu/dts/mips/HLKRM04.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "HLKRM04", "ralink,rt5350-soc";
+ compatible = "hilink,hlk-rm04", "ralink,rt5350-soc";
model = "HILINK HLK-RM04";
memory@0 {
@@ -24,13 +27,13 @@
/* I2C_I2C_SD */
gpio-export,name = "hlk-rm04:gpio0";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 1 0>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
};
gpio2 {
/* I2C_I2C_SCLK */
gpio-export,name = "hlk-rm04:gpio1";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 2 0>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
};
};
@@ -41,13 +44,13 @@
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 14 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -64,7 +67,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/HPM.dts
===================================================================
--- sys/gnu/dts/mips/HPM.dts
+++ sys/gnu/dts/mips/HPM.dts
@@ -2,8 +2,11 @@
#include "rt3883.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "HPM", "ralink,rt3883-soc";
+ compatible = "omnima,hpm", "ralink,rt3883-soc";
model = "Omnima HPM";
chosen {
@@ -18,8 +21,8 @@
reset {
label = "reset";
- gpios = <&gpio0 14 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -28,32 +31,32 @@
power {
label = "hpm:orange:power";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
status {
label = "hpm:green:status";
- gpios = <&gpio0 21 1>;
+ gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
};
eth {
label = "hpm:green:eth";
- gpios = <&gpio0 20 1>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
eth2 {
label = "hpm:red:eth";
- gpios = <&gpio0 18 1>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
};
wifi {
label = "hpm:green:wifi";
- gpios = <&gpio0 17 1>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
};
wifi2 {
label = "hpm:red:wifi";
- gpios = <&gpio0 19 1>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
};
@@ -65,13 +68,13 @@
usb0 {
gpio-export,name = "usb0";
gpio-export,output = <1>;
- gpios = <&gpio0 2 0>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
};
usb1 {
gpio-export,name = "usb1";
gpio-export,output = <1>;
- gpios = <&gpio0 1 0>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
};
};
};
Index: sys/gnu/dts/mips/HT-TM02.dts
===================================================================
--- sys/gnu/dts/mips/HT-TM02.dts
+++ sys/gnu/dts/mips/HT-TM02.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "HT-TM02", "ralink,rt5350-soc";
+ compatible = "hootoo,ht-tm02", "ralink,rt5350-soc";
model = "HooToo HT-TM02";
gpio-leds {
@@ -11,12 +14,12 @@
wlan {
label = "ht-tm02:blue:wlan";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
lan {
label = "ht-tm02:green:lan";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
};
@@ -28,15 +31,15 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
modeswitch {
label = "modeswitch";
- gpios = <&gpio0 14 1>;
- linux,code = <0x100>;
- linux,input-type = <5>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
};
@@ -53,7 +56,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/HW550-3G.dts
===================================================================
--- sys/gnu/dts/mips/HW550-3G.dts
+++ sys/gnu/dts/mips/HW550-3G.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "HW550-3G", "ralink,rt3052-soc";
+ compatible = "aztech,hw550-3g", "ralink,rt3052-soc";
model = "Aztech HW550-3G";
cfi@1f000000 {
@@ -43,22 +46,22 @@
usb {
label = "hw550-3g:green:usb";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
3g {
label = "hw550-3g:green:3g";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
status {
label = "hw550-3g:green:status";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "hw550-3g:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -70,20 +73,20 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
connect {
label = "connect";
- gpios = <&gpio0 7 1>;
- linux,code = <0xda>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_CONNECT>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/IP2202.dts
===================================================================
--- sys/gnu/dts/mips/IP2202.dts
+++ sys/gnu/dts/mips/IP2202.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "IP2202", "ralink,rt3052-soc";
+ compatible = "poray,ip2202", "ralink,rt3052-soc";
model = "Poray IP2202";
cfi@1f000000 {
@@ -43,12 +46,12 @@
run {
label = "ip2202:green:run";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
net {
label = "ip2202:amber:net";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -60,8 +63,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/JHR-N805R.dts
===================================================================
--- sys/gnu/dts/mips/JHR-N805R.dts
+++ sys/gnu/dts/mips/JHR-N805R.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "JHR-N805R", "ralink,rt3050-soc";
+ compatible = "jcg,jhr-n805r", "ralink,rt3050-soc";
model = "JCG JHR-N805R";
gpio-leds {
@@ -11,7 +14,7 @@
system {
label = "jhr-n805r:blue:system";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -23,8 +26,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -46,7 +49,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/JHR-N825R.dts
===================================================================
--- sys/gnu/dts/mips/JHR-N825R.dts
+++ sys/gnu/dts/mips/JHR-N825R.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "JHR-N825R", "ralink,rt3052-soc";
+ compatible = "jcg,jhr-n825r", "ralink,rt3052-soc";
model = "JCG JHR-N825R";
cfi@1f000000 {
@@ -42,7 +45,7 @@
compatible = "gpio-leds";
system {
label = "jhr-n825r:red:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -53,8 +56,8 @@
poll-interval = <20>;
reset_wps {
label = "reset_wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/JHR-N926R.dts
===================================================================
--- sys/gnu/dts/mips/JHR-N926R.dts
+++ sys/gnu/dts/mips/JHR-N926R.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "JHR-N926R", "ralink,rt3052-soc";
+ compatible = "jcg,jhr-n926r", "ralink,rt3052-soc";
model = "JCG JHR-N926R";
cfi@1f000000 {
@@ -43,22 +46,22 @@
wlan1 {
label = "jhr-n926r:red:wlan";
- gpios = <&gpio0 20 1>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
wlan2 {
label = "jhr-n926r:yellow:wlan";
- gpios = <&gpio0 19 1>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
wlan3 {
label = "jhr-n926r:green:wlan";
- gpios = <&gpio0 17 1>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
};
system {
label = "jhr-n926r:blue:system";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -69,19 +72,19 @@
display_data {
gpio-export,name = "display_data";
gpio-export,output = <1>;
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
display_clock {
gpio-export,name = "display_clock";
gpio-export,output = <1>;
- gpios = <&gpio0 8 0>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
};
display_blank {
gpio-export,name = "display_blank";
gpio-export,output = <1>;
- gpios = <&gpio0 11 0>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
};
};
@@ -93,14 +96,14 @@
reset_wps {
label = "reset_wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wlan {
label = "wlan";
- gpios = <&gpio0 1 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
Index: sys/gnu/dts/mips/K2G.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/K2G.dts
@@ -0,0 +1,139 @@
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "phicomm,k2g", "ralink,mt7620a-soc";
+ model = "Phicomm K2G";
+
+ aliases {
+ serial0 = &uartlite;
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ led_blue: blue {
+ label = "k2g:blue:status";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ yellow {
+ label = "k2g:yellow:status";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ red {
+ label = "k2g:red:status";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <24000000>;
+
+ partitions {
+ compatible = "fixed-partitions";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ u-boot@0 {
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ u-boot-env@30000 {
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: factory@40000 {
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ permanent_config@50000 {
+ reg = <0x50000 0x50000>;
+ read-only;
+ };
+
+ firmware@a0000 {
+ reg = <0xa0000 0x760000>;
+ };
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ pinctrl-names = "default";
+ pinctrl-0 = <&rgmii2_pins &mdio_pins>;
+ mtd-mac-address = <&factory 0x28>;
+ mediatek,portmap = "llllw";
+
+ port@5 {
+ status = "okay";
+ phy-handle = <&phy5>;
+ phy-mode = "rgmii";
+ };
+
+ mdio-bus {
+ status = "okay";
+
+ phy5: ethernet-phy@5 {
+ reg = <5>;
+ phy-mode = "rgmii";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
+};
Index: sys/gnu/dts/mips/K2P.dts
===================================================================
--- sys/gnu/dts/mips/K2P.dts
+++ sys/gnu/dts/mips/K2P.dts
@@ -2,9 +2,12 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "STORYLiNK SAP-G3200U3";
+ compatible = "phicomm,k2p", "mediatek,mt7621-soc";
+ model = "Phicomm K2P";
memory@0 {
device_type = "memory";
@@ -18,9 +21,19 @@
gpio-leds {
compatible = "gpio-leds";
- usb {
- label = "sap-g3200u3:green:usb";
- gpios = <&gpio0 13 1>;
+ stat_r {
+ label = "k2p:red:status";
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
+ };
+
+ stat_y {
+ label = "k2p:yellow:status";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ stat_b {
+ label = "k2p:blue:status";
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
};
};
@@ -32,14 +45,8 @@
reset {
label = "reset";
- gpios = <&gpio0 16 1>;
- linux,code = <0x198>;
- };
-
- rfkill {
- label = "rfkill";
- gpios = <&gpio0 14 1>;
- linux,code = <0xf7>;
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -52,8 +59,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -63,13 +70,7 @@
partition@30000 {
label = "u-boot-env";
- reg = <0x30000 0x1000>;
- read-only;
- };
-
- partition@31000 {
- label = "config";
- reg = <0x31000 0xf000>;
+ reg = <0x30000 0x10000>;
read-only;
};
@@ -80,8 +81,14 @@
};
partition@50000 {
+ label = "permanent_config";
+ reg = <0x50000 0x50000>;
+ read-only;
+ };
+
+ partition@a0000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
+ reg = <0xa0000 0xf60000>;
};
};
};
@@ -93,17 +100,7 @@
mt76@0,0 {
reg = <0x0000 0 0 0 0>;
device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
- };
- };
-
- pcie1 {
- mt76@1,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x0>;
};
};
};
@@ -115,7 +112,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "uart3", "jtag";
+ ralink,group = "i2c", "jtag";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/LINKIT7688.dts
===================================================================
--- sys/gnu/dts/mips/LINKIT7688.dts
+++ sys/gnu/dts/mips/LINKIT7688.dts
@@ -2,8 +2,11 @@
#include "mt7628an.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,linkit", "mediatek,mt7628an-soc";
+ compatible = "mediatek,linkit-smart-7688", "mediatek,mt7628an-soc";
model = "MediaTek LinkIt Smart 7688";
chosen {
@@ -29,9 +32,8 @@
compatible = "gpio-leds";
wifi {
- label = "mediatek:orange:wifi";
- gpios = <&wgpio 0 0>;
- default-state = "on";
+ label = "linkit-smart-7688:orange:wifi";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
};
};
@@ -43,18 +45,10 @@
wps {
label = "reset";
- gpios = <&gpio1 6 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
-
- wgpio: gpio-wifi {
- compatible = "mediatek,gpio-wifi";
- #address-cells = <1>;
- #size-cells = <0>;
- gpio-controller;
- #gpio-cells = <2>;
- };
};
&pinctrl {
@@ -64,11 +58,6 @@
ralink,function = "gpio";
};
- perst {
- ralink,group = "perst";
- ralink,function = "gpio";
- };
-
refclk {
ralink,group = "refclk";
ralink,function = "gpio";
@@ -84,14 +73,9 @@
ralink,function = "gpio";
};
- wled_kn {
- ralink,group = "wled_kn";
- ralink,function = "gpio";
- };
-
wled_an {
ralink,group = "wled_an";
- ralink,function = "wled_an";
+ ralink,function = "gpio";
};
wdt {
@@ -116,7 +100,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l25635e";
spi-max-frequency = <40000000>;
m25p,chunked-io = <31>;
Index: sys/gnu/dts/mips/M2M.dts
===================================================================
--- sys/gnu/dts/mips/M2M.dts
+++ sys/gnu/dts/mips/M2M.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "M2M", "ralink,rt5350-soc";
+ compatible = "intenso,memory2move", "ralink,rt5350-soc";
model = "Intenso Memory 2 Move";
chosen {
@@ -15,12 +18,12 @@
wifi {
label = "m2m:blue:wifi";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wan {
label = "m2m:green:wan";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
};
@@ -32,14 +35,14 @@
power {
label = "power";
- gpios = <&gpio0 1 1>;
- linux,code = <0x116>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_POWER>;
};
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -52,7 +55,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/M3.dts
===================================================================
--- sys/gnu/dts/mips/M3.dts
+++ sys/gnu/dts/mips/M3.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "M3", "ralink,rt5350-soc";
+ compatible = "poray,m3", "ralink,rt5350-soc";
model = "Poray M3";
gpio-leds {
@@ -11,7 +14,7 @@
status {
label = "m3:blue:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -23,15 +26,15 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
mode {
label = "mode";
- gpios = <&gpio0 17 1>;
- linux,code = <0x100>;
- linux,input-type = <5>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
};
@@ -44,7 +47,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q32";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/M4-4M.dts
===================================================================
--- sys/gnu/dts/mips/M4-4M.dts
+++ sys/gnu/dts/mips/M4-4M.dts
@@ -1,32 +1,10 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "M4.dtsi"
/ {
- compatible = "M4", "ralink,rt5350-soc";
- model = "Poray M4";
-
- gpio-leds {
- compatible = "gpio-leds";
-
- status {
- label = "m4:blue:status";
- gpios = <&gpio0 9 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
- };
+ compatible = "poray,m4-4m", "poray,m4", "ralink,rt5350-soc";
+ model = "Poray M4 (4M)";
};
&spi0 {
@@ -37,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "pm25lq032";
spi-max-frequency = <10000000>;
partition@0 {
@@ -64,29 +41,3 @@
};
};
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x4>;
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <1>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
Index: sys/gnu/dts/mips/M4-8M.dts
===================================================================
--- sys/gnu/dts/mips/M4-8M.dts
+++ sys/gnu/dts/mips/M4-8M.dts
@@ -1,32 +1,10 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "M4.dtsi"
/ {
- compatible = "M4", "ralink,rt5350-soc";
- model = "Poray M4";
-
- gpio-leds {
- compatible = "gpio-leds";
-
- status {
- label = "m4:blue:status";
- gpios = <&gpio0 9 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
- };
+ compatible = "poray,m4-8m", "poray,m4", "ralink,rt5350-soc";
+ model = "Poray M4 (8M)";
};
&spi0 {
@@ -37,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "gd25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -64,34 +41,3 @@
};
};
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x4>;
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <1>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
- ralink,led-polarity = <1>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
Index: sys/gnu/dts/mips/M4.dtsi
===================================================================
--- sys/gnu/dts/mips/M4.dtsi
+++ sys/gnu/dts/mips/M4.dtsi
@@ -1,8 +1,19 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "PX-4885", "ralink,rt5350-soc";
- model = "7Links PX-4885";
+ compatible = "poray,m4", "ralink,rt5350-soc";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status {
+ label = "m4:blue:status";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ };
+ };
gpio-keys-polled {
compatible = "gpio-keys-polled";
@@ -12,22 +23,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- orange {
- label = "px-4885:orange:wifi";
- gpios = <&gpio0 18 1>;
- };
-
- blue {
- label = "px-4885:blue:storage";
- gpios = <&gpio0 19 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -42,13 +39,23 @@
};
&ethernet {
- mtd-mac-address = <&factory 0x28>;
+ mtd-mac-address = <&factory 0x4>;
};
&esw {
- mediatek,portmap = <0x3f>;
+ mediatek,portmap = <0x2f>;
+ mediatek,led_polarity = <1>;
};
&wmac {
ralink,mtd-eeprom = <&factory 0>;
+ ralink,led-polarity = <1>;
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
};
Index: sys/gnu/dts/mips/MAC1200RV2.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/MAC1200RV2.dts
@@ -0,0 +1,96 @@
+/dts-v1/;
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "mercury,mac1200r-v2", "mediatek,mt7628an-soc";
+ model = "Mercury MAC1200R v2";
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x2000000>;
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+ status {
+ label = "mac1200rv2:green:status";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0 0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x1d800>;
+ };
+
+ factory: partition@0x1d800 {
+ label = "factory_info";
+ reg = <0x1d800 0x800>;
+ read-only;
+ };
+
+ art: partition@0x1e000 {
+ label = "art";
+ reg = <0x1e000 0x2000>;
+ read-only;
+ };
+
+ partition@20000 {
+ label = "config";
+ reg = <0x20000 0x10000>;
+ };
+
+ partition@30000 {
+ label = "u-boot2";
+ reg = <0x30000 0x10000>;
+ };
+
+ partition@40000 {
+ label = "firmware";
+ reg = <0x40000 0x7c0000>;
+ };
+ };
+};
+
+&ethernet {
+ pinctrl-names = "default";
+ mtd-mac-address = <&factory 0xd>;
+ mediatek,portmap = "llllw";
+};
+
+&wmac {
+ status = "okay";
+ ralink,mtd-eeprom = <&art 0x0>;
+};
+
+&pcie {
+ status = "okay";
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&art 0x1000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/MINIEMBPLUG.dts
===================================================================
--- sys/gnu/dts/mips/MINIEMBPLUG.dts
+++ sys/gnu/dts/mips/MINIEMBPLUG.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MINIEMBPLUG", "ralink,rt5350-soc";
+ compatible = "omnima,miniembplug", "ralink,rt5350-soc";
model = "Omnima MiniEMBPlug";
gpio-leds {
@@ -11,12 +14,12 @@
wlan {
label = "miniembplug:red:wlan";
- gpios = <&gpio0 9 0>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
};
mobile {
label = "miniembplug:green:mobile";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -28,26 +31,26 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
mode-one {
label = "mode1";
- gpios = <&gpio0 11 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
mode-two {
label = "mode2";
- gpios = <&gpio0 12 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -73,7 +76,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MINIEMBWIFI.dts
===================================================================
--- sys/gnu/dts/mips/MINIEMBWIFI.dts
+++ sys/gnu/dts/mips/MINIEMBWIFI.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MINIEMBWIFI", "ralink,rt3052-soc";
+ compatible = "omnima,miniembwifi", "ralink,rt3052-soc";
model = "Omnima MiniEMBWiFi";
gpio-leds {
@@ -11,12 +14,12 @@
status {
label = "miniembwifi:green:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan {
label = "miniembwifi:green:wlan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
reset {
label = "reset";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
Index: sys/gnu/dts/mips/MIR3G.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/MIR3G.dts
@@ -0,0 +1,195 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "xiaomi,mir3g", "mediatek,mt7621-soc";
+ model = "Xiaomi Mi Router 3G";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,115200n8";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status_red {
+ label = "mir3g:red:status";
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+ };
+
+ status_blue {
+ label = "mir3g:blue:status";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ };
+
+ status_yellow {
+ label = "mir3g:yellow:status";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_amber {
+ label = "mir3g:amber:wan";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+
+ lan1_amber {
+ label = "mir3g:amber:lan1";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ lan2_amber {
+ label = "mir3g:amber:lan2";
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
+ };
+
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ usbpower {
+ gpio-export,name = "usbpower";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&nand {
+ status = "okay";
+
+ partition@0 {
+ label = "Bootloader";
+ reg = <0x0 0x80000>;
+ read-only;
+ };
+
+ partition@80000 {
+ label = "Config";
+ reg = <0x80000 0x40000>;
+ };
+
+ partition@c0000 {
+ label = "Bdata";
+ reg = <0xc0000 0x40000>;
+ read-only;
+ };
+
+ factory: partition@100000 {
+ label = "Factory";
+ reg = <0x100000 0x40000>;
+ read-only;
+ };
+
+ partition@140000 {
+ label = "crash";
+ reg = <0x140000 0x40000>;
+ };
+
+ partition@180000 {
+ label = "crash_syslog";
+ reg = <0x180000 0x40000>;
+ };
+
+ partition@1c0000 {
+ label = "reserved0";
+ reg = <0x1c0000 0x40000>;
+ read-only;
+ };
+
+ /* uboot expects to find kernels at 0x200000 & 0x600000
+ * referred to as system 1 & system 2 respectively.
+ * a kernel is considered suitable for handing control over
+ * if its linux magic number exists & uImage CRC are correct.
+ * If either of those conditions fail, a matching sys'n'_fail flag
+ * is set in uboot env & a restart performed in the hope that the
+ * alternate kernel is okay.
+ * if neither kernel checksums ok and both are marked failed, system 2
+ * is booted anyway.
+ *
+ * Note uboot's tftp flash install writes the transferred
+ * image to both kernel partitions.
+ */
+
+ partition@200000 {
+ label = "kernel_stock";
+ reg = <0x200000 0x400000>;
+ };
+
+ partition@600000 {
+ label = "kernel";
+ reg = <0x600000 0x400000>;
+ };
+
+ /* ubi partition is the result of squashing
+ * next consecutive stock partitions:
+ * - rootfs0 (rootfs partition for stock kernel0),
+ * - rootfs1 (rootfs partition for stock failsafe kernel1),
+ * - overlay (used as ubi overlay in stock fw)
+ * resulting 117,5MiB space for packages.
+ */
+
+ partition@a00000 {
+ label = "ubi";
+ reg = <0xa00000 0x7580000>;
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie0 {
+ wifi@14c3,7603 {
+ compatible = "pci14c3,7603";
+ reg = <0x0000 0 0 0 0>;
+ mediatek,mtd-eeprom = <&factory 0x0000>;
+ ieee80211-freq-limit = <2400000 2500000>;
+ };
+ };
+
+ pcie1 {
+ wifi@14c3,7662 {
+ compatible = "pci14c3,7662";
+ reg = <0x0000 0 0 0 0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0xe000>;
+ mediatek,portmap = "lwlll";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "jtag", "uart2", "uart3", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/MIWIFI-MINI.dts
===================================================================
--- sys/gnu/dts/mips/MIWIFI-MINI.dts
+++ sys/gnu/dts/mips/MIWIFI-MINI.dts
@@ -2,6 +2,9 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "xiaomi,miwifi-mini", "ralink,mt7620a-soc";
model = "Xiaomi MiWiFi Mini";
@@ -15,17 +18,17 @@
blue {
label = "miwifi-mini:blue:status";
- gpios = <&gpio1 0 1>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
};
yellow {
label = "miwifi-mini:yellow:status";
- gpios = <&gpio1 2 1>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
};
red {
label = "miwifi-mini:red:status";
- gpios = <&gpio1 5 1>;
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
};
};
@@ -37,8 +40,8 @@
reset {
label = "reset";
- gpios = <&gpio1 6 0>;
- linux,code = <0x198>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -63,7 +66,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -117,12 +119,14 @@
&ethernet {
pinctrl-names = "default";
pinctrl-0 = <&ephy_pins>;
- mtd-mac-address = <&factory 0x4>;
+ mtd-mac-address = <&factory 0x28>;
mediatek,portmap = "llllw";
};
&wmac {
ralink,mtd-eeprom = <&factory 0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
};
&pcie {
@@ -133,7 +137,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
@@ -144,10 +148,5 @@
ralink,group = "i2c", "rgmii1";
ralink,function = "gpio";
};
-
- pa {
- ralink,group = "pa";
- ralink,function = "pa";
- };
};
};
Index: sys/gnu/dts/mips/MIWIFI-NANO.dts
===================================================================
--- sys/gnu/dts/mips/MIWIFI-NANO.dts
+++ sys/gnu/dts/mips/MIWIFI-NANO.dts
@@ -2,8 +2,11 @@
#include "mt7628an.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "xiaomi,MiWifi Nano", "mediatek,mt7628an-soc";
+ compatible = "xiaomi,miwifi-nano", "mediatek,mt7628an-soc";
model = "MiWiFi Nano";
chosen {
@@ -18,21 +21,30 @@
gpio-leds {
compatible = "gpio-leds";
- wifi {
- label = "miwifi-nano:blue:wifi";
- gpios = <&gpio0 11 1>;
- default-state = "1";
+ status_blue {
+ label = "miwifi-nano:blue:status";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
- status {
+ status_red {
label = "miwifi-nano:red:status";
- gpios = <&gpio1 5 1>;
- default-state = "on";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ };
+ status_amber {
+ label = "miwifi-nano:amber:status";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
};
- radio {
- label = "miwifi-nano:amber:radio";
- gpios = <&gpio1 12 1>;
- default-state = "1";
+ };
+ gpio-keys {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -40,7 +52,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "refclk", "wled", "gpio";
+ ralink,group = "refclk", "wled_an", "gpio";
ralink,function = "gpio";
};
};
@@ -48,6 +60,11 @@
&wmac {
status = "okay";
+ ralink,mtd-eeprom = <&factory 0x4>;
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
};
&spi0 {
@@ -58,7 +75,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
m25p,chunked-io = <32>;
@@ -82,7 +98,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
+ reg = <0x50000 0xfb0000>;
};
};
};
Index: sys/gnu/dts/mips/MLW221.dts
===================================================================
--- sys/gnu/dts/mips/MLW221.dts
+++ sys/gnu/dts/mips/MLW221.dts
@@ -2,8 +2,11 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mlw221", "ralink,mt7620n-soc";
+ compatible = "kingston,mlw221", "ralink,mt7620n-soc";
model = "Kingston MLW221";
gpio-leds {
@@ -11,12 +14,12 @@
system {
label = "mlw221:blue:system";
- gpios = <&gpio2 3 1>;
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
};
wifi {
label = "mlw221:blue:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -28,14 +31,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
system {
label = "system";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
};
};
@@ -60,7 +63,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl129p1";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MLWG2.dts
===================================================================
--- sys/gnu/dts/mips/MLWG2.dts
+++ sys/gnu/dts/mips/MLWG2.dts
@@ -2,8 +2,11 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mlwg2", "ralink,mt7620n-soc";
+ compatible = "kingston,mlwg2", "ralink,mt7620n-soc";
model = "Kingston MLWG2";
gpio-leds {
@@ -11,12 +14,12 @@
system {
label = "mlwg2:blue:system";
- gpios = <&gpio2 3 1>;
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
};
wifi {
label = "mlwg2:blue:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -28,14 +31,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
system {
label = "system";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
};
};
@@ -60,7 +63,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MOFI3500-3GN.dts
===================================================================
--- sys/gnu/dts/mips/MOFI3500-3GN.dts
+++ sys/gnu/dts/mips/MOFI3500-3GN.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MOFI3500-3GN", "ralink,rt3052-soc";
+ compatible = "mofinetwork,mofi3500-3gn", "ralink,rt3052-soc";
model = "MoFi Network MOFI3500-3GN";
cfi@1f000000 {
@@ -43,22 +46,22 @@
usb {
label = "mofi3500-3gn:green:usb";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
3g {
label = "mofi3500-3gn:green:3g";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
status {
label = "mofi3500-3gn:green:status";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "mofi3500-3gn:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -70,20 +73,20 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
connect {
label = "connect";
- gpios = <&gpio0 7 1>;
- linux,code = <0xda>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_CONNECT>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/MPRA1.dts
===================================================================
--- sys/gnu/dts/mips/MPRA1.dts
+++ sys/gnu/dts/mips/MPRA1.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MPRA1", "ralink,rt5350-soc";
+ compatible = "hame,mpr-a1", "ralink,rt5350-soc";
model = "HAME MPR-A1";
gpio-leds {
@@ -11,12 +14,12 @@
system {
label = "mpr-a1:blue:system";
- gpios = <&gpio0 20 1>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
power {
label = "mpr-a1:red:power";
- gpios = <&gpio0 17 1>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
wps {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -40,13 +43,13 @@
usb {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio0 7 0>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
root_hub {
gpio-export,name = "root_hub";
gpio-export,output = <1>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -59,7 +62,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MPRA2.dts
===================================================================
--- sys/gnu/dts/mips/MPRA2.dts
+++ sys/gnu/dts/mips/MPRA2.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MPRA2", "ralink,rt5350-soc";
+ compatible = "hame,mpr-a2", "ralink,rt5350-soc";
model = "HAME MPR-A2";
gpio-leds {
@@ -11,12 +14,12 @@
system {
label = "mpr-a2:blue:system";
- gpios = <&gpio0 20 1>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
power {
label = "mpr-a2:red:power";
- gpios = <&gpio0 17 1>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
wps {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -40,13 +43,13 @@
usb {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio0 7 0>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
root_hub {
gpio-export,name = "root_hub";
gpio-export,output = <1>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -59,7 +62,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MR-102N.dts
===================================================================
--- sys/gnu/dts/mips/MR-102N.dts
+++ sys/gnu/dts/mips/MR-102N.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MR-102N", "ralink,rt3052-soc";
+ compatible = "aximcom,mr-102n", "ralink,rt3052-soc";
model = "AXIMCom MR-102N";
cfi@1f000000 {
@@ -53,17 +56,17 @@
usb {
label = "mr-102n:green:usb";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
status {
label = "mr-102n:amber:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan {
label = "mr-102n:green:wlan";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
};
@@ -75,14 +78,14 @@
reset {
label = "reset";
- gpios = <&gpio0 13 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 18 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/MT7620a.dts
===================================================================
--- sys/gnu/dts/mips/MT7620a.dts
+++ sys/gnu/dts/mips/MT7620a.dts
@@ -2,6 +2,9 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "ralink,mt7620a-eval-board", "ralink,mt7620a-soc";
model = "Ralink MT7620a + MT7610e evaluation board";
@@ -14,14 +17,14 @@
s2 {
label = "S2";
- gpios = <&gpio0 1 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
s3 {
label = "S3";
- gpios = <&gpio0 2 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
@@ -34,7 +37,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MT7620a_MT7530.dts
===================================================================
--- sys/gnu/dts/mips/MT7620a_MT7530.dts
+++ sys/gnu/dts/mips/MT7620a_MT7530.dts
@@ -15,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MT7620a_MT7610e.dts
===================================================================
--- sys/gnu/dts/mips/MT7620a_MT7610e.dts
+++ sys/gnu/dts/mips/MT7620a_MT7610e.dts
@@ -2,6 +2,9 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "ralink,mt7620a-eval-board", "ralink,mt7620a-soc";
model = "Ralink MT7620A evaluation board";
@@ -14,14 +17,14 @@
wps {
label = "wps";
- gpios = <&gpio0 12 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
reset {
label = "reset";
- gpios = <&gpio0 13 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
@@ -38,7 +41,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <1000000>;
partition@0 {
Index: sys/gnu/dts/mips/MT7620a_V22SG.dts
===================================================================
--- sys/gnu/dts/mips/MT7620a_V22SG.dts
+++ sys/gnu/dts/mips/MT7620a_V22SG.dts
@@ -2,6 +2,9 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "ralink,mt7620a-eval-board", "ralink,mt7620a-soc";
model = "Ralink MT7620a V22SG High Power evaluation board";
@@ -14,14 +17,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
Index: sys/gnu/dts/mips/MT7621.dts
===================================================================
--- sys/gnu/dts/mips/MT7621.dts
+++ sys/gnu/dts/mips/MT7621.dts
@@ -14,35 +14,33 @@
chosen {
bootargs = "console=ttyS0,57600";
};
+};
- nand@1e003000 {
- partition@0 {
- label = "uboot";
- reg = <0x00000 0x80000>; /* 64 KB */
- };
+&nand {
+ status = "okay";
- partition@80000 {
- label = "uboot_env";
- reg = <0x80000 0x80000>; /* 64 KB */
- };
+ partition@0 {
+ label = "uboot";
+ reg = <0x00000 0x80000>; /* 64 KB */
+ };
- partition@100000 {
- label = "factory";
- reg = <0x100000 0x40000>;
- };
+ partition@80000 {
+ label = "uboot_env";
+ reg = <0x80000 0x80000>; /* 64 KB */
+ };
- partition@140000 {
- label = "rootfs";
- reg = <0x140000 0xec0000>;
- };
+ partition@100000 {
+ label = "factory";
+ reg = <0x100000 0x40000>;
};
-};
-&sdhci {
- status = "okay";
+ partition@140000 {
+ label = "rootfs";
+ reg = <0x140000 0xec0000>;
+ };
};
-&xhci {
+&sdhci {
status = "okay";
};
Index: sys/gnu/dts/mips/MT7628.dts
===================================================================
--- sys/gnu/dts/mips/MT7628.dts
+++ sys/gnu/dts/mips/MT7628.dts
@@ -15,7 +15,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "jtag";
+ ralink,group = "i2c";
ralink,function = "gpio";
};
};
@@ -33,7 +33,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
m25p,chunked-io = <32>;
Index: sys/gnu/dts/mips/MZK-750DHP.dts
===================================================================
--- sys/gnu/dts/mips/MZK-750DHP.dts
+++ sys/gnu/dts/mips/MZK-750DHP.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "planex,mzk-750dhp", "ralink,mt7620a-soc";
model = "Planex MZK-750DHP";
gpio-leds {
@@ -11,17 +14,17 @@
wps {
label = "mzk-750dhp:green:wps";
- gpios = <&gpio2 15 1>;
+ gpios = <&gpio2 15 GPIO_ACTIVE_LOW>;
};
power {
label = "mzk-750dhp:green:power";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
wlan5g {
label = "mzk-750dhp:green:wlan5g";
- gpios = <&gpio1 14 1>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
};
@@ -33,14 +36,14 @@
s1 {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
s2 {
label = "wps";
- gpios = <&gpio2 19 1>;
- linux,code = <0x211>;
+ gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -61,7 +64,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -121,7 +123,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
};
};
};
Index: sys/gnu/dts/mips/MZK-DP150N.dts
===================================================================
--- sys/gnu/dts/mips/MZK-DP150N.dts
+++ sys/gnu/dts/mips/MZK-DP150N.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MZK-DP150N", "ralink,rt5350-soc";
+ compatible = "planex,mzk-dp150n", "ralink,rt5350-soc";
model = "Planex MZK-DP150N";
gpio-leds {
@@ -11,7 +14,7 @@
power {
label = "mzk-dp150n:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -23,8 +26,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -41,7 +44,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MZK-EX300NP.dts
===================================================================
--- sys/gnu/dts/mips/MZK-EX300NP.dts
+++ sys/gnu/dts/mips/MZK-EX300NP.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "planex,mzk-ex300np", "ralink,mt7620a-soc";
model = "Planex MZK-EX300NP";
gpio-leds {
@@ -11,32 +14,32 @@
wifi {
label = "mzk-ex300np:green:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wps {
label = "mzk-ex300np:green:wps";
- gpios = <&gpio1 5 1>;
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
};
rep {
label = "mzk-ex300np:blue:rep";
- gpios = <&gpio1 4 1>;
+ gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
};
wifi1 {
label = "mzk-ex300np:blue:wifi1";
- gpios = <&gpio1 1 1>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
};
wifi2 {
label = "mzk-ex300np:blue:wifi2";
- gpios = <&gpio1 2 1>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
};
wifi3 {
label = "mzk-ex300np:blue:wifi3";
- gpios = <&gpio1 0 1>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
};
};
@@ -48,14 +51,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio1 3 0>;
- linux,code = <0x211>;
+ gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RFKILL>;
};
};
};
@@ -76,7 +79,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q64";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/MZK-EX750NP.dts
===================================================================
--- sys/gnu/dts/mips/MZK-EX750NP.dts
+++ sys/gnu/dts/mips/MZK-EX750NP.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "planex,mzk-ex750np", "ralink,mt7620a-soc";
model = "Planex MZK-EX750NP";
gpio-leds {
@@ -11,37 +14,37 @@
power {
label = "mzk-ex750np:red:power";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wifi {
label = "mzk-ex750np:red:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wps {
label = "mzk-ex750np:green:wps";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
rep {
label = "mzk-ex750np:blue:rep";
- gpios = <&gpio2 16 1>;
+ gpios = <&gpio2 16 GPIO_ACTIVE_LOW>;
};
wifi1 {
label = "mzk-ex750np:blue:wifi1";
- gpios = <&gpio2 19 1>;
+ gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
};
wifi2 {
label = "mzk-ex750np:blue:wifi2";
- gpios = <&gpio2 18 1>;
+ gpios = <&gpio2 18 GPIO_ACTIVE_LOW>;
};
wifi3 {
label = "mzk-ex750np:blue:wifi3";
- gpios = <&gpio2 17 1>;
+ gpios = <&gpio2 17 GPIO_ACTIVE_LOW>;
};
};
@@ -53,14 +56,14 @@
reset {
label = "reset";
- gpios = <&gpio0 9 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 13 0>;
- linux,code = <0x211>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RFKILL>;
};
};
};
@@ -81,7 +84,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -142,7 +144,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
};
};
};
Index: sys/gnu/dts/mips/MZK-W04N-XX.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/MZK-W04N-XX.dts
@@ -1,94 +0,0 @@
-/dts-v1/;
-
-#include "rt2880.dtsi"
-
-/ {
- compatible = "MZK-WNH", "ralink,rt2880-soc";
- model = "Planex MZK-WNH";
-
-/*
- memory@0 {
- device_type = "memory";
- reg = <0x0 0x2000000>;
- };
-*/
-
- cfi@1f000000 {
- compatible = "cfi-flash";
- reg = <0x1f000000 0x800000>;
- bank-width = <2>;
- device-width = <2>;
- #address-cells = <1>;
- #size-cells = <1>;
-
- partition@0 {
- label = "Bootloader";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- devdata: partition@30000 {
- label = "Config";
- reg = <0x00030000 0x00010000>;
- read-only;
- };
-
- factory: partition@40000 {
- label = "Factory";
- reg = <0x00040000 0x00010000>;
- read-only;
- };
- kernel: partition@50000 {
- label = "kernel";
- reg = <0x00050000 0x000f0000>;
- read-only;
- };
- rootfs: partition@160000 {
- label = "rootfs";
- reg = <0x00140000 0x002c0000>;
- read-only;
- };
- upgrade: partition@400000 {
- label = "upgrade";
- reg = <0x00050000 0x003b0000>;
- read-only;
- };
-
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- status {
- label = "status";
- gpios = <&gpio0 12 0>;
- };
-
- };
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
-
- };
-
- ip17x@0 {
- compatible = "icplus,ip17x";
- };
-
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x28>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
Index: sys/gnu/dts/mips/MZK-W300NH2.dts
===================================================================
--- sys/gnu/dts/mips/MZK-W300NH2.dts
+++ sys/gnu/dts/mips/MZK-W300NH2.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MZK-W300NH2", "ralink,rt3052-soc";
+ compatible = "planex,mzk-w300nh2", "ralink,rt3052-soc";
model = "Planex MZK-W300NH2";
cfi@1f000000 {
@@ -49,17 +52,17 @@
power {
label = "mzk-w300nh2:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan {
label = "mzk-w300nh2:amber:wlan";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wps {
label = "mzk-w300nh2:amber:wps";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
};
@@ -71,20 +74,20 @@
wps {
label = "wps";
- gpios = <&gpio0 12 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
rt {
label = "rt";
- gpios = <&gpio0 13 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
Index: sys/gnu/dts/mips/MZK-WDPR.dts
===================================================================
--- sys/gnu/dts/mips/MZK-WDPR.dts
+++ sys/gnu/dts/mips/MZK-WDPR.dts
@@ -2,8 +2,10 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+
/ {
- compatible = "MZK-WDPR", "ralink,rt3052-soc";
+ compatible = "planex,mzk-wdpr", "ralink,rt3052-soc";
model = "Planex MZK-WDPR";
chosen {
@@ -55,7 +57,7 @@
lcd_ctrl1 {
gpio-export,name = "lcd_ctrl1";
gpio-export,output = <0>;
- gpios = <&gpio0 1 0>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
};
};
};
Index: sys/gnu/dts/mips/MicroWRT.dts
===================================================================
--- sys/gnu/dts/mips/MicroWRT.dts
+++ sys/gnu/dts/mips/MicroWRT.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "microwrt", "ralink,mt7620a-soc";
+ compatible = "microduino,microwrt", "ralink,mt7620a-soc";
model = "Microduino MicroWRT";
chosen {
@@ -18,14 +21,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -46,7 +49,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/NA930.dts
===================================================================
--- sys/gnu/dts/mips/NA930.dts
+++ sys/gnu/dts/mips/NA930.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-eval-board", "ralink,mt7620a-soc";
+ compatible = "sercomm,na930", "ralink,mt7620a-soc";
model = "Sercomm NA930";
chosen {
@@ -47,20 +50,20 @@
reset {
label = "reset";
- gpios = <&gpio0 11 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
zwave {
label = "zwave";
- gpios = <&gpio0 12 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
wps {
label = "wps";
- gpios = <&gpio0 14 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -69,22 +72,22 @@
zwave {
label = "na930:blue:zwave";
- gpios = <&gpio2 0 1>;
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
};
status {
label = "na930:blue:status";
- gpios = <&gpio2 26 1>;
+ gpios = <&gpio2 26 GPIO_ACTIVE_LOW>;
};
service {
label = "na930:blue:service";
- gpios = <&gpio2 28 1>;
+ gpios = <&gpio2 28 GPIO_ACTIVE_LOW>;
};
power {
label = "na930:blue:power";
- gpios = <&gpio2 29 1>;
+ gpios = <&gpio2 29 GPIO_ACTIVE_LOW>;
};
};
@@ -95,7 +98,7 @@
telit {
gpio-export,name = "telit";
gpio-export,output = <1>;
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
};
};
Index: sys/gnu/dts/mips/NBG-419N.dts
===================================================================
--- sys/gnu/dts/mips/NBG-419N.dts
+++ sys/gnu/dts/mips/NBG-419N.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "NBG-419N", "ralink,rt3052-soc";
+ compatible = "zyxel,nbg-419n", "ralink,rt3052-soc";
model = "ZyXEL NBG-419N";
cfi@1f000000 {
@@ -43,12 +46,12 @@
power {
label = "nbg-419n:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps {
label = "nbg-419n:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -60,14 +63,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/NBG-419N2.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/NBG-419N2.dts
@@ -0,0 +1,119 @@
+/dts-v1/;
+
+#include "rt3352.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "zyxel,nbg-419n-v2", "ralink,rt3352-soc";
+ model = "ZyXEL NBG-419N v2";
+
+ palmbus@10000000 {
+ spi@b00 {
+ status = "okay";
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0 0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x7b0000>;
+ };
+ };
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "nbg-419n2:green:power";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "nbg-419n2:green:wps";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "nbg-419n2:green:usb";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ wps {
+ label = "wps";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ rfkill {
+ label = "rfkill";
+ linux,input-type = <EV_SW>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&esw {
+ mediatek,portmap = <0x2f>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/NCS601W.dts
===================================================================
--- sys/gnu/dts/mips/NCS601W.dts
+++ sys/gnu/dts/mips/NCS601W.dts
@@ -3,7 +3,7 @@
#include "rt5350.dtsi"
/ {
- compatible = "NCS601W", "ralink,rt5350-soc";
+ compatible = "wansview,ncs601w", "ralink,rt5350-soc";
model = "Wansview NCS601W";
};
@@ -15,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/NIXCORE-16M.dts
===================================================================
--- sys/gnu/dts/mips/NIXCORE-16M.dts
+++ sys/gnu/dts/mips/NIXCORE-16M.dts
@@ -1,6 +1,11 @@
/dts-v1/;
-#include "VOCORE.dtsi"
+#include "NIXCORE.dtsi"
+
+/ {
+ compatible = "nixcore,x1-16m", "nixcore,x1", "ralink,rt5350-soc";
+ model = "NixcoreX1 (16M)";
+};
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/NIXCORE-8M.dts
===================================================================
--- sys/gnu/dts/mips/NIXCORE-8M.dts
+++ sys/gnu/dts/mips/NIXCORE-8M.dts
@@ -1,6 +1,11 @@
/dts-v1/;
-#include "VOCORE.dtsi"
+#include "NIXCORE.dtsi"
+
+/ {
+ compatible = "nixcore,x1-8m", "nixcore,x1", "ralink,rt5350-soc";
+ model = "NixcoreX1 (8M)";
+};
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/NIXCORE.dtsi
===================================================================
--- sys/gnu/dts/mips/NIXCORE.dtsi
+++ sys/gnu/dts/mips/NIXCORE.dtsi
@@ -1,8 +1,13 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+
/ {
- compatible = "VoCore", "ralink,rt5350-soc";
- model = "VoCore";
+ compatible = "nixcore,x1", "ralink,rt5350-soc";
+
+ chosen {
+ bootargs = "console=ttyS1,57600";
+ };
gpio-export {
compatible = "gpio-export";
@@ -11,154 +16,119 @@
gpio0 {
gpio-export,name = "gpio0";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 0 0>;
- };
-
- /* UARTF */
- gpio7 {
- /* UARTF_RTS_N */
- gpio-export,name = "gpio7";
- gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 7 0>;
- };
-
- gpio8 {
- /* UARTF_TXD */
- gpio-export,name = "gpio8";
- gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 8 0>;
- };
-
- gpio9 {
- /* UARTF_CTS_N */
- gpio-export,name = "gpio9";
- gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 9 0>;
- };
-
- gpio12 {
- /* UARTF_DCD_N */
- gpio-export,name = "gpio12";
- gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 12 0>;
- };
-
- gpio13 {
- /* UARTF_DSR_N */
- gpio-export,name = "gpio13";
- gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
};
- gpio14 {
- /* UARTF_RIN */
- gpio-export,name = "gpio14";
+ gpio1 {
+ gpio-export,name = "gpio1";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 14 0>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_HIGH>;
};
+ /* GPIOs 1-6 are I2C,SPI */
+ /* GPIO 7-14 are uart1 */
+ /* GPIOs 15 & 16 are uart2 */
/* JTAG */
+
gpio17 {
/* JTAG_TDO */
gpio-export,name = "gpio17";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 17 0>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
};
gpio18 {
/* JTAG_TDI */
gpio-export,name = "gpio18";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 18 0>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>;
};
gpio19 {
/* JTAG_TMS */
gpio-export,name = "gpio19";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 19 0>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_HIGH>;
};
gpio20 {
/* JTAG_TCLK */
gpio-export,name = "gpio20";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 20 0>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_HIGH>;
};
gpio21 {
/* JTAG_TRST_N */
gpio-export,name = "gpio21";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 21 0>;
+ gpios = <&gpio0 21 GPIO_ACTIVE_HIGH>;
};
/* ETH LEDs */
+ /*
gpio22 {
- /* ETH0_LED */
gpio-export,name = "gpio22";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 0 0>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_HIGH>;
};
gpio23 {
- /* ETH1_LED */
gpio-export,name = "gpio23";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 1 0>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_HIGH>;
};
gpio24 {
- /* ETH2_LED */
gpio-export,name = "gpio24";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 2 0>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
};
gpio25 {
- /* ETH3_LED */
gpio-export,name = "gpio25";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 3 0>;
+ gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
};
+ */
gpio26 {
/* ETH4_LED */
gpio-export,name = "gpio26";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 4 0>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- status {
- /* UARTF_RXD */
- label = "vocore:green:status";
- gpios = <&gpio0 10 0>;
+ gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
};
- eth {
- /* UARTF_DTR_N */
- label = "vocore:orange:eth";
- gpios = <&gpio0 11 0>;
+ gpio27 {
+ /* spi_cs1 */
+ gpio-export,name = "gpio27";
+ gpio-export,direction_may_change = <1>;
+ gpios = <&gpio1 5 GPIO_ACTIVE_HIGH>;
};
};
};
+&gpio0 {
+ status = "okay";
+};
+
&gpio1 {
- status = "okay";
+ status = "okay";
};
&i2c {
- status = "okay";
+ status = "okay";
+};
+
+&uart {
+ status = "okay";
+ reset-names = "gpio uartf";
};
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "jtag", "uartf", "led";
+ ralink,group = "jtag", "led", "spi_cs1";
ralink,function = "gpio";
};
};
@@ -169,8 +139,7 @@
};
&esw {
- mediatek,portmap = <0x11>;
- mediatek,portdisable = <0x2e>;
+ mediatek,portmap = <0x17>;
};
&wmac {
@@ -184,13 +153,3 @@
&ohci {
status = "okay";
};
-
-&spi1 {
- status = "okay";
-
- spidev@0 {
- compatible = "linux,spidev";
- spi-max-frequency = <10000000>;
- reg = <0>;
- };
-};
Index: sys/gnu/dts/mips/NW718.dts
===================================================================
--- sys/gnu/dts/mips/NW718.dts
+++ sys/gnu/dts/mips/NW718.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "NW718", "ralink,rt3050-soc";
+ compatible = "netcore,nw718", "ralink,rt3050-soc";
model = "Netcore NW718";
gpio-leds {
@@ -11,17 +14,17 @@
cpu {
label = "nw718:amber:cpu";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
usb {
label = "nw718:amber:usb";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
wps {
label = "nw718:amber:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -33,14 +36,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -53,7 +56,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <25000000>;
partition@0 {
Index: sys/gnu/dts/mips/Newifi-D1.dts
===================================================================
--- sys/gnu/dts/mips/Newifi-D1.dts
+++ sys/gnu/dts/mips/Newifi-D1.dts
@@ -2,28 +2,38 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "ZBT-WG2626";
+ compatible = "lenovo,newifi-d1", "mediatek,mt7621-soc";
+ model = "Newifi-D1";
memory@0 {
device_type = "memory";
- reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
+ reg = <0x0 0x10000000>;
};
chosen {
bootargs = "console=ttyS0,115200";
};
- palmbus: palmbus@1E000000 {
- i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
- status = "okay";
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status-red {
+ label = "newifi-d1:red:status";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ status-green {
+ label = "newifi-d1:green:status";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+
+ statys-blue {
+ label = "newifi-d1:blue:status";
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
};
};
@@ -35,23 +45,34 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
- gpio-leds {
- compatible = "gpio-leds";
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
- status {
- label = "zbt-wg2626:green:status";
- gpios = <&gpio0 24 1>;
+ usb2power {
+ gpio-export,name = "usb2power";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
+ };
+
+ usb3power {
+ gpio-export,name = "usb3power";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
};
};
};
&sdhci {
status = "okay";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&sdhci_pins>;
};
&spi0 {
@@ -62,8 +83,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -85,7 +106,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0xfb0000>;
+ reg = <0x50000 0x1fb0000>;
};
};
};
@@ -98,7 +119,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -107,7 +128,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
};
};
};
@@ -119,7 +139,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "wdt rst", "jtag", "mdio";
+ ralink,group = "wdt", "rgmii2", "jtag", "uart2", "uart3", "i2c";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/Newifi-D2.dts
===================================================================
--- sys/gnu/dts/mips/Newifi-D2.dts
+++ sys/gnu/dts/mips/Newifi-D2.dts
@@ -2,63 +2,58 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "PBR-M1";
+ compatible = "d-team,newifi-d2", "mediatek,mt7621-soc";
+ model = "Newifi-D2";
memory@0 {
device_type = "memory";
- reg = <0x0 0x10000000>;
+ reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
};
chosen {
bootargs = "console=ttyS0,115200";
};
- palmbus: palmbus@1E000000 {
- i2c: i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
- status = "okay";
-
- pcf8563: rtc@51 {
- status = "okay";
- compatible = "nxp,pcf8563";
- reg = <0x51>;
- };
- };
- };
-
gpio-leds {
compatible = "gpio-leds";
- power {
- label = "pbr-m1:blue:power";
- gpios = <&gpio0 31 1>;
+ power-amber {
+ label = "newifi-d2:amber:power";
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
};
- sys {
- label = "pbr-m1:blue:sys";
- gpios = <&gpio1 0 1>;
+ power-blue {
+ label = "newifi-d2:blue:power";
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
};
- internet {
- label = "pbr-m1:blue:internet";
- gpios = <&gpio0 29 1>;
+ internet-amber {
+ label = "newifi-d2:amber:internet";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
+ };
+
+ internet-blue {
+ label = "newifi-d2:blue:internet";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
wlan2g {
- label = "pbr-m1:blue:wlan2g";
- gpios = <&gpio1 1 1>;
+ label = "newifi-d2:blue:wlan2g";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
wlan5g {
- label = "pbr-m1:blue:wlan5g";
- gpios = <&gpio0 28 1>;
+ label = "newifi-d2:blue:wlan5g";
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "newifi-d2:blue:usb";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
};
@@ -70,8 +65,14 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -79,39 +80,12 @@
compatible = "gpio-export";
#size-cells = <0>;
- power_usb2 {
- gpio-export,name = "power_usb2";
- gpio-export,output = <1>;
- gpios = <&gpio0 22 0>;
- };
-
power_usb3 {
gpio-export,name = "power_usb3";
gpio-export,output = <1>;
- gpios = <&gpio0 25 0>;
- };
-
- power_sata {
- gpio-export,name = "power_sata";
- gpio-export,output = <1>;
- gpios = <&gpio0 27 0>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
};
};
-
- beeper: beeper {
- compatible = "gpio-beeper";
- gpios = <&gpio0 26 1>;
- };
-};
-
-&sdhci {
- status = "okay";
- pinctrl-names = "default";
- pinctrl-0 = <&sdhci_pins>;
-};
-
-&xhci {
- status = "okay";
};
&spi0 {
@@ -122,8 +96,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -145,7 +119,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0xfb0000>;
+ reg = <0x50000 0x1fb0000>;
};
};
};
@@ -158,7 +132,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -167,7 +141,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
};
};
};
@@ -176,12 +149,10 @@
mtd-mac-address = <&factory 0xe000>;
};
-
-
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "jtag", "mdio";
+ ralink,group = "i2c", "jtag", "uart2", "uart3";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/OMEGA2.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/OMEGA2.dts
@@ -0,0 +1,21 @@
+/dts-v1/;
+
+#include "OMEGA2.dtsi"
+
+/ {
+ compatible = "onion,omega2", "mediatek,mt7628an-soc";
+ model = "Onion Omega2";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
+};
+
+&firmware {
+ reg = <0x50000 0xfb0000>;
+};
+
+&system_led {
+ label = "omega2:amber:system";
+};
Index: sys/gnu/dts/mips/OMEGA2.dtsi
===================================================================
--- sys/gnu/dts/mips/OMEGA2.dtsi
+++ sys/gnu/dts/mips/OMEGA2.dtsi
@@ -1,37 +1,20 @@
-/dts-v1/;
-
#include "mt7628an.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,linkit", "mediatek,mt7628an-soc";
- model = "MediaTek LinkIt Smart 7688";
+ compatible = "onion,omega2", "mediatek,mt7628an-soc";
chosen {
- bootargs = "console=ttyS2,57600";
- };
-
- aliases {
- serial0 = &uart2;
- };
-
- memory@0 {
- device_type = "memory";
- reg = <0x0 0x8000000>;
- };
-
- bootstrap {
- compatible = "mediatek,linkit";
-
- status = "okay";
+ bootargs = "console=ttyS0,115200";
};
gpio-leds {
compatible = "gpio-leds";
- wifi {
- label = "mediatek:orange:wifi";
- gpios = <&wgpio 0 0>;
- default-state = "on";
+ system_led: system {
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
};
};
@@ -41,20 +24,12 @@
#size-cells = <0>;
poll-interval = <20>;
- wps {
+ reset {
label = "reset";
- gpios = <&gpio1 6 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
-
- wgpio: gpio-wifi {
- compatible = "mediatek,gpio-wifi";
- #address-cells = <1>;
- #size-cells = <0>;
- gpio-controller;
- #gpio-cells = <2>;
- };
};
&pinctrl {
@@ -91,17 +66,31 @@
wled_an {
ralink,group = "wled_an";
- ralink,function = "wled_an";
+ ralink,function = "gpio";
};
wdt {
ralink,group = "wdt";
ralink,function = "gpio";
};
+
+ pwm0 {
+ ralink,group = "pwm0";
+ ralink,function = "gpio";
+ };
+
+ pwm1 {
+ ralink,group = "pwm1";
+ ralink,function = "gpio";
+ };
};
};
-&wmac {
+&gpio1 {
+ status = "okay";
+};
+
+&gpio2 {
status = "okay";
};
@@ -116,7 +105,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l25635e";
spi-max-frequency = <40000000>;
m25p,chunked-io = <31>;
@@ -129,6 +117,7 @@
partition@30000 {
label = "u-boot-env";
reg = <0x30000 0x10000>;
+ read-only;
};
factory: partition@40000 {
@@ -137,9 +126,8 @@
read-only;
};
- partition@50000 {
+ firmware: partition@50000 {
label = "firmware";
- reg = <0x50000 0x1fb0000>;
};
};
@@ -164,17 +152,13 @@
status = "okay";
};
-&pwm {
- status = "okay";
-};
-
&ethernet {
mtd-mac-address = <&factory 0x28>;
};
&sdhci {
status = "okay";
- mediatek,cd-high;
+ mediatek,cd-low;
};
&wmac {
Index: sys/gnu/dts/mips/OMEGA2P.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/OMEGA2P.dts
@@ -0,0 +1,21 @@
+/dts-v1/;
+
+#include "OMEGA2.dtsi"
+
+/ {
+ compatible = "onion,omega2p", "onion,omega2", "mediatek,mt7628an-soc";
+ model = "Onion Omega2+";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+};
+
+&firmware {
+ reg = <0x50000 0x1fb0000>;
+};
+
+&system_led {
+ label = "omega2p:amber:system";
+};
Index: sys/gnu/dts/mips/OY-0001.dts
===================================================================
--- sys/gnu/dts/mips/OY-0001.dts
+++ sys/gnu/dts/mips/OY-0001.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "ohyeah,oy-0001", "ralink,mt7620a-soc";
model = "OY-0001";
chosen {
@@ -15,12 +18,12 @@
powerled {
label = "oy-0001:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wifiled {
label = "oy-0001:green:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -32,8 +35,8 @@
s1 {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -54,7 +57,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/PBR-D1.dts
===================================================================
--- sys/gnu/dts/mips/PBR-D1.dts
+++ sys/gnu/dts/mips/PBR-D1.dts
@@ -2,12 +2,15 @@
#include "mt7628an.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,linkit", "mediatek,mt7628an-soc";
- model = "MediaTek LinkIt Smart 7688";
+ compatible = "d-team,pbr-d1", "mediatek,mt7628an-soc";
+ model = "PBR-D1";
chosen {
- bootargs = "console=ttyS2,57600";
+ bootargs = "console=ttyS0,115200";
};
aliases {
@@ -19,18 +22,18 @@
reg = <0x0 0x8000000>;
};
- bootstrap {
- compatible = "mediatek,linkit";
-
- status = "okay";
- };
-
gpio-leds {
compatible = "gpio-leds";
- wifi {
- label = "mediatek:orange:wifi";
- gpios = <&wgpio 0 0>;
+ usb {
+ label = "pbr-d1:orange:usb";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ default-state = "off";
+ };
+
+ power {
+ label = "pbr-d1:orange:power";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
default-state = "on";
};
};
@@ -41,10 +44,10 @@
#size-cells = <0>;
poll-interval = <20>;
- wps {
+ reset {
label = "reset";
- gpios = <&gpio1 6 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 38 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -64,13 +67,8 @@
ralink,function = "gpio";
};
- perst {
- ralink,group = "perst";
- ralink,function = "gpio";
- };
-
- refclk {
- ralink,group = "refclk";
+ i2c {
+ ralink,group = "i2c";
ralink,function = "gpio";
};
@@ -84,16 +82,6 @@
ralink,function = "gpio";
};
- wled_kn {
- ralink,group = "wled_kn";
- ralink,function = "gpio";
- };
-
- wled_an {
- ralink,group = "wled_an";
- ralink,function = "wled_an";
- };
-
wdt {
ralink,group = "wdt";
ralink,function = "gpio";
@@ -101,10 +89,6 @@
};
};
-&wmac {
- status = "okay";
-};
-
&spi0 {
status = "okay";
@@ -116,7 +100,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l25635e";
spi-max-frequency = <40000000>;
m25p,chunked-io = <31>;
@@ -139,7 +122,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x1fb0000>;
+ reg = <0x50000 0x0fb0000>;
};
};
@@ -176,7 +159,3 @@
status = "okay";
mediatek,cd-high;
};
-
-&wmac {
- status = "okay";
-};
Index: sys/gnu/dts/mips/PBR-M1.dts
===================================================================
--- sys/gnu/dts/mips/PBR-M1.dts
+++ sys/gnu/dts/mips/PBR-M1.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
+ compatible = "d-team,pbr-m1", "mediatek,mt7621-soc";
model = "PBR-M1";
memory@0 {
@@ -17,12 +20,6 @@
palmbus: palmbus@1E000000 {
i2c: i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
status = "okay";
pcf8563: rtc@51 {
@@ -38,27 +35,27 @@
power {
label = "pbr-m1:blue:power";
- gpios = <&gpio0 31 1>;
+ gpios = <&gpio0 31 GPIO_ACTIVE_LOW>;
};
sys {
label = "pbr-m1:blue:sys";
- gpios = <&gpio1 0 1>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
};
internet {
label = "pbr-m1:blue:internet";
- gpios = <&gpio0 29 1>;
+ gpios = <&gpio0 29 GPIO_ACTIVE_LOW>;
};
wlan2g {
label = "pbr-m1:blue:wlan2g";
- gpios = <&gpio1 1 1>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
};
wlan5g {
label = "pbr-m1:blue:wlan5g";
- gpios = <&gpio0 28 1>;
+ gpios = <&gpio0 28 GPIO_ACTIVE_LOW>;
};
};
@@ -70,8 +67,8 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -82,25 +79,25 @@
power_usb2 {
gpio-export,name = "power_usb2";
gpio-export,output = <1>;
- gpios = <&gpio0 22 0>;
+ gpios = <&gpio0 22 GPIO_ACTIVE_HIGH>;
};
power_usb3 {
gpio-export,name = "power_usb3";
gpio-export,output = <1>;
- gpios = <&gpio0 25 0>;
+ gpios = <&gpio0 25 GPIO_ACTIVE_HIGH>;
};
power_sata {
gpio-export,name = "power_sata";
gpio-export,output = <1>;
- gpios = <&gpio0 27 0>;
+ gpios = <&gpio0 27 GPIO_ACTIVE_HIGH>;
};
};
beeper: beeper {
compatible = "gpio-beeper";
- gpios = <&gpio0 26 1>;
+ gpios = <&gpio0 26 GPIO_ACTIVE_LOW>;
};
};
@@ -110,10 +107,6 @@
pinctrl-0 = <&sdhci_pins>;
};
-&xhci {
- status = "okay";
-};
-
&spi0 {
status = "okay";
@@ -122,8 +115,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -158,7 +151,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -167,7 +160,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
};
};
};
@@ -176,8 +168,6 @@
mtd-mac-address = <&factory 0xe000>;
};
-
-
&pinctrl {
state_default: pinctrl0 {
gpio {
Index: sys/gnu/dts/mips/PSG1208.dts
===================================================================
--- sys/gnu/dts/mips/PSG1208.dts
+++ sys/gnu/dts/mips/PSG1208.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "PSG1208", "ralink,mt7620a-soc";
+ compatible = "phicomm,psg1208", "ralink,mt7620a-soc";
model = "Phicomm PSG1208";
gpio-leds {
@@ -11,12 +14,12 @@
wan {
label = "psg1208:white:wps";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
wlan {
label = "psg1208:white:wlan2g";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -50,7 +53,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -81,7 +83,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "ephy", "wled", "nd_sd";
+ ralink,group = "i2c", "spi refclk", "wled";
ralink,function = "gpio";
};
};
@@ -102,7 +104,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
Index: sys/gnu/dts/mips/PSG1218.dtsi
===================================================================
--- sys/gnu/dts/mips/PSG1218.dtsi
+++ sys/gnu/dts/mips/PSG1218.dtsi
@@ -1,9 +1,10 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- chosen {
- bootargs = "console=ttyS0,115200";
- };
+ compatible = "phicomm,psg1218", "ralink,mt7620a-soc";
gpio-keys-polled {
compatible = "gpio-keys-polled";
@@ -13,21 +14,13 @@
reset {
label = "reset";
- gpios = <&gpio0 11 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
-
-&gpio0 {
- status = "okay";
-};
-&gpio2 {
- status = "okay";
-};
-
-&gpio3 {
+&gpio0 {
status = "okay";
};
@@ -39,7 +32,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -48,33 +40,25 @@
read-only;
};
- partition@30000 {
+ partition@20000 {
label = "u-boot-env";
reg = <0x30000 0x10000>;
read-only;
};
- factory: partition@40000 {
+ factory: partition@30000 {
label = "factory";
reg = <0x40000 0x10000>;
read-only;
};
- partition@50000 {
+ partition@40000 {
label = "firmware";
- reg = <0x50000 0xfb0000>;
+ reg = <0x50000 0x7b0000>;
};
};
};
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
&pcie {
status = "okay";
@@ -83,25 +67,11 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
-
+
&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "uartf", "wled", "nd_sd";
- ralink,function = "gpio";
- };
-
- pa {
- ralink,group = "pa";
- ralink,function = "pa";
- };
- };
-};
Index: sys/gnu/dts/mips/PSG1218A.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/PSG1218A.dts
@@ -0,0 +1,47 @@
+/dts-v1/;
+
+#include "PSG1218.dtsi"
+
+/ {
+ compatible = "phicomm,psg1218a", "phicomm,psg1218", "ralink,mt7620a-soc";
+ model = "Phicomm PSG1218 rev.A";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+ blue {
+ label = "psg1218a:blue:status";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ yellow {
+ label = "psg1218a:yellow:status";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ red {
+ label = "psg1218a:red:status";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ pinctrl-names = "default";
+ pinctrl-0 = <&ephy_pins>;
+ mtd-mac-address = <&factory 0x28>;
+ mediatek,portmap = "llllw";
+};
+
+&wmac {
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
+};
Index: sys/gnu/dts/mips/PSG1218B.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/PSG1218B.dts
@@ -0,0 +1,42 @@
+/dts-v1/;
+
+#include "PSG1218.dtsi"
+
+/ {
+ compatible = "phicomm,psg1218b", "phicomm,psg1218", "ralink,mt7620a-soc";
+ model = "Phicomm PSG1218 rev.B";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+ blue {
+ label = "psg1218b:blue:status";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ yellow {
+ label = "psg1218b:yellow:status";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ red {
+ label = "psg1218b:red:status";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd", "pa";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ pinctrl-names = "default";
+ pinctrl-0 = <&ephy_pins>;
+ mtd-mac-address = <&factory 0x28>;
+ mediatek,portmap = "llllw";
+};
Index: sys/gnu/dts/mips/PSR-680W.dts
===================================================================
--- sys/gnu/dts/mips/PSR-680W.dts
+++ sys/gnu/dts/mips/PSR-680W.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "PSR-680W", "ralink,rt3052-soc";
+ compatible = "petatel,psr-680w", "ralink,rt3052-soc";
model = "Petatel PSR-680W Wireless 3G Router";
chosen {
@@ -47,7 +50,7 @@
wan {
label = "psr-680w:red:wan";
- gpios = <&gpio0 19 1>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
};
@@ -59,8 +62,8 @@
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/PWH2004.dts
===================================================================
--- sys/gnu/dts/mips/PWH2004.dts
+++ sys/gnu/dts/mips/PWH2004.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "PWH2004", "ralink,rt3052-soc";
+ compatible = "prolink,pwh2004", "ralink,rt3052-soc";
model = "Prolink PWH2004";
cfi@1f000000 {
@@ -43,12 +46,12 @@
wifi {
label = "pwh2004:red:wifi";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
power {
label = "pwh2004:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -60,8 +63,8 @@
wps {
label = "wps";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/PX-4885-4M.dts
===================================================================
--- sys/gnu/dts/mips/PX-4885-4M.dts
+++ sys/gnu/dts/mips/PX-4885-4M.dts
@@ -2,6 +2,11 @@
#include "PX-4885.dtsi"
+/ {
+ compatible = "7links,px-4885-4m", "7links,px-4885", "ralink,rt5350-soc";
+ model = "7Links PX-4885 (4M)";
+};
+
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/PX-4885-8M.dts
===================================================================
--- sys/gnu/dts/mips/PX-4885-8M.dts
+++ sys/gnu/dts/mips/PX-4885-8M.dts
@@ -2,6 +2,11 @@
#include "PX-4885.dtsi"
+/ {
+ compatible = "7links,px-4885-8m", "7links,px-4885", "ralink,rt5350-soc";
+ model = "7Links PX-4885 (8M)";
+};
+
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/PX-4885.dtsi
===================================================================
--- sys/gnu/dts/mips/PX-4885.dtsi
+++ sys/gnu/dts/mips/PX-4885.dtsi
@@ -1,8 +1,10 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "PX-4885", "ralink,rt5350-soc";
- model = "7Links PX-4885";
+ compatible = "7links,px-4885", "ralink,rt5350-soc";
gpio-keys-polled {
compatible = "gpio-keys-polled";
@@ -12,8 +14,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -22,12 +24,12 @@
orange {
label = "px-4885:orange:wifi";
- gpios = <&gpio0 18 1>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
};
blue {
label = "px-4885:blue:storage";
- gpios = <&gpio0 19 1>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/R6220.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/R6220.dts
@@ -0,0 +1,158 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "netgear,r6220", "mediatek,mt7621-soc";
+ model = "Netgear R6220";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "r6220:green:power";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "r6220:green:usb";
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
+ };
+
+ internet {
+ label = "r6220:green:wan";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+
+ wifi {
+ label = "r6220:green:wifi";
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "r6220:green:wps";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ wifi {
+ label = "wifi";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RFKILL>;
+ };
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ usbpower {
+ gpio-export,name = "usbpower";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&nand {
+ status = "okay";
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x100000>;
+ read-only;
+ };
+
+ partition@100000 {
+ label = "SC PID";
+ reg = <0x100000 0x100000>;
+ read-only;
+ };
+
+ partition@200000 {
+ label = "kernel";
+ reg = <0x200000 0x400000>;
+ };
+
+ partition@600000 {
+ label = "ubi";
+ reg = <0x600000 0x1c00000>;
+ };
+
+ factory: partition@2e00000 {
+ label = "factory";
+ reg = <0x2e00000 0x100000>;
+ read-only;
+ };
+
+ partition@4200000 {
+ label = "reserved";
+ reg = <0x4200000 0x3c00000>;
+ read-only;
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie0 {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+
+ pcie1 {
+ mt76@1,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x0000>;
+ ieee80211-freq-limit = <2400000 2500000>;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x00000004>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "uart3", "jtag";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/RB750Gr3.dts
===================================================================
--- sys/gnu/dts/mips/RB750Gr3.dts
+++ sys/gnu/dts/mips/RB750Gr3.dts
@@ -2,13 +2,16 @@
#include "mt7621.dtsi"
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "Firefly FireWRT";
+ compatible = "mikrotik,rb750gr3", "mediatek,mt7621-soc";
+ model = "MikroTik RB750Gr3";
memory@0 {
device_type = "memory";
- reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
+ reg = <0x0 0x10000000>;
};
chosen {
@@ -18,9 +21,14 @@
gpio-leds {
compatible = "gpio-leds";
- power {
- label = "firewrt:green:power";
- gpios = <&gpio0 22 1>;
+ pwr {
+ label = "rb750gr3:blue:pwr";
+ gpios = <&gpio0 16 GPIO_ACTIVE_HIGH>;
+ };
+
+ usr {
+ label = "rb750gr3:green:usr";
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
};
};
@@ -30,22 +38,35 @@
#size-cells = <0>;
poll-interval = <20>;
- wps {
- label = "wps";
- gpios = <&gpio0 18 1>;
- linux,code = <0x211>;
+ mode {
+ label = "mode";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
- power {
- label = "power";
- gpios = <&gpio0 23 1>;
- linux,code = <116>;
+ res {
+ label = "res";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
-};
-&sdhci {
- status = "okay";
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ buzzer {
+ gpio-export,name = "buzzer";
+ gpio-export,output = <0>;
+ gpios = <&gpio0 15 GPIO_ACTIVE_HIGH>;
+ };
+
+ usb {
+ gpio-export,name = "usb";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ };
+ };
};
&spi0 {
@@ -56,8 +77,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -81,40 +102,24 @@
label = "firmware";
reg = <0x50000 0xfb0000>;
};
- };
-};
-
-&pcie {
- status = "okay";
-
- pcie0 {
- mt76@0,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
- };
- };
- pcie1 {
- mt76@1,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
- };
};
};
&ethernet {
mtd-mac-address = <&factory 0xe000>;
+ mtd-mac-address-increment = <1>;
};
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2";
+ ralink,group = "i2c", "uart2", "uart3", "pcie", "rgmii2", "jtag";
ralink,function = "gpio";
};
};
};
+
+&sdhci {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/RBM33G.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/RBM33G.dts
@@ -0,0 +1,156 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "mikrotik,rbm33g", "mediatek,mt7621-soc";
+ model = "MikroTik RBM33G";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ usr {
+ label = "rbm33g:green:usr";
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
+ };
+
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ res {
+ label = "res";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ pcie0_vcc_reg {
+ compatible = "regulator-fixed";
+ regulator-name = "pcie0_vcc";
+
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ gpio = <&gpio0 9 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ regulator-boot-on;
+ regulator-always-on;
+ };
+
+ pcie1_vcc_reg {
+ compatible = "regulator-fixed";
+ regulator-name = "pcie1_vcc";
+
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ gpio = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ regulator-boot-on;
+ regulator-always-on;
+ };
+
+ pcie2_vcc_reg {
+ compatible = "regulator-fixed";
+ regulator-name = "pcie2_vcc";
+
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ gpio = <&gpio0 11 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ regulator-boot-on;
+ regulator-always-on;
+ };
+
+ usb_vcc_reg {
+ compatible = "regulator-fixed";
+ regulator-name = "usb_vcc";
+
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+ gpio = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ regulator-always-on;
+ };
+};
+
+
+&spi0 {
+ status = "okay";
+
+ w25q40@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <3125000>;
+
+ partition@0 {
+ label = "routerboot";
+ reg = <0x0 0xf000>;
+ read-only;
+ };
+
+ factory: partition@f000 {
+ label = "factory";
+ reg = <0xf000 0x71000>;
+ read-only;
+ };
+
+ };
+
+ w25q128@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <1>;
+ spi-max-frequency = <3125000>;
+
+ partition@40000 {
+ label = "firmware";
+ reg = <0x040000 0xFC0000>;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x0010>;
+ mtd-mac-address-increment = <1>;
+};
+
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "uart2", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&sdhci {
+ status = "okay";
+};
+
+&i2c {
+ status = "okay";
+};
+
+&pcie {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/RE350.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/RE350.dts
@@ -0,0 +1,164 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,re350-v1", "mediatek,mt7621-soc";
+ model = "TP-LINK RE350 v1";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "re350-v1:blue:power";
+ gpios = <&gpio0 22 GPIO_ACTIVE_LOW>;
+ };
+
+ wifi2g {
+ label = "re350-v1:blue:wifi2G";
+ gpios = <&gpio0 23 GPIO_ACTIVE_LOW>;
+ };
+
+ wifi5g {
+ label = "re350-v1:blue:wifi5G";
+ gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
+ };
+
+ wps_r {
+ label = "re350-v1:red:wps";
+ gpios = <&gpio0 25 GPIO_ACTIVE_HIGH>;
+ };
+
+ wps_b {
+ label = "re350-v1:blue:wps";
+ gpios = <&gpio0 26 GPIO_ACTIVE_HIGH>;
+ };
+
+ eth {
+ label = "re350-v1:green:eth_act";
+ gpios = <&gpio0 28 GPIO_ACTIVE_LOW>;
+ };
+
+ eth2 {
+ label = "re350-v1:green:eth_link";
+ gpios = <&gpio0 29 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ led {
+ label = "led";
+ gpios = <&gpio0 30 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ };
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 31 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ power {
+ label = "power";
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_POWER>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ w25q64@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x20000>;
+ read-only;
+ };
+
+ partition@20000 {
+ label = "firmware";
+ reg = <0x20000 0x5e0000>;
+ };
+
+ config: partition@600000 {
+ label = "config";
+ reg = <0x600000 0x50000>;
+ read-only;
+ };
+
+ radio: partition@7f0000 {
+ label = "radio";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie0 {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&radio 0>;
+ mtd-mac-address = <&config 0x10008>;
+ mtd-mac-address-increment = <1>;
+ };
+ };
+
+ pcie1 {
+ mt76@1,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&radio 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ mtd-mac-address = <&config 0x10008>;
+ mtd-mac-address-increment = <2>;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&config 0x10008>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "rgmii2", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/RE6500.dts
===================================================================
--- sys/gnu/dts/mips/RE6500.dts
+++ sys/gnu/dts/mips/RE6500.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
+ compatible = "linksys,re6500", "mediatek,mt7621-soc";
model = "Linksys RE6500";
memory@0 {
@@ -20,12 +23,12 @@
wifi {
label = "re6500:orange:wifi";
- gpios = <&gpio0 0 0>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
};
power {
label = "re6500:white:power";
- gpios = <&gpio0 9 0>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
};
};
@@ -37,14 +40,14 @@
wps {
label = "wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 11 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -57,8 +60,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -102,7 +105,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -111,7 +114,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
@@ -119,3 +122,7 @@
&ethernet {
mtd-mac-address = <&factory 0x2e>;
};
+
+&xhci {
+ status = "disabled";
+};
Index: sys/gnu/dts/mips/RP-N53.dts
===================================================================
--- sys/gnu/dts/mips/RP-N53.dts
+++ sys/gnu/dts/mips/RP-N53.dts
@@ -2,6 +2,9 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "asus,rp-n53", "ralink,mt7620a-soc";
model = "Asus RP-N53";
@@ -14,26 +17,26 @@
touch {
label = "touch";
- gpios = <&gpio1 0 1>;
- linux,code = <0x100>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
wps {
label = "wps";
- gpios = <&gpio1 1 1>;
- linux,code = <0x100>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
reset {
label = "reset";
- gpios = <&gpio1 2 1>;
- linux,code = <0x100>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
audio {
label = "audio";
- gpios = <&gpio1 3 0>;
- linux,code = <0x101>;
+ gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_1>;
};
};
@@ -42,42 +45,42 @@
backlight {
label = "rp-n53:white:back";
- gpios = <&gpio1 4 1>;
+ gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
};
wifi0 {
label = "rp-n53:blue:5g3";
- gpios = <&gpio1 5 1>;
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
};
wifi1 {
label = "rp-n53:blue:5g2";
- gpios = <&gpio1 6 1>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
};
wifi2 {
label = "rp-n53:blue:5g1";
- gpios = <&gpio1 7 1>;
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
};
wifi3 {
label = "rp-n53:blue:wifi";
- gpios = <&gpio1 8 1>;
+ gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
};
wifi4 {
label = "rp-n53:blue:2g1";
- gpios = <&gpio1 9 1>;
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
};
wifi5 {
label = "rp-n53:blue:2g2";
- gpios = <&gpio1 10 1>;
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
};
wifi6 {
label = "rp-n53:blue:2g3";
- gpios = <&gpio1 11 1>;
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
};
};
};
@@ -104,7 +107,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
partition@0 {
@@ -161,4 +163,13 @@
&pcie {
status = "okay";
+
+ pcie-bridge {
+ wifi@1814,5592 {
+ compatible = "pci1814,5592";
+ reg = <0x0000 0 0 0 0>;
+ ralink,2ghz = <0>;
+ ralink,mtd-eeprom = <&factory 0x8000>;
+ };
+ };
};
Index: sys/gnu/dts/mips/RT-AC51U.dts
===================================================================
--- sys/gnu/dts/mips/RT-AC51U.dts
+++ sys/gnu/dts/mips/RT-AC51U.dts
@@ -1,37 +1,30 @@
/dts-v1/;
-#include "mt7620n.dtsi"
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
- compatible = "asus,rt-n14u", "ralink,mt7620n-soc";
- model = "Asus RT-N14U";
+ compatible = "asus,rt-ac51u", "ralink,mt7620a-soc";
+ model = "Asus RT-AC51U";
gpio-leds {
compatible = "gpio-leds";
- wan {
- label = "rt-n14u:blue:wan";
- gpios = <&gpio2 0 1>;
- };
-
- lan {
- label = "rt-n14u:blue:lan";
- gpios = <&gpio2 1 1>;
+ power {
+ label = "rt-ac51u:blue:power";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
usb {
- label = "rt-n14u:blue:usb";
- gpios = <&gpio2 2 1>;
- };
-
- power {
- label = "rt-n14u:blue:power";
- gpios = <&gpio2 3 1>;
+ label = "rt-ac51u:blue:usb";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
- air {
- label = "rt-n14u:blue:air";
- gpios = <&gpio3 0 1>;
+ wifi {
+ label = "rt-ac51u:blue:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -43,24 +36,27 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
-};
-&gpio2 {
- status = "okay";
-};
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
-&gpio3 {
- status = "okay";
+ enable-leds {
+ gpio-export,name = "enable-leds";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ };
+ };
};
&spi0 {
@@ -71,7 +67,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -107,7 +102,12 @@
status = "okay";
};
+&gpio3 {
+ status = "okay";
+};
+
&ethernet {
+ status = "okay";
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "wllll";
};
@@ -118,8 +118,8 @@
&pinctrl {
state_default: pinctrl0 {
- default {
- ralink,group = "ephy", "wled", "i2c";
+ gpio {
+ ralink,group = "i2c", "wled", "uartf";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/RT-G32-B1.dts
===================================================================
--- sys/gnu/dts/mips/RT-G32-B1.dts
+++ sys/gnu/dts/mips/RT-G32-B1.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "RT-G32-B1", "ralink,rt3050-soc";
+ compatible = "asus,rt-g32-b1", "ralink,rt3050-soc";
model = "Asus RT-G32 B1";
gpio-keys-polled {
@@ -14,14 +17,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -34,7 +37,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/RT-N10-PLUS.dts
===================================================================
--- sys/gnu/dts/mips/RT-N10-PLUS.dts
+++ sys/gnu/dts/mips/RT-N10-PLUS.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "RT-N10-PLUS", "ralink,rt3050-soc";
+ compatible = "asus,rt-n10-plus", "ralink,rt3050-soc";
model = "Asus RT-N10+";
cfi@1f000000 {
@@ -43,7 +46,7 @@
wps {
label = "rt-n10-plus:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -55,14 +58,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/RT-N12-PLUS.dts
===================================================================
--- sys/gnu/dts/mips/RT-N12-PLUS.dts
+++ sys/gnu/dts/mips/RT-N12-PLUS.dts
@@ -2,36 +2,38 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "asus,rt-n14u", "ralink,mt7620n-soc";
- model = "Asus RT-N14U";
+ compatible = "asus,rt-n12p", "ralink,mt7620n-soc";
+ model = "Asus RT-N12+";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
gpio-leds {
compatible = "gpio-leds";
wan {
- label = "rt-n14u:blue:wan";
- gpios = <&gpio2 0 1>;
+ label = "rt-n12p:green:wan";
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
};
lan {
- label = "rt-n14u:blue:lan";
- gpios = <&gpio2 1 1>;
- };
-
- usb {
- label = "rt-n14u:blue:usb";
- gpios = <&gpio2 2 1>;
+ label = "rt-n12p:green:lan";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
power {
- label = "rt-n14u:blue:power";
- gpios = <&gpio2 3 1>;
+ label = "rt-n12p:green:power";
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
};
air {
- label = "rt-n14u:blue:air";
- gpios = <&gpio3 0 1>;
+ label = "rt-n12p:green:air";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -43,18 +45,16 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
- };
-
- wps {
- label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
+&gpio1 {
+ status = "okay";
+};
+
&gpio2 {
status = "okay";
};
@@ -71,7 +71,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -99,14 +98,6 @@
};
};
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
&ethernet {
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "wllll";
@@ -119,7 +110,7 @@
&pinctrl {
state_default: pinctrl0 {
default {
- ralink,group = "ephy", "wled", "i2c";
+ ralink,group = "ephy", "wled", "i2c", "wdt", "pa", "spi refclk";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/RT-N13U.dts
===================================================================
--- sys/gnu/dts/mips/RT-N13U.dts
+++ sys/gnu/dts/mips/RT-N13U.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "RT-N13U", "ralink,rt3052-soc";
+ compatible = "asus,rt-n13u", "ralink,rt3052-soc";
model = "Asus RT-N13U";
cfi@1f000000 {
@@ -43,12 +46,12 @@
power {
label = "rt-n13u:blue:power";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wifi {
label = "rt-n13u:blue:wifi";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
};
@@ -60,14 +63,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/RT-N14U.dts
===================================================================
--- sys/gnu/dts/mips/RT-N14U.dts
+++ sys/gnu/dts/mips/RT-N14U.dts
@@ -2,6 +2,9 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "asus,rt-n14u", "ralink,mt7620n-soc";
model = "Asus RT-N14U";
@@ -11,27 +14,27 @@
wan {
label = "rt-n14u:blue:wan";
- gpios = <&gpio2 0 1>;
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
};
lan {
label = "rt-n14u:blue:lan";
- gpios = <&gpio2 1 1>;
+ gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
};
usb {
label = "rt-n14u:blue:usb";
- gpios = <&gpio2 2 1>;
+ gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
};
power {
label = "rt-n14u:blue:power";
- gpios = <&gpio2 3 1>;
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
};
air {
label = "rt-n14u:blue:air";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -43,14 +46,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -71,7 +74,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/RT-N15.dts
===================================================================
--- sys/gnu/dts/mips/RT-N15.dts
+++ sys/gnu/dts/mips/RT-N15.dts
@@ -2,10 +2,13 @@
#include "rt2880.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "RT-N15", "ralink,rt2880-soc";
+ compatible = "asus,rt-n15", "ralink,rt2880-soc";
model = "Asus RT-N15";
cfi@1f000000 {
@@ -42,8 +45,8 @@
rtl8366s {
compatible = "realtek,rtl8366s";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
};
gpio-keys-polled {
@@ -54,14 +57,14 @@
wps {
label = "wps";
- gpios = <&gpio0 0 0>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 12 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -70,7 +73,7 @@
power {
label = "rt-n15:blue:power";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/RT-N56U.dts
===================================================================
--- sys/gnu/dts/mips/RT-N56U.dts
+++ sys/gnu/dts/mips/RT-N56U.dts
@@ -2,8 +2,11 @@
#include "rt3883.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "RT-N56U", "ralink,rt3883-soc";
+ compatible = "asus,rt-n56u", "ralink,rt3883-soc";
model = "Asus RT-N56U";
nor-flash@1c000000 {
@@ -39,8 +42,8 @@
rtl8367 {
compatible = "realtek,rtl8367";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
realtek,extif1 = <1 0 1 1 1 1 1 1 2>;
};
@@ -52,14 +55,14 @@
reset {
label = "reset";
- gpios = <&gpio0 13 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio1 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -68,22 +71,22 @@
power {
label = "rt-n56u:blue:power";
- gpios = <&gpio0 0 1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
};
lan {
label = "rt-n56u:blue:lan";
- gpios = <&gpio0 19 1>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
};
wan {
label = "rt-n56u:blue:wan";
- gpios = <&gpio1 3 1>;
+ gpios = <&gpio1 3 GPIO_ACTIVE_LOW>;
};
usb {
label = "rt-n56u:blue:usb";
- gpios = <&gpio1 0 1>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_LOW>;
};
};
};
@@ -125,10 +128,10 @@
pci-bridge@1 {
status = "okay";
- wmac@0,0 {
- compatible = "ralink,rt2880-pci", "pciclass060400", "pciclass0604";
- reg = < 0x10000 0 0 0 0 >;
- ralink,eeprom = "rt2x00pci_1_0.eeprom";
+ wifi@1814,3091 {
+ compatible = "pci1814,3091";
+ reg = <0x10000 0 0 0 0>;
+ ralink,mtd-eeprom = <&factory 0x8000>;
};
};
};
Index: sys/gnu/dts/mips/RT5350F-OLINUXINO-EVB.dts
===================================================================
--- sys/gnu/dts/mips/RT5350F-OLINUXINO-EVB.dts
+++ sys/gnu/dts/mips/RT5350F-OLINUXINO-EVB.dts
@@ -1,9 +1,11 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "RT5350F-OLINUXINO.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
/ {
- compatible = "RT5350F-OLINUXINO-EVB", "ralink,rt5350-soc";
+ compatible = "olimex,rt5350f-olinuxino-evb", "ralink,rt5350-soc";
model = "Olimex RT5350F-OLinuXino-EVB";
gpio_export {
@@ -13,88 +15,18 @@
relay1 {
gpio-export,name = "relay1";
gpio-export,output = <0>;
- gpios = <&gpio0 14 0>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
};
relay2 {
gpio-export,name = "relay2";
gpio-export,output = <0>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
button {
gpio-export,name = "button";
- gpios = <&gpio0 0 1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
};
};
};
-
-&spi0 {
- status = "okay";
-
- m25p80@0 {
- #address-cells = <1>;
- #size-cells = <1>;
- compatible = "jedec,spi-nor";
- reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
- spi-max-frequency = <10000000>;
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- partition@30000 {
- label = "u-boot-env";
- reg = <0x30000 0x10000>;
- read-only;
- };
-
- factory: partition@40000 {
- label = "factory";
- reg = <0x40000 0x10000>;
- read-only;
- };
-
- partition@50000 {
- label = "firmware";
- reg = <0x50000 0x3b0000>;
- };
- };
-};
-
-&gpio1 {
- status = "okay";
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x4>;
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <0x17>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
Index: sys/gnu/dts/mips/RT5350F-OLINUXINO.dts
===================================================================
--- sys/gnu/dts/mips/RT5350F-OLINUXINO.dts
+++ sys/gnu/dts/mips/RT5350F-OLINUXINO.dts
@@ -1,78 +1,8 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "RT5350F-OLINUXINO.dtsi"
/ {
- compatible = "RT5350F-OLINUXINO", "ralink,rt5350-soc";
+ compatible = "olimex,rt5350f-olinuxino", "ralink,rt5350-soc";
model = "Olimex RT5350F-OLinuXino";
};
-
-&spi0 {
- status = "okay";
-
- m25p80@0 {
- #address-cells = <1>;
- #size-cells = <1>;
- compatible = "jedec,spi-nor";
- reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
- spi-max-frequency = <10000000>;
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- partition@30000 {
- label = "u-boot-env";
- reg = <0x30000 0x10000>;
- read-only;
- };
-
- factory: partition@40000 {
- label = "factory";
- reg = <0x40000 0x10000>;
- read-only;
- };
-
- partition@50000 {
- label = "firmware";
- reg = <0x50000 0x3b0000>;
- };
- };
-};
-
-&gpio1 {
- status = "okay";
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x4>;
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <0x17>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
Index: sys/gnu/dts/mips/RT5350F-OLINUXINO.dtsi
===================================================================
--- sys/gnu/dts/mips/RT5350F-OLINUXINO.dtsi
+++ sys/gnu/dts/mips/RT5350F-OLINUXINO.dtsi
@@ -1,19 +1,14 @@
-/dts-v1/;
-
#include "rt5350.dtsi"
/ {
- compatible = "WIZARD8800", "ralink,rt5350-soc";
- model = "EASYACC WI-STOR WIZARD 8800";
-};
+ compatible = "olimex,rt5350f-olinuxino", "ralink,rt5350-soc";
-&gpio0 {
- status = "okay";
+ aliases {
+ serial0 = &uartlite;
+ serial1 = &uart;
+ };
};
-&gpio1 {
- status = "okay";
-};
&spi0 {
status = "okay";
@@ -23,7 +18,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q32";
spi-max-frequency = <10000000>;
partition@0 {
@@ -51,12 +45,20 @@
};
};
+&gpio1 {
+ status = "okay";
+};
+
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "jtag", "rgmii", "mdio";
ralink,function = "gpio";
};
+ uartf_gpio {
+ ralink,group = "uartf";
+ ralink,function = "gpio uartf";
+ };
};
};
@@ -66,6 +68,12 @@
&esw {
mediatek,portmap = <0x2f>;
+ mediatek,led_polarity = <0x17>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+ ralink,led-polarity = <1>;
};
&ehci {
@@ -76,6 +84,11 @@
status = "okay";
};
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
+&i2c {
+ status = "okay";
};
+
+&uart {
+ status = "okay";
+};
+
Index: sys/gnu/dts/mips/RUT5XX.dts
===================================================================
--- sys/gnu/dts/mips/RUT5XX.dts
+++ sys/gnu/dts/mips/RUT5XX.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "RUT5XX", "ralink,rt3050-soc";
+ compatible = "teltonika,rut5xx", "ralink,rt3050-soc";
model = "Teltonika RUT5XX";
gpio-leds {
@@ -11,7 +14,7 @@
status {
label = "rut5xx:green:status";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -23,8 +26,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -37,7 +40,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "n25q128a13";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/SAP-G3200U3.dts
===================================================================
--- sys/gnu/dts/mips/SAP-G3200U3.dts
+++ sys/gnu/dts/mips/SAP-G3200U3.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
+ compatible = "storylink,sap-g3200u3", "mediatek,mt7621-soc";
model = "STORYLiNK SAP-G3200U3";
memory@0 {
@@ -20,7 +23,7 @@
usb {
label = "sap-g3200u3:green:usb";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -32,14 +35,14 @@
reset {
label = "reset";
- gpios = <&gpio0 16 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
rfkill {
label = "rfkill";
- gpios = <&gpio0 14 1>;
- linux,code = <0xf7>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
};
};
@@ -52,8 +55,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -94,7 +97,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -103,7 +106,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
Index: sys/gnu/dts/mips/SK-WB8.dts
===================================================================
--- sys/gnu/dts/mips/SK-WB8.dts
+++ sys/gnu/dts/mips/SK-WB8.dts
@@ -1,9 +1,11 @@
/dts-v1/;
#include "mt7621.dtsi"
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
+ compatible = "samknows,whitebox-v8", "mediatek,mt7621-soc";
model = "SamKnows Whitebox 8";
memory@0 {
@@ -20,12 +22,12 @@
wps {
label = "sk-wb8:green:wps";
- gpios = <&gpio1 14 1>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
usb {
label = "sk-wb8:green:usb";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
};
@@ -36,13 +38,13 @@
poll-interval = <20>;
wps {
label = "wps";
- gpios = <&gpio1 11 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio1 9 1>;
- linux,code = <0x198>;
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -55,8 +57,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -77,12 +79,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
- };
-
- partition@e30000 {
- label = "recovery";
- reg = <0xe30000 0x1d0000>;
+ reg = <0x50000 0xfb0000>;
};
};
@@ -96,7 +93,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -105,7 +102,6 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
};
};
};
Index: sys/gnu/dts/mips/SL-R7205.dts
===================================================================
--- sys/gnu/dts/mips/SL-R7205.dts
+++ sys/gnu/dts/mips/SL-R7205.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "SL-R7205", "ralink,rt3052-soc";
+ compatible = "skyline,sl-r7205", "ralink,rt3052-soc";
model = "Skyline SL-R7205 Wireless 3G Router";
cfi@1f000000 {
@@ -43,7 +46,7 @@
wifi {
label = "sl-r7205:green:wifi";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
};
@@ -55,14 +58,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/TEW-638APB-V2.dts
===================================================================
--- sys/gnu/dts/mips/TEW-638APB-V2.dts
+++ sys/gnu/dts/mips/TEW-638APB-V2.dts
@@ -2,13 +2,16 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WCR150GN", "ralink,rt3050-soc";
- model = "Sparklan WCR-150GN";
+ compatible = "trendnet,tew-638apb-v2", "ralink,rt3050-soc";
+ model = "TRENDnet TEW-638APB v2";
cfi@1f000000 {
compatible = "cfi-flash";
- reg = <0x1f000000 0x800000>;
+ reg = <0x1f000000 0x400000>;
bank-width = <2>;
device-width = <2>;
#address-cells = <1>;
@@ -38,36 +41,36 @@
};
};
- gpio-leds {
- compatible = "gpio-leds";
-
- user {
- label = "wcr-150gn:amber:user";
- gpios = <&gpio0 12 1>;
- };
-
- power {
- label = "wcr-150gn:amber:power";
- gpios = <&gpio0 8 1>;
- };
- };
-
gpio-keys-polled {
compatible = "gpio-keys-polled";
#address-cells = <1>;
#size-cells = <0>;
poll-interval = <20>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
wps {
label = "wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
+ };
- reset {
- label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ wps {
+ label = "tew-638apb-v2:orange:wps";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wps2 {
+ label = "tew-638apb-v2:green:wps";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
};
@@ -75,7 +78,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "uartf";
ralink,function = "gpio";
};
};
@@ -92,7 +95,3 @@
&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
-
-&otg {
- status = "okay";
-};
Index: sys/gnu/dts/mips/TEW-691GR.dts
===================================================================
--- sys/gnu/dts/mips/TEW-691GR.dts
+++ sys/gnu/dts/mips/TEW-691GR.dts
@@ -2,8 +2,11 @@
#include "rt3883.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "TEW-691GR", "ralink,rt3883-soc";
+ compatible = "trendnet,tew-691gr", "ralink,rt3883-soc";
model = "TRENDnet TEW-691GR";
nor-flash@1c000000 {
@@ -45,20 +48,20 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio1 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
rfkill {
label = "rfkill";
- gpios = <&gpio0 0 1>;
- linux,code = <0xf7>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
};
@@ -67,7 +70,7 @@
wps {
label = "tew-691gr:green:wps";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
};
@@ -86,7 +89,7 @@
};
&ethernet {
- mtd-mac-address = <&factory 0x28>;
+ mtd-mac-address = <&factory 0x4>;
port@0 {
phy-handle = <&phy0>;
@@ -98,10 +101,15 @@
phy0: ethernet-phy@0 {
reg = <0>;
+ phy-mode = "rgmii";
};
};
};
&wmac {
+ status = "okay";
+ ralink,mtd-eeprom = <&factory 0x0>;
ralink,5ghz = <0>;
+ mtd-mac-address = <&factory 0x4>;
+ mtd-mac-address-increment = <1>;
};
Index: sys/gnu/dts/mips/TEW-692GR.dts
===================================================================
--- sys/gnu/dts/mips/TEW-692GR.dts
+++ sys/gnu/dts/mips/TEW-692GR.dts
@@ -2,8 +2,11 @@
#include "rt3883.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "TEW-692GR", "ralink,rt3883-soc";
+ compatible = "trendnet,tew-692gr", "ralink,rt3883-soc";
model = "TRENDnet TEW-692GR";
nor-flash@1c000000 {
@@ -45,14 +48,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio1 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -61,12 +64,12 @@
wps {
label = "tew-692gr:orange:wps";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps2 {
label = "tew-692gr:green:wps";
- gpios = <&gpio1 4 1>;
+ gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
};
};
};
@@ -86,7 +89,7 @@
&ethernet {
status = "okay";
- mtd-mac-address = <&factory 0x28>;
+ mtd-mac-address = <&factory 0x4>;
port@0 {
phy-handle = <&phy0>;
@@ -98,6 +101,19 @@
phy0: ethernet-phy@0 {
reg = <0>;
+ phy-mode = "rgmii";
+
+ qca,ar8327-initvals = <
+ 0x04 0x07600000 /* PORT0 PAD MODE CTRL */
+ 0x0c 0x07600000 /* PORT6 PAD MODE CTRL */
+ 0x10 0x40000000 /* Power-on Strapping: 176-pin interface configuration */
+ 0x50 0xc437c437 /* LED Control Register 0 */
+ 0x54 0xc337c337 /* LED Control Register 1 */
+ 0x58 0x00000000 /* LED Control Register 2 */
+ 0x5c 0x03ffff00 /* LED Control Register 3 */
+ 0x7c 0x0000007e /* PORT0_STATUS */
+ 0x94 0x0000007e /* PORT6 STATUS */
+ >;
};
};
};
@@ -117,10 +133,20 @@
host-bridge {
pci-bridge@1 {
status = "okay";
+
+ wifi@0,0 {
+ compatible = "pci0,0";
+ reg = < 0x10000 0 0 0 0 >;
+ ralink,2ghz = <0>;
+ };
};
};
};
&wmac {
+ status = "okay";
+ ralink,mtd-eeprom = <&factory 0x0>;
ralink,5ghz = <0>;
+ mtd-mac-address = <&factory 0x4>;
+ mtd-mac-address-increment = <3>;
};
Index: sys/gnu/dts/mips/TEW-714TRU.dts
===================================================================
--- sys/gnu/dts/mips/TEW-714TRU.dts
+++ sys/gnu/dts/mips/TEW-714TRU.dts
@@ -2,21 +2,24 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "MPRA2", "ralink,rt5350-soc";
- model = "HAME MPR-A2";
+ compatible = "trendnet,tew-714tru", "ralink,rt5350-soc";
+ model = "TRENDnet TEW714TRU";
gpio-leds {
compatible = "gpio-leds";
- system {
- label = "mpr-a2:blue:system";
- gpios = <&gpio0 20 1>;
+ usb {
+ label = "tew-714tru:red:usb";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
- power {
- label = "mpr-a2:red:power";
- gpios = <&gpio0 17 1>;
+ wifi {
+ label = "tew-714tru:green:wifi";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -26,27 +29,31 @@
#size-cells = <0>;
poll-interval = <20>;
- wps {
- label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
- };
+ reset {
+ label = "reset";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
};
gpio_export {
compatible = "gpio-export";
#size-cells = <0>;
- usb {
- gpio-export,name = "usb";
- gpio-export,output = <1>;
- gpios = <&gpio0 7 0>;
+ repeater {
+ gpio-export,name = "repeater_switch";
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
- root_hub {
- gpio-export,name = "root_hub";
- gpio-export,output = <1>;
- gpios = <&gpio0 12 0>;
+ wisp {
+ gpio-export,name = "wisp_switch";
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -59,7 +66,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
@@ -90,7 +96,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "i2c", "jtag", "uartf";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/TINY-AC.dts
===================================================================
--- sys/gnu/dts/mips/TINY-AC.dts
+++ sys/gnu/dts/mips/TINY-AC.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "TINY-AC", "ralink,mt7620a-soc";
+ compatible = "dovado,tiny-ac", "ralink,mt7620a-soc";
model = "Dovado Tiny AC";
chosen {
@@ -15,12 +18,12 @@
usb {
label = "tiny-ac:green:usb";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
wifi {
label = "tiny-ac:orange:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -33,8 +36,8 @@
reset {
label = "reset";
- gpios = <&gpio0 13 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -46,7 +49,7 @@
usbpower {
gpio-export,name = "usbpower";
gpio-export,output = <1>;
- gpios = <&gpio2 5 0>;
+ gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -71,7 +74,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -145,10 +147,6 @@
mediatek,mt7530 = <1>;
};
-&wmac {
- ralink,eeprom = "rt2x00pci_1_0.eeprom";
-};
-
&pcie {
status = "okay";
};
Index: sys/gnu/dts/mips/TL-MR3420V5.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/TL-MR3420V5.dts
@@ -0,0 +1,86 @@
+/dts-v1/;
+
+#include "TPLINK-8M.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,tl-mr3420-v5", "mediatek,mt7628an-soc";
+ model = "TP-Link TL-MR3420 v5";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "tl-mr3420-v5:green:lan";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "tl-mr3420-v5:green:power";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "tl-mr3420-v5:green:usb";
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "tl-mr3420-v5:green:wan";
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_amber {
+ label = "tl-mr3420-v5:amber:wan";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "tl-mr3420-v5:green:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "tl-mr3420-v5:green:wps";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "i2s", "p2led_an", "refclk", "uart1", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/TL-WR840NV4.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/TL-WR840NV4.dts
@@ -0,0 +1,62 @@
+/dts-v1/;
+
+#include "TPLINK-8M.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,tl-wr840n-v4", "mediatek,mt7628an-soc";
+ model = "TP-Link TL-WR840N v4";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "tl-wr840n-v4:green:lan";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "tl-wr840n-v4:green:power";
+ gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "tl-wr840n-v4:green:wan";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "tl-wr840n-v4:green:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "tl-wr840n-v4:green:wps";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "p0led_an", "p2led_an", "perst", "refclk", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/TL-WR840NV5.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/TL-WR840NV5.dts
@@ -0,0 +1,105 @@
+/dts-v1/;
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,tl-wr840n-v5", "mediatek,mt7628an-soc";
+ model = "TP-Link TL-WR840N v5";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+ /* LED used is dual-color,dual lead LED */
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "tl-wr840n-v5:green:power";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ orange {
+ label = "tl-wr840n-v5:orange:power";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "boot";
+ reg = <0x0 0x20000>;
+ read-only;
+ };
+
+ partition@20000 {
+ label = "firmware";
+ reg = <0x20000 0x3d0000>;
+ };
+
+ factory: partition@3f0000 {
+ label = "factory";
+ reg = <0x3f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&ehci {
+ status = "disabled";
+};
+
+&ohci {
+ status = "disabled";
+};
+
+&wmac {
+ status = "okay";
+ mtd-mac-address = <&factory 0xf100>;
+ mediatek,mtd-eeprom = <&factory 0x10000>;
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0xf100>;
+ mediatek,portmap = "wllll";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "p0led_an", "p2led_an", "perst";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/TL-WR841NV13.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/TL-WR841NV13.dts
@@ -0,0 +1,88 @@
+/dts-v1/;
+
+#include "TPLINK-8M.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,tl-wr841n-v13", "mediatek,mt7628an-soc";
+ model = "TP-Link TL-WR841N v13";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "tl-wr841n-v13:green:power";
+ gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "tl-wr841n-v13:green:wps";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ };
+
+ lan1 {
+ label = "tl-wr841n-v13:green:lan1";
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+ };
+
+ lan2 {
+ label = "tl-wr841n-v13:green:lan2";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ lan3 {
+ label = "tl-wr841n-v13:green:lan3";
+ gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
+ };
+
+ lan4 {
+ label = "tl-wr841n-v13:green:lan4";
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_green {
+ label = "tl-wr841n-v13:green:wan";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_orange {
+ label = "tl-wr841n-v13:orange:wan";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "tl-wr841n-v13:green:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "gpio", "p0led_an", "p1led_an", "p2led_an", "p3led_an", "p4led_an", "perst", "refclk", "uart1", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/TL-WR842NV5.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/TL-WR842NV5.dts
@@ -0,0 +1,86 @@
+/dts-v1/;
+
+#include "TPLINK-8M.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,tl-wr842n-v5", "mediatek,mt7628an-soc";
+ model = "TP-Link TL-WR842N v5";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "tl-wr842n-v5:green:lan";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "tl-wr842n-v5:green:power";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "tl-wr842n-v5:green:usb";
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "tl-wr842n-v5:green:wan";
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
+ };
+
+ wan_amber {
+ label = "tl-wr842n-v5:amber:wan";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "tl-wr842n-v5:green:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "tl-wr842n-v5:green:wps";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "i2s", "p2led_an", "refclk", "uart1", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/TL-WR902ACV3.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/TL-WR902ACV3.dts
@@ -0,0 +1,108 @@
+/dts-v1/;
+
+#include "TPLINK-8M.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "tplink,tl-wr902ac-v3", "mediatek,mt7628an-soc";
+ model = "TP-Link TL-WR902AC v3";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ sw1 {
+ label = "sw1";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ };
+
+ sw2 {
+ label = "sw2";
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ lan {
+ label = "tl-wr902ac-v3:green:lan";
+ gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+ };
+
+ power {
+ label = "tl-wr902ac-v3:green:power";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "tl-wr902ac-v3:green:usb";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "tl-wr902ac-v3:green:wan";
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "tl-wr902ac-v3:green:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "tl-wr902ac-v3:green:wps";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "i2s", "p0led_an", "p2led_an", "p4led_an", "uart1", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&pcie {
+ status = "okay";
+
+ pcie-bridge {
+ mt76@1,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x28000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ mtd-mac-address = <&factory 0xf100>;
+ mtd-mac-address-increment = <(-1)>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/TPLINK-8M.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/TPLINK-8M.dtsi
@@ -0,0 +1,67 @@
+#include "mt7628an.dtsi"
+
+/ {
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "boot";
+ reg = <0x0 0x20000>;
+ read-only;
+ };
+
+ partition@20000 {
+ label = "firmware";
+ reg = <0x20000 0x7a0000>;
+ };
+
+ partition@7c0000 {
+ label = "config";
+ reg = <0x7c0000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@7d0000 {
+ label = "factory";
+ reg = <0x7d0000 0x30000>;
+ read-only;
+ };
+ };
+};
+
+&ehci {
+ status = "disabled";
+};
+
+&ohci {
+ status = "disabled";
+};
+
+&wmac {
+ status = "okay";
+ mtd-mac-address = <&factory 0xf100>;
+ mediatek,mtd-eeprom = <&factory 0x20000>;
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0xf100>;
+ mediatek,portmap = "llllw";
+};
Index: sys/gnu/dts/mips/Timecloud.dts
===================================================================
--- sys/gnu/dts/mips/Timecloud.dts
+++ sys/gnu/dts/mips/Timecloud.dts
@@ -1,10 +1,18 @@
/dts-v1/;
-#include "mt7620a.dtsi"
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
- compatible = "ralink,mt7620a-soc";
- model = "OY-0001";
+ compatible = "thunder,timecloud", "mediatek,mt7621-soc";
+ model = "Thunder Timecloud";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
chosen {
bootargs = "console=ttyS0,115200";
@@ -13,15 +21,16 @@
gpio-leds {
compatible = "gpio-leds";
- powerled {
- label = "oy-0001:green:power";
- gpios = <&gpio0 9 1>;
+ statw {
+ label = "timecloud:white:status";
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
- wifiled {
- label = "oy-0001:green:wifi";
- gpios = <&gpio3 0 1>;
+ stato {
+ label = "timecloud:orange:status";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
};
+
};
gpio-keys-polled {
@@ -30,20 +39,25 @@
#size-cells = <0>;
poll-interval = <20>;
- s1 {
+ reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ BTN_0 {
+ label = "BTN_0";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
-&gpio2 {
+&sdhci {
status = "okay";
-};
-&gpio3 {
- status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&sdhci_pins>;
};
&spi0 {
@@ -54,8 +68,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -82,41 +96,15 @@
};
};
+&ethernet {
+ mtd-mac-address = <&factory 0xe000>;
+};
+
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
+ ralink,group = "i2c", "uart2", "jtag";
ralink,function = "gpio";
};
};
};
-
-&ethernet {
- pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
- mediatek,portmap = "llllw";
-};
-
-&gsw {
- mediatek,port4 = "ephy";
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&sdhci {
- status = "okay";
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
-&pcie {
- status = "okay";
-};
Index: sys/gnu/dts/mips/U25AWF-H1.dts
===================================================================
--- sys/gnu/dts/mips/U25AWF-H1.dts
+++ sys/gnu/dts/mips/U25AWF-H1.dts
@@ -1,10 +1,13 @@
/dts-v1/;
-#include "mt7620n.dtsi"
+#include "mt7620a.dtsi"
-/ {
- compatible = "wt3020", "ralink,mt7620n-soc";
- model = "Nexx WT3020";
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/{
+ compatible = "kimax,u25awf-h1","ralink,mt7620a-soc";
+ model = "Kimax U25AWF-H1";
gpio-keys-polled {
compatible = "gpio-keys-polled";
@@ -14,17 +17,22 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
gpio-leds {
compatible = "gpio-leds";
- power {
- label = "wt3020:blue:power";
- gpios = <&gpio3 0 0>;
+ wifi {
+ label = "u25awf:red:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+
+ lan {
+ label = "u25awf:green:lan";
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
};
};
};
@@ -45,7 +53,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -68,7 +75,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
+ reg = <0x50000 0xfb0000>;
};
};
};
@@ -83,7 +90,6 @@
&ethernet {
mtd-mac-address = <&factory 0x4>;
- mediatek,portmap = "wllll";
};
&wmac {
@@ -93,7 +99,7 @@
&pinctrl {
state_default: pinctrl0 {
default {
- ralink,group = "ephy", "wled", "pa", "i2c", "wdt", "uartf";
+ ralink,group = "uartf", "ephy", "wled";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/U7621-06-256M-16M.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/U7621-06-256M-16M.dts
@@ -0,0 +1,86 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * Copyright(c) 2017 Piotr Dymacz <pepe2k@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/dts-v1/;
+
+#include "U7621-06.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "unielec,u7621-06-256m-16m", "unielec,u7621-06", "mediatek,mt7621-soc";
+ model = "UniElec U7621-06 (256M RAM/16M flash)";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <14000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "bootloader";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "config";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ firmware: partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/U7621-06.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/U7621-06.dtsi
@@ -0,0 +1,117 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * Copyright(c) 2017 Piotr Dymacz <pepe2k@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "unielec,u7621-06", "mediatek,mt7621-soc";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ modem_reset {
+ gpio-export,name = "modem_reset";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status {
+ label = "u7621-06:green:status";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ led4 {
+ label = "u7621-06:green:led4";
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
+ };
+
+ led5 {
+ label = "u7621-06:green:led5";
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&gpio0 {
+ status = "okay";
+};
+
+&sdhci {
+ status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&sdhci_pins>;
+};
+
+&pcie {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0xe000>;
+ mediatek,portmap = "llllw";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "jtag", "uart2", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/U7628-01-128M-16M.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/U7628-01-128M-16M.dts
@@ -0,0 +1,83 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * Copyright(c) 2017 Piotr Dymacz <pepe2k@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/dts-v1/;
+
+#include "U7628-01.dtsi"
+
+/ {
+ compatible = "unielec,u7628-01-128m-16m", "unielec,u7628-01", "mediatek,mt7628an-soc";
+ model = "UniElec U7628-01 (128M RAM/16M flash)";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <12000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "bootloader";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "config";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/U7628-01.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/U7628-01.dtsi
@@ -0,0 +1,132 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * Copyright(c) 2017 Piotr Dymacz <pepe2k@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "unielec,u7628-01", "mediatek,mt7628an-soc";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "u7628-01:green:power";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "u7628-01:green:wlan";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wan {
+ label = "u7628-01:green:wan";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ lan1 {
+ label = "u7628-01:green:lan1";
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+ };
+
+ lan2 {
+ label = "u7628-01:green:lan2";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ lan3 {
+ label = "u7628-01:green:lan3";
+ gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
+ };
+
+ lan4 {
+ label = "u7628-01:green:lan4";
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "u7628-01:green:usb";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&gpio0 {
+ status = "okay";
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&pcie {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&wmac {
+ status = "okay";
+ ralink,mtd-eeprom = <&factory 0x0>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "gpio", "p0led_an", "p1led_an", "p2led_an", "p3led_an", "p4led_an", "refclk", "wdt", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/UBNT-ER-e50.dtsi
===================================================================
--- sys/gnu/dts/mips/UBNT-ER-e50.dtsi
+++ sys/gnu/dts/mips/UBNT-ER-e50.dtsi
@@ -1,12 +1,10 @@
-#include <dt-bindings/input/input.h>
-
-/dts-v1/;
-
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "UBNT-ERX";
+ compatible = "ubiquiti,edgerouterx", "mediatek,mt7621-soc";
memory@0 {
device_type = "memory";
@@ -17,43 +15,6 @@
bootargs = "console=ttyS0,57600";
};
- nand@1e003000 {
- status = "okay";
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x80000>;
- read-only;
- };
-
- partition@80000 {
- label = "u-boot-env";
- reg = <0x80000 0x60000>;
- read-only;
- };
-
- factory: partition@e0000 {
- label = "factory";
- reg = <0xe0000 0x60000>;
- };
-
- partition@140000 {
- label = "kernel1";
- reg = <0x140000 0x300000>;
- };
-
- partition@440000 {
- label = "kernel2";
- reg = <0x440000 0x300000>;
- };
-
- partition@740000 {
- label = "ubi";
- reg = <0x740000 0xf7c0000>;
- };
-
- };
-
gpio-keys-polled {
compatible = "gpio-keys-polled";
#address-cells = <1>;
@@ -62,7 +23,7 @@
reset {
label = "reset";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
linux,code = <KEY_RESTART>;
};
};
@@ -72,6 +33,42 @@
mtd-mac-address = <&factory 0x22>;
};
+&nand {
+ status = "okay";
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x80000>;
+ read-only;
+ };
+
+ partition@80000 {
+ label = "u-boot-env";
+ reg = <0x80000 0x60000>;
+ read-only;
+ };
+
+ factory: partition@e0000 {
+ label = "factory";
+ reg = <0xe0000 0x60000>;
+ };
+
+ partition@140000 {
+ label = "kernel1";
+ reg = <0x140000 0x300000>;
+ };
+
+ partition@440000 {
+ label = "kernel2";
+ reg = <0x440000 0x300000>;
+ };
+
+ partition@740000 {
+ label = "ubi";
+ reg = <0x740000 0xf7c0000>;
+ };
+};
+
&pinctrl {
state_default: pinctrl0 {
gpio {
@@ -81,27 +78,20 @@
};
};
-&sdhci {
- status = "disabled";
-};
-
-&pcie {
- status = "disabled";
-};
-
&spi0 {
/* This board has 2Mb spi flash soldered in and visible
from manufacturer's firmware.
But this SoC shares spi and nand pins,
and current driver does't handle this sharing well */
status = "disabled";
+
m25p80@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <1>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "spi";
@@ -110,3 +100,7 @@
};
};
};
+
+&xhci {
+ status = "disabled";
+};
Index: sys/gnu/dts/mips/UBNT-ERX-SFP.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/UBNT-ERX-SFP.dts
@@ -0,0 +1,24 @@
+/dts-v1/;
+
+#include "UBNT-ER-e50.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ model = "UBNT-ERX-SFP";
+ compatible = "ubiquiti,edgerouterx-sfp", "mediatek,mt7621-soc";
+
+ i2c-gpio {
+ compatible = "i2c-gpio";
+ gpios = <&gpio0 3 GPIO_ACTIVE_HIGH /* sda */
+ &gpio0 4 GPIO_ACTIVE_HIGH /* scl */
+ >;
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ pca9555@25 {
+ compatible = "pca9555";
+ reg = <0x25>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/UBNT-ERX.dts
===================================================================
--- sys/gnu/dts/mips/UBNT-ERX.dts
+++ sys/gnu/dts/mips/UBNT-ERX.dts
@@ -1,112 +1,7 @@
-#include <dt-bindings/input/input.h>
-
/dts-v1/;
-#include "mt7621.dtsi"
+#include "UBNT-ER-e50.dtsi"
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
model = "UBNT-ERX";
-
- memory@0 {
- device_type = "memory";
- reg = <0x0 0x10000000>;
- };
-
- chosen {
- bootargs = "console=ttyS0,57600";
- };
-
- nand@1e003000 {
- status = "okay";
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x80000>;
- read-only;
- };
-
- partition@80000 {
- label = "u-boot-env";
- reg = <0x80000 0x60000>;
- read-only;
- };
-
- factory: partition@e0000 {
- label = "factory";
- reg = <0xe0000 0x60000>;
- };
-
- partition@140000 {
- label = "kernel1";
- reg = <0x140000 0x300000>;
- };
-
- partition@440000 {
- label = "kernel2";
- reg = <0x440000 0x300000>;
- };
-
- partition@740000 {
- label = "ubi";
- reg = <0x740000 0xf7c0000>;
- };
-
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 12 1>;
- linux,code = <KEY_RESTART>;
- };
- };
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x22>;
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "uart2", "uart3", "i2c", "pcie", "rgmii2", "jtag";
- ralink,function = "gpio";
- };
- };
-};
-
-&sdhci {
- status = "disabled";
-};
-
-&pcie {
- status = "disabled";
-};
-
-&spi0 {
- /* This board has 2Mb spi flash soldered in and visible
- from manufacturer's firmware.
- But this SoC shares spi and nand pins,
- and current driver does't handle this sharing well */
- status = "disabled";
- m25p80@0 {
- #address-cells = <1>;
- #size-cells = <1>;
- compatible = "jedec,spi-nor";
- reg = <1>;
- linux,modalias = "m25p80";
- spi-max-frequency = <10000000>;
-
- partition@0 {
- label = "spi";
- reg = <0x0 0x200000>;
- read-only;
- };
- };
};
Index: sys/gnu/dts/mips/UR-326N4G.dts
===================================================================
--- sys/gnu/dts/mips/UR-326N4G.dts
+++ sys/gnu/dts/mips/UR-326N4G.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "UR-326N4G", "ralink,rt3052-soc";
+ compatible = "upvel,ur-326n4g", "ralink,rt3052-soc";
model = "UPVEL UR-326N4G";
cfi@1f000000 {
@@ -43,27 +46,27 @@
3g {
label = "ur-326n4g:green:3g";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
gateway {
label = "ur-326n4g:green:gateway";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
ap {
label = "ur-326n4g:green:ap";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "ur-326n4g:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
station {
label = "ur-326n4g:green:station";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -75,14 +78,14 @@
reset_wps {
label = "reset_wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
mode {
label = "mode";
- gpios = <&gpio0 7 1>;
- linux,code = <0x32>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
Index: sys/gnu/dts/mips/UR-336UN.dts
===================================================================
--- sys/gnu/dts/mips/UR-336UN.dts
+++ sys/gnu/dts/mips/UR-336UN.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "UR-336UN", "ralink,rt3052-soc";
+ compatible = "upvel,ur-336un", "ralink,rt3052-soc";
model = "UPVEL UR-336UN";
cfi@1f000000 {
@@ -13,6 +16,29 @@
device-width = <2>;
#address-cells = <1>;
#size-cells = <1>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x7b0000>;
+ };
};
gpio-leds {
@@ -20,27 +46,27 @@
3g {
label = "ur-336un:green:3g";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
gateway {
label = "ur-336un:green:gateway";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
ap {
label = "ur-336un:green:ap";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wps {
label = "ur-336un:green:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
station {
label = "ur-336un:green:station";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -52,14 +78,14 @@
reset_wps {
label = "reset_wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
mode {
label = "mode";
- gpios = <&gpio0 7 1>;
- linux,code = <0x32>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
@@ -73,20 +99,18 @@
};
};
-/* FIXME: no partitions defined */
-/*&ethernet {
+&ethernet {
mtd-mac-address = <&factory 0x4004>;
};
-*/
+
&esw {
mediatek,portmap = <0x2f>;
};
-/* FIXME: no partitions defined */
-/*&wmac {
+&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
-*/
+
&otg {
status = "okay";
};
Index: sys/gnu/dts/mips/V11STFE.dts
===================================================================
--- sys/gnu/dts/mips/V11STFE.dts
+++ sys/gnu/dts/mips/V11STFE.dts
@@ -2,8 +2,11 @@
#include "rt2880.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "V11ST-FE", "ralink,rt2880-soc";
+ compatible = "ralink,v11st-fe", "ralink,rt2880-soc";
model = "Ralink V11ST-FE";
pci@440000 {
@@ -55,8 +58,8 @@
wps {
label = "wps";
- gpios = <&gpio0 0 0>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -65,7 +68,7 @@
status {
label = "v11st-fe:green:status";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/V22RW-2X2.dts
===================================================================
--- sys/gnu/dts/mips/V22RW-2X2.dts
+++ sys/gnu/dts/mips/V22RW-2X2.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "V22RW-2X2", "ralink,rt3052-soc";
+ compatible = "ralink,v22rw-2x2", "ralink,rt3052-soc";
model = "Ralink AP-RT3052-V22RW-2X2";
cfi@1f000000 {
@@ -43,12 +46,12 @@
security {
label = "v22rw-2x2:green:security";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
wps {
label = "v22rw-2x2:red:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -60,14 +63,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/VAR11N-300.dts
===================================================================
--- sys/gnu/dts/mips/VAR11N-300.dts
+++ sys/gnu/dts/mips/VAR11N-300.dts
@@ -2,9 +2,21 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "wt3020", "ralink,mt7620n-soc";
- model = "Nexx WT3020";
+ compatible = "vonets,var11n-300", "ralink,mt7620n-soc";
+ model = "Vonets VAR11N-300";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ system {
+ label = "var11n-300:blue:system";
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
+ };
+ };
gpio-keys-polled {
compatible = "gpio-keys-polled";
@@ -14,26 +26,13 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- power {
- label = "wt3020:blue:power";
- gpios = <&gpio3 0 0>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
-&gpio2 {
- status = "okay";
-};
-
-&gpio3 {
+&gpio0 {
status = "okay";
};
@@ -45,7 +44,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q32";
spi-max-frequency = <10000000>;
partition@0 {
@@ -73,17 +71,9 @@
};
};
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
&ethernet {
mtd-mac-address = <&factory 0x4>;
- mediatek,portmap = "wllll";
+ mediatek,portmap = "llllw";
};
&wmac {
@@ -93,7 +83,7 @@
&pinctrl {
state_default: pinctrl0 {
default {
- ralink,group = "ephy", "wled", "pa", "i2c", "wdt", "uartf";
+ ralink,group = "i2c";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/VOCORE-16M.dts
===================================================================
--- sys/gnu/dts/mips/VOCORE-16M.dts
+++ sys/gnu/dts/mips/VOCORE-16M.dts
@@ -2,6 +2,11 @@
#include "VOCORE.dtsi"
+/ {
+ compatible = "vocore,vocore-16m", "vocore,vocore", "ralink,rt5350-soc";
+ model = "VoCore (16M)";
+};
+
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/VOCORE-8M.dts
===================================================================
--- sys/gnu/dts/mips/VOCORE-8M.dts
+++ sys/gnu/dts/mips/VOCORE-8M.dts
@@ -2,6 +2,11 @@
#include "VOCORE.dtsi"
+/ {
+ compatible = "vocore,vocore-8m", "vocore,vocore", "ralink,rt5350-soc";
+ model = "VoCore (8M)";
+};
+
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/VOCORE.dtsi
===================================================================
--- sys/gnu/dts/mips/VOCORE.dtsi
+++ sys/gnu/dts/mips/VOCORE.dtsi
@@ -1,8 +1,9 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+
/ {
- compatible = "VoCore", "ralink,rt5350-soc";
- model = "VoCore";
+ compatible = "vocore,vocore", "ralink,rt5350-soc";
gpio-export {
compatible = "gpio-export";
@@ -11,7 +12,7 @@
gpio0 {
gpio-export,name = "gpio0";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 0 0>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
};
/* UARTF */
@@ -19,42 +20,42 @@
/* UARTF_RTS_N */
gpio-export,name = "gpio7";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 7 0>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
};
gpio8 {
/* UARTF_TXD */
gpio-export,name = "gpio8";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 8 0>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
};
gpio9 {
/* UARTF_CTS_N */
gpio-export,name = "gpio9";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 9 0>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
};
gpio12 {
/* UARTF_DCD_N */
gpio-export,name = "gpio12";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
gpio13 {
/* UARTF_DSR_N */
gpio-export,name = "gpio13";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
gpio14 {
/* UARTF_RIN */
gpio-export,name = "gpio14";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 14 0>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
};
/* JTAG */
@@ -62,35 +63,35 @@
/* JTAG_TDO */
gpio-export,name = "gpio17";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 17 0>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
};
gpio18 {
/* JTAG_TDI */
gpio-export,name = "gpio18";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 18 0>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_HIGH>;
};
gpio19 {
/* JTAG_TMS */
gpio-export,name = "gpio19";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 19 0>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_HIGH>;
};
gpio20 {
/* JTAG_TCLK */
gpio-export,name = "gpio20";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 20 0>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_HIGH>;
};
gpio21 {
/* JTAG_TRST_N */
gpio-export,name = "gpio21";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio0 21 0>;
+ gpios = <&gpio0 21 GPIO_ACTIVE_HIGH>;
};
/* ETH LEDs */
@@ -98,35 +99,35 @@
/* ETH0_LED */
gpio-export,name = "gpio22";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 0 0>;
+ gpios = <&gpio1 0 GPIO_ACTIVE_HIGH>;
};
gpio23 {
/* ETH1_LED */
gpio-export,name = "gpio23";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 1 0>;
+ gpios = <&gpio1 1 GPIO_ACTIVE_HIGH>;
};
gpio24 {
/* ETH2_LED */
gpio-export,name = "gpio24";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 2 0>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
};
gpio25 {
/* ETH3_LED */
gpio-export,name = "gpio25";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 3 0>;
+ gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
};
gpio26 {
/* ETH4_LED */
gpio-export,name = "gpio26";
gpio-export,direction_may_change = <1>;
- gpios = <&gpio1 4 0>;
+ gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
};
};
@@ -136,13 +137,13 @@
status {
/* UARTF_RXD */
label = "vocore:green:status";
- gpios = <&gpio0 10 0>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
};
eth {
/* UARTF_DTR_N */
label = "vocore:orange:eth";
- gpios = <&gpio0 11 0>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_HIGH>;
};
};
};
Index: sys/gnu/dts/mips/VOCORE2.dts
===================================================================
--- sys/gnu/dts/mips/VOCORE2.dts
+++ sys/gnu/dts/mips/VOCORE2.dts
@@ -1,6 +1,22 @@
/dts-v1/;
-#include "WT1520.dtsi"
+#include "VOCORE2.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "vocore,vocore2", "mediatek,mt7628an-soc";
+ model = "VoCore2";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status {
+ label = "vocore2:fuchsia:status";
+ gpios = <&gpio1 12 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
&spi0 {
status = "okay";
@@ -10,8 +26,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -33,7 +49,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x3b0000>;
+ reg = <0x50000 0xfb0000>;
};
};
};
Index: sys/gnu/dts/mips/VOCORE2.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/VOCORE2.dtsi
@@ -0,0 +1,53 @@
+#include "mt7628an.dtsi"
+
+/ {
+ compatible = "vocore,vocore2", "mediatek,mt7628an-soc";
+
+ chosen {
+ bootargs = "console=ttyS2,115200";
+ };
+};
+
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "wled_an", "refclk", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&wmac {
+ status = "okay";
+ ralink,mtd-eeprom = <&factory 0x4>;
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&esw {
+ mediatek,portmap = <0x7>;
+ mediatek,portdisable = <0x3a>;
+};
+
+&i2s {
+ status = "okay";
+};
+
+&gdma {
+ status = "okay";
+};
+
+&pwm {
+ status = "okay";
+};
+
+&uart1 {
+ status = "okay";
+};
+
+&uart2 {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/VOCORE2LITE.dts
===================================================================
--- sys/gnu/dts/mips/VOCORE2LITE.dts
+++ sys/gnu/dts/mips/VOCORE2LITE.dts
@@ -1,6 +1,22 @@
/dts-v1/;
-#include "WT1520.dtsi"
+#include "VOCORE2.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "vocore,vocore2lite", "vocore,vocore2", "mediatek,mt7628an-soc";
+ model = "VoCore2-Lite";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ status {
+ label = "vocore2lite:green:status";
+ gpios = <&gpio1 12 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
&spi0 {
status = "okay";
@@ -10,8 +26,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
Index: sys/gnu/dts/mips/VR500.dts
===================================================================
--- sys/gnu/dts/mips/VR500.dts
+++ sys/gnu/dts/mips/VR500.dts
@@ -1,17 +1,29 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
- compatible = "X8", "ralink,rt5350-soc";
- model = "Poray X8";
+ compatible = "planex,vr500", "mediatek,mt7621-soc";
+ model = "Planex VR500";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
gpio-leds {
compatible = "gpio-leds";
power {
- label = "x8:green:power";
- gpios = <&gpio0 13 1>;
+ label = "vr500:green:power";
+ gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
};
};
@@ -23,8 +35,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -37,8 +49,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "gd25q64";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -60,7 +72,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
+ reg = <0x50000 0x3fb0000>;
};
};
};
@@ -68,30 +80,8 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "jtag", "uartf";
+ ralink,group = "i2c", "uart2", "uart3", "rgmii2", "sdhci";
ralink,function = "gpio";
};
};
};
-
-&ethernet {
- mtd-mac-address = <&factory 0x4>;
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <1>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
- ralink,led-polarity = <1>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
Index: sys/gnu/dts/mips/W06.dts
===================================================================
--- sys/gnu/dts/mips/W06.dts
+++ sys/gnu/dts/mips/W06.dts
@@ -1,22 +1,35 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
- compatible = "HT-TM02", "ralink,rt5350-soc";
- model = "HooToo HT-TM02";
+ compatible = "tama,w06", "mediatek,mt7628an-soc";
+ model = "Tama W06";
+
+ memory@0{
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
gpio-leds {
compatible = "gpio-leds";
- wlan {
- label = "ht-tm02:blue:wlan";
- gpios = <&gpio0 7 1>;
+ wps {
+ label = "w06:green:wps";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
- lan {
- label = "ht-tm02:green:lan";
- gpios = <&gpio0 12 1>;
+ wan {
+ label = "w06:green:wan";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ wireless {
+ label = "w06:green:wlan";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
};
@@ -28,23 +41,33 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
-
- modeswitch {
- label = "modeswitch";
- gpios = <&gpio0 14 1>;
- linux,code = <0x100>;
- linux,input-type = <5>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
-&gpio0 {
+&ehci {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&ohci {
status = "okay";
};
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "uart1", "p0led_an", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
+
&spi0 {
status = "okay";
@@ -53,8 +76,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -76,37 +99,17 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
+ reg = <0x50000 0xeb0000>;
};
- };
-};
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "uartf";
- ralink,function = "gpio";
+ partition@f00000 {
+ label = "user-data";
+ reg = <0xf00000 0x100000>;
+ read-only;
};
};
};
-&ethernet {
- mtd-mac-address = <&factory 0x28>;
-};
-
-&esw {
- mediatek,portmap = <0x10>;
- mediatek,portdisable = <0x2f>;
-};
-
&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
status = "okay";
};
Index: sys/gnu/dts/mips/W150M.dts
===================================================================
--- sys/gnu/dts/mips/W150M.dts
+++ sys/gnu/dts/mips/W150M.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "W150M", "ralink,rt3050-soc";
+ compatible = "tenda,w150m", "ralink,rt3050-soc";
model = "Tenda W150M";
cfi@1f000000 {
@@ -43,32 +46,32 @@
3grouter {
label = "w150m:blue:3grouter";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
ap {
label = "w150m:blue:ap";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wisprouter {
label = "w150m:blue:wisprouter";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wirelessrouter {
label = "w150m:blue:wirelessrouter";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
3g {
label = "w150m:blue:3g";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wpsreset {
label = "w150m:blue:wpsreset";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -80,14 +83,14 @@
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
mode {
label = "mode";
- gpios = <&gpio0 10 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
};
Index: sys/gnu/dts/mips/W2914NSV2.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/W2914NSV2.dts
@@ -0,0 +1,26 @@
+/dts-v1/;
+
+#include "W2914NSV2.dtsi"
+
+/ {
+ model = "WeVO W2914NS v2";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ // Only USB LED is connected to GPIO.
+ // All of other LEDs are connected directly to
+ // switch, WiFi chip, Vcc, so they are not controllable
+ // via GPIO
+
+ usb {
+ label = "w2914nsv2:green:usb";
+ gpios = <&gpio0 27 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/W2914NSV2.dtsi
===================================================================
--- sys/gnu/dts/mips/W2914NSV2.dtsi
+++ sys/gnu/dts/mips/W2914NSV2.dtsi
@@ -1,50 +1,36 @@
-/dts-v1/;
-
#include "mt7621.dtsi"
-/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "Firefly FireWRT";
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
- memory@0 {
- device_type = "memory";
- reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
- };
+/ {
+ compatible = "wevo,w2914ns-v2", "mediatek,mt7621-soc";
chosen {
bootargs = "console=ttyS0,57600";
};
- gpio-leds {
- compatible = "gpio-leds";
-
- power {
- label = "firewrt:green:power";
- gpios = <&gpio0 22 1>;
- };
- };
-
gpio-keys-polled {
compatible = "gpio-keys-polled";
#address-cells = <1>;
#size-cells = <0>;
poll-interval = <20>;
- wps {
- label = "wps";
- gpios = <&gpio0 18 1>;
- linux,code = <0x211>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 29 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
- power {
- label = "power";
- gpios = <&gpio0 23 1>;
- linux,code = <116>;
+ wps {
+ label = "wps";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
-&sdhci {
+&xhci {
status = "okay";
};
@@ -56,8 +42,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -88,20 +74,19 @@
status = "okay";
pcie0 {
- mt76@0,0 {
+ wifi@14c3,7603 {
+ compatible = "pci14c3,7603";
reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x0000>;
};
};
pcie1 {
- mt76@1,0 {
+ wifi@14c3,7662 {
+ compatible = "pci14c3,7662";
reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
@@ -113,7 +98,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2";
+ ralink,group = "wdt", "rgmii2", "jtag", "mdio";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/W306R_V20.dts
===================================================================
--- sys/gnu/dts/mips/W306R_V20.dts
+++ sys/gnu/dts/mips/W306R_V20.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "W306R_V20", "ralink,rt3052-soc";
+ compatible = "tenda,w306r-v2", "ralink,rt3052-soc";
model = "Tenda W306R V2.0";
cfi@1f000000 {
@@ -43,12 +46,12 @@
sys {
label = "w306r-v20:green:sys";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wps {
label = "w306r-v20:green:wps";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -60,8 +63,8 @@
reset {
label = "RESET/WPS";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/W502U.dts
===================================================================
--- sys/gnu/dts/mips/W502U.dts
+++ sys/gnu/dts/mips/W502U.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "W502U", "ralink,rt3052-soc";
+ compatible = "alfanetworks,w502u", "ralink,rt3052-soc";
model = "ALFA Networks W502U";
chosen {
@@ -47,12 +50,12 @@
usb {
label = "w502u:blue:usb";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
wps {
label = "w502u:blue:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -64,14 +67,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/WCR-1166DS.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WCR-1166DS.dts
@@ -0,0 +1,172 @@
+/dts-v1/;
+
+#include "mt7628an.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "buffalo,wcr-1166ds", "mediatek,mt7628an-soc";
+ model = "Buffalo WCR-1166DS";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ aoss {
+ label = "aoss";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ ap {
+ label = "ap";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
+ };
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ router_o {
+ label = "wcr-1166ds:orange:router";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
+ };
+
+ router_g {
+ label = "wcr-1166ds:green:router";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ };
+
+ internet_o {
+ label = "wcr-1166ds:orange:internet";
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
+ };
+
+ internet_g {
+ label = "wcr-1166ds:green:internet";
+ gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
+ };
+
+ wireless_o {
+ label = "wcr-1166ds:orange:wireless";
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
+ };
+
+ wireless_g {
+ label = "wcr-1166ds:green:wireless";
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+ };
+
+ diag {
+ label = "wcr-1166ds:orange:diag";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "wcr-1166ds:green:power";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&ehci {
+ status = "disabled";
+};
+
+&esw {
+ mediatek,portmap = <0x2f>;
+ mediatek,portdisable = <0x27>;
+};
+
+&ohci {
+ status = "disabled";
+};
+
+&pcie {
+ status = "okay";
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "uart1", "wled_an", "p0led_an", "p1led_an", "p2led_an", "p3led_an", "p4led_an", "wdt", "refclk", "gpio", "i2s";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x7c0000>;
+ };
+
+ partition@810000 {
+ label = "firmware2";
+ reg = <0x810000 0x7c0000>;
+ };
+
+ partition@fd0000 {
+ label = "glbcfg";
+ reg = <0xfd0000 0x10000>;
+ read-only;
+ };
+
+ partition@fe0000 {
+ label = "board_data";
+ reg = <0xfe0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&wmac {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/WCR150GN.dts
===================================================================
--- sys/gnu/dts/mips/WCR150GN.dts
+++ sys/gnu/dts/mips/WCR150GN.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WCR150GN", "ralink,rt3050-soc";
+ compatible = "sparklan,wcr150gn", "ralink,rt3050-soc";
model = "Sparklan WCR-150GN";
cfi@1f000000 {
@@ -43,12 +46,12 @@
user {
label = "wcr-150gn:amber:user";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
power {
label = "wcr-150gn:amber:power";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
};
@@ -60,14 +63,14 @@
wps {
label = "wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/WD03.dts
===================================================================
--- sys/gnu/dts/mips/WD03.dts
+++ sys/gnu/dts/mips/WD03.dts
@@ -1,10 +1,13 @@
/dts-v1/;
-#include "mt7620n.dtsi"
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
- compatible = "cf-wr800n", "ralink,mt7620n-soc";
- model = "Comfast CF-WR800N";
+ compatible = "ravpower,wd03", "ralink,mt7620a-soc";
+ model = "Ravpower WD03";
chosen {
bootargs = "console=ttyS0,115200";
@@ -13,19 +16,15 @@
gpio-leds {
compatible = "gpio-leds";
- ethernet {
- label = "cf-wr800n:white:ethernet";
- gpios = <&gpio2 4 1>;
+ green-wifi {
+ label = "wd03:green:wifi";
+ gpios = <&gpio2 0 GPIO_ACTIVE_HIGH>;
};
- wifi {
- label = "cf-wr800n:white:wifi";
- gpios = <&gpio3 0 1>;
- };
- wps {
- label = "cf-wr800n:white:wps";
- gpios = <&gpio1 15 1>;
+ blue-wifi {
+ label = "wd03:blue:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_HIGH>;
};
};
@@ -37,20 +36,12 @@
reset {
label = "reset";
- gpios = <&gpio0 2 1>;
- linux,code = <0x198>;
+ gpios = <&gpio2 1 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
};
-&gpio0 {
- status = "okay";
-};
-
-&gpio1 {
- status = "okay";
-};
-
&gpio2 {
status = "okay";
};
@@ -67,7 +58,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -95,8 +85,17 @@
};
};
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
&ethernet {
- mtd-mac-address = <&factory 0x4>;
+ mtd-mac-address = <&factory 0x4000>;
+ ralink,port-map = "wllll";
};
&wmac {
@@ -105,8 +104,8 @@
&pinctrl {
state_default: pinctrl0 {
- default {
- ralink,group = "ephy", "wled", "spi refclk", "i2c";
+ gpio {
+ ralink,group = "wled", "ephy";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/WE1026-5G-16M.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WE1026-5G-16M.dts
@@ -0,0 +1,76 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/dts-v1/;
+
+#include "WE1026-5G.dtsi"
+
+/ {
+ compatible = "zbtlink,we1026-5g-16m", "ralink,mt7620a-soc";
+ model = "ZBT WE1026-5G (16M)";
+};
+
+&spi0 {
+ status = "okay";
+
+ en25q128@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ firmware: partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/WE1026-5G.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WE1026-5G.dtsi
@@ -0,0 +1,124 @@
+/*
+ * BSD LICENSE
+ *
+ * Copyright(c) 2017 Kristian Evensen <kristian.evensen@gmail.com>.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Broadcom Corporation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "zbtlink,we1026-5g", "ralink,mt7620a-soc";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+ lan {
+ label = "we1026-5g:green:lan";
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "we1026-5g:green:usb";
+ gpios = <&gpio2 2 GPIO_ACTIVE_HIGH>;
+ };
+
+ wifi {
+ label = "we1026-5g:green:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&sdhci {
+ status = "okay";
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x28>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "i2c", "uartf", "spi refclk", "ephy", "wled";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+ pcie-bridge {
+ wifi@14c3,7662 {
+ compatible = "pci14c3,7662";
+ reg = <0x0000 0 0 0 0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+ };
+ };
+};
Index: sys/gnu/dts/mips/WF-2881.dts
===================================================================
--- sys/gnu/dts/mips/WF-2881.dts
+++ sys/gnu/dts/mips/WF-2881.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
+ compatible = "netis,wf-2881", "mediatek,mt7621-soc";
model = "NETIS WF-2881";
memory@0 {
@@ -15,50 +18,17 @@
bootargs = "console=ttyS0,57600";
};
- nand@1e003000 {
- status = "okay";
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- partition@30000 {
- label = "u-boot-env";
- reg = <0x30000 0x1000>;
- read-only;
- };
-
- partition@80000 {
- label = "config";
- reg = <0x80000 0x80000>;
- read-only;
- };
-
- factory: partition@100000 {
- label = "factory";
- reg = <0x100000 0x40000>;
- read-only;
- };
-
- partition@140000 {
- label = "firmware";
- reg = <0x140000 0x7E40000>;
- };
- };
-
gpio-leds {
compatible = "gpio-leds";
usb {
label = "wf-2881:green:usb";
- gpios = <&gpio0 6 1>;
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
};
wps {
label = "wf-2881:green:wps";
- gpios = <&gpio0 0 1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
};
};
@@ -70,14 +40,43 @@
reset {
label = "reset";
- gpios = <&gpio0 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
-&spi0 {
- status="disabled";
+&nand {
+ status = "okay";
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x1000>;
+ read-only;
+ };
+
+ partition@80000 {
+ label = "config";
+ reg = <0x80000 0x80000>;
+ read-only;
+ };
+
+ factory: partition@100000 {
+ label = "factory";
+ reg = <0x100000 0x40000>;
+ read-only;
+ };
+
+ partition@140000 {
+ label = "firmware";
+ reg = <0x140000 0x7E40000>;
+ };
};
&pcie {
@@ -88,7 +87,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -97,7 +96,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
Index: sys/gnu/dts/mips/WHR-1166D.dts
===================================================================
--- sys/gnu/dts/mips/WHR-1166D.dts
+++ sys/gnu/dts/mips/WHR-1166D.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "buffalo,whr-1166d", "ralink,mt7620a-soc";
model = "Buffalo WHR-1166D";
gpio-leds {
@@ -11,37 +14,37 @@
power {
label = "whr-1166d:red:power";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wifi {
label = "whr-1166d:green:wifi";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
power2 {
label = "whr-1166d:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wifi2 {
label = "whr-1166d:orange:wifi";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
internet {
label = "whr-1166d:green:internet";
- gpios = <&gpio2 17 1>;
+ gpios = <&gpio2 17 GPIO_ACTIVE_LOW>;
};
router {
label = "whr-1166d:orange:router";
- gpios = <&gpio2 18 1>;
+ gpios = <&gpio2 18 GPIO_ACTIVE_LOW>;
};
router2 {
label = "whr-1166d:green:router";
- gpios = <&gpio2 19 1>;
+ gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
};
};
@@ -53,28 +56,28 @@
reset {
label = "reset";
- gpios = <&gpio2 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio2 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio2 13 1>;
- linux,code = <0x211>;
+ gpios = <&gpio2 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
ap {
label = "ap";
- gpios = <&gpio2 14 1>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio2 14 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
bridge {
label = "bridge";
- gpios = <&gpio2 15 1>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio2 15 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
};
@@ -91,7 +94,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -143,7 +145,7 @@
phy5: ethernet-phy@5 {
reg = <5>;
- phy-mode = "rgmii";
+ phy-mode = "rgmii-rxid";
};
};
};
@@ -160,11 +162,11 @@
status = "okay";
pcie-bridge {
- mt76@0,0 {
+ wifi@0,0 {
+ compatible = "pci0,0";
reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 32768>;
- mediatek,2ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
Index: sys/gnu/dts/mips/WHR-300HP2.dts
===================================================================
--- sys/gnu/dts/mips/WHR-300HP2.dts
+++ sys/gnu/dts/mips/WHR-300HP2.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "buffalo,whr-300hp2", "ralink,mt7620a-soc";
model = "Buffalo WHR-300HP2";
gpio-leds {
@@ -11,37 +14,37 @@
power {
label = "whr-300hp2:red:power";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wifi {
label = "whr-300hp2:green:wifi";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
power2 {
label = "whr-300hp2:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wifi2 {
label = "whr-300hp2:orange:wifi";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
internet {
label = "whr-300hp2:green:internet";
- gpios = <&gpio2 17 1>;
+ gpios = <&gpio2 17 GPIO_ACTIVE_LOW>;
};
router {
label = "whr-300hp2:green:router";
- gpios = <&gpio2 18 1>;
+ gpios = <&gpio2 18 GPIO_ACTIVE_LOW>;
};
router2 {
label = "whr-300hp2:orange:router";
- gpios = <&gpio2 19 1>;
+ gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
};
};
@@ -53,28 +56,28 @@
reset {
label = "reset";
- gpios = <&gpio2 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio2 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio2 13 1>;
- linux,code = <0x211>;
+ gpios = <&gpio2 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
ap {
label = "ap";
- gpios = <&gpio2 14 1>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio2 14 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
bridge {
label = "bridge";
- gpios = <&gpio2 15 1>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio2 15 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
};
@@ -91,7 +94,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
@@ -125,11 +127,6 @@
ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "wled", "nd_sd";
ralink,function = "gpio";
};
-
- pa {
- ralink,group = "pa";
- ralink,function = "pa";
- };
};
};
@@ -145,4 +142,6 @@
&wmac {
ralink,mtd-eeprom = <&factory 0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
};
Index: sys/gnu/dts/mips/WHR-600D.dts
===================================================================
--- sys/gnu/dts/mips/WHR-600D.dts
+++ sys/gnu/dts/mips/WHR-600D.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7620a-soc";
+ compatible = "buffalo,whr-600d", "ralink,mt7620a-soc";
model = "Buffalo WHR-600D";
gpio-leds {
@@ -11,37 +14,37 @@
power {
label = "whr-600d:red:power";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
wifi {
label = "whr-600d:green:wifi";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
power2 {
label = "whr-600d:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wifi2 {
label = "whr-600d:orange:wifi";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
internet {
label = "whr-600d:green:internet";
- gpios = <&gpio2 17 1>;
+ gpios = <&gpio2 17 GPIO_ACTIVE_LOW>;
};
router {
label = "whr-600d:green:router";
- gpios = <&gpio2 18 1>;
+ gpios = <&gpio2 18 GPIO_ACTIVE_LOW>;
};
router2 {
label = "whr-600d:orange:router";
- gpios = <&gpio2 19 1>;
+ gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
};
};
@@ -53,28 +56,28 @@
reset {
label = "reset";
- gpios = <&gpio2 12 1>;
- linux,code = <0x198>;
+ gpios = <&gpio2 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio2 13 1>;
- linux,code = <0x211>;
+ gpios = <&gpio2 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
ap {
label = "ap";
- gpios = <&gpio2 14 1>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio2 14 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
bridge {
label = "bridge";
- gpios = <&gpio2 15 1>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio2 15 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
};
@@ -91,7 +94,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l6405d";
spi-max-frequency = <10000000>;
partition@0 {
@@ -145,4 +147,12 @@
&pcie {
status = "okay";
+
+ pcie-bridge {
+ wifi@1814,5592 {
+ compatible = "pci1814,5592";
+ reg = <0x0000 0 0 0 0>;
+ ralink,mtd-eeprom = <&factory 0x8000>;
+ };
+ };
};
Index: sys/gnu/dts/mips/WHR-G300N.dts
===================================================================
--- sys/gnu/dts/mips/WHR-G300N.dts
+++ sys/gnu/dts/mips/WHR-G300N.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WHR-G300N", "ralink,rt3052-soc";
+ compatible = "buffalo,whr-g300n", "ralink,rt3052-soc";
model = "Buffalo WHR-G300N";
cfi@1f000000 {
@@ -13,6 +16,35 @@
device-width = <2>;
#address-cells = <1>;
#size-cells = <1>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x3a0000>;
+ };
+
+ partition@3f0000 {
+ label = "user";
+ reg = <0x3f0000 0x10000>;
+ read-only;
+ };
};
gpio-leds {
@@ -20,17 +52,17 @@
diag {
label = "whr-g300n:red:diag";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
router {
label = "whr-g300n:green:router";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
security {
label = "whr-g300n:amber:security";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -42,26 +74,26 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
router-off {
label = "router-off";
- gpios = <&gpio0 11 1>;
- linux,code = <0x102>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_2>;
};
router-on {
label = "router-on";
- gpios = <&gpio0 8 1>;
- linux,code = <0x103>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_3>;
};
};
};
@@ -75,12 +107,14 @@
};
};
+&ethernet {
+ mtd-mac-address = <&factory 0x4>;
+};
+
&esw {
mediatek,portmap = <0x2f>;
};
-/* FIXME: no partitions defined */
-/*&wmac {
+&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
-*/
Index: sys/gnu/dts/mips/WIDORA-NEO-16M.dts
===================================================================
--- sys/gnu/dts/mips/WIDORA-NEO-16M.dts
+++ sys/gnu/dts/mips/WIDORA-NEO-16M.dts
@@ -1,17 +1,25 @@
/dts-v1/;
-#include "WT1520.dtsi"
+#include "WIDORA-NEO.dtsi"
+
+/ {
+ compatible = "widora,neo-16m", "widora,neo", "mediatek,mt7628an-soc";
+ model = "Widora-NEO (16M)";
+};
&spi0 {
status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&spi_pins>, <&spi_cs1_pins>;
+
m25p80@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
- spi-max-frequency = <10000000>;
+ spi-max-frequency = <40000000>;
+ m25p,chunked-io = <31>;
partition@0 {
label = "u-boot";
@@ -22,7 +30,6 @@
partition@30000 {
label = "u-boot-env";
reg = <0x30000 0x10000>;
- read-only;
};
factory: partition@40000 {
@@ -33,7 +40,15 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
+ reg = <0x50000 0x0fb0000>;
};
};
+
+ spidev@1 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "linux,spidev";
+ reg = <1>;
+ spi-max-frequency = <40000000>;
+ };
};
Index: sys/gnu/dts/mips/WIDORA-NEO-32M.dts
===================================================================
--- sys/gnu/dts/mips/WIDORA-NEO-32M.dts
+++ sys/gnu/dts/mips/WIDORA-NEO-32M.dts
@@ -1,17 +1,25 @@
/dts-v1/;
-#include "WT1520.dtsi"
+#include "WIDORA-NEO.dtsi"
+
+/ {
+ compatible = "widora,neo-32m", "widora,neo", "mediatek,mt7628an-soc";
+ model = "Widora-NEO (32M)";
+};
&spi0 {
status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&spi_pins>, <&spi_cs1_pins>;
+
m25p80@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
- spi-max-frequency = <10000000>;
+ spi-max-frequency = <40000000>;
+ m25p,chunked-io = <31>;
partition@0 {
label = "u-boot";
@@ -22,7 +30,6 @@
partition@30000 {
label = "u-boot-env";
reg = <0x30000 0x10000>;
- read-only;
};
factory: partition@40000 {
@@ -33,7 +40,15 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0x3b0000>;
+ reg = <0x50000 0x1fb0000>;
};
};
+
+ spidev@1 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "linux,spidev";
+ reg = <1>;
+ spi-max-frequency = <40000000>;
+ };
};
Index: sys/gnu/dts/mips/WIDORA-NEO.dtsi
===================================================================
--- sys/gnu/dts/mips/WIDORA-NEO.dtsi
+++ sys/gnu/dts/mips/WIDORA-NEO.dtsi
@@ -1,17 +1,13 @@
-/dts-v1/;
-
#include "mt7628an.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,linkit", "mediatek,mt7628an-soc";
- model = "MediaTek LinkIt Smart 7688";
+ compatible = "widora,neo", "mediatek,mt7628an-soc";
chosen {
- bootargs = "console=ttyS2,57600";
- };
-
- aliases {
- serial0 = &uart2;
+ bootargs = "console=ttyS0,115200";
};
memory@0 {
@@ -19,18 +15,12 @@
reg = <0x0 0x8000000>;
};
- bootstrap {
- compatible = "mediatek,linkit";
-
- status = "okay";
- };
-
gpio-leds {
compatible = "gpio-leds";
wifi {
- label = "mediatek:orange:wifi";
- gpios = <&wgpio 0 0>;
+ label = "widora:orange:wifi";
+ gpios = <&wgpio 0 GPIO_ACTIVE_HIGH>;
default-state = "on";
};
};
@@ -43,8 +33,8 @@
wps {
label = "reset";
- gpios = <&gpio1 6 1>;
- linux,code = <0x211>;
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -101,57 +91,6 @@
};
};
-&wmac {
- status = "okay";
-};
-
-&spi0 {
- status = "okay";
-
- pinctrl-names = "default";
- pinctrl-0 = <&spi_pins>, <&spi_cs1_pins>;
-
- m25p80@0 {
- #address-cells = <1>;
- #size-cells = <1>;
- compatible = "jedec,spi-nor";
- reg = <0>;
- linux,modalias = "m25p80", "mx25l25635e";
- spi-max-frequency = <40000000>;
- m25p,chunked-io = <31>;
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- partition@30000 {
- label = "u-boot-env";
- reg = <0x30000 0x10000>;
- };
-
- factory: partition@40000 {
- label = "factory";
- reg = <0x40000 0x10000>;
- read-only;
- };
-
- partition@50000 {
- label = "firmware";
- reg = <0x50000 0x1fb0000>;
- };
- };
-
- spidev@1 {
- #address-cells = <1>;
- #size-cells = <1>;
- compatible = "linux,spidev";
- reg = <1>;
- spi-max-frequency = <40000000>;
- };
-};
-
&i2c {
status = "okay";
};
@@ -174,7 +113,7 @@
&sdhci {
status = "okay";
- mediatek,cd-high;
+ mediatek,cd-low;
};
&wmac {
Index: sys/gnu/dts/mips/WITI-256M.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WITI-256M.dts
@@ -0,0 +1,13 @@
+/dts-v1/;
+
+#include "WITI.dtsi"
+
+/ {
+ compatible = "mqmaker,witi-256m", "mqmaker,witi", "mediatek,mt7621-soc";
+ model = "MQmaker WiTi (256MB RAM)";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x10000000>;
+ };
+};
Index: sys/gnu/dts/mips/WITI-512M.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WITI-512M.dts
@@ -0,0 +1,13 @@
+/dts-v1/;
+
+#include "WITI.dtsi"
+
+/ {
+ compatible = "mqmaker,witi-512m", "mqmaker,witi", "mediatek,mt7621-soc";
+ model = "MQmaker WiTi (512MB RAM)";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
+ };
+};
Index: sys/gnu/dts/mips/WITI.dtsi
===================================================================
--- sys/gnu/dts/mips/WITI.dtsi
+++ sys/gnu/dts/mips/WITI.dtsi
@@ -2,14 +2,11 @@
#include "mt7621.dtsi"
-/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "MQmaker WiTi";
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
- memory@0 {
- device_type = "memory";
- reg = <0x0 0x10000000>;
- };
+/ {
+ compatible = "mqmaker,witi", "mediatek,mt7621-soc";
chosen {
bootargs = "console=ttyS0,57600";
@@ -17,12 +14,6 @@
palmbus: palmbus@1E000000 {
i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
status = "okay";
pcf8563: rtc@51 {
@@ -41,21 +32,16 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
-
&sdhci {
status = "okay";
};
-&xhci {
- status = "okay";
-};
-
&spi0 {
status = "okay";
@@ -64,8 +50,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -99,7 +85,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
mtd-mac-address = <&factory 0xe000>;
};
};
@@ -109,7 +95,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
mtd-mac-address = <&factory 0xe000>;
};
};
Index: sys/gnu/dts/mips/WIZARD8800.dts
===================================================================
--- sys/gnu/dts/mips/WIZARD8800.dts
+++ sys/gnu/dts/mips/WIZARD8800.dts
@@ -3,7 +3,7 @@
#include "rt5350.dtsi"
/ {
- compatible = "WIZARD8800", "ralink,rt5350-soc";
+ compatible = "easyacc,wizard8800", "ralink,rt5350-soc";
model = "EASYACC WI-STOR WIZARD 8800";
};
@@ -23,7 +23,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q32";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WIZFI630A.dts
===================================================================
--- sys/gnu/dts/mips/WIZFI630A.dts
+++ sys/gnu/dts/mips/WIZFI630A.dts
@@ -2,40 +2,38 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "wizfi630a", "ralink,rt5350-soc";
+ compatible = "wiznet,wizfi630a", "ralink,rt5350-soc";
model = "WIZnet WizFi630A";
chosen {
bootargs = "console=ttyS1,115200";
};
- gpio-export {
- compatible = "gpio-export";
- #size-cells = <0>;
- };
-
gpio-leds {
compatible = "gpio-leds";
run {
label = "wizfi630a::run";
- gpios = <&gpio0 1 1>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
};
wps {
label = "wizfi630a::wps";
- gpios = <&gpio0 20 1>;
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
uart1 {
label = "wizfi630a::uart1";
- gpios = <&gpio0 18 1>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
};
uart2 {
label = "wizfi630a::uart2";
- gpios = <&gpio0 21 1>;
+ gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
};
};
@@ -47,26 +45,26 @@
reset {
label = "reset";
- gpios = <&gpio0 17 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
scm1 {
label = "SCM1";
- gpios = <&gpio0 19 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 19 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
scm2 {
label = "SCM2";
- gpios = <&gpio0 2 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
@@ -83,7 +81,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -116,28 +113,9 @@
};
&uart {
- compatible = "ralink,mt7620a-uart", "ralink,rt2880-uart", "ns16550a";
- reg = <0x500 0x100>;
- resets = <&rstctrl 12>;
- reset-names = "uart";
- interrupt-parent = <&intc>;
- interrupts = <5>;
- reg-shift = <2>;
- pinctrl-names = "default";
- pinctrl-0 = <&uartf_pins>;
status = "okay";
-};
-
-&uartlite {
- compatible = "ralink,mt7620a-uart", "ralink,rt2880-uart", "ns16550a";
- reg = <0xc00 0x100>;
- resets = <&rstctrl 19>;
- reset-names = "uartl";
- interrupt-parent = <&intc>;
- interrupts = <12>;
- reg-shift = <2>;
pinctrl-names = "default";
- pinctrl-0 = <&uartlite_pins>;
+ pinctrl-0 = <&uartf_pins>;
};
&pinctrl {
@@ -147,20 +125,6 @@
ralink,function = "gpio";
};
};
-
- uartf_gpio_pins: uartf_gpio {
- uartf_gpio {
- ralink,group = "uartf";
- ralink,function = "uartf";
- };
- };
-
- uartlite_pins: uartlite {
- uart {
- ralink,group = "uartlite";
- ralink,function = "uartlite";
- };
- };
};
&ethernet {
Index: sys/gnu/dts/mips/WL-330N.dts
===================================================================
--- sys/gnu/dts/mips/WL-330N.dts
+++ sys/gnu/dts/mips/WL-330N.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WL-330N", "ralink,rt3050-soc";
+ compatible = "asus,wl-330n", "ralink,rt3050-soc";
model = "Asus WL-330N";
gpio-leds {
@@ -11,12 +14,12 @@
link {
label = "wl-330n:blue:link";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
power {
label = "wl-330n:blue:power";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
};
@@ -28,14 +31,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -48,7 +51,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WL-330N3G.dts
===================================================================
--- sys/gnu/dts/mips/WL-330N3G.dts
+++ sys/gnu/dts/mips/WL-330N3G.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WL-330N3G", "ralink,rt3050-soc";
+ compatible = "asus,wl-330n3g", "ralink,rt3050-soc";
model = "Asus WL-330N3G";
gpio-leds {
@@ -11,17 +14,17 @@
3g {
label = "wl-330n3g:blue:3g";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
3g2 {
label = "wl-330n3g:red:3g";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
power {
label = "wl-330n3g:blue:power";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
};
@@ -33,14 +36,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -53,7 +56,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WL-341V3.dts
===================================================================
--- sys/gnu/dts/mips/WL-341V3.dts
+++ sys/gnu/dts/mips/WL-341V3.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WL-341V3", "ralink,rt3052-soc";
+ compatible = "sitecom,wl-341-v3", "ralink,rt3052-soc";
model = "Sitecom WL-341 v3";
cfi@1f000000 {
@@ -43,37 +46,37 @@
first {
label = "wl-341v3:amber:first";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
first2 {
label = "wl-341v3:blue:first";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
third {
label = "wl-341v3:amber:third";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
third2 {
label = "wl-341v3:blue:third";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
fourth {
label = "wl-341v3:blue:fourth";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
fifth {
label = "wl-341v3:amber:fifth";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
fifth2 {
label = "wl-341v3:blue:fifth";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
};
@@ -85,14 +88,14 @@
reset {
label = "reset";
- gpios = <&gpio0 7 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 5 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
Index: sys/gnu/dts/mips/WL-351.dts
===================================================================
--- sys/gnu/dts/mips/WL-351.dts
+++ sys/gnu/dts/mips/WL-351.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WL-351", "ralink,rt3052-soc";
+ compatible = "sitecom,wl-351", "ralink,rt3052-soc";
model = "Sitecom WL-351 v1 002";
cfi@1f000000 {
@@ -43,17 +46,17 @@
power {
label = "wl-351:amber:power";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
unpopulated {
label = "wl-351:amber:unpopulated";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
unpopulated2 {
label = "wl-351:blue:unpopulated";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -65,28 +68,28 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
rtl8366rb {
- compatible = "rtl8366rb";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ compatible = "realtek,rtl8366rb";
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
};
};
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "spi", "i2c", "jtag", "mdio", "uartf";
ralink,function = "gpio";
};
};
@@ -94,9 +97,12 @@
&ethernet {
mtd-mac-address = <&factory 0x4>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&rgmii_pins>;
};
&esw {
+ ralink,rgmii = <1>;
mediatek,portmap = <0x3f>;
ralink,fct2 = <0x0002500c>;
/*
Index: sys/gnu/dts/mips/WL-WN575A3.dts
===================================================================
--- sys/gnu/dts/mips/WL-WN575A3.dts
+++ sys/gnu/dts/mips/WL-WN575A3.dts
@@ -1,50 +1,83 @@
/dts-v1/;
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
-#include "mt7621.dtsi"
+#include "mt7628an.dtsi"
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "Linksys RE6500";
+ compatible = "wavlink,wl-wn575a3", "mediatek,mt7628an-soc";
+ model = "Wavlink WL-WN575A3";
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
memory@0 {
device_type = "memory";
reg = <0x0 0x4000000>;
};
- chosen {
- bootargs = "console=ttyS0,57600";
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
};
gpio-leds {
compatible = "gpio-leds";
- wifi {
- label = "re6500:orange:wifi";
- gpios = <&gpio0 0 0>;
+ wifi-high {
+ label = "wl-wn575a3:green:wifi-high";
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
};
- power {
- label = "re6500:white:power";
- gpios = <&gpio0 9 0>;
+ wifi-med {
+ label = "wl-wn575a3:green:wifi-med";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
- };
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
+ wifi-low {
+ label = "wl-wn575a3:green:wifi-low";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
+ };
wps {
- label = "wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x211>;
+ label = "wl-wn575a3:green:wps";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
};
+ };
+};
- reset {
- label = "reset";
- gpios = <&gpio0 11 0>;
- linux,code = <0x198>;
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "wled_an";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+ pcie-bridge {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
@@ -57,8 +90,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -85,37 +118,12 @@
};
};
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "uart2", "uart3", "rgmii2";
- ralink,function = "gpio";
- };
- };
-};
-
-&pcie {
+&wmac {
status = "okay";
-
- pcie0 {
- mt76@0,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,2ghz = <0>;
- };
- };
-
- pcie1 {
- mt76@1,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,5ghz = <0>;
- };
- };
+ ralink,mtd-eeprom = <&factory 0x4>;
};
&ethernet {
mtd-mac-address = <&factory 0x2e>;
+ mediatek,portmap = "llllw";
};
Index: sys/gnu/dts/mips/WLI-TX4-AG300N.dts
===================================================================
--- sys/gnu/dts/mips/WLI-TX4-AG300N.dts
+++ sys/gnu/dts/mips/WLI-TX4-AG300N.dts
@@ -2,10 +2,13 @@
#include "rt2880.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "WLI-TX4-AG300N", "ralink,rt2880-soc";
+ compatible = "buffalo,wli-tx4-ag300n", "ralink,rt2880-soc";
model = "Buffalo WLI-TX4-AG300N";
cfi@1f000000 {
@@ -35,7 +38,7 @@
};
partition@50000 {
- label = "linux";
+ label = "firmware";
reg = <0x50000 0x3b0000>;
};
};
@@ -48,20 +51,20 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
bandwidth {
label = "bandwidth";
- gpios = <&gpio0 8 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
reset {
label = "reset";
- gpios = <&gpio0 9 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -70,17 +73,17 @@
diag {
label = "wli-tx4-ag300n:red:diag";
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
};
power {
label = "wli-tx4-ag300n:blue:power";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
security {
label = "wli-tx4-ag300n:blue:security";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
};
@@ -94,7 +97,16 @@
mtd-mac-address = <&factory 0x4>;
port@0 {
- mediatek,fixed-link = <1000 1 1 1>;
+ mediatek,fixed-link = <100 1 1 1>;
+ };
+
+ mdio-bus {
+ status = "okay";
+
+ phy0: ethernet-phy@0 {
+ phy-mode = "mii";
+ reg = <0>;
+ };
};
};
Index: sys/gnu/dts/mips/WLR-6000.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WLR-6000.dts
@@ -0,0 +1,187 @@
+/dts-v1/;
+
+#include "rt3883.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "sitecom,wlr-6000", "ralink,rt3883-soc";
+ model = "Sitecom WLR-6000";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "wlr-6000:red:power";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ };
+
+ ops {
+ label = "wlr-6000:white:ops";
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ usb {
+ gpio-export,name = "usb";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "jtag", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ status = "okay";
+ mtd-mac-address = <&factory 0x8004>;
+ mtd-mac-address-increment = <1>;
+
+ port@0 {
+ phy-handle = <&phy0>;
+ phy-mode = "rgmii";
+ };
+
+ mdio-bus {
+ status = "okay";
+
+ phy0: ethernet-phy@0 {
+ reg = <0>;
+ phy-mode = "rgmii";
+
+ qca,ar8327-initvals = <
+ 0x04 0x07600000 /* PORT0 PAD MODE CTRL */
+ 0x0c 0x07600000 /* PORT6 PAD MODE CTRL */
+ 0x10 0x40000000 /* Power-on Strapping: 176-pin interface configuration */
+ 0x50 0xc437c437 /* LED Control Register 0 */
+ 0x54 0xc337c337 /* LED Control Register 1 */
+ 0x58 0x00000000 /* LED Control Register 2 */
+ 0x5c 0x03ffff00 /* LED Control Register 3 */
+ 0x7c 0x0000007e /* PORT0_STATUS */
+ 0x94 0x0000007e /* PORT6 STATUS */
+ >;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <8600000>;
+ m25p,fast-read;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0x713000>;
+ };
+
+ partition@763000 {
+ label = "manufacture";
+ reg = <0x763000 0x7D000>;
+ read-only;
+ };
+
+ partition@7E0000 {
+ label = "backup";
+ reg = <0x7E0000 0x10000>;
+ read-only;
+ };
+
+ partition@7F0000 {
+ label = "storage";
+ reg = <0x7F0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&pci {
+ status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&pci_pins>;
+
+ pci_pins: pci {
+ pci {
+ ralink,group = "pci";
+ ralink,function = "pci-fnc";
+ };
+ };
+
+ host-bridge {
+ pci-bridge@1 {
+ status = "okay";
+
+ wifi@1814,3091 {
+ compatible = "pci1814,3091";
+ reg = <0x10000 0 0 0 0>;
+ ralink,mtd-eeprom = <&factory 0x8000>;
+ };
+ };
+ };
+};
+
+&wmac {
+ status = "okay";
+ ralink,2ghz = <0>;
+ ralink,mtd-eeprom = <&factory 0x0>;
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/WMDR-143N.dts
===================================================================
--- sys/gnu/dts/mips/WMDR-143N.dts
+++ sys/gnu/dts/mips/WMDR-143N.dts
@@ -1,10 +1,10 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "rt3883.dtsi"
/ {
- compatible = "NCS601W", "ralink,rt5350-soc";
- model = "Wansview NCS601W";
+ compatible = "loewe,wmdr-143n", "ralink,rt3883-soc";
+ model = "Loewe WMDR-143N";
};
&spi0 {
@@ -15,8 +15,7 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
- spi-max-frequency = <10000000>;
+ spi-max-frequency = <25000000>;
partition@0 {
label = "u-boot";
@@ -26,7 +25,7 @@
partition@30000 {
label = "u-boot-env";
- reg = <0x30000 0x10000>;
+ reg = <0x30000 0x00010000>;
read-only;
};
@@ -43,31 +42,23 @@
};
};
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
&ethernet {
- mtd-mac-address = <&factory 0x4>;
-};
+ port@0 {
+ phy-handle = <&phy0>;
+ phy-mode = "mii";
+ };
+ mdio-bus {
+ status = "okay";
-&esw {
- mediatek,portmap = <0x2f>;
+ phy0: ethernet-phy@0 {
+ reg = <0>;
+ phy-mode = "mii";
+ };
+ };
};
&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
status = "okay";
+ ralink,mtd-eeprom = <&factory 0>;
+ mtd-mac-address = <&factory 0x4>;
};
Index: sys/gnu/dts/mips/WMR-300.dts
===================================================================
--- sys/gnu/dts/mips/WMR-300.dts
+++ sys/gnu/dts/mips/WMR-300.dts
@@ -2,6 +2,9 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "buffalo,wmr-300", "ralink,mt7620n-soc";
model = "Buffalo WMR-300";
@@ -11,17 +14,17 @@
aoss1 {
label = "wmr-300:red:aoss";
- gpios = <&gpio2 1 1>;
+ gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
};
aoss2 {
label = "wmr-300:green:aoss";
- gpios = <&gpio2 2 1>;
+ gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
};
power {
label = "wmr-300:green:status";
- gpios = <&gpio2 4 1>;
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
};
};
@@ -33,14 +36,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -57,7 +60,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WN-GX300GR.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WN-GX300GR.dts
@@ -0,0 +1,156 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "iodata,wn-gx300gr", "mediatek,mt7621-soc";
+ model = "I-O DATA WN-GX300GR";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x4000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "wn-gx300gr:green:power";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "wn-gx300gr:green:wps";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ auto {
+ label = "auto";
+ gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
+ };
+
+ custom {
+ label = "custom";
+ gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
+ };
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "Bootloader";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "Config";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ Factory: partition@40000 {
+ label = "Factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "iNIC_rf";
+ reg = <0x50000 0x10000>;
+ read-only;
+ };
+
+ partition@60000 {
+ label = "firmware";
+ reg = <0x60000 0x770000>;
+ };
+
+ partition@7d0000 {
+ label = "Key";
+ reg = <0x7d0000 0x10000>;
+ read-only;
+ };
+
+ partition@7e0000 {
+ label = "backup";
+ reg = <0x7e0000 0x10000>;
+ read-only;
+ };
+
+ partition@7f0000 {
+ label = "storage";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&Factory 0x4>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "uart2", "uart3", "jtag";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+
+ pcie0 {
+ mt76@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&Factory 0x0>;
+ };
+ };
+};
+
+&xhci {
+ status = "disabled";
+};
Index: sys/gnu/dts/mips/WN3000RPV3.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WN3000RPV3.dts
@@ -0,0 +1,143 @@
+/* This file is released into the public domain */
+
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ compatible = "netgear,wn3000rp-v3", "ralink,mt7620a-soc";
+ model = "Netgear WN3000RPv3";
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power_g {
+ label = "wn3000rpv3:green:power";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ default-state = "on";
+ };
+
+ power_r {
+ label = "wn3000rpv3:red:power";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ client_g {
+ label = "wn3000rpv3:green:client";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+
+ client_r {
+ label = "wn3000rpv3:red:client";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ router_g {
+ label = "wn3000rpv3:green:router";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ };
+
+ router_r {
+ label = "wn3000rpv3:red:router";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "wn3000rpv3:green:wps";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
+ };
+
+ l_arrow {
+ label = "wn3000rpv3:blue:leftarrow";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ };
+
+ r_arrow {
+ label = "wn3000rpv3:blue:rightarrow";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+};
+
+&gpio1 {
+ status = "okay";
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ partition@40000 {
+ label = "firmware";
+ reg = <0x40000 0x7b0000>;
+ };
+
+ art: partition@7f0000 {
+ label = "art";
+ reg = <0x7f0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&art 0x0>;
+};
+
+&wmac {
+ mtd-mac-address = <&art 0x6>;
+ ralink,mtd-eeprom = <&art 0x1000>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "i2c", "uartf", "spi refclk";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/WNCE2001.dts
===================================================================
--- sys/gnu/dts/mips/WNCE2001.dts
+++ sys/gnu/dts/mips/WNCE2001.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WNCE2001", "ralink,rt3052-soc";
+ compatible = "netgear,wnce2001", "ralink,rt3052-soc";
model = "Netgear WNCE2001";
chosen {
@@ -15,22 +18,22 @@
power-green {
label = "wnce2001:green:power";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
power-red {
label = "wnce2001:red:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan-green {
label = "wnce2001:green:wlan";
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
wlan-red {
label = "wnce2001:red:wlan";
- gpios = <&gpio0 13 0>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
};
@@ -42,26 +45,26 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
rt {
label = "rt";
- gpios = <&gpio0 11 1>;
- linux,code = <0x100>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
ap {
label = "ap";
- gpios = <&gpio0 7 1>;
- linux,code = <0x101>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_1>;
};
};
};
@@ -74,7 +77,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l3205d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WNDR3700V5.dts
===================================================================
--- sys/gnu/dts/mips/WNDR3700V5.dts
+++ sys/gnu/dts/mips/WNDR3700V5.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board","ralink,mt7621-soc";
+ compatible = "netgear,wndr3700-v5", "mediatek,mt7621-soc";
model = "Netgear WNDR3700v5";
memory@0 {
@@ -20,12 +23,12 @@
wps {
label = "wndr3700v5:green:wps";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
power {
label = "wndr3700v5:green:power";
- gpios = <&gpio0 18 1>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
};
};
@@ -37,20 +40,20 @@
wps {
label = "wndr3700v5:wps";
- gpios = <&gpio0 7 0>;
- linux,code = <0x211>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_WPS_BUTTON>;
};
wifi {
label = "wndr3700v5:wifi";
- gpios = <&gpio0 8 0>;
- linux,code = <0xf7>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RFKILL>;
};
reset {
label = "wndr3700v5:reset";
- gpios = <&gpio0 14 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -61,7 +64,7 @@
usbpower {
gpio-export,name = "usbpower";
gpio-export,output = <1>;
- gpios = <&gpio0 10 1>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
};
};
};
@@ -69,17 +72,18 @@
&spi0 {
status = "okay";
- m25p80@0 {
+ mx25l12805d@0 {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "mx25l12805d";
+ compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
reg = <0x0 0x30000>;
+ read-only;
};
partition@30000 {
@@ -96,7 +100,7 @@
partition@50000 {
label = "firmware";
- reg = <0x50000 0xfb0000>;
+ reg = <0x50000 0xee0000>;
};
};
};
@@ -108,17 +112,16 @@
mt76@0,0 {
reg = <0x0000 0 0 0 0>;
device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0004>;
- mediatek,2ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
- pcie2 {
- mt76@2,0 {
- reg = <0x1000 0 0 0 0>;
+ pcie1 {
+ mt76@1,0 {
+ reg = <0x0000 0 0 0 0>;
device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8004>;
- mediatek,5ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x0000>;
};
};
};
Index: sys/gnu/dts/mips/WR1200JS.dts
===================================================================
--- sys/gnu/dts/mips/WR1200JS.dts
+++ sys/gnu/dts/mips/WR1200JS.dts
@@ -2,28 +2,38 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "ZBT-WG2626";
+ compatible = "youhua,wr1200js", "mediatek,mt7621-soc";
+ model = "YouHua WR1200JS";
memory@0 {
device_type = "memory";
- reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
+ reg = <0x0 0x8000000>;
};
chosen {
bootargs = "console=ttyS0,115200";
};
- palmbus: palmbus@1E000000 {
- i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
- status = "okay";
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ internet {
+ label = "wr1200js:blue:internet";
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "wr1200js:blue:wps";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "wr1200js:blue:usb";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
};
@@ -35,25 +45,24 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
- };
- gpio-leds {
- compatible = "gpio-leds";
+ wps {
+ label = "wps";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
- status {
- label = "zbt-wg2626:green:status";
- gpios = <&gpio0 24 1>;
+ wifi {
+ label = "wifi";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
};
};
};
-&sdhci {
- status = "okay";
-};
-
&spi0 {
status = "okay";
@@ -62,8 +71,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -97,8 +106,7 @@
mt76@0,0 {
reg = <0x0000 0 0 0 0>;
device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x0000>;
};
};
@@ -106,8 +114,13 @@
mt76@1,0 {
reg = <0x0000 0 0 0 0>;
device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+
+ led {
+ led-sources = <2>;
+ led-active-low;
+ };
};
};
};
@@ -119,7 +132,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "wdt rst", "jtag", "mdio";
+ ralink,group = "i2c", "uart2", "uart3", "wdt";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/WR512-3GN-4M.dts
===================================================================
--- sys/gnu/dts/mips/WR512-3GN-4M.dts
+++ sys/gnu/dts/mips/WR512-3GN-4M.dts
@@ -1,10 +1,10 @@
/dts-v1/;
-#include "rt3050.dtsi"
+#include "WR512-3GN.dtsi"
/ {
- compatible = "WR512-3GN", "ralink,rt3052-soc";
- model = "WR512-3GN-like router";
+ compatible = "unbranded,wr512-3gn-4m", "unbranded,wr512-3gn", "ralink,rt3052-soc";
+ model = "WR512-3GN (4M)";
cfi@1f000000 {
compatible = "cfi-flash";
@@ -37,73 +37,4 @@
reg = <0x50000 0x3c8000>;
};
};
-
- gpio-leds {
- compatible = "gpio-leds";
-
- 3g {
- label = "wr512-3gn:green:3g";
- gpios = <&gpio0 9 1>;
- };
-
- gateway {
- label = "wr512-3gn:green:gateway";
- gpios = <&gpio0 11 1>;
- };
-
- ap {
- label = "wr512-3gn:green:ap";
- gpios = <&gpio0 12 1>;
- };
-
- wps {
- label = "wr512-3gn:green:wps";
- gpios = <&gpio0 14 1>;
- };
-
- station {
- label = "wr512-3gn:green:station";
- gpios = <&gpio0 13 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset_wps {
- label = "reset_wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
-
- mode {
- label = "mode";
- gpios = <&gpio0 7 1>;
- linux,code = <0x32>;
- };
- };
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&otg {
- status = "okay";
};
Index: sys/gnu/dts/mips/WR512-3GN-8M.dts
===================================================================
--- sys/gnu/dts/mips/WR512-3GN-8M.dts
+++ sys/gnu/dts/mips/WR512-3GN-8M.dts
@@ -1,10 +1,10 @@
/dts-v1/;
-#include "rt3050.dtsi"
+#include "WR512-3GN.dtsi"
/ {
- compatible = "WR512-3GN", "ralink,rt3052-soc";
- model = "WR512-3GN-like router";
+ compatible = "unbranded,wr512-3gn-8m", "unbranded,wr512-3gn", "ralink,rt3052-soc";
+ model = "WR512-3GN (8M)";
cfi@1f000000 {
compatible = "cfi-flash";
@@ -37,73 +37,4 @@
reg = <0x50000 0x7b0000>;
};
};
-
- gpio-leds {
- compatible = "gpio-leds";
-
- 3g {
- label = "wr512-3gn:green:3g";
- gpios = <&gpio0 9 1>;
- };
-
- gateway {
- label = "wr512-3gn:green:gateway";
- gpios = <&gpio0 11 1>;
- };
-
- ap {
- label = "wr512-3gn:green:ap";
- gpios = <&gpio0 12 1>;
- };
-
- wps {
- label = "wr512-3gn:green:wps";
- gpios = <&gpio0 14 1>;
- };
-
- station {
- label = "wr512-3gn:green:station";
- gpios = <&gpio0 13 1>;
- };
- };
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset_wps {
- label = "reset_wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
- };
-
- mode {
- label = "mode";
- gpios = <&gpio0 7 1>;
- linux,code = <0x32>;
- };
- };
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
- ralink,function = "gpio";
- };
- };
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&otg {
- status = "okay";
};
Index: sys/gnu/dts/mips/WR512-3GN.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WR512-3GN.dtsi
@@ -0,0 +1,77 @@
+#include "rt3050.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "unbranded,wr512-3gn", "ralink,rt3052-soc";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ 3g {
+ label = "wr512-3gn:green:3g";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ };
+
+ gateway {
+ label = "wr512-3gn:green:gateway";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ ap {
+ label = "wr512-3gn:green:ap";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "wr512-3gn:green:wps";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ station {
+ label = "wr512-3gn:green:station";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset_wps {
+ label = "reset_wps";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ mode {
+ label = "mode";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&esw {
+ mediatek,portmap = <0x2f>;
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&otg {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/WR6202.dts
===================================================================
--- sys/gnu/dts/mips/WR6202.dts
+++ sys/gnu/dts/mips/WR6202.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "WR6202", "ralink,rt3052-soc";
+ compatible = "accton,wr6202", "ralink,rt3052-soc";
model = "AWB WR6202";
chosen {
@@ -15,12 +18,12 @@
wps {
label = "wr6202:blue:wps";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
3g {
label = "wr6202:blue:3g";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -32,14 +35,14 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
@@ -82,7 +85,7 @@
usb {
gpio-export,name = "usb";
gpio-export,output = <0>;
- gpios = <&gpio0 11 0>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/WRC-1167GHBK2-S.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WRC-1167GHBK2-S.dts
@@ -0,0 +1,144 @@
+/dts-v1/;
+
+#include "mt7621.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "elecom,wrc-1167ghbk2-s", "mediatek,mt7621-soc";
+ model = "ELECOM WRC-1167GHBK2-S";
+
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x8000000>;
+ };
+
+ chosen {
+ bootargs = "console=ttyS0,57600";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ wlan2g {
+ label = "wrc-1167ghbk2-s:white:wlan2g";
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan5g {
+ label = "wrc-1167ghbk2-s:white:wlan5g";
+ gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
+ };
+
+ power_green {
+ label = "wrc-1167ghbk2-s:green:power";
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
+ };
+
+ power_blue {
+ label = "wrc-1167ghbk2-s:blue:power";
+ gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+ };
+
+ wps {
+ label = "wrc-1167ghbk2-s:red:wps";
+ gpios = <&gpio0 15 GPIO_ACTIVE_HIGH>;
+ };
+
+ power_red {
+ label = "wrc-1167ghbk2-s:red:power";
+ gpios = <&gpio0 16 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0xe000>;
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xf20000>;
+ };
+
+ partition@f70000 {
+ label = "user_data";
+ reg = <0xf70000 0x80000>;
+ read-only;
+ };
+
+ partition@ff0000 {
+ label = "NVRAM";
+ reg = <0xff0000 0x10000>;
+ read-only;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uart3", "jtag", "wdt";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&pcie {
+ status = "okay";
+ // WRC-1167GHBK2-S has MT7615D for 2.4/5 GHz wifi,
+ // but it's not supported in OpenWrt.
+};
+
+&xhci {
+ status = "disabled";
+};
Index: sys/gnu/dts/mips/WRH-300CR.dts
===================================================================
--- sys/gnu/dts/mips/WRH-300CR.dts
+++ sys/gnu/dts/mips/WRH-300CR.dts
@@ -2,6 +2,9 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "elecom,wrh-300cr", "ralink,mt7620n-soc";
model = "ELECOM WRH-300CR";
@@ -11,17 +14,17 @@
wps {
label = "wrh-300cr:green:wps";
- gpios = <&gpio2 0 1>;
+ gpios = <&gpio2 0 GPIO_ACTIVE_LOW>;
};
ethernet {
label = "wrh-300cr:green:ethernet";
- gpios = <&gpio2 3 1>;
+ gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
};
wlan {
label = "wrh-300cr:green:wlan";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -33,14 +36,14 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 2 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -65,7 +68,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "mx25l12805d";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WRTNODE.dts
===================================================================
--- sys/gnu/dts/mips/WRTNODE.dts
+++ sys/gnu/dts/mips/WRTNODE.dts
@@ -2,8 +2,10 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+
/ {
- compatible = "wrtnode", "ralink,mt7620n-soc";
+ compatible = "wrtnode,wrtnode", "ralink,mt7620n-soc";
model = "WRTNODE";
gpio-leds {
@@ -11,7 +13,7 @@
indicator {
label = "wrtnode:blue:indicator";
- gpios = <&gpio1 14 1>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
};
};
@@ -36,7 +38,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WRTNODE2.dtsi
===================================================================
--- sys/gnu/dts/mips/WRTNODE2.dtsi
+++ sys/gnu/dts/mips/WRTNODE2.dtsi
@@ -1,6 +1,11 @@
#include "mt7628an.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
+ compatible = "wrtnode,wrtnode2", "mediatek,mt7628an-soc";
+
chosen {
bootargs = "console=ttyS0,115200";
};
@@ -13,8 +18,8 @@
reset {
label = "reset";
- gpios = <&gpio0 5 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -73,7 +78,7 @@
&ethernet {
mtd-mac-address = <&factory 0x4>;
- ralink,port-map = "llllw";
+ mediatek,portmap = "llllw";
};
&sdhci {
Index: sys/gnu/dts/mips/WRTNODE2P.dts
===================================================================
--- sys/gnu/dts/mips/WRTNODE2P.dts
+++ sys/gnu/dts/mips/WRTNODE2P.dts
@@ -3,7 +3,7 @@
#include "WRTNODE2.dtsi"
/ {
- compatible = "mediatek,wrtnode2p", "mediatek,mt7628an-soc";
+ compatible = "wrtnode,wrtnode2p", "wrtnode,wrtnode2", "mediatek,mt7628an-soc";
model = "WRTnode2P";
gpio-leds {
@@ -11,7 +11,7 @@
indicator {
label = "wrtnode:blue:indicator";
- gpios = <&gpio1 9 1>;
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/WRTNODE2R.dts
===================================================================
--- sys/gnu/dts/mips/WRTNODE2R.dts
+++ sys/gnu/dts/mips/WRTNODE2R.dts
@@ -3,7 +3,7 @@
#include "WRTNODE2.dtsi"
/ {
- compatible = "mediatek,wrtnode2r", "mediatek,mt7628an-soc";
+ compatible = "wrtnode,wrtnode2r", "wrtnode,wrtnode2", "mediatek,mt7628an-soc";
model = "WRTnode2R";
gpio-leds {
@@ -11,7 +11,7 @@
indicator {
label = "wrtnode:blue:indicator";
- gpios = <&gpio1 12 1>;
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/WSR-1166.dts
===================================================================
--- sys/gnu/dts/mips/WSR-1166.dts
+++ sys/gnu/dts/mips/WSR-1166.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7621-eval-board", "ralink,mt7621-soc";
+ compatible = "buffalo,wsr-1166dhp", "mediatek,mt7621-soc";
model = "Buffalo WSR-1166DHP";
memory@0 {
@@ -20,42 +23,42 @@
internet_g {
label = "wsr-1166:green:internet";
- gpios = <&gpio1 9 1>;
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
};
router_g {
label = "wsr-1166:green:router";
- gpios = <&gpio1 10 1>;
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
};
router_o {
label = "wsr-1166:orange:router";
- gpios = <&gpio1 11 1>;
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
};
internet_o {
label = "wsr-1166:orange:internet";
- gpios = <&gpio1 12 1>;
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
};
wifi_o {
label = "wsr-1166:orange:wifi";
- gpios = <&gpio1 13 1>;
+ gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
};
power {
label = "wsr-1166:green:power";
- gpios = <&gpio1 14 1>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
diag {
label = "wsr-1166:orange:diag";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
wifi_g {
label = "wsr-1166:green:wifi";
- gpios = <&gpio1 16 1>;
+ gpios = <&gpio1 16 GPIO_ACTIVE_LOW>;
};
};
@@ -67,47 +70,47 @@
power {
label = "power";
- gpios = <&gpio0 18 1>;
- linux,code = <0x74>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_POWER>;
};
reset {
label = "reset";
- gpios = <&gpio0 3 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 3 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio0 6 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
auto {
label = "mode";
- gpios = <&gpio0 7 0>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
ap {
label = "ap";
- gpios = <&gpio0 10 0>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
router {
label = "router";
- gpios = <&gpio0 12 0>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
gpio_poweroff {
compatible = "gpio-poweroff";
- gpios = <&gpio0 0 1>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
};
};
@@ -119,8 +122,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -169,7 +172,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -178,7 +181,10 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
};
};
};
+
+&xhci {
+ status = "disabled";
+};
Index: sys/gnu/dts/mips/WSR-600.dts
===================================================================
--- sys/gnu/dts/mips/WSR-600.dts
+++ sys/gnu/dts/mips/WSR-600.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ralink,mt7621-eval-board", "ralink,mt7621-soc";
+ compatible = "buffalo,wsr-600dhp", "mediatek,mt7621-soc";
model = "Buffalo WSR-600DHP";
memory@0 {
@@ -20,42 +23,42 @@
power {
label = "wsr-600:green:power";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
wifi_o {
label = "wsr-600:orange:wifi";
- gpios = <&gpio1 9 1>;
+ gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
};
diag {
label = "wsr-600:orange:diag";
- gpios = <&gpio1 10 1>;
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
};
wifi_g {
label = "wsr-600:green:wifi";
- gpios = <&gpio1 12 1>;
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
};
router_o {
label = "wsr-600:orange:router";
- gpios = <&gpio1 13 1>;
+ gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
};
router_g {
label = "wsr-600:green:router";
- gpios = <&gpio1 14 1>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
internet_o {
label = "wsr-600:orange:internet";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
internet_g {
label = "wsr-600:green:internet";
- gpios = <&gpio1 16 1>;
+ gpios = <&gpio1 16 GPIO_ACTIVE_LOW>;
};
};
@@ -67,47 +70,47 @@
power {
label = "power";
- gpios = <&gpio0 8 1>;
- linux,code = <0x74>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_POWER>;
};
reset {
label = "reset";
- gpios = <&gpio0 11 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
aoss {
label = "aoss";
- gpios = <&gpio0 18 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
auto {
label = "mode";
- gpios = <&gpio0 7 0>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
ap {
label = "ap";
- gpios = <&gpio0 6 0>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
router {
label = "router";
- gpios = <&gpio0 10 0>;
- linux,code = <0x100>;
- linux,input-type = <5>; /* EV_SW */
+ gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
gpio_poweroff {
compatible = "gpio-poweroff";
- gpios = <&gpio1 11 1>;
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
};
};
@@ -119,8 +122,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -155,3 +158,27 @@
};
};
};
+
+&pcie {
+ status = "okay";
+
+ pcie0 {
+ rt5592@0,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ ralink,mtd-eeprom = <&factory 0x8000>;
+ };
+ };
+
+ pcie1 {
+ mt76@1,0 {
+ reg = <0x0000 0 0 0 0>;
+ device_type = "pci";
+ mediatek,mtd-eeprom = <&factory 0x0000>;
+ };
+ };
+};
+
+&xhci {
+ status = "disabled";
+};
Index: sys/gnu/dts/mips/WT1520-4M.dts
===================================================================
--- sys/gnu/dts/mips/WT1520-4M.dts
+++ sys/gnu/dts/mips/WT1520-4M.dts
@@ -2,6 +2,11 @@
#include "WT1520.dtsi"
+/ {
+ compatible = "nexx,wt1520-4m", "nexx,wt1520", "ralink,rt5350-soc";
+ model = "Nexx WT1520 (4M)";
+};
+
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WT1520-8M.dts
===================================================================
--- sys/gnu/dts/mips/WT1520-8M.dts
+++ sys/gnu/dts/mips/WT1520-8M.dts
@@ -2,6 +2,11 @@
#include "WT1520.dtsi"
+/ {
+ compatible = "nexx,wt1520-8m", "nexx,wt1520", "ralink,rt5350-soc";
+ model = "Nexx WT1520 (8M)";
+};
+
&spi0 {
status = "okay";
@@ -10,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/WT1520.dtsi
===================================================================
--- sys/gnu/dts/mips/WT1520.dtsi
+++ sys/gnu/dts/mips/WT1520.dtsi
@@ -1,29 +1,34 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "NEXXWT1520", "ralink,rt5350-soc";
- model = "Nexx WT1520";
+ compatible = "nexx,wt1520", "ralink,rt5350-soc";
memory@0 {
device_type = "memory";
reg = <0x0 0x2000000>;
};
- chosen {
- bootargs = "console=ttyS1,57600";
- };
-};
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
-&uart {
- pinctrl-names = "default";
- pinctrl-0 = <&uartf_pins>;
- status = "okay";
+ reset {
+ label = "reset";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
};
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "jtag";
+ ralink,group = "jtag", "uartf";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/WT3020-4M.dts
===================================================================
--- sys/gnu/dts/mips/WT3020-4M.dts
+++ sys/gnu/dts/mips/WT3020-4M.dts
@@ -1,40 +1,10 @@
/dts-v1/;
-#include "mt7620n.dtsi"
+#include "WT3020.dtsi"
/ {
- compatible = "wt3020", "ralink,mt7620n-soc";
- model = "Nexx WT3020";
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- power {
- label = "wt3020:blue:power";
- gpios = <&gpio3 0 0>;
- };
- };
-};
-
-&gpio2 {
- status = "okay";
-};
-
-&gpio3 {
- status = "okay";
+ compatible = "nexx,wt3020-4m", "nexx,wt3020", "ralink,mt7620n-soc";
+ model = "Nexx WT3020 (4M)";
};
&spi0 {
@@ -45,7 +15,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q32";
spi-max-frequency = <10000000>;
partition@0 {
@@ -72,29 +41,3 @@
};
};
};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x4>;
- mediatek,portmap = "wllll";
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- default {
- ralink,group = "ephy", "wled", "pa", "i2c", "wdt", "uartf";
- ralink,function = "gpio";
- };
- };
-};
Index: sys/gnu/dts/mips/WT3020-8M.dts
===================================================================
--- sys/gnu/dts/mips/WT3020-8M.dts
+++ sys/gnu/dts/mips/WT3020-8M.dts
@@ -1,39 +1,17 @@
/dts-v1/;
-#include "mt7620n.dtsi"
+#include "WT3020.dtsi"
/ {
- compatible = "wt3020", "ralink,mt7620n-soc";
- model = "Nexx WT3020";
-
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
-
- reset {
- label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- power {
- label = "wt3020:blue:power";
- gpios = <&gpio3 0 0>;
- };
- };
+ compatible = "nexx,wt3020-8m", "nexx,wt3020", "ralink,mt7620n-soc";
+ model = "Nexx WT3020 (8M)";
};
-&gpio2 {
+&ehci {
status = "okay";
};
-&gpio3 {
+&ohci {
status = "okay";
};
@@ -45,7 +23,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -72,29 +49,3 @@
};
};
};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
-&ethernet {
- mtd-mac-address = <&factory 0x4>;
- mediatek,portmap = "wllll";
-};
-
-&wmac {
- ralink,mtd-eeprom = <&factory 0>;
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- default {
- ralink,group = "ephy", "wled", "pa", "i2c", "wdt", "uartf";
- ralink,function = "gpio";
- };
- };
-};
Index: sys/gnu/dts/mips/WT3020.dtsi
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/WT3020.dtsi
@@ -0,0 +1,56 @@
+#include "mt7620n.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "nexx,wt3020", "ralink,mt7620n-soc";
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ power {
+ label = "wt3020:blue:power";
+ gpios = <&gpio3 0 GPIO_ACTIVE_HIGH>;
+ };
+ };
+};
+
+&gpio2 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
+&ethernet {
+ mtd-mac-address = <&factory 0x4>;
+ mediatek,portmap = "wllll";
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ default {
+ ralink,group = "ephy", "wled", "pa", "i2c", "wdt", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
Index: sys/gnu/dts/mips/WZR-AGL300NH.dts
===================================================================
--- sys/gnu/dts/mips/WZR-AGL300NH.dts
+++ sys/gnu/dts/mips/WZR-AGL300NH.dts
@@ -2,17 +2,16 @@
#include "rt2880.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "WZR-AGL300NH", "ralink,rt2880-soc";
+ compatible = "buffalo,wzr-agl300nh", "ralink,rt2880-soc";
model = "Buffalo WZR-AGL300NH";
pci@440000 {
- compatible = "ralink,rt288x-pci";
- reg = <0x00440000 0x20000>;
- #address-cells = <1>;
- #size-cells = <1>;
status = "ok";
};
@@ -50,8 +49,8 @@
rtl8366s {
compatible = "realtek,rtl8366s";
- gpio-sda = <&gpio0 1 0>;
- gpio-sck = <&gpio0 2 0>;
+ gpio-sda = <&gpio0 1 GPIO_ACTIVE_HIGH>;
+ gpio-sck = <&gpio0 2 GPIO_ACTIVE_HIGH>;
};
gpio-keys-polled {
@@ -62,20 +61,20 @@
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
router {
label = "router_switch";
- gpios = <&gpio0 7 0>;
- linux,code = <0x100>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
+ linux,code = <BTN_0>;
};
reset {
label = "reset";
- gpios = <&gpio0 9 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -84,22 +83,22 @@
router {
label = "wzr-agl300nh:green:router";
- gpios = <&gpio0 8 1>;
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
};
diag {
label = "wzr-agl300nh:red:diag";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
security_g {
label = "wzr-agl300nh:orange:security_g";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
security_n {
label = "wzr-agl300nh:orange:security_n";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/X5.dts
===================================================================
--- sys/gnu/dts/mips/X5.dts
+++ sys/gnu/dts/mips/X5.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "X5", "ralink,rt5350-soc";
+ compatible = "poray,x5", "ralink,rt5350-soc";
model = "Poray X5";
gpio-leds {
@@ -11,22 +14,22 @@
power {
label = "x5:green:power";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
20 {
label = "x5:green:20";
- gpios = <&gpio0 12 1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
50 {
label = "x5:green:50";
- gpios = <&gpio0 11 1>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
80 {
label = "x5:green:80";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
};
@@ -38,21 +41,21 @@
bat {
label = "bat";
- gpios = <&gpio0 9 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
mode {
label = "mode";
- gpios = <&gpio0 14 1>;
- linux,code = <0x100>;
- linux,input-type = <5>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ linux,input-type = <EV_SW>;
};
};
@@ -63,7 +66,7 @@
usb-mode {
gpio-export,name = "usb-mode";
gpio-export,output = <0>;
- gpios = <&gpio0 18 0>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
};
};
};
@@ -76,7 +79,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "gd25q64";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/X8.dts
===================================================================
--- sys/gnu/dts/mips/X8.dts
+++ sys/gnu/dts/mips/X8.dts
@@ -2,8 +2,11 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "X8", "ralink,rt5350-soc";
+ compatible = "poray,x8", "ralink,rt5350-soc";
model = "Poray X8";
gpio-leds {
@@ -11,7 +14,7 @@
power {
label = "x8:green:power";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
};
@@ -23,8 +26,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -37,7 +40,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "gd25q64";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/XDXRN502J.dts
===================================================================
--- sys/gnu/dts/mips/XDXRN502J.dts
+++ sys/gnu/dts/mips/XDXRN502J.dts
@@ -2,8 +2,11 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "XDXRN502J", "ralink,rt3052-soc";
+ compatible = "unbranded,xdxrn502j", "ralink,rt3052-soc";
model = "XDX RN502J";
cfi@1f000000 {
@@ -43,12 +46,12 @@
wifi {
label = "xdxrn502j:green:wifi";
- gpios = <&gpio0 7 1>;
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
};
power {
label = "xdxrn502j:green:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -60,8 +63,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
Index: sys/gnu/dts/mips/Y1.dts
===================================================================
--- sys/gnu/dts/mips/Y1.dts
+++ sys/gnu/dts/mips/Y1.dts
@@ -3,7 +3,7 @@
#include "Y1.dtsi"
/ {
- compatible = "lenovo,Y1", "ralink,mt7620a-soc";
+ compatible = "lenovo,newifi-y1", "ralink,mt7620a-soc";
model = "Lenovo Y1";
gpio-leds {
@@ -11,32 +11,32 @@
power1 {
label = "y1:blue:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan1 {
label = "y1:blue:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wlan2 {
label = "y1:blue:wifi5g";
- gpios = <&gpio2 10 1>;
+ gpios = <&gpio2 10 GPIO_ACTIVE_LOW>;
};
usb {
label = "y1:blue:usb";
- gpios = <&gpio2 12 1>;
+ gpios = <&gpio2 12 GPIO_ACTIVE_LOW>;
};
lan {
label = "y1:blue:lan";
- gpios = <&gpio2 15 1>;
+ gpios = <&gpio2 15 GPIO_ACTIVE_LOW>;
};
internet {
label = "y1:blue:internet";
- gpios = <&gpio2 11 1>;
+ gpios = <&gpio2 11 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/Y1.dtsi
===================================================================
--- sys/gnu/dts/mips/Y1.dtsi
+++ sys/gnu/dts/mips/Y1.dtsi
@@ -1,6 +1,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
+ compatible = "lenovo,newifi-y1", "ralink,mt7620a-soc";
+
chosen {
bootargs = "console=ttyS0,115200";
};
@@ -13,8 +18,8 @@
reset {
label = "reset";
- gpios = <&gpio0 11 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -39,7 +44,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -83,13 +87,15 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
&wmac {
ralink,mtd-eeprom = <&factory 0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
};
&pinctrl {
@@ -98,10 +104,5 @@
ralink,group = "uartf", "wled", "nd_sd";
ralink,function = "gpio";
};
-
- pa {
- ralink,group = "pa";
- ralink,function = "pa";
- };
};
};
Index: sys/gnu/dts/mips/Y1S.dts
===================================================================
--- sys/gnu/dts/mips/Y1S.dts
+++ sys/gnu/dts/mips/Y1S.dts
@@ -3,7 +3,7 @@
#include "Y1.dtsi"
/ {
- compatible = "lenovo,Y1S", "ralink,mt7620a-soc";
+ compatible = "lenovo,newifi-y1s", "lenovo,newifi-y1", "ralink,mt7620a-soc";
model = "Lenovo Y1S";
gpio_export {
@@ -13,17 +13,17 @@
usb0 {
gpio-export,name = "usb0";
gpio-export,output = <1>; // GPIOF_OUT_INIT_HIGH
- gpios = <&gpio2 14 0>; // GPIO2:40+14=GPIO 54
+ gpios = <&gpio2 14 GPIO_ACTIVE_HIGH>; // GPIO2:40+14=GPIO 54
};
usb1 {
gpio-export,name = "usb1";
gpio-export,output = <1>;
- gpios = <&gpio2 15 0>;
+ gpios = <&gpio2 15 GPIO_ACTIVE_HIGH>;
};
usb2 {
gpio-export,name = "usb2";
gpio-export,output = <1>;
- gpios = <&gpio2 16 0>;
+ gpios = <&gpio2 16 GPIO_ACTIVE_HIGH>;
};
};
@@ -32,37 +32,37 @@
power1 {
label = "y1s:yellow:power";
- gpios = <&gpio0 14 1>;
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
power2 {
label = "y1s:blue:power";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
wlan1 {
label = "y1s:yellow:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
wlan2 {
label = "y1s:blue:wifi";
- gpios = <&gpio2 10 1>;
+ gpios = <&gpio2 10 GPIO_ACTIVE_LOW>;
};
usb1 {
label = "y1s:yellow:usb";
- gpios = <&gpio2 13 1>;
+ gpios = <&gpio2 13 GPIO_ACTIVE_LOW>;
};
usb2 {
label = "y1s:blue:usb";
- gpios = <&gpio2 12 1>;
+ gpios = <&gpio2 12 GPIO_ACTIVE_LOW>;
};
internet {
label = "y1s:blue:internet";
- gpios = <&gpio2 11 1>;
+ gpios = <&gpio2 11 GPIO_ACTIVE_LOW>;
};
};
};
Index: sys/gnu/dts/mips/YOUKU-YK1.dts
===================================================================
--- sys/gnu/dts/mips/YOUKU-YK1.dts
+++ sys/gnu/dts/mips/YOUKU-YK1.dts
@@ -2,27 +2,30 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "YOUKU-YK1", "ralink,mt7620a-soc";
+ compatible = "youku,yk1", "ralink,mt7620a-soc";
model = "YOUKU YK1";
gpio-leds {
compatible = "gpio-leds";
wan {
label = "youku-yk1:blue:wan";
- gpios = <&gpio2 4 1>;
+ gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
};
air {
label = "youku-yk1:blue:air";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
usb {
label = "youku-yk1:blue:usb";
- gpios = <&gpio1 11 1>;
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
};
power {
label = "youku-yk1:blue:power";
- gpios = <&gpio1 5 1>;
+ gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
};
};
@@ -33,8 +36,8 @@
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -63,7 +66,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q256";
spi-max-frequency = <10000000>;
partition@0 {
@@ -94,7 +96,7 @@
&pinctrl {
state_default: pinctrl0 {
default {
- ralink,group = "i2c", "uartf", "rgmii1", "rgmii2", "ephy", "wled", "nd_sd";
+ ralink,group = "i2c", "rgmii1", "ephy", "wled";
ralink,function = "gpio";
};
};
@@ -102,7 +104,6 @@
&ethernet {
pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "llllw";
};
Index: sys/gnu/dts/mips/ZBT-APE522II.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-APE522II.dts
+++ sys/gnu/dts/mips/ZBT-APE522II.dts
@@ -2,9 +2,12 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "xiaomi,miwifi-mini", "ralink,mt7620a-soc";
- model = "Xiaomi MiWiFi Mini";
+ compatible = "zbtlink,zbt-ape522ii", "ralink,mt7620a-soc";
+ model = "ZBT-APE522II";
chosen {
bootargs = "console=ttyS0,115200";
@@ -13,19 +16,29 @@
gpio-leds {
compatible = "gpio-leds";
- blue {
- label = "miwifi-mini:blue:status";
- gpios = <&gpio1 0 1>;
+ sys1 {
+ label = "zbt-ape522ii:green:sys1";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ sys2 {
+ label = "zbt-ape522ii:green:sys2";
+ gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
};
- yellow {
- label = "miwifi-mini:yellow:status";
- gpios = <&gpio1 2 1>;
+ sys3 {
+ label = "zbt-ape522ii:green:sys3";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
- red {
- label = "miwifi-mini:red:status";
- gpios = <&gpio1 5 1>;
+ sys4 {
+ label = "zbt-ape522ii:green:sys4";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan2g4 {
+ label = "zbt-ape522ii:green:wlan2g4";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -37,8 +50,8 @@
reset {
label = "reset";
- gpios = <&gpio1 6 0>;
- linux,code = <0x198>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -55,6 +68,10 @@
status = "okay";
};
+&gpio3 {
+ status = "okay";
+};
+
&spi0 {
status = "okay";
@@ -63,7 +80,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "w25q128";
spi-max-frequency = <10000000>;
partition@0 {
@@ -87,42 +103,20 @@
label = "firmware";
reg = <0x50000 0xf80000>;
};
-
- partition@fd0000 {
- label = "crash";
- reg = <0xfd0000 0x10000>;
- };
-
- partition@fe0000 {
- label = "reserved";
- reg = <0xfe0000 0x10000>;
- read-only;
- };
-
- partition@ff0000 {
- label = "Bdata";
- reg = <0xff0000 0x10000>;
- };
};
};
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
&ethernet {
pinctrl-names = "default";
pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4>;
- mediatek,portmap = "llllw";
+ mediatek,portmap = "wllll";
};
&wmac {
ralink,mtd-eeprom = <&factory 0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pa_pins>;
};
&pcie {
@@ -133,7 +127,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
@@ -141,13 +135,8 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "rgmii1";
+ ralink,group = "wled", "i2c", "uartf", "wdt";
ralink,function = "gpio";
};
-
- pa {
- ralink,group = "pa";
- ralink,function = "pa";
- };
};
};
Index: sys/gnu/dts/mips/ZBT-CPE102.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-CPE102.dts
+++ sys/gnu/dts/mips/ZBT-CPE102.dts
@@ -2,9 +2,12 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "zbtlink,zbt-wa05", "ralink,mt7620n-soc";
- model = "Zbtlink ZBT-WA05";
+ compatible = "zbtlink,zbt-cpe102", "ralink,mt7620n-soc";
+ model = "Zbtlink ZBT-CPE102";
chosen {
bootargs = "console=ttyS0,115200";
@@ -13,19 +16,19 @@
gpio-leds {
compatible = "gpio-leds";
- power {
- label = "zbt-wa05:blue:power";
- gpios = <&gpio1 14 1>;
+ 4g-0 {
+ label = "zbt-cpe102:green:4g-0";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
- usb {
- label = "zbt-wa05:blue:usb";
- gpios = <&gpio1 15 0>;
+ 4g-1 {
+ label = "zbt-cpe102:green:4g-1";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
};
- air {
- label = "zbt-wa05:blue:air";
- gpios = <&gpio3 0 1>;
+ 4g-2 {
+ label = "zbt-cpe102:green:4g-2";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
};
@@ -37,8 +40,8 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -63,7 +66,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/ZBT-WA05.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WA05.dts
+++ sys/gnu/dts/mips/ZBT-WA05.dts
@@ -2,6 +2,9 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "zbtlink,zbt-wa05", "ralink,mt7620n-soc";
model = "Zbtlink ZBT-WA05";
@@ -15,17 +18,17 @@
power {
label = "zbt-wa05:blue:power";
- gpios = <&gpio1 14 1>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
usb {
label = "zbt-wa05:blue:usb";
- gpios = <&gpio1 15 0>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
};
air {
label = "zbt-wa05:blue:air";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -37,8 +40,8 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -63,7 +66,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
partition@0 {
Index: sys/gnu/dts/mips/ZBT-WE1226.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WE1226.dts
+++ sys/gnu/dts/mips/ZBT-WE1226.dts
@@ -1,50 +1,65 @@
/dts-v1/;
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
-#include "mt7621.dtsi"
+#include "mt7628an.dtsi"
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "Linksys RE6500";
+ compatible = "zbtlink,zbt-we1226", "mediatek,mt7628an-soc";
+ model = "Zbtlink ZBT-WE1226";
+
+ chosen {
+ bootargs = "console=ttyS0,115200";
+ };
memory@0 {
device_type = "memory";
reg = <0x0 0x4000000>;
};
- chosen {
- bootargs = "console=ttyS0,57600";
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
};
gpio-leds {
compatible = "gpio-leds";
- wifi {
- label = "re6500:orange:wifi";
- gpios = <&gpio0 0 0>;
+ wan {
+ label = "zbt-we1226:green:wan";
+ gpios = <&gpio1 7 GPIO_ACTIVE_LOW>;
};
- power {
- label = "re6500:white:power";
- gpios = <&gpio0 9 0>;
+ lan1 {
+ label = "zbt-we1226:green:lan1";
+ gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
};
- };
- gpio-keys-polled {
- compatible = "gpio-keys-polled";
- #address-cells = <1>;
- #size-cells = <0>;
- poll-interval = <20>;
+ lan2 {
+ label = "zbt-we1226:green:lan2";
+ gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
+ };
- wps {
- label = "wps";
- gpios = <&gpio0 10 1>;
- linux,code = <0x211>;
+ wlan {
+ label = "zbt-we1226:green:wlan";
+ gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
};
+ };
+};
- reset {
- label = "reset";
- gpios = <&gpio0 11 0>;
- linux,code = <0x198>;
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "p0led_an", "p1led_an", "p4led_an", "wdt", "wled_an";
+ ralink,function = "gpio";
};
};
};
@@ -57,8 +72,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -85,37 +100,12 @@
};
};
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "i2c", "uart2", "uart3", "rgmii2";
- ralink,function = "gpio";
- };
- };
-};
-
-&pcie {
+&wmac {
status = "okay";
-
- pcie0 {
- mt76@0,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,2ghz = <0>;
- };
- };
-
- pcie1 {
- mt76@1,0 {
- reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,5ghz = <0>;
- };
- };
+ ralink,mtd-eeprom = <&factory 0x4>;
};
&ethernet {
mtd-mac-address = <&factory 0x2e>;
+ mediatek,portmap = "llllw";
};
Index: sys/gnu/dts/mips/ZBT-WE1326.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WE1326.dts
+++ sys/gnu/dts/mips/ZBT-WE1326.dts
@@ -2,26 +2,20 @@
#include "mt7621.dtsi"
-/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "Firefly FireWRT";
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
- memory@0 {
- device_type = "memory";
- reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
- };
+/ {
+ compatible = "zbtlink,zbt-we1326", "mediatek,mt7621-soc";
+ model = "ZBT-WE1326";
chosen {
- bootargs = "console=ttyS0,57600";
+ bootargs = "console=ttyS0,115200";
};
- gpio-leds {
- compatible = "gpio-leds";
-
- power {
- label = "firewrt:green:power";
- gpios = <&gpio0 22 1>;
- };
+ memory@0 {
+ device_type = "memory";
+ reg = <0x0 0x1c000000>, <0x20000000 0x4000000>;
};
gpio-keys-polled {
@@ -30,22 +24,21 @@
#size-cells = <0>;
poll-interval = <20>;
- wps {
- label = "wps";
- gpios = <&gpio0 18 1>;
- linux,code = <0x211>;
- };
-
- power {
- label = "power";
- gpios = <&gpio0 23 1>;
- linux,code = <116>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
-&sdhci {
- status = "okay";
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "wdt";
+ ralink,function = "gpio";
+ };
+ };
};
&spi0 {
@@ -56,8 +49,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -84,6 +77,10 @@
};
};
+&ethernet {
+ mtd-mac-address = <&factory 0xe000>;
+};
+
&pcie {
status = "okay";
@@ -92,7 +89,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -101,20 +98,11 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
-&ethernet {
- mtd-mac-address = <&factory 0xe000>;
-};
-
-&pinctrl {
- state_default: pinctrl0 {
- gpio {
- ralink,group = "wdt", "rgmii2";
- ralink,function = "gpio";
- };
- };
+&sdhci {
+ status = "okay";
};
Index: sys/gnu/dts/mips/ZBT-WE2026.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WE2026.dts
+++ sys/gnu/dts/mips/ZBT-WE2026.dts
@@ -1,10 +1,13 @@
/dts-v1/;
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
#include "mt7620n.dtsi"
/ {
- compatible = "zbtlink,zbt-wa05", "ralink,mt7620n-soc";
- model = "Zbtlink ZBT-WA05";
+ compatible = "zbtlink,zbt-we2026", "ralink,mt7620n-soc";
+ model = "Zbtlink ZBT-WE2026";
chosen {
bootargs = "console=ttyS0,115200";
@@ -14,18 +17,13 @@
compatible = "gpio-leds";
power {
- label = "zbt-wa05:blue:power";
- gpios = <&gpio1 14 1>;
- };
-
- usb {
- label = "zbt-wa05:blue:usb";
- gpios = <&gpio1 15 0>;
+ label = "zbt-we2026:red:power";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
- air {
- label = "zbt-wa05:blue:air";
- gpios = <&gpio3 0 1>;
+ wlan {
+ label = "zbt-we2026:green:wlan";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -37,8 +35,8 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -47,10 +45,6 @@
status = "okay";
};
-&gpio2 {
- status = "okay";
-};
-
&gpio3 {
status = "okay";
};
@@ -63,7 +57,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
partition@0 {
@@ -91,14 +84,6 @@
};
};
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
-};
-
&ethernet {
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "wllll";
Index: sys/gnu/dts/mips/ZBT-WE3526.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WE3526.dts
+++ sys/gnu/dts/mips/ZBT-WE3526.dts
@@ -2,9 +2,12 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "ZBT-WG3526";
+ compatible = "zbtlink,zbt-we3526", "mediatek,mt7621-soc";
+ model = "ZBT-WE3526";
memory@0 {
device_type = "memory";
@@ -17,12 +20,6 @@
palmbus: palmbus@1E000000 {
i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
status = "okay";
};
};
@@ -35,17 +32,8 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
- };
- };
-
- gpio-leds {
- compatible = "gpio-leds";
-
- status {
- label = "zbt-wg3526:green:status";
- gpios = <&gpio0 24 1>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -62,8 +50,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -83,7 +71,7 @@
read-only;
};
- partition@50000 {
+ firmware: partition@50000 {
label = "firmware";
reg = <0x50000 0xfb0000>;
};
@@ -94,20 +82,23 @@
status = "okay";
pcie0 {
- mt76@0,0 {
+ wifi@14c3,7662 {
+ compatible = "pci14c3,7662";
reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x8000>;
+ ieee80211-freq-limit = <5000000 6000000>;
+
+ led {
+ led-sources = <2>;
+ };
};
};
pcie1 {
- mt76@1,0 {
+ wifi@14c3,7603 {
+ compatible = "pci14c3,7603";
reg = <0x0000 0 0 0 0>;
- device_type = "pci";
- mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ mediatek,mtd-eeprom = <&factory 0x0000>;
};
};
};
@@ -119,7 +110,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "wdt rst", "jtag", "mdio";
+ ralink,group = "wdt";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/ZBT-WE826-16M.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WE826-16M.dts
+++ sys/gnu/dts/mips/ZBT-WE826-16M.dts
@@ -1,16 +1,20 @@
/dts-v1/;
-#include "WT1520.dtsi"
+#include "ZBT-WE826.dtsi"
+
+/ {
+ compatible = "zbtlink,zbt-we826-16m", "zbtlink,zbt-we826", "ralink,mt7620a-soc";
+ model = "ZBT-WE826 (16M)";
+};
&spi0 {
status = "okay";
- m25p80@0 {
+ en25q128@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
@@ -31,9 +35,9 @@
read-only;
};
- partition@50000 {
+ firmware: partition@50000 {
label = "firmware";
- reg = <0x50000 0x3b0000>;
+ reg = <0x50000 0xfb0000>;
};
};
};
Index: sys/gnu/dts/mips/ZBT-WE826-32M.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WE826-32M.dts
+++ sys/gnu/dts/mips/ZBT-WE826-32M.dts
@@ -1,16 +1,20 @@
/dts-v1/;
-#include "WT1520.dtsi"
+#include "ZBT-WE826.dtsi"
+
+/ {
+ compatible = "zbtlink,zbt-we826-32m", "zbtlink,zbt-we826", "ralink,mt7620a-soc";
+ model = "ZBT-WE826 (32M)";
+};
&spi0 {
status = "okay";
- m25p80@0 {
+ en25q128@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
@@ -31,9 +35,9 @@
read-only;
};
- partition@50000 {
+ firmware: partition@50000 {
label = "firmware";
- reg = <0x50000 0x7b0000>;
+ reg = <0x50000 0x1fb0000>;
};
};
};
Index: sys/gnu/dts/mips/ZBT-WE826.dtsi
===================================================================
--- sys/gnu/dts/mips/ZBT-WE826.dtsi
+++ sys/gnu/dts/mips/ZBT-WE826.dtsi
@@ -1,10 +1,10 @@
-/dts-v1/;
-
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "zbtlink,zbt-we826", "ralink,mt7620a-soc";
- model = "ZBT-WE826";
chosen {
bootargs = "console=ttyS0,115200";
@@ -14,15 +14,15 @@
compatible = "gpio-leds";
power {
label = "zbt-we826:green:power";
- gpios = <&gpio1 14 0>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_HIGH>;
};
usb {
label = "zbt-we826:green:usb";
- gpios = <&gpio1 15 0>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
};
air {
label = "zbt-we826:green:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -33,8 +33,8 @@
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -51,42 +51,6 @@
status = "okay";
};
-&spi0 {
- status = "okay";
-
- en25q128@0 {
- #address-cells = <1>;
- #size-cells = <1>;
- compatible = "w25q128";
- reg = <0>;
- linux,modalias = "m25p80";
- spi-max-frequency = <10000000>;
-
- partition@0 {
- label = "u-boot";
- reg = <0x0 0x30000>;
- read-only;
- };
-
- partition@30000 {
- label = "u-boot-env";
- reg = <0x30000 0x10000>;
- read-only;
- };
-
- factory: partition@40000 {
- label = "factory";
- reg = <0x40000 0x10000>;
- read-only;
- };
-
- partition@50000 {
- label = "firmware";
- reg = <0x50000 0xfb0000>;
- };
- };
-};
-
&sdhci {
status = "okay";
};
@@ -101,7 +65,7 @@
&ethernet {
mtd-mac-address = <&factory 0x4>;
- ralink,port-map = "wllll";
+ mediatek,portmap = "wllll";
};
&wmac {
Index: sys/gnu/dts/mips/ZBT-WG2626.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WG2626.dts
+++ sys/gnu/dts/mips/ZBT-WG2626.dts
@@ -2,8 +2,11 @@
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
+ compatible = "zbtlink,zbt-wg2626", "mediatek,mt7621-soc";
model = "ZBT-WG2626";
memory@0 {
@@ -17,12 +20,6 @@
palmbus: palmbus@1E000000 {
i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
status = "okay";
};
};
@@ -35,8 +32,8 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -45,7 +42,7 @@
status {
label = "zbt-wg2626:green:status";
- gpios = <&gpio0 24 1>;
+ gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
};
};
};
@@ -62,8 +59,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -98,7 +95,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
@@ -107,7 +104,7 @@
reg = <0x0000 0 0 0 0>;
device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
+ ieee80211-freq-limit = <2400000 2500000>;
};
};
};
@@ -119,7 +116,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "wdt rst", "jtag", "mdio";
+ ralink,group = "wdt", "rgmii2", "jtag", "mdio";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/ZBT-WG3526-16M.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ZBT-WG3526-16M.dts
@@ -0,0 +1,12 @@
+/dts-v1/;
+
+#include "ZBT-WG3526.dtsi"
+
+/ {
+ compatible = "zbtlink,zbt-wg3526-16m", "zbtlink,zbt-wg3526", "mediatek,mt7621-soc";
+ model = "ZBT-WG3526 (16M)";
+};
+
+&firmware {
+ reg = <0x50000 0xfb0000>;
+};
Index: sys/gnu/dts/mips/ZBT-WG3526-32M.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/ZBT-WG3526-32M.dts
@@ -0,0 +1,12 @@
+/dts-v1/;
+
+#include "ZBT-WG3526.dtsi"
+
+/ {
+ compatible = "zbtlink,zbt-wg3526-32m", "zbtlink,zbt-wg3526", "mediatek,mt7621-soc";
+ model = "ZBT-WG3526 (32M)";
+};
+
+&firmware {
+ reg = <0x50000 0x1fb0000>;
+};
Index: sys/gnu/dts/mips/ZBT-WG3526.dtsi
===================================================================
--- sys/gnu/dts/mips/ZBT-WG3526.dtsi
+++ sys/gnu/dts/mips/ZBT-WG3526.dtsi
@@ -1,10 +1,10 @@
-/dts-v1/;
-
#include "mt7621.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "mediatek,mt7621-eval-board", "mediatek,mt7621-soc";
- model = "ZBT-WG3526";
+ compatible = "zbtlink,zbt-wg3526", "mediatek,mt7621-soc";
memory@0 {
device_type = "memory";
@@ -17,12 +17,6 @@
palmbus: palmbus@1E000000 {
i2c@900 {
- compatible = "ralink,i2c-mt7621";
- reg = <0x900 0x100>;
- #address-cells = <1>;
- #size-cells = <0>;
- pinctrl-names = "default";
- pinctrl-0 = <&i2c_pins>;
status = "okay";
};
};
@@ -35,8 +29,8 @@
reset {
label = "reset";
- gpios = <&gpio0 18 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
@@ -45,7 +39,7 @@
status {
label = "zbt-wg3526:green:status";
- gpios = <&gpio0 24 1>;
+ gpios = <&gpio0 24 GPIO_ACTIVE_LOW>;
};
};
};
@@ -62,8 +56,8 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80";
spi-max-frequency = <10000000>;
+ m25p,chunked-io = <32>;
partition@0 {
label = "u-boot";
@@ -83,9 +77,8 @@
read-only;
};
- partition@50000 {
+ firmware: partition@50000 {
label = "firmware";
- reg = <0x50000 0xfb0000>;
};
};
};
@@ -94,20 +87,19 @@
status = "okay";
pcie0 {
- mt76@0,0 {
+ wifi@14c3,7603 {
+ compatible = "pci14c3,7603";
reg = <0x0000 0 0 0 0>;
- device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
};
};
pcie1 {
- mt76@1,0 {
+ wifi@14c3,7662 {
+ compatible = "pci14c3,7662";
reg = <0x0000 0 0 0 0>;
- device_type = "pci";
mediatek,mtd-eeprom = <&factory 0x8000>;
- mediatek,2ghz = <0>;
+ ieee80211-freq-limit = <5000000 6000000>;
};
};
};
@@ -119,7 +111,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "wdt", "rgmii2", "wdt rst", "jtag", "mdio";
+ ralink,group = "wdt", "rgmii2", "jtag", "mdio";
ralink,function = "gpio";
};
};
Index: sys/gnu/dts/mips/ZBT-WR8305RT.dts
===================================================================
--- sys/gnu/dts/mips/ZBT-WR8305RT.dts
+++ sys/gnu/dts/mips/ZBT-WR8305RT.dts
@@ -2,6 +2,9 @@
#include "mt7620n.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
compatible = "zbtlink,zbt-wr8305rt", "ralink,mt7620n-soc";
model = "Zbtlink ZBT-WR8305RT";
@@ -11,17 +14,17 @@
sys {
label = "zbt-wr8305rt:green:sys";
- gpios = <&gpio1 14 1>;
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
lan {
label = "zbt-wr8305rt:green:usb";
- gpios = <&gpio1 15 1>;
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
wifi {
label = "zbt-wr8305rt:green:wifi";
- gpios = <&gpio3 0 1>;
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
};
};
@@ -33,8 +36,8 @@
reset {
label = "reset";
- gpios = <&gpio0 1 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -55,7 +58,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -92,6 +94,8 @@
};
&ethernet {
+ pinctrl-names = "default";
+ pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "llllw";
};
@@ -102,11 +106,6 @@
&pinctrl {
state_default: pinctrl0 {
- ephy {
- ralink,group = "ephy";
- ralink,function = "ephy";
- };
-
default {
ralink,group = "i2c", "uartf", "spi refclk", "wled";
ralink,function = "gpio";
Index: sys/gnu/dts/mips/ZL5900V2.dts
===================================================================
--- sys/gnu/dts/mips/ZL5900V2.dts
+++ sys/gnu/dts/mips/ZL5900V2.dts
@@ -2,16 +2,24 @@
#include "rt5350.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "X8", "ralink,rt5350-soc";
- model = "Poray X8";
+ compatible = "zorlik,zl5900v2", "ralink,rt5350-soc";
+ model = "Zorlik ZL5900V2";
gpio-leds {
compatible = "gpio-leds";
+ lan {
+ label = "zl5900v2:green:lan";
+ gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
+ };
+
power {
- label = "x8:green:power";
- gpios = <&gpio0 13 1>;
+ label = "zl5900v2:blue:power";
+ gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
};
};
@@ -23,8 +31,8 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -37,7 +45,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "gd25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -68,7 +75,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "jtag", "uartf";
+ ralink,group = "jtag", "uartf";
ralink,function = "gpio";
};
};
@@ -79,19 +86,10 @@
};
&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <1>;
+ mediatek,portmap = <0>;
+ mediatek,portdisable = <0x2f>;
};
&wmac {
ralink,mtd-eeprom = <&factory 0>;
- ralink,led-polarity = <1>;
-};
-
-&ehci {
- status = "okay";
-};
-
-&ohci {
- status = "okay";
};
Index: sys/gnu/dts/mips/ZTE-Q7.dts
===================================================================
--- sys/gnu/dts/mips/ZTE-Q7.dts
+++ sys/gnu/dts/mips/ZTE-Q7.dts
@@ -2,8 +2,11 @@
#include "mt7620a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "ZTE-Q7", "ralink,mt7620a-soc";
+ compatible = "zte,q7", "ralink,mt7620a-soc";
model = "ZTE Q7";
gpio-leds {
@@ -11,12 +14,12 @@
statred {
label = "zte-q7:red:status";
- gpios = <&gpio0 13 1>;
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
statblue {
label = "zte-q7:blue:status";
- gpios = <&gpio0 9 1>;
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
};
};
@@ -28,8 +31,8 @@
reset {
label = "reset";
- gpios = <&gpio1 2 1>;
- linux,code = <0x198>;
+ gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
};
};
@@ -50,7 +53,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "en25q64";
spi-max-frequency = <10000000>;
partition@0 {
@@ -88,8 +90,6 @@
};
&ethernet {
- pinctrl-names = "default";
- pinctrl-0 = <&ephy_pins>;
mtd-mac-address = <&factory 0x4>;
mediatek,portmap = "wllll";
};
@@ -109,3 +109,7 @@
&ohci {
status = "okay";
};
+
+&gsw {
+ mediatek,port4 = "ephy";
+};
Index: sys/gnu/dts/mips/kn.dts
===================================================================
--- sys/gnu/dts/mips/kn.dts
+++ sys/gnu/dts/mips/kn.dts
@@ -2,9 +2,12 @@
#include "rt3050.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
/ {
- compatible = "NBG-419N", "ralink,rt3052-soc";
- model = "ZyXEL NBG-419N";
+ compatible = "zyxel,keenetic", "ralink,rt3052-soc";
+ model = "ZyXEL Keenetic";
cfi@1f000000 {
compatible = "cfi-flash";
@@ -42,13 +45,18 @@
compatible = "gpio-leds";
power {
- label = "nbg-419n:green:power";
- gpios = <&gpio0 9 1>;
+ label = "kn:green:power";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "kn:green:usb";
+ gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
};
wps {
- label = "nbg-419n:green:wps";
- gpios = <&gpio0 14 1>;
+ label = "kn:green:wps";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
};
};
@@ -60,14 +68,21 @@
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ rfkill {
+ label = "rfkill";
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ linux,code = <KEY_RFKILL>;
+ linux,input-type = <EV_SW>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
};
};
};
@@ -75,7 +90,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "uartf";
ralink,function = "gpio";
};
};
@@ -92,3 +107,7 @@
&wmac {
ralink,mtd-eeprom = <&factory 0>;
};
+
+&otg {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/kn_rc.dts
===================================================================
--- sys/gnu/dts/mips/kn_rc.dts
+++ sys/gnu/dts/mips/kn_rc.dts
@@ -1,46 +1,60 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "mt7620n.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
- compatible = "DIR-320-B1", "ralink,rt5350-soc";
- model = "D-Link DIR-320 B1";
+ compatible = "zyxel,keenetic-omni", "ralink,mt7620n-soc";
+ model = "ZyXEL Keenetic Omni";
gpio-leds {
compatible = "gpio-leds";
- status {
- label = "dir-320-b1:green:status";
- gpios = <&gpio0 9 1>;
+ wan {
+ label = "kn_rc:green:wan";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
usb {
- label = "dir-320-b1:green:usb";
- gpios = <&gpio0 14 1>;
+ label = "kn_rc:green:usb";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
- wps {
- label = "dir-320-b1:green:wps";
- gpios = <&gpio0 13 1>;
+ wifi {
+ label = "kn_rc:green:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "kn_rc:green:power";
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
};
gpio-keys-polled {
- compatible = "gpio-keys-polled";
+ compatible = "gpio-keys";
#address-cells = <1>;
#size-cells = <0>;
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ fn {
+ label = "fn";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
@@ -48,20 +62,22 @@
compatible = "gpio-export";
#size-cells = <0>;
- usb {
+ usb_power {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio0 7 0>;
- };
-
- root_hub {
- gpio-export,name = "root_hub";
- gpio-export,output = <1>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 21 GPIO_ACTIVE_HIGH>;
};
};
};
+&gpio1 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
&spi0 {
status = "okay";
@@ -70,7 +86,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
@@ -101,7 +116,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "i2c", "wdt", "pa", "spi refclk", "wled";
ralink,function = "gpio";
};
};
@@ -109,11 +124,7 @@
&ethernet {
mtd-mac-address = <&factory 0x4>;
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <0x17>;
+ mediatek,portmap = "llllw";
};
&wmac {
Index: sys/gnu/dts/mips/kn_rf.dts
===================================================================
--- sys/gnu/dts/mips/kn_rf.dts
+++ sys/gnu/dts/mips/kn_rf.dts
@@ -1,46 +1,60 @@
/dts-v1/;
-#include "rt5350.dtsi"
+#include "mt7620n.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
- compatible = "DIR-320-B1", "ralink,rt5350-soc";
- model = "D-Link DIR-320 B1";
+ compatible = "zyxel,keenetic-omni-ii", "ralink,mt7620n-soc";
+ model = "ZyXEL Keenetic Omni II";
gpio-leds {
compatible = "gpio-leds";
- status {
- label = "dir-320-b1:green:status";
- gpios = <&gpio0 9 1>;
+ wan {
+ label = "kn_rc:green:wan";
+ gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
usb {
- label = "dir-320-b1:green:usb";
- gpios = <&gpio0 14 1>;
+ label = "kn_rc:green:usb";
+ gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
};
- wps {
- label = "dir-320-b1:green:wps";
- gpios = <&gpio0 13 1>;
+ wifi {
+ label = "kn_rc:green:wifi";
+ gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "kn_rc:green:power";
+ gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
};
gpio-keys-polled {
- compatible = "gpio-keys-polled";
+ compatible = "gpio-keys";
#address-cells = <1>;
#size-cells = <0>;
poll-interval = <20>;
reset {
label = "reset";
- gpios = <&gpio0 10 1>;
- linux,code = <0x198>;
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
};
wps {
label = "wps";
- gpios = <&gpio0 0 1>;
- linux,code = <0x211>;
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ fn {
+ label = "fn";
+ gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
};
};
@@ -48,20 +62,22 @@
compatible = "gpio-export";
#size-cells = <0>;
- usb {
+ usb_power {
gpio-export,name = "usb";
gpio-export,output = <1>;
- gpios = <&gpio0 7 0>;
- };
-
- root_hub {
- gpio-export,name = "root_hub";
- gpio-export,output = <1>;
- gpios = <&gpio0 12 0>;
+ gpios = <&gpio0 21 GPIO_ACTIVE_HIGH>;
};
};
};
+&gpio1 {
+ status = "okay";
+};
+
+&gpio3 {
+ status = "okay";
+};
+
&spi0 {
status = "okay";
@@ -70,7 +86,6 @@
#size-cells = <1>;
compatible = "jedec,spi-nor";
reg = <0>;
- linux,modalias = "m25p80", "s25fl064k";
spi-max-frequency = <10000000>;
partition@0 {
@@ -101,7 +116,7 @@
&pinctrl {
state_default: pinctrl0 {
gpio {
- ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
+ ralink,group = "i2c", "wdt", "pa", "spi refclk", "wled";
ralink,function = "gpio";
};
};
@@ -109,11 +124,7 @@
&ethernet {
mtd-mac-address = <&factory 0x4>;
-};
-
-&esw {
- mediatek,portmap = <0x2f>;
- mediatek,led_polarity = <0x17>;
+ mediatek,portmap = "wllll";
};
&wmac {
Index: sys/gnu/dts/mips/kng_rc.dts
===================================================================
--- /dev/null
+++ sys/gnu/dts/mips/kng_rc.dts
@@ -0,0 +1,166 @@
+/dts-v1/;
+
+#include "mt7620a.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+ compatible = "zyxel,keenetic-viva", "ralink,mt7620a-soc";
+ model = "ZyXEL Keenetic Viva";
+
+ gpio-leds {
+ compatible = "gpio-leds";
+
+ wan {
+ label = "kng_rc:green:wan";
+ gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
+ };
+
+ usb {
+ label = "kng_rc:green:usb";
+ gpios = <&gpio0 8 GPIO_ACTIVE_LOW>;
+ };
+
+ power_alert {
+ label = "kng_rc:red:power";
+ gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
+ };
+
+ wifi {
+ label = "kng_rc:green:wifi";
+ gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
+ };
+
+ power {
+ label = "kng_rc:green:power";
+ gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+
+ reset {
+ label = "reset";
+ gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ fn {
+ label = "fn";
+ gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
+ linux,code = <BTN_0>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ usb_power {
+ gpio-export,name = "usb";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
+ };
+ };
+
+ rtl8367rb {
+ compatible = "realtek,rtl8367b";
+ cpu_port = <7>;
+ realtek,extif2 = <1 0 1 1 1 1 1 1 2>;
+ mdio = <&mdio0>;
+ };
+};
+
+&spi0 {
+ status = "okay";
+
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-max-frequency = <10000000>;
+
+ partition@0 {
+ label = "u-boot";
+ reg = <0x0 0x30000>;
+ read-only;
+ };
+
+ partition@30000 {
+ label = "u-boot-env";
+ reg = <0x30000 0x10000>;
+ read-only;
+ };
+
+ factory: partition@40000 {
+ label = "factory";
+ reg = <0x40000 0x10000>;
+ read-only;
+ };
+
+ partition@50000 {
+ label = "firmware";
+ reg = <0x50000 0xfb0000>;
+ };
+ };
+};
+
+&pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "uartf";
+ ralink,function = "gpio";
+ };
+ };
+};
+
+&ethernet {
+ status = "okay";
+ pinctrl-names = "default";
+ pinctrl-0 = <&rgmii2_pins &mdio_pins>;
+ mtd-mac-address = <&factory 0x00004>;
+
+ port@4 {
+ status = "okay";
+ mediatek,fixed-link = <1000 1 1 1>;
+ phy-mode = "rgmii";
+ phy-handle = <&phy4>;
+ };
+
+ mdio0: mdio-bus {
+ status = "okay";
+
+ phy4: ethernet-phy@4 {
+ reg = <4>;
+ phy-mode = "rgmii";
+ };
+ };
+};
+
+&gsw {
+ mediatek,port4 = "gmac";
+};
+
+&wmac {
+ ralink,mtd-eeprom = <&factory 0>;
+};
+
+&ehci {
+ status = "okay";
+};
+
+&ohci {
+ status = "okay";
+};
Index: sys/gnu/dts/mips/mt7620a.dtsi
===================================================================
--- sys/gnu/dts/mips/mt7620a.dtsi
+++ sys/gnu/dts/mips/mt7620a.dtsi
@@ -35,7 +35,7 @@
#size-cells = <1>;
sysc: sysc@0 {
- compatible = "ralink,mt7620a-sysc", "ralink,rt3050-sysc";
+ compatible = "ralink,mt7620a-sysc", "ralink,rt3050-sysc", "syscon";
reg = <0x0 0x100>;
};
@@ -176,7 +176,7 @@
};
i2c: i2c@900 {
- compatible = "link,mt7620a-i2c", "ralink,rt2880-i2c";
+ compatible = "ralink,rt2880-i2c";
reg = <0x900 0x100>;
resets = <&rstctrl 16>;
@@ -192,7 +192,7 @@
};
i2s: i2s@a00 {
- compatible = "ralink,mt7620a-i2s";
+ compatible = "mediatek,mt7620-i2s";
reg = <0xa00 0x100>;
resets = <&rstctrl 17>;
@@ -201,8 +201,11 @@
interrupt-parent = <&intc>;
interrupts = <10>;
+ txdma-req = <2>;
+ rxdma-req = <3>;
+
dmas = <&gdma 4>,
- <&gdma 5>;
+ <&gdma 6>;
dma-names = "tx", "rx";
status = "disabled";
@@ -281,7 +284,7 @@
};
gdma: gdma@2800 {
- compatible = "ralink,mt7620a-gdma", "ralink,rt2880-gdma";
+ compatible = "ralink,mt7620a-gdma", "ralink,rt3883-gdma";
reg = <0x2800 0x800>;
resets = <&rstctrl 14>;
@@ -320,6 +323,13 @@
};
};
+ gpio_i2s_pins: gpio_i2s {
+ gpio_i2s {
+ ralink,group = "uartf";
+ ralink,function = "gpio i2s";
+ };
+ };
+
spi_pins: spi {
spi {
ralink,group = "spi";
@@ -355,6 +365,13 @@
};
};
+ mdio_refclk_pins: mdio_refclk {
+ mdio_refclk {
+ ralink,group = "mdio";
+ ralink,function = "refclk";
+ };
+ };
+
ephy_pins: ephy {
ephy {
ralink,group = "ephy";
@@ -389,6 +406,13 @@
ralink,function = "pcie rst";
};
};
+
+ pa_pins: pa {
+ pa {
+ ralink,group = "pa";
+ ralink,function = "pa";
+ };
+ };
};
rstctrl: rstctrl {
@@ -403,8 +427,9 @@
usbphy: usbphy {
compatible = "mediatek,mt7620-usbphy";
- #phy-cells = <1>;
+ #phy-cells = <0>;
+ ralink,sysctl = <&sysc>;
resets = <&rstctrl 22 &rstctrl 25>;
reset-names = "host", "device";
@@ -477,7 +502,7 @@
interrupt-parent = <&intc>;
interrupts = <18>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
status = "disabled";
@@ -490,7 +515,7 @@
interrupt-parent = <&intc>;
interrupts = <18>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
status = "disabled";
@@ -546,5 +571,3 @@
ralink,eeprom = "soc_wmac.eeprom";
};
};
-
-#include "fbsd-mt7620a.dtsi"
Index: sys/gnu/dts/mips/mt7620n.dtsi
===================================================================
--- sys/gnu/dts/mips/mt7620n.dtsi
+++ sys/gnu/dts/mips/mt7620n.dtsi
@@ -35,7 +35,7 @@
#size-cells = <1>;
sysc: sysc@0 {
- compatible = "ralink,mt7620a-sysc", "ralink,rt3050-sysc";
+ compatible = "ralink,mt7620a-sysc", "ralink,rt3050-sysc", "syscon";
reg = <0x0 0x100>;
};
@@ -160,6 +160,22 @@
status = "disabled";
};
+ i2c: i2c@900 {
+ compatible = "ralink,rt2880-i2c";
+ reg = <0x900 0x100>;
+
+ resets = <&rstctrl 16>;
+ reset-names = "i2c";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ status = "disabled";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c_pins>;
+ };
+
spi0: spi@b00 {
compatible = "ralink,mt7620a-spi", "ralink,rt2880-spi";
reg = <0xb00 0x40>;
@@ -228,6 +244,13 @@
state_default: pinctrl0 {
};
+ ephy_pins: ephy {
+ ephy {
+ ralink,group = "ephy";
+ ralink,function = "ephy";
+ };
+ };
+
spi_pins: spi {
spi {
ralink,group = "spi";
@@ -242,6 +265,13 @@
};
};
+ i2c_pins: i2c {
+ i2c {
+ ralink,group = "i2c";
+ ralink,function = "i2c";
+ };
+ };
+
uartlite_pins: uartlite {
uart {
ralink,group = "uartlite";
@@ -262,8 +292,9 @@
usbphy: usbphy {
compatible = "mediatek,mt7620-usbphy";
- #phy-cells = <1>;
+ #phy-cells = <0>;
+ ralink,sysctl = <&sysc>;
resets = <&rstctrl 22 &rstctrl 25>;
reset-names = "host", "device";
@@ -292,6 +323,13 @@
status = "disabled";
};
+
+ port@4 {
+ compatible = "mediatek,mt7620a-gsw-port", "mediatek,eth-port";
+ reg = <4>;
+
+ status = "disabled";
+ };
};
gsw: gsw@10110000 {
@@ -303,7 +341,7 @@
interrupt-parent = <&intc>;
interrupts = <17>;
- mediatek,port4 = "gmac";
+ mediatek,port4 = "ephy";
};
ehci: ehci@101c0000 {
@@ -313,7 +351,7 @@
interrupt-parent = <&intc>;
interrupts = <18>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
status = "disabled";
@@ -323,7 +361,7 @@
compatible = "generic-ohci";
reg = <0x101c1000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
Index: sys/gnu/dts/mips/mt7621.dtsi
===================================================================
--- sys/gnu/dts/mips/mt7621.dtsi
+++ sys/gnu/dts/mips/mt7621.dtsi
@@ -3,7 +3,7 @@
/ {
#address-cells = <1>;
#size-cells = <1>;
- compatible = "mediatek,mtk7621-soc";
+ compatible = "mediatek,mt7621-soc";
cpus {
cpu@0 {
@@ -42,6 +42,8 @@
clock-frequency = <50000000>;
};
+
+
palmbus: palmbus@1E000000 {
compatible = "palmbus";
reg = <0x1E000000 0x100000>;
@@ -56,7 +58,7 @@
};
wdt: wdt@100 {
- compatible = "mtk,mt7621-wdt";
+ compatible = "mediatek,mt7621-wdt";
reg = <0x100 0x100>;
};
@@ -89,6 +91,57 @@
};
};
+ i2c: i2c@900 {
+ compatible = "mediatek,mt7621-i2c";
+ reg = <0x900 0x100>;
+
+ clocks = <&sysclock>;
+
+ resets = <&rstctrl 16>;
+ reset-names = "i2c";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ status = "disabled";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c_pins>;
+ };
+
+ i2s: i2s@a00 {
+ compatible = "mediatek,mt7621-i2s";
+ reg = <0xa00 0x100>;
+
+ clocks = <&sysclock>;
+
+ resets = <&rstctrl 17>;
+ reset-names = "i2s";
+
+ interrupt-parent = <&gic>;
+ interrupts = <GIC_SHARED 16 IRQ_TYPE_LEVEL_HIGH>;
+
+ txdma-req = <2>;
+ rxdma-req = <3>;
+
+ dmas = <&gdma 4>,
+ <&gdma 6>;
+ dma-names = "tx", "rx";
+
+ status = "disabled";
+ };
+
+ systick: systick@d00 {
+ compatible = "ralink,mt7621-systick", "ralink,cevt-systick";
+ reg = <0xd00 0x10>;
+
+ resets = <&rstctrl 28>;
+ reset-names = "intc";
+
+ interrupt-parent = <&gic>;
+ interrupts = <GIC_SHARED 5 IRQ_TYPE_LEVEL_HIGH>;
+ };
+
memc: memc@5000 {
compatible = "mtk,mt7621-memc";
reg = <0x300 0x100>;
@@ -120,7 +173,7 @@
};
spi0: spi@b00 {
- status = "okay";
+ status = "disabled";
compatible = "ralink,mt7621-spi";
reg = <0xb00 0x100>;
@@ -135,14 +188,40 @@
pinctrl-names = "default";
pinctrl-0 = <&spi_pins>;
+ };
- m25p80@0 {
- #address-cells = <1>;
- #size-cells = <1>;
- reg = <0>;
- spi-max-frequency = <10000000>;
- m25p,chunked-io = <32>;
- };
+ gdma: gdma@2800 {
+ compatible = "ralink,rt3883-gdma";
+ reg = <0x2800 0x800>;
+
+ resets = <&rstctrl 14>;
+ reset-names = "dma";
+
+ interrupt-parent = <&gic>;
+ interrupts = <0 13 4>;
+
+ #dma-cells = <1>;
+ #dma-channels = <16>;
+ #dma-requests = <16>;
+
+ status = "disabled";
+ };
+
+ hsdma: hsdma@7000 {
+ compatible = "mediatek,mt7621-hsdma";
+ reg = <0x7000 0x1000>;
+
+ resets = <&rstctrl 5>;
+ reset-names = "hsdma";
+
+ interrupt-parent = <&gic>;
+ interrupts = <0 11 4>;
+
+ #dma-cells = <1>;
+ #dma-channels = <1>;
+ #dma-requests = <1>;
+
+ status = "disabled";
};
};
@@ -154,13 +233,6 @@
state_default: pinctrl0 {
};
- spi_pins: spi {
- spi {
- ralink,group = "spi";
- ralink,function = "spi";
- };
- };
-
i2c_pins: i2c {
i2c {
ralink,group = "i2c";
@@ -168,6 +240,13 @@
};
};
+ spi_pins: spi {
+ spi {
+ ralink,group = "spi";
+ ralink,function = "spi";
+ };
+ };
+
uart1_pins: uart1 {
uart1 {
ralink,group = "uart1";
@@ -248,6 +327,8 @@
};
sdhci: sdhci@1E130000 {
+ status = "disabled";
+
compatible = "ralink,mt7620-sdhci";
reg = <0x1E130000 0x4000>;
@@ -261,6 +342,7 @@
compatible = "mediatek,mt8173-xhci";
reg = <0x1e1c0000 0x1000
0x1e1d0700 0x0100>;
+ reg-names = "mac", "ippc";
clocks = <&sysclock>;
clock-names = "sys_ck";
@@ -296,6 +378,16 @@
#size-cells = <1>;
};
+ hnat: hnat@1e100000 {
+ compatible = "mediatek,mt7623-hnat";
+ reg = <0x1e100000 0x10000>;
+ mtketh-ppd = "eth0";
+ mtketh-lan = "eth0";
+ mtketh-wan = "eth0";
+ resets = <&rstctrl 0>;
+ reset-names = "mtketh";
+ };
+
ethernet: ethernet@1e100000 {
compatible = "mediatek,mt7621-eth";
reg = <0x1e100000 0x10000>;
@@ -353,7 +445,7 @@
GIC_SHARED 24 IRQ_TYPE_LEVEL_HIGH
GIC_SHARED 25 IRQ_TYPE_LEVEL_HIGH>;
- status = "okay";
+ status = "disabled";
resets = <&rstctrl 24 &rstctrl 25 &rstctrl 26>;
reset-names = "pcie0", "pcie1", "pcie2";
@@ -388,5 +480,3 @@
};
};
};
-
-#include "fbsd-mt7621.dtsi"
Index: sys/gnu/dts/mips/mt7628an.dtsi
===================================================================
--- sys/gnu/dts/mips/mt7628an.dtsi
+++ sys/gnu/dts/mips/mt7628an.dtsi
@@ -33,13 +33,13 @@
#size-cells = <1>;
sysc: sysc@0 {
- compatible = "ralink,mt7620a-sysc";
+ compatible = "ralink,mt7620a-sysc", "syscon";
reg = <0x0 0x100>;
};
- watchdog: watchdog@120 {
- compatible = "ralink,mt7628an-wdt", "mtk,mt7621-wdt";
- reg = <0x120 0x10>;
+ watchdog: watchdog@100 {
+ compatible = "ralink,mt7628an-wdt", "mediatek,mt7621-wdt";
+ reg = <0x100 0x30>;
resets = <&rstctrl 8>;
reset-names = "wdt";
@@ -110,7 +110,7 @@
};
i2c: i2c@900 {
- compatible = "mediatek,mt7628-i2c";
+ compatible = "mediatek,mt7621-i2c";
reg = <0x900 0x100>;
resets = <&rstctrl 16>;
@@ -126,7 +126,7 @@
};
i2s: i2s@a00 {
- compatible = "ralink,mt7620a-i2s";
+ compatible = "mediatek,mt7628-i2s";
reg = <0xa00 0x100>;
resets = <&rstctrl 17>;
@@ -135,8 +135,11 @@
interrupt-parent = <&intc>;
interrupts = <10>;
- dmas = <&gdma 2>,
- <&gdma 3>;
+ txdma-req = <2>;
+ rxdma-req = <3>;
+
+ dmas = <&gdma 4>,
+ <&gdma 6>;
dma-names = "tx", "rx";
status = "disabled";
@@ -249,7 +252,7 @@
};
gdma: gdma@2800 {
- compatible = "ralink,mt7620a-gdma", "ralink,rt2880-gdma";
+ compatible = "ralink,rt3883-gdma";
reg = <0x2800 0x800>;
resets = <&rstctrl 14>;
@@ -295,6 +298,13 @@
};
};
+ i2s_pins: i2s {
+ i2s {
+ ralink,group = "i2s";
+ ralink,function = "i2s";
+ };
+ };
+
uart0_pins: uartlite {
uartlite {
ralink,group = "uart0";
@@ -337,12 +347,19 @@
};
};
- pcm_i2s_pins: i2s {
- i2s {
+ pcm_i2s_pins: pcm_i2s {
+ pcm_i2s {
ralink,group = "i2s";
ralink,function = "pcm";
};
};
+
+ refclk_pins: refclk {
+ refclk {
+ ralink,group = "refclk";
+ ralink,function = "refclk";
+ };
+ };
};
rstctrl: rstctrl {
@@ -356,10 +373,11 @@
};
usbphy: usbphy@10120000 {
- compatible = "ralink,mt7628an-usbphy", "mediatek,mt7620-usbphy";
- reg = <0x10120000 0x4000>;
- #phy-cells = <1>;
+ compatible = "mediatek,mt7628-usbphy", "mediatek,mt7620-usbphy";
+ reg = <0x10120000 0x1000>;
+ #phy-cells = <0>;
+ ralink,sysctl = <&sysc>;
resets = <&rstctrl 22 &rstctrl 25>;
reset-names = "host", "device";
clocks = <&clkctrl 22 &clkctrl 25>;
@@ -383,7 +401,7 @@
compatible = "generic-ehci";
reg = <0x101c0000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
@@ -394,7 +412,7 @@
compatible = "generic-ohci";
reg = <0x101c1000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
@@ -471,8 +489,5 @@
status = "disabled";
mediatek,mtd-eeprom = <&factory 0x0000>;
- mediatek,5ghz = <0>;
};
};
-
-#include "fbsd-mt7628an.dtsi"
Index: sys/gnu/dts/mips/rt2880.dtsi
===================================================================
--- sys/gnu/dts/mips/rt2880.dtsi
+++ sys/gnu/dts/mips/rt2880.dtsi
@@ -5,7 +5,7 @@
cpus {
cpu@0 {
- compatible = "mips,mips4KEc";
+ compatible = "mips,mips24KEc";
};
};
@@ -80,9 +80,6 @@
ralink,register-map = [ 00 04 08 0c
20 24 28 2c
30 34 ];
-
- interrupt-parent = <&intc>;
- interrupts = <7>;
};
gpio1: gpio@638 {
@@ -117,6 +114,22 @@
status = "disabled";
};
+ i2c: i2c@900 {
+ compatible = "ralink,rt2880-i2c";
+ reg = <0x900 0x100>;
+
+ resets = <&rstctrl 9>;
+ reset-names = "i2c";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ status = "disabled";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c_pins>;
+ };
+
uartlite: uartlite@c00 {
compatible = "ralink,rt2880-uart", "ns16550a";
reg = <0xc00 0x100>;
@@ -141,6 +154,13 @@
};
};
+ i2c_pins: i2c {
+ i2c {
+ ralink,group = "i2c";
+ ralink,function = "i2c";
+ };
+ };
+
spi_pins: spi {
spi {
ralink,group = "spi";
@@ -166,6 +186,14 @@
#clock-cells = <1>;
};
+ pci: pci@440000 {
+ compatible = "ralink,rt288x-pci";
+ reg = <0x00440000 0x20000>;
+ #address-cells = <1>;
+ #size-cells = <1>;
+ status = "disabled";
+ };
+
ethernet: ethernet@400000 {
compatible = "ralink,rt2880-eth";
reg = <0x00400000 0x10000>;
@@ -185,13 +213,13 @@
compatible = "ralink,rt2880-port", "mediatek,eth-port";
reg = <0>;
};
- };
- mdio-bus {
- compatible = "ralink,rt2880-mdio";
- reg = <0x00400000 0x10000>;
- #address-cells = <1>;
- #size-cells = <0>;
+ mdio-bus {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ status = "disabled";
+ };
};
wmac: wmac@480000 {
Index: sys/gnu/dts/mips/rt3050.dtsi
===================================================================
--- sys/gnu/dts/mips/rt3050.dtsi
+++ sys/gnu/dts/mips/rt3050.dtsi
@@ -34,7 +34,7 @@
#size-cells = <1>;
sysc: sysc@0 {
- compatible = "ralink,rt3050-sysc";
+ compatible = "ralink,rt3050-sysc", "syscon";
reg = <0x0 0x100>;
};
@@ -149,6 +149,57 @@
status = "disabled";
};
+ gdma: gdma@700 {
+ compatible = "ralink,rt305x-gdma";
+ reg = <0x700 0x100>;
+
+ resets = <&rstctrl 14>;
+ reset-names = "dma";
+
+ interrupt-parent = <&intc>;
+ interrupts = <7>;
+
+ #dma-cells = <1>;
+ #dma-channels = <8>;
+ #dma-requests = <8>;
+
+ status = "disabled";
+ };
+
+ i2c@900 {
+ compatible = "ralink,rt2880-i2c";
+ reg = <0x900 0x100>;
+
+ resets = <&rstctrl 16>;
+ reset-names = "i2c";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ status = "disabled";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c_pins>;
+ };
+
+ i2s@a00 {
+ compatible = "ralink,rt3050-i2s";
+ reg = <0xa00 0x100>;
+
+ resets = <&rstctrl 17>;
+ reset-names = "i2s";
+
+ interrupt-parent = <&intc>;
+ interrupts = <10>;
+
+ txdma-req = <2>;
+
+ dmas = <&gdma 4>;
+ dma-names = "tx";
+
+ status = "disabled";
+ };
+
spi0: spi@b00 {
compatible = "ralink,rt3050-spi", "ralink,rt2880-spi";
reg = <0xb00 0x100>;
@@ -195,6 +246,13 @@
};
};
+ i2c_pins: i2c {
+ i2c {
+ ralink,group = "i2c";
+ ralink,function = "i2c";
+ };
+ };
+
spi_pins: spi {
spi {
ralink,group = "spi";
@@ -202,6 +260,13 @@
};
};
+ rgmii_pins: rgmii {
+ rgmii {
+ ralink,group = "rgmii";
+ ralink,function = "rgmii";
+ };
+ };
+
uartlite_pins: uartlite {
uart {
ralink,group = "uartlite";
@@ -222,6 +287,9 @@
usbphy: usbphy {
compatible = "ralink,rt3050-usbphy";
+ #phy-cells = <0>;
+
+ ralink,sysctl = <&sysc>;
resets = <&rstctrl 22>;
reset-names = "host";
clocks = <&clkctrl 18>;
Index: sys/gnu/dts/mips/rt3352.dtsi
===================================================================
--- sys/gnu/dts/mips/rt3352.dtsi
+++ sys/gnu/dts/mips/rt3352.dtsi
@@ -35,7 +35,7 @@
#size-cells = <1>;
sysc: sysc@0 {
- compatible = "ralink,rt3352-sysc", "ralink,rt3050-sysc";
+ compatible = "ralink,rt3352-sysc", "ralink,rt3050-sysc", "syscon";
reg = <0x0 0x100>;
};
@@ -146,6 +146,42 @@
status = "disabled";
};
+ i2c@900 {
+ compatible = "ralink,rt2880-i2c";
+ reg = <0x900 0x100>;
+
+ resets = <&rstctrl 16>;
+ reset-names = "i2c";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ status = "disabled";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c_pins>;
+ };
+
+ i2s@a00 {
+ compatible = "ralink,rt3352-i2s";
+ reg = <0xa00 0x100>;
+
+ resets = <&rstctrl 17>;
+ reset-names = "i2s";
+
+ interrupt-parent = <&intc>;
+ interrupts = <10>;
+
+ txdma-req = <2>;
+ rxdma-req = <3>;
+
+ dmas = <&gdma 4>,
+ <&gdma 6>;
+ dma-names = "tx", "rx";
+
+ status = "disabled";
+ };
+
spi0: spi@b00 {
compatible = "ralink,rt3352-spi", "ralink,rt2880-spi";
reg = <0xb00 0x40>;
@@ -191,6 +227,23 @@
pinctrl-names = "default";
pinctrl-0 = <&uartlite_pins>;
};
+
+ gdma: gdma@2800 {
+ compatible = "ralink,rt3883-gdma";
+ reg = <0x2800 0x800>;
+
+ resets = <&rstctrl 14>;
+ reset-names = "dma";
+
+ interrupt-parent = <&intc>;
+ interrupts = <7>;
+
+ #dma-cells = <1>;
+ #dma-channels = <16>;
+ #dma-requests = <16>;
+
+ status = "disabled";
+ };
};
pinctrl: pinctrl {
@@ -202,6 +255,27 @@
state_default: pinctrl0 {
};
+ i2c_pins: i2c {
+ i2c {
+ ralink,group = "i2c";
+ ralink,function = "i2c";
+ };
+ };
+
+ mdio_pins: mdio {
+ mdio {
+ ralink,group = "mdio";
+ ralink,function = "mdio";
+ };
+ };
+
+ rgmii_pins: rgmii {
+ rgmii {
+ ralink,group = "rgmii";
+ ralink,function = "rgmii";
+ };
+ };
+
spi_pins: spi {
spi {
ralink,group = "spi";
@@ -260,8 +334,9 @@
usbphy: usbphy {
compatible = "ralink,rt3352-usbphy";
- #phy-cells = <1>;
+ #phy-cells = <0>;
+ ralink,sysctl = <&sysc>;
resets = <&rstctrl 22 &rstctrl 25>;
reset-names = "host", "device";
clocks = <&clkctrl 18 &clkctrl 20>;
@@ -282,7 +357,7 @@
compatible = "generic-ehci";
reg = <0x101c0000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
@@ -295,7 +370,7 @@
compatible = "generic-ohci";
reg = <0x101c1000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
Index: sys/gnu/dts/mips/rt3883.dtsi
===================================================================
--- sys/gnu/dts/mips/rt3883.dtsi
+++ sys/gnu/dts/mips/rt3883.dtsi
@@ -35,7 +35,7 @@
#size-cells = <1>;
sysc: sysc@0 {
- compatible = "ralink,rt3883-sysc", "ralink,rt3050-sysc";
+ compatible = "ralink,rt3883-sysc", "ralink,rt3050-sysc", "syscon";
reg = <0x0 0x100>;
};
@@ -166,6 +166,42 @@
status = "disabled";
};
+ i2c@900 {
+ compatible = "ralink,rt2880-i2c";
+ reg = <0x900 0x100>;
+
+ resets = <&rstctrl 16>;
+ reset-names = "i2c";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ status = "disabled";
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c_pins>;
+ };
+
+ i2s@a00 {
+ compatible = "ralink,rt3883-i2s";
+ reg = <0xa00 0x100>;
+
+ resets = <&rstctrl 17>;
+ reset-names = "i2s";
+
+ interrupt-parent = <&intc>;
+ interrupts = <10>;
+
+ txdma-req = <2>;
+ rxdma-req = <3>;
+
+ dmas = <&gdma 4>,
+ <&gdma 6>;
+ dma-names = "tx", "rx";
+
+ status = "disabled";
+ };
+
spi0: spi@b00 {
compatible = "ralink,rt3883-spi", "ralink,rt2880-spi";
reg = <0xb00 0x40>;
@@ -211,6 +247,23 @@
pinctrl-names = "default";
pinctrl-0 = <&uartlite_pins>;
};
+
+ gdma: gdma@2800 {
+ compatible = "ralink,rt3883-gdma";
+ reg = <0x2800 0x800>;
+
+ resets = <&rstctrl 14>;
+ reset-names = "dma";
+
+ interrupt-parent = <&intc>;
+ interrupts = <7>;
+
+ #dma-cells = <1>;
+ #dma-channels = <16>;
+ #dma-requests = <16>;
+
+ status = "disabled";
+ };
};
pinctrl: pinctrl {
@@ -222,6 +275,13 @@
state_default: pinctrl0 {
};
+ i2c_pins: i2c {
+ i2c {
+ ralink,group = "i2c";
+ ralink,function = "i2c";
+ };
+ };
+
spi_pins: spi {
spi {
ralink,group = "spi";
@@ -246,6 +306,8 @@
ethernet: ethernet@10100000 {
compatible = "ralink,rt3883-eth";
+ #address-cells = <1>;
+ #size-cells = <0>;
reg = <0x10100000 0x10000>;
resets = <&rstctrl 21>;
@@ -365,8 +427,9 @@
usbphy: usbphy {
compatible = "ralink,rt3352-usbphy";
- #phy-cells = <1>;
+ #phy-cells = <0>;
+ ralink,sysctl = <&sysc>;
resets = <&rstctrl 22 &rstctrl 25>;
reset-names = "host", "device";
clocks = <&clkctrl 22 &clkctrl 25>;
@@ -387,7 +450,7 @@
compatible = "generic-ehci";
reg = <0x101c0000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
@@ -400,7 +463,7 @@
compatible = "generic-ohci";
reg = <0x101c1000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
@@ -409,5 +472,3 @@
status = "disabled";
};
};
-
-#include "fbsd-rt3883.dtsi"
Index: sys/gnu/dts/mips/rt5350.dtsi
===================================================================
--- sys/gnu/dts/mips/rt5350.dtsi
+++ sys/gnu/dts/mips/rt5350.dtsi
@@ -35,7 +35,7 @@
#size-cells = <1>;
sysc: sysc@0 {
- compatible = "ralink,rt5350-sysc", "ralink,rt3050-sysc";
+ compatible = "ralink,rt5350-sysc", "ralink,rt3050-sysc", "syscon";
reg = <0x0 0x100>;
};
@@ -138,7 +138,7 @@
};
i2c: i2c@900 {
- compatible = "link,rt5350-i2c", "ralink,rt2880-i2c";
+ compatible = "ralink,rt2880-i2c";
reg = <0x900 0x100>;
resets = <&rstctrl 16>;
@@ -153,6 +153,26 @@
status = "disabled";
};
+ i2s: i2s@a00 {
+ compatible = "ralink,rt3352-i2s";
+ reg = <0xa00 0x100>;
+
+ resets = <&rstctrl 17>;
+ reset-names = "i2s";
+
+ interrupt-parent = <&intc>;
+ interrupts = <10>;
+
+ txdma-req = <2>;
+ rxdma-req = <3>;
+
+ dmas = <&gdma 4>,
+ <&gdma 6>;
+ dma-names = "tx", "rx";
+
+ status = "disabled";
+ };
+
spi0: spi@b00 {
compatible = "ralink,rt5350-spi", "ralink,rt2880-spi";
reg = <0xb00 0x40>;
@@ -208,6 +228,36 @@
interrupt-parent = <&cpuintc>;
interrupts = <7>;
};
+
+ pcm: pcm@2000 {
+ compatible = "ralink,rt5350-pcm";
+ reg = <0x2000 0x800>;
+
+ resets = <&rstctrl 11>;
+ reset-names = "pcm";
+
+ interrupt-parent = <&intc>;
+ interrupts = <4>;
+
+ status = "disabled";
+ };
+
+ gdma: gdma@2800 {
+ compatible = "ralink,rt3883-gdma";
+ reg = <0x2800 0x800>;
+
+ resets = <&rstctrl 14>;
+ reset-names = "dma";
+
+ interrupt-parent = <&intc>;
+ interrupts = <7>;
+
+ #dma-cells = <1>;
+ #dma-channels = <16>;
+ #dma-requests = <16>;
+
+ status = "disabled";
+ };
};
pinctrl: pinctrl {
@@ -219,13 +269,6 @@
state_default: pinctrl0 {
};
- spi_pins: spi {
- spi {
- ralink,group = "spi";
- ralink,function = "spi";
- };
- };
-
i2c_pins: i2c {
i2c {
ralink,group = "i2c";
@@ -233,6 +276,13 @@
};
};
+ spi_pins: spi {
+ spi {
+ ralink,group = "spi";
+ ralink,function = "spi";
+ };
+ };
+
phy_led_pins: phy_led {
phy_led {
ralink,group = "led";
@@ -274,8 +324,9 @@
usbphy: usbphy {
compatible = "ralink,rt3352-usbphy";
- #phy-cells = <1>;
+ #phy-cells = <0>;
+ ralink,sysctl = <&sysc>;
resets = <&rstctrl 22 &rstctrl 25>;
reset-names = "host", "device";
clocks = <&clkctrl 18>;
@@ -320,7 +371,7 @@
compatible = "generic-ehci";
reg = <0x101c0000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;
@@ -331,7 +382,7 @@
compatible = "generic-ohci";
reg = <0x101c1000 0x1000>;
- phys = <&usbphy 1>;
+ phys = <&usbphy>;
phy-names = "usb";
interrupt-parent = <&intc>;

File Metadata

Mime Type
text/plain
Expires
Sun, Mar 15, 10:23 PM (2 h, 31 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29738179
Default Alt Text
D17955.diff (534 KB)

Event Timeline