[openwrt/openwrt] ramips: fix ethernet MAC address on Omega2

LEDE Commits lede-commits at lists.infradead.org
Sat Aug 21 07:31:41 PDT 2021


hauke pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/4b4fa2f9fed7340dca12b4fcd8e36e0c8612b95d

commit 4b4fa2f9fed7340dca12b4fcd8e36e0c8612b95d
Author: Michael Siegenthaler <msiegen at google.com>
AuthorDate: Wed Aug 18 17:58:56 2021 -0700

    ramips: fix ethernet MAC address on Omega2
    
    According to https://docs.onion.io/omega2-docs/mac-address.html, 0x28 is
    the correct location to read the address on Onion Omega 2(+) devices.
    
    This fixes a regression introduced by commit 77e850fe76e3 ("ramips: tidy up
    MAC address setup for Linkit Smart and Omega2"), which was a cleanup that
    intended to preserve existing behavior. In my testing with v19.07.7,
    however, the MAC address determined from the device tree takes precedence
    over the one set by 02_network, so the aforementioned commit actually
    changed the behavior.
    
    Signed-off-by: Michael Siegenthaler <msiegen at google.com>
    [Adapt patch to nvmem usage]
    Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
---
 target/linux/ramips/dts/mt7628an_onion_omega2.dtsi | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/target/linux/ramips/dts/mt7628an_onion_omega2.dtsi b/target/linux/ramips/dts/mt7628an_onion_omega2.dtsi
index 555a2a1261..742c975d66 100644
--- a/target/linux/ramips/dts/mt7628an_onion_omega2.dtsi
+++ b/target/linux/ramips/dts/mt7628an_onion_omega2.dtsi
@@ -152,7 +152,7 @@
 };
 
 &ethernet {
-	nvmem-cells = <&macaddr_factory_2e>;
+	nvmem-cells = <&macaddr_factory_28>;
 	nvmem-cell-names = "mac-address";
 };
 
@@ -172,7 +172,7 @@
 	#address-cells = <1>;
 	#size-cells = <1>;
 
-	macaddr_factory_2e: macaddr at 2e {
-		reg = <0x2e 0x6>;
+	macaddr_factory_28: macaddr at 28 {
+		reg = <0x28 0x6>;
 	};
 };



More information about the lede-commits mailing list