Skip to contentSkip to conversation

wifi: ath9k: return by of_get_mac_address

PATCH Superseded Rosen Penev 2 participants 4 messages Sep 30, 2024 – Oct 2, 2024 Qualcomm Atheros ATH9K wireless driver

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 wifi: ath9k: return by of_get_mac_address

It can return -EPROBE_DEFER when using NVMEM. return it so that it gets forwarded to _init.

---
 drivers/net/wireless/ath/ath9k/init.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/net/wireless/ath/ath9k/init.c +1 -3
index f9e77c4624d9..8924d49fd8b5 100644
@@ -647,9 +647,7 @@ static int ath9k_of_init(struct ath_softc *sc)
 		ah->ah_flags |= AH_NO_EEP_SWAP;
 	}
 
-	of_get_mac_address(np, common->macaddr);
-
-	return 0;
+	return of_get_mac_address(np, common->macaddr);
 }
 
 static int ath9k_init_softc(u16 devid, struct ath_softc *sc,
Signature · 1 line
2.46.2
#1 lore raw
Quoted 2 lines · Rosen Penev

It can return -EPROBE_DEFER when using NVMEM. return it so that it gets forwarded to _init.

What bug, if any, does this fix?

-Toke

#2 lore raw
Quoted 7 lines · Toke Høiland-Jørgensen
Quoted 2 lines · Rosen Penev

It can return -EPROBE_DEFER when using NVMEM. return it so that it gets forwarded to _init.

What bug, if any, does this fix?

None that I've seen. But the goal is: if ath9k probes before NVMEM, defer so that it can get an NVMEM mac address properly.

I think in OpenWrt there are hacks that force ath9k to probe later, I think because of the GPIO driver situation there.

Quoted 2 lines

-Toke

#3 lore raw
Quoted 7 lines · Rosen Penev
Quoted 6 lines · Toke Høiland-Jørgensen
Quoted 2 lines · Rosen Penev

It can return -EPROBE_DEFER when using NVMEM. return it so that it gets forwarded to _init.

Quoted 6 lines
Quoted 1 line

What bug, if any, does this fix?

None that I've seen. But the goal is: if ath9k probes before NVMEM, defer so that it can get an NVMEM mac address properly.

I think in OpenWrt there are hacks that force ath9k to probe later, I think because of the GPIO driver situation there.

Right. Please include this rationale in the patch description :)

-Toke