ramips: mt7628: use nvmem-layout
[openwrt/staging/hauke.git] / target / linux / ramips / dts / mt7628an_jotale_js76x8.dtsi
index 61c5d7b7c498fd73e2729482d99f1a8bd61e59fe..643f599246c045a78f019baf2f20bc19a139057f 100644 (file)
                compatible = "gpio-leds";
 
                led_system: system {
-                       label = "js76x8:green:system";
+                       label = "green:system";
                        gpios = <&gpio 37 GPIO_ACTIVE_LOW>;
                };
 
                wifi {
-                       label = "js76x8:green:wifi";
+                       label = "green:wifi";
                        gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
                        linux,default-trigger = "phy0tpt";
                };
        pinctrl-names = "default";
        pinctrl-0 = <&spi_pins>, <&spi_cs1_pins>;
 
-       flash@0 {
+       flash0: flash@0 {
                compatible = "jedec,spi-nor";
                reg = <0>;
                spi-max-frequency = <40000000>;
-               m25p,chunked-io = <32>;
 
                partitions {
                        compatible = "fixed-partitions";
                                label = "factory";
                                reg = <0x40000 0x10000>;
                                read-only;
+
+                               nvmem-layout {
+                                       compatible = "fixed-layout";
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       eeprom_factory_0: eeprom@0 {
+                                               reg = <0x0 0x400>;
+                                       };
+
+                                       macaddr_factory_28: macaddr@28 {
+                                               reg = <0x28 0x6>;
+                                       };
+                               };
                        };
 
                        firmware: partition@50000 {
 };
 
 &ethernet {
-       mtd-mac-address = <&factory 0x28>;
+       nvmem-cells = <&macaddr_factory_28>;
+       nvmem-cell-names = "mac-address";
 };
 
 &sdhci {
 
 &wmac {
        status = "okay";
+
+       nvmem-cells = <&eeprom_factory_0>;
+       nvmem-cell-names = "eeprom";
 };