Search Linux Wireless

[PATCH] wifi: iwlwifi: fw: remove dead branch in iwl_acpi_get_wgds_table()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Since the first loop in iwl_acpi_get_wgds_table() always terminates
with 'idx == ARRAY_SIZE(rev_data)' unless one of goto branches is
taken, remove unreachable code. Compile tested only.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Signed-off-by: Dmitry Antipov <dmantipov@xxxxxxxxx>
---
 drivers/net/wireless/intel/iwlwifi/fw/acpi.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/net/wireless/intel/iwlwifi/fw/acpi.c b/drivers/net/wireless/intel/iwlwifi/fw/acpi.c
index fa339791223b..7fb3cd06edbb 100644
--- a/drivers/net/wireless/intel/iwlwifi/fw/acpi.c
+++ b/drivers/net/wireless/intel/iwlwifi/fw/acpi.c
@@ -745,10 +745,7 @@ int iwl_acpi_get_wgds_table(struct iwl_fw_runtime *fwrt)
 		}
 	}
 
-	if (idx < ARRAY_SIZE(rev_data))
-		ret = PTR_ERR(wifi_pkg);
-	else
-		ret = -ENOENT;
+	ret = -ENOENT;
 	goto out_free;
 
 read_table:
-- 
2.45.0





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux