From 5e50515fa6b3e2ddfd7ffb478b2111dc589dfd4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thibaut=20VAR=C3=88NE?= Date: Mon, 20 Apr 2020 14:35:57 +0200 Subject: ramips/mt7621: mikrotik: don't use mtd-mac-address in DTS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As evidenced here[1] the device MAC address can be stored at a random offset in the hard_config partition. Rely on sysfs to update the MAC address correctly. Adjust config so that WAN is base MAC and LAN is base MAC +1 to better match label and vendor OS. [1] https://github.com/openwrt/openwrt/pull/2850#issuecomment-610809021 Signed-off-by: Thibaut VARĂˆNE --- .../linux/ramips/dts/mt7621_mikrotik_routerboard-750gr3.dts | 12 ------------ target/linux/ramips/dts/mt7621_mikrotik_routerboard-m11g.dts | 5 ----- target/linux/ramips/dts/mt7621_mikrotik_routerboard-m33g.dts | 7 ------- 3 files changed, 24 deletions(-) (limited to 'target/linux/ramips/dts') diff --git a/target/linux/ramips/dts/mt7621_mikrotik_routerboard-750gr3.dts b/target/linux/ramips/dts/mt7621_mikrotik_routerboard-750gr3.dts index a075d085565..018e83664db 100644 --- a/target/linux/ramips/dts/mt7621_mikrotik_routerboard-750gr3.dts +++ b/target/linux/ramips/dts/mt7621_mikrotik_routerboard-750gr3.dts @@ -126,10 +126,6 @@ }; }; -&gmac0 { - mtd-mac-address = <&hard_config 0x0010>; -}; - &switch0 { ports { port@0 { @@ -140,29 +136,21 @@ port@1 { status = "okay"; label = "lan2"; - mtd-mac-address = <&hard_config 0x0010>; - mtd-mac-address-increment = <1>; }; port@2 { status = "okay"; label = "lan3"; - mtd-mac-address = <&hard_config 0x0010>; - mtd-mac-address-increment = <2>; }; port@3 { status = "okay"; label = "lan4"; - mtd-mac-address = <&hard_config 0x0010>; - mtd-mac-address-increment = <3>; }; port@4 { status = "okay"; label = "lan5"; - mtd-mac-address = <&hard_config 0x0010>; - mtd-mac-address-increment = <4>; }; }; }; diff --git a/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m11g.dts b/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m11g.dts index 128b8a2816a..d7c4a457981 100644 --- a/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m11g.dts +++ b/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m11g.dts @@ -134,11 +134,6 @@ }; }; -&gmac0 { - mtd-mac-address = <&hard_config 0x0010>; - mtd-mac-address-increment = <1>; -}; - &switch0 { ports { port@0 { diff --git a/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m33g.dts b/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m33g.dts index aff2d0e64f4..30bb36a77fc 100644 --- a/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m33g.dts +++ b/target/linux/ramips/dts/mt7621_mikrotik_routerboard-m33g.dts @@ -158,18 +158,11 @@ }; }; -&gmac0 { - mtd-mac-address = <&hard_config 0x0010>; - mtd-mac-address-increment = <1>; -}; - &switch0 { ports { port@0 { status = "okay"; label = "wan"; - mtd-mac-address = <&hard_config 0x0010>; - mtd-mac-address-increment = <2>; }; port@1 { -- cgit v1.2.3