ath79: ar: convert to nvmem-layout
[openwrt/staging/hauke.git] / target / linux / ath79 / dts / ar7241_tplink_tl-wr842n-v1.dts
index c02154a90232766860b29512b516efbdf7071bec..02b96912ba9a9dcb64db6b235f8f35ae500be91f 100644 (file)
                compatible = "gpio-leds";
 
                led_system: system {
-                       label = "tp-link:green:system";
+                       label = "green:system";
                        gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
                };
 
                qss {
-                       label = "tp-link:green:qss";
+                       label = "green:qss";
                        gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
                };
 
                led3g {
-                       label = "tp-link:green:3g";
+                       label = "green:3g";
                        gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
                        trigger-sources = <&hub_port>;
                        linux,default-trigger = "usbport";
@@ -60,7 +60,7 @@
                compatible = "gpio-leds";
 
                wlan {
-                       label = "tp-link:green:wlan";
+                       label = "green:wlan";
                        gpios = <&ath9k 0 GPIO_ACTIVE_LOW>;
                        linux,default-trigger = "phy0tpt";
                };
 };
 
 &usb {
-       #address-cells = <1>;
-       #size-cells = <0>;
        status = "okay";
-
-       hub_port: port@1 {
-               reg = <1>;
-               #trigger-source-cells = <0>;
-       };
 };
 
 &usb_phy {
@@ -95,8 +88,6 @@
 &spi {
        status = "okay";
 
-       num-cs = <1>;
-
        flash@0 {
                compatible = "jedec,spi-nor";
                reg = <0>;
                                reg = <0x0 0x20000>;
                                label = "u-boot";
                                read-only;
+
+                               nvmem-layout {
+                                       compatible = "fixed-layout";
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       macaddr_uboot_1fc00: macaddr@1fc00 {
+                                               reg = <0x1fc00 0x6>;
+                                       };
+                               };
                        };
 
                        partition@20000 {
                #gpio-cells = <2>;
                gpio-controller;
                qca,no-eeprom;
-               mtd-mac-address = <&uboot 0x1fc00>;
+               nvmem-cells = <&macaddr_uboot_1fc00>;
+               nvmem-cell-names = "mac-address";
        };
 };
 
 &eth0 {
        status = "okay";
 
-       mtd-mac-address = <&uboot 0x1fc00>;
-       mtd-mac-address-increment = <(-1)>;
+       nvmem-cells = <&macaddr_uboot_1fc00>;
+       nvmem-cell-names = "mac-address";
+       mac-address-increment = <(-1)>;
 };
 
 &eth1 {
-       mtd-mac-address = <&uboot 0x1fc00>;
-       mtd-mac-address-increment = <1>;
-};
-
-&uart {
-       status = "okay";
+       nvmem-cells = <&macaddr_uboot_1fc00>;
+       nvmem-cell-names = "mac-address";
+       mac-address-increment = <1>;
 };