archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <>
To: Amitkumar Karwar <>, Xinming Hu <>
Cc: Nishant Sarmukadam <>,
	Ganapathi Bhat <>,
	Kalle Valo <>,,
Subject: [PATCH] mwifiex: usb: unlock on error in mwifiex_usb_tx_aggr_tmo()
Date: Mon, 10 Jul 2017 10:21:15 +0300	[thread overview]
Message-ID: <20170710072115.2y4ukbl7x4rk4bac@mwanda> (raw)

We need to unlock if mwifiex_usb_prepare_tx_aggr_skb() fails.

Fixes: a2ca85ad721d ("mwifiex: usb: add timer to flush aggregation packets")
Signed-off-by: Dan Carpenter <>

diff --git a/drivers/net/wireless/marvell/mwifiex/usb.c b/drivers/net/wireless/marvell/mwifiex/usb.c
index cb1753e43ef4..880ef1cb4088 100644
--- a/drivers/net/wireless/marvell/mwifiex/usb.c
+++ b/drivers/net/wireless/marvell/mwifiex/usb.c
@@ -1112,7 +1112,7 @@ static void mwifiex_usb_tx_aggr_tmo(unsigned long context)
 	if (err) {
 		mwifiex_dbg(adapter, ERROR,
 			    "prepare tx aggr skb failed, err=%d\n", err);
-		return;
+		goto unlock;
 	if (atomic_read(&port->tx_data_urb_pending) >=
@@ -1133,6 +1133,7 @@ static void mwifiex_usb_tx_aggr_tmo(unsigned long context)
 	if (err == -1)
 		mwifiex_write_data_complete(adapter, skb_send, 0, -1);
 	spin_unlock_irqrestore(&port->tx_aggr_lock, flags);

             reply	other threads:[~2017-07-10  7:21 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-10  7:21 Dan Carpenter [this message]
2017-07-17  3:12 ` [PATCH] mwifiex: usb: unlock on error in mwifiex_usb_tx_aggr_tmo() Xinming Hu
2017-07-28 14:51 ` Kalle Valo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170710072115.2y4ukbl7x4rk4bac@mwanda \ \ \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).