ipq40xx: use nvmem ethernet MACs on Aruba AP-303H
authorRyan Salsbury <ryanrs@gmail.com>
Sat, 27 Apr 2024 00:35:58 +0000 (17:35 -0700)
committerChristian Marangi <ansuelsmth@gmail.com>
Sat, 27 Apr 2024 09:23:29 +0000 (11:23 +0200)
Use NVMEM to assign "factory sticker" MAC address to WAN ethernet
interface. Set LAN address to sticker + 1.

Signed-off-by: Ryan Salsbury <ryanrs@gmail.com>
target/linux/ipq40xx/files-6.6/arch/arm/boot/dts/qcom/qcom-ipq4029-ap-303h.dts

index 41b42e8f58fbb5de3cdfd72196c07c658022f661..2e1fc6aedc8dc58cdcdbed713a4263d45cbba1d4 100644 (file)
                                        #size-cells = <1>;
 
                                        macaddr_mfginfo_1d: macaddr@1d {
+                                               compatible = "mac-base";
                                                reg = <0x1d 0x6>;
+                                               #nvmem-cell-cells = <1>;
                                        };
 
                                        macaddr_mfginfo_45: macaddr@45 {
 
 &gmac {
        status = "okay";
+
+       nvmem-cell-names = "mac-address";
+       nvmem-cells = <&macaddr_mfginfo_1d 1>;
 };
 
 &switch {
        status = "okay";
 
        label = "wan";
+       nvmem-cell-names = "mac-address";
+       nvmem-cells = <&macaddr_mfginfo_1d 0>;
 };
 
 &wifi0 {