Skip to contentSkip to conversation

ath9k: remove unnecessary code

PATCH In review Gustavo A. R. Silva 2 participants 2 messages May 9, 2017 – May 19, 2017

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 ath9k: remove unnecessary code

The array field eeprom_data in struct th9k_platform_data is a fixed size array so it can never be NULL.

Addresses-Coverity-ID: 1364903

Cc Arend Van Spriel <[email protected]>
Cc Kalle Valo <[email protected]>

---
Changes in v2:
Rephrase commit log.

 drivers/net/wireless/ath/ath9k/eeprom.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/ath/ath9k/eeprom.c +1 -1
index fb80ec8..5c3bc28 100644
@@ -143,7 +143,7 @@ bool ath9k_hw_nvram_read(struct ath_hw *ah, u32 off, u16 *data)
 
 	if (ah->eeprom_blob)
 		ret = ath9k_hw_nvram_read_firmware(ah->eeprom_blob, off, data);
-	else if (pdata && !pdata->use_eeprom && pdata->eeprom_data)
+	else if (pdata && !pdata->use_eeprom)
 		ret = ath9k_hw_nvram_read_pdata(pdata, off, data);
 	else
 		ret = common->bus_ops->eeprom_read(common, off, data);
Signature · 1 line
2.5.0
#1 lore raw
Quoted 7 lines · Gustavo A. R. Silva

The array field eeprom_data in struct th9k_platform_data is a fixed size array so it can never be NULL.

Addresses-Coverity-ID: 1364903

Cc Arend Van Spriel <[email protected]>
Cc Kalle Valo <[email protected]>

Patch applied to ath-next branch of ath.git, thanks.

641c1f4ab7f6 ath9k: remove unnecessary code

Signature · 3 lines
https://patchwork.kernel.org/patch/9717873/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches