From: Sujith Manoharan <sujith-TPRpbcbO+rZAfugRpC6u6w@public.gmane.org>
To: Larry Finger <Larry.Finger-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
Cc: linville-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org,
linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Stable <stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"Luis R. Rodriguez"
<mcgrof-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org>,
Vasanthakumar Thiagarajan
<vthiagar-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org>,
Senthil Balasubramanian
<senthilb-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org>,
ath9k-devel-xDcbHBWguxHbcTqmT+pZeQ@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] ath9k_htc: Fix skb leaks
Date: Wed, 2 Jan 2013 10:00:19 +0530 [thread overview]
Message-ID: <20707.47067.474241.813195@gargle.gargle.HOWL> (raw)
In-Reply-To: <1357098567-8558-1-git-send-email-Larry.Finger-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
Larry Finger wrote:
> diff --git a/drivers/net/wireless/ath/ath9k/htc_hst.c b/drivers/net/wireless/ath/ath9k/htc_hst.c
> index 4a9570d..a304748 100644
> --- a/drivers/net/wireless/ath/ath9k/htc_hst.c
> +++ b/drivers/net/wireless/ath/ath9k/htc_hst.c
> @@ -278,10 +278,12 @@ int htc_connect_service(struct htc_target *target,
> if (!time_left) {
> dev_err(target->dev, "Service connection timeout for: %d\n",
> service_connreq->service_id);
> - return -ETIMEDOUT;
> + ret = -ETIMEDOUT;
> + goto err;
> }
>
> *conn_rsp_epid = target->conn_rsp_epid;
> + kfree_skb(skb);
> return 0;
> err:
> kfree_skb(skb);
The allocated skb should be freed in the TX completion hander,
ath9k_htc_txcompletion_cb() - doing it in htc_connect_service() is wrong, I think.
Sujith
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2013-01-02 4:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-02 3:49 [PATCH] ath9k_htc: Fix skb leaks Larry Finger
[not found] ` <1357098567-8558-1-git-send-email-Larry.Finger-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
2013-01-02 4:30 ` Sujith Manoharan [this message]
2013-01-02 4:57 ` Larry Finger
2013-01-02 5:26 ` Sujith Manoharan
2013-01-08 16:09 ` Larry Finger
2013-01-09 8:19 ` Sujith Manoharan
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:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20707.47067.474241.813195@gargle.gargle.HOWL \
--to=sujith-tprpbcbo+rzafugrpc6u6w@public.gmane.org \
--cc=Larry.Finger-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org \
--cc=ath9k-devel-xDcbHBWguxHbcTqmT+pZeQ@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linville-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org \
--cc=mcgrof-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org \
--cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=senthilb-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org \
--cc=stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=vthiagar-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* 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