lantiq: convert to new LED color/function format where possible
[openwrt/openwrt.git] / target / linux / lantiq / files / arch / mips / boot / dts / lantiq / ar9_buffalo_wbmr-hp-g300h.dts
index e240f0c57630c1e87d1d321605d21a190801e224..5a50f27c08b059799a2bafa3474631ed52f69c6b 100644 (file)
@@ -1,6 +1,7 @@
 #include "ar9.dtsi"
 
 #include <dt-bindings/input/input.h>
+#include <dt-bindings/leds/common.h>
 
 / {
        compatible = "buffalo,wbmr-hp-g300h", "lantiq,xway", "lantiq,ar9";
                compatible = "gpio-leds";
 
                power_green: power {
-                       label = "green:power";
+                       function = LED_FUNCTION_POWER;
+                       color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
                        default-state = "keep";
                };
                power_red: power2 {
-                       label = "red:power";
+                       function = LED_FUNCTION_POWER;
+                       color = <LED_COLOR_ID_RED>;
                        gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
                };
                security {
@@ -90,7 +93,8 @@
                        gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
                };
                led_usb: usb {
-                       label = "green:usb";
+                       function = LED_FUNCTION_USB;
+                       color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 28 GPIO_ACTIVE_LOW>;
                        default-state = "on";
                };
 
 &gsw {
        phy-mode = "rgmii";
-       mtd-mac-address = <&boardconfig 0x10024>;
+       nvmem-cells = <&macaddr_boardconfig_10024>;
+       nvmem-cell-names = "mac-address";
 };
 
 &pci0 {
                                label = "board";
                                reg = <0x1fc0000 0x20000>;
                                read-only;
+
+                               nvmem-layout {
+                                       compatible = "fixed-layout";
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       macaddr_boardconfig_10024: macaddr@10024 {
+                                               reg = <0x10024 0x6>;
+                                       };
+                               };
                        };
 
                        partition@1fe0000 {