diff mbox series

[3/8] wifi: wilc1000: set correct value of 'close' variable in failure case

Message ID 20220720160302.231516-3-ajay.kathat@microchip.com
State New
Headers show
Series [1/8] wifi: wilc1000: fix incorrect type assignment sparse warning | expand

Commit Message

Ajay Singh July 20, 2022, 4:03 p.m. UTC
From: Ajay Singh <ajay.kathat@microchip.com>

Set 'close' variable to '1' to indicate closing operation when
initialisation fails during wlan_initialize_threads() call.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
---
 drivers/net/wireless/microchip/wilc1000/netdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/net/wireless/microchip/wilc1000/netdev.c b/drivers/net/wireless/microchip/wilc1000/netdev.c
index fcc4e61592ee..7879446f282f 100644
--- a/drivers/net/wireless/microchip/wilc1000/netdev.c
+++ b/drivers/net/wireless/microchip/wilc1000/netdev.c
@@ -472,7 +472,7 @@  static int wlan_initialize_threads(struct net_device *dev)
 				       "%s-tx", dev->name);
 	if (IS_ERR(wilc->txq_thread)) {
 		netdev_err(dev, "couldn't create TXQ thread\n");
-		wilc->close = 0;
+		wilc->close = 1;
 		return PTR_ERR(wilc->txq_thread);
 	}
 	wait_for_completion(&wilc->txq_thread_started);