Skip to contentSkip to conversation

ath9k: fix return code check

PATCH In review Felix Fietkau 1 participant 1 message Jul 20, 2008 Networking drivers (wireless)

lore
Share & tools
lore
#0 lore raw

PATCH 4/5 ath9k: fix return code check

Fix a return code check for ath9k_hw_nvram_read, this function returns AH_TRUE when the call succeeded

---

drivers/net/wireless/ath9k/hw.c +1 -1
@@ -803,7 +803,7 @@
 		u_int16_t magic, magic2;
 		int addr;
 
-		if (ath9k_hw_nvram_read(ah, AR5416_EEPROM_MAGIC_OFFSET,
+		if (!ath9k_hw_nvram_read(ah, AR5416_EEPROM_MAGIC_OFFSET,
 					&magic)) {
 			HDPRINTF(ah, HAL_DBG_EEPROM,
 				 "%s: Reading Magic # failed\n", __func__);