ramips: dts: Unify naming of gpio-keys nodes
[openwrt/openwrt.git] / target / linux / ramips / dts / TEW-692GR.dts
index b9c7006406e898f48cd48a15bcf0c6b2c75f8fdb..53963414e674b5ed2ca59e75a9506ba26440b997 100644 (file)
@@ -2,58 +2,69 @@
 
 #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";
 
+       aliases {
+               led-boot = &led_wps_green;
+               led-failsafe = &led_wps_green;
+               led-running = &led_wps_green;
+               led-upgrade = &led_wps_green;
+       };
+
        nor-flash@1c000000 {
                compatible = "cfi-flash";
                reg = <0x1c000000 0x800000>;
                bank-width = <2>;
-               #address-cells = <1>;
-               #size-cells = <1>;
 
-               partition@0 {
-                       reg = <0x0 0x0030000>;
-                       label = "u-boot";
-                       read-only;
-               };
+               partitions {
+                       compatible = "fixed-partitions";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
 
-               partition@30000 {
-                       reg = <0x00030000 0x00010000>;
-                       label = "u-boot-env";
-                       read-only;
-               };
+                       partition@0 {
+                               reg = <0x0 0x0030000>;
+                               label = "u-boot";
+                               read-only;
+                       };
 
-               factory: partition@40000 {
-                       reg = <0x00040000 0x00010000>;
-                       label = "factory";
-                       read-only;
-               };
+                       partition@30000 {
+                               reg = <0x00030000 0x00010000>;
+                               label = "u-boot-env";
+                               read-only;
+                       };
+
+                       factory: partition@40000 {
+                               reg = <0x00040000 0x00010000>;
+                               label = "factory";
+                               read-only;
+                       };
 
-               partition@50000 {
-                       reg = <0x00050000 0x007b0000>;
-                       label = "firmware";
+                       partition@50000 {
+                               compatible = "denx,uimage";
+                               reg = <0x00050000 0x007b0000>;
+                               label = "firmware";
+                       };
                };
        };
 
-       gpio-keys-polled {
+       keys {
                compatible = "gpio-keys-polled";
-               #address-cells = <1>;
-               #size-cells = <0>;
                poll-interval = <100>;
 
                reset {
                        label = "reset";
-                       gpios = <&gpio0 10 1>;
+                       gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
                        linux,code = <KEY_RESTART>;
                };
 
                wps {
                        label = "wps";
-                       gpios = <&gpio1 2 1>;
+                       gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
                        linux,code = <KEY_WPS_BUTTON>;
                };
        };
 
                wps {
                        label = "tew-692gr:orange:wps";
-                       gpios = <&gpio0 9 1>;
+                       gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
                };
 
-               wps2 {
+               led_wps_green: wps2 {
                        label = "tew-692gr:green:wps";
-                       gpios = <&gpio1 4 1>;
+                       gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
                };
        };
 };
 
 &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";
+&pci1 {
+       status = "okay";
 
-                       wifi@0,0 {
-                               compatible = "pci0,0";
-                               reg = < 0x10000 0 0 0 0 >;
-                               ralink,2ghz = <0>;
-                       };
-               };
+       wifi@0,0 {
+               compatible = "pci0,0";
+               reg = < 0x10000 0 0 0 0 >;
+               ralink,2ghz = <0>;
        };
 };