Skip to content

Commit

Permalink
mt76: mt76x0: eeprom: add support for MAC address from OF
Browse files Browse the repository at this point in the history
mt76x0e driver only supports MAC addresses from
calibration data eeprom. Many routers however do not
have a valid stock address set in this field.

This patch makes it possible to take a MAC address
from OF (e.g. from mtd).

Signed-off-by: Pawel Dembicki <[email protected]>
[adjusted for kernel submission]
Signed-off-by: Adrian Schmutzler <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
  • Loading branch information
CHKDSK88 authored and nbd168 committed Oct 7, 2019
1 parent d94cc81 commit c11a4ad
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions mt76x0/eeprom.c
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,7 @@ int mt76x0_eeprom_init(struct mt76x02_dev *dev)
version, fae);

mt76x02_mac_setaddr(dev, dev->mt76.eeprom.data + MT_EE_MAC_ADDR);
mt76_eeprom_override(&dev->mt76);
mt76x0_set_chip_cap(dev);
mt76x0_set_freq_offset(dev);
mt76x0_set_temp_offset(dev);
Expand Down

0 comments on commit c11a4ad

Please sign in to comment.