kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] iwlwifi: pcie: missing unlock on error path
@ 2017-04-21 10:39 Dan Carpenter
  2017-04-21 10:43 ` Kalle Valo
  2017-04-21 10:43 ` Coelho, Luciano
  0 siblings, 2 replies; 3+ messages in thread
From: Dan Carpenter @ 2017-04-21 10:39 UTC (permalink / raw)
  To: Johannes Berg, Sara Sharon
  Cc: Emmanuel Grumbach, Luca Coelho, Intel Linux Wireless, Kalle Valo,
	linux-wireless, kernel-janitors

We should unlock before returning.

Fixes: eda50cde58de ("iwlwifi: pcie: add context information support")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c b/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c
index 302310dfef9e..4e84955d55c8 100644
--- a/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c
+++ b/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c
@@ -212,8 +212,10 @@ int iwl_trans_pcie_gen2_start_fw(struct iwl_trans *trans,
 		goto out;
 	}
 
-	if (iwl_pcie_ctxt_info_init(trans, fw))
-		return -ENOMEM;
+	if (iwl_pcie_ctxt_info_init(trans, fw)) {
+		ret = -ENOMEM;
+		goto out;
+	}
 
 	/* re-check RF-Kill state since we may have missed the interrupt */
 	hw_rfkill = iwl_trans_check_hw_rf_kill(trans);

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

end of thread, other threads:[~2017-04-21 10:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-21 10:39 [PATCH] iwlwifi: pcie: missing unlock on error path Dan Carpenter
2017-04-21 10:43 ` Kalle Valo
2017-04-21 10:43 ` Coelho, Luciano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).