public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ath9k: fix calibration data endianness
@ 2023-04-15 15:05 Álvaro Fernández Rojas
  2023-04-15 15:25 ` Toke Høiland-Jørgensen
  0 siblings, 1 reply; 10+ messages in thread
From: Álvaro Fernández Rojas @ 2023-04-15 15:05 UTC (permalink / raw)
  To: f.fainelli, jonas.gorski, nbd, toke, kvalo, davem, edumazet, kuba,
	pabeni, chunkeey, linux-wireless, netdev, linux-kernel
  Cc: Álvaro Fernández Rojas

BCM63xx (Big Endian MIPS) devices store the calibration data in MTD
partitions but it needs to be swapped in order to work, otherwise it fails:
ath9k 0000:00:01.0: enabling device (0000 -> 0002)
ath: phy0: Ignoring endianness difference in EEPROM magic bytes.
ath: phy0: Bad EEPROM VER 0x0001 or REV 0x00e0
ath: phy0: Unable to initialize hardware; initialization status: -22
ath9k 0000:00:01.0: Failed to initialize device
ath9k: probe of 0000:00:01.0 failed with error -22

Fixes: eb3a97a69be8 ("ath9k: fetch calibration data via nvmem subsystem")
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
---
 drivers/net/wireless/ath/ath9k/init.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/wireless/ath/ath9k/init.c b/drivers/net/wireless/ath/ath9k/init.c
index 4f00400c7ffb..1314fbc55c0b 100644
--- a/drivers/net/wireless/ath/ath9k/init.c
+++ b/drivers/net/wireless/ath/ath9k/init.c
@@ -615,7 +615,6 @@ static int ath9k_nvmem_request_eeprom(struct ath_softc *sc)
 
 	ah->nvmem_blob_len = len;
 	ah->ah_flags &= ~AH_USE_EEPROM;
-	ah->ah_flags |= AH_NO_EEP_SWAP;
 
 	return 0;
 }
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2023-04-17  5:33 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-15 15:05 [PATCH] ath9k: fix calibration data endianness Álvaro Fernández Rojas
2023-04-15 15:25 ` Toke Høiland-Jørgensen
2023-04-15 16:02   ` Christian Lamparter
2023-04-15 19:32     ` Christian Lamparter
2023-04-16 10:50       ` Toke Høiland-Jørgensen
2023-04-16 13:37         ` Christian Lamparter
2023-04-16 14:28           ` Álvaro Fernández Rojas
2023-04-16 14:44           ` Andrew Lunn
2023-04-16 21:49           ` Toke Høiland-Jørgensen
2023-04-17  5:33             ` Álvaro Fernández Rojas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox