* [PATCH wireless-next] wifi: mt76: fix MAC address for non OF pcie cards
@ 2026-06-30 21:02 Rosen Penev
2026-07-06 7:23 ` Thorsten Leemhuis
2026-07-06 14:40 ` Klara Modin
0 siblings, 2 replies; 4+ messages in thread
From: Rosen Penev @ 2026-06-30 21:02 UTC (permalink / raw)
To: linux-wireless
Cc: Felix Fietkau, Lorenzo Bianconi, Ryder Lee, Shayne Chen,
Sean Wang, Matthias Brugger, AngeloGioacchino Del Regno,
Rosen Penev, open list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support
If seems the check for err is wrong as the proper macaddr gets written
to from the EEPROM itself. Meaning checking err from of_get_mac_address is
wrong as the proper macaddr has been written by this point.
Fixes: 31ee1582717e ("wifi: mt76: fix of_get_mac_address error handling")
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
drivers/net/wireless/mediatek/mt76/eeprom.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/mediatek/mt76/eeprom.c b/drivers/net/wireless/mediatek/mt76/eeprom.c
index b99d7452800f..afdb73661866 100644
--- a/drivers/net/wireless/mediatek/mt76/eeprom.c
+++ b/drivers/net/wireless/mediatek/mt76/eeprom.c
@@ -181,7 +181,7 @@ mt76_eeprom_override(struct mt76_phy *phy)
if (err == -EPROBE_DEFER)
return err;
- if (err) {
+ if (!is_valid_ether_addr(phy->macaddr)) {
eth_random_addr(phy->macaddr);
dev_info(dev->dev,
"Invalid MAC address, using random address %pM\n",
--
2.55.0
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH wireless-next] wifi: mt76: fix MAC address for non OF pcie cards
2026-06-30 21:02 [PATCH wireless-next] wifi: mt76: fix MAC address for non OF pcie cards Rosen Penev
@ 2026-07-06 7:23 ` Thorsten Leemhuis
2026-07-06 8:19 ` Tobias Klausmann
2026-07-06 14:40 ` Klara Modin
1 sibling, 1 reply; 4+ messages in thread
From: Thorsten Leemhuis @ 2026-07-06 7:23 UTC (permalink / raw)
To: Rosen Penev, linux-wireless
Cc: Felix Fietkau, Lorenzo Bianconi, Ryder Lee, Shayne Chen,
Sean Wang, Matthias Brugger, AngeloGioacchino Del Regno,
open list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support,
Linux kernel regressions list, Klara Modin, Tobias Klausmann
On 6/30/26 23:02, Rosen Penev wrote:
> If seems the check for err is wrong as the proper macaddr gets written
> to from the EEPROM itself. Meaning checking err from of_get_mac_address is
> wrong as the proper macaddr has been written by this point.
By our submission guidelines and requests from Linus this afaics should
also contain:
Reported-by: Klara Modin <klarasmodin@gmail.com>
Closes: https://lore.kernel.org/all/ajRmlyx_AEGybykL@soda.int.kasm.eu/
Reported-by: Tobias Klausmann <klausman@schwarzvogel.de>
Closes:
https://lore.kernel.org/linux-wireless/30a90714-02d8-45f2-a7f1-4cfe0627d50b@skade.local/
Both of them now CCed, too, to give them a chance to provide a "Tested-by:".
> Fixes: 31ee1582717e ("wifi: mt76: fix of_get_mac_address error handling")
Given this and the reports linked above this afaics should also be
tagged with "wireless", and not with "wireless-next", as this commit is
in 7.2-rc1 -- and thus ideally should be fixed by now. See
https://www.kernel.org/doc/html/latest/process/handling-regressions.html#on-how-quickly-regressions-should-be-fixed,
which contains links to these quotes from Linus:
""But a user complaining should basically result in an immediate fix -
possibly a "revert and rethink"."" and ""It's also worth noting that
"immediate" obviously doesn't mean "right this *second* when the problem
has been reported". But if it's a regression with a known commit that
caused it, I think the rule of thumb should generally be "within a
week", preferably before the next rc.""
Ciao, Thorsten
> Signed-off-by: Rosen Penev <rosenp@gmail.com>
> ---
> drivers/net/wireless/mediatek/mt76/eeprom.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/wireless/mediatek/mt76/eeprom.c b/drivers/net/wireless/mediatek/mt76/eeprom.c
> index b99d7452800f..afdb73661866 100644
> --- a/drivers/net/wireless/mediatek/mt76/eeprom.c
> +++ b/drivers/net/wireless/mediatek/mt76/eeprom.c
> @@ -181,7 +181,7 @@ mt76_eeprom_override(struct mt76_phy *phy)
> if (err == -EPROBE_DEFER)
> return err;
>
> - if (err) {
> + if (!is_valid_ether_addr(phy->macaddr)) {
> eth_random_addr(phy->macaddr);
> dev_info(dev->dev,
> "Invalid MAC address, using random address %pM\n",
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH wireless-next] wifi: mt76: fix MAC address for non OF pcie cards
2026-07-06 7:23 ` Thorsten Leemhuis
@ 2026-07-06 8:19 ` Tobias Klausmann
0 siblings, 0 replies; 4+ messages in thread
From: Tobias Klausmann @ 2026-07-06 8:19 UTC (permalink / raw)
To: Thorsten Leemhuis
Cc: Rosen Penev, linux-wireless, Felix Fietkau, Lorenzo Bianconi,
Ryder Lee, Shayne Chen, Sean Wang, Matthias Brugger,
AngeloGioacchino Del Regno, open list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support,
Linux kernel regressions list, Klara Modin
Hi!
On Mon, 06 Jul 2026, Thorsten Leemhuis wrote:
> On 6/30/26 23:02, Rosen Penev wrote:
> > If seems the check for err is wrong as the proper macaddr gets written
> > to from the EEPROM itself. Meaning checking err from of_get_mac_address is
> > wrong as the proper macaddr has been written by this point.
>
> By our submission guidelines and requests from Linus this afaics should
> also contain:
>
> Reported-by: Klara Modin <klarasmodin@gmail.com>
> Closes: https://lore.kernel.org/all/ajRmlyx_AEGybykL@soda.int.kasm.eu/
> Reported-by: Tobias Klausmann <klausman@schwarzvogel.de>
> Closes:
> https://lore.kernel.org/linux-wireless/30a90714-02d8-45f2-a7f1-4cfe0627d50b@skade.local/
>
> Both of them now CCed, too, to give them a chance to provide a "Tested-by:".
>
> > Fixes: 31ee1582717e ("wifi: mt76: fix of_get_mac_address error handling")
Indeed:
Tested-by: Tobias Klausmann <klausman@schwarzvogel.de>
I've been running 7.2.0-rc1+the revert for a few days now with zero
issues (not that I expected any).
Best,
Tobias
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH wireless-next] wifi: mt76: fix MAC address for non OF pcie cards
2026-06-30 21:02 [PATCH wireless-next] wifi: mt76: fix MAC address for non OF pcie cards Rosen Penev
2026-07-06 7:23 ` Thorsten Leemhuis
@ 2026-07-06 14:40 ` Klara Modin
1 sibling, 0 replies; 4+ messages in thread
From: Klara Modin @ 2026-07-06 14:40 UTC (permalink / raw)
To: Rosen Penev
Cc: linux-wireless, Felix Fietkau, Lorenzo Bianconi, Ryder Lee,
Shayne Chen, Sean Wang, Matthias Brugger,
AngeloGioacchino Del Regno, open list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support,
moderated list:ARM/Mediatek SoC support, Tobias Klausmann,
Thorsten Leemhuis, Linux kernel regressions list
On 2026-06-30 14:02:15 -0700, Rosen Penev wrote:
> If seems the check for err is wrong as the proper macaddr gets written
> to from the EEPROM itself. Meaning checking err from of_get_mac_address is
> wrong as the proper macaddr has been written by this point.
>
> Fixes: 31ee1582717e ("wifi: mt76: fix of_get_mac_address error handling")
> Signed-off-by: Rosen Penev <rosenp@gmail.com>
Tested-by: Klara Modin <klarasmodin@gmail.com>
> ---
> drivers/net/wireless/mediatek/mt76/eeprom.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/wireless/mediatek/mt76/eeprom.c b/drivers/net/wireless/mediatek/mt76/eeprom.c
> index b99d7452800f..afdb73661866 100644
> --- a/drivers/net/wireless/mediatek/mt76/eeprom.c
> +++ b/drivers/net/wireless/mediatek/mt76/eeprom.c
> @@ -181,7 +181,7 @@ mt76_eeprom_override(struct mt76_phy *phy)
> if (err == -EPROBE_DEFER)
> return err;
>
> - if (err) {
> + if (!is_valid_ether_addr(phy->macaddr)) {
> eth_random_addr(phy->macaddr);
> dev_info(dev->dev,
> "Invalid MAC address, using random address %pM\n",
> --
> 2.55.0
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-07-06 14:40 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-30 21:02 [PATCH wireless-next] wifi: mt76: fix MAC address for non OF pcie cards Rosen Penev
2026-07-06 7:23 ` Thorsten Leemhuis
2026-07-06 8:19 ` Tobias Klausmann
2026-07-06 14:40 ` Klara Modin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox