Hello Adrian,

On 8/15/19 1:26 PM, Adrian Schmutzler wrote:
> My current understanding of ralink,mtd-eeprom for &wmac is that this reads 
> the MAC address "automatically" if it's in the correct location (start+4).

This is correct, the MAC address is stored as 3 16bit words within the EEPROM 
data, beginning at
the third word of the EEPROM data.

See
https://elixir.bootlin.com/linux/latest/source/drivers/net/wireless/ralink/rt2x00/rt2800.h#L2590
or
https://elixir.bootlin.com/linux/latest/source/drivers/net/wireless/ralink/rt2x00/rt2800lib.c#L9187

> Does this mean that e.g. in the following configuration I can tell that &wmac 
> and &ethernet have the _same_ MAC address (without checking on device):
> 
> &ethernet {
>       mtd-mac-address = <&factory 0x4>;
>       mediatek,portmap = "wllll";
> };
> &wmac {
>       ralink,mtd-eeprom = <&factory 0>;
> };

If the MAC address is not altered via userspace: correct

Best wishes
David

_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to