mediatek: filogic: set label MAC address on TP-Link BE450
The label-mac-device alias cannot work on this device: it is resolved by reading the mac-address property of the aliased DT node, but gmac0 never has one. The MAC is stored in a file inside the tp_data UBIFS volume, so there is no fixed flash offset an nvmem-layout could point at, and the vendor bootloader does not fix up the FDT either. Drop the dead alias. Record the label MAC in board.d instead and assign it to the lan interface, as is already done for the other devices reading /tmp/tp_data/default-mac (Mercusys MR90X v1, Archer AX80 v1, RE6000XD). The explicit lan MAC also makes the br-lan address independent of the order of the bridge ports. Suggested-by: Felix Baumann <felix.bau@gmx.de> Signed-off-by: Semih Baskan <strst.gs@gmail.com> Link: https://github.com/openwrt/openwrt/pull/24180 Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
This commit is contained in:
@@ -19,7 +19,6 @@
|
||||
|
||||
aliases {
|
||||
serial0 = &serial0;
|
||||
label-mac-device = &gmac0;
|
||||
led-boot = &led_status;
|
||||
led-failsafe = &led_status;
|
||||
led-running = &led_status;
|
||||
|
||||
@@ -299,6 +299,7 @@ mediatek_setup_macs()
|
||||
mercusys,mr90x-v1|\
|
||||
tplink,archer-ax80-v1|\
|
||||
tplink,archer-ax80-v1-eu|\
|
||||
tplink,be450|\
|
||||
tplink,re6000xd)
|
||||
label_mac=$(get_mac_binary "/tmp/tp_data/default-mac" 0)
|
||||
lan_mac=$label_mac
|
||||
|
||||
Reference in New Issue
Block a user