LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Pengcheng Li <lipengcheng8@huawei.com>
To: <linux-kernel@vger.kernel.org>
Cc: <lipengcheng8@huawei.com>, <yaobaofeng@huawei.com>,
	<lijiangxiong@hisilicon.com>, <kongfei@hisilicon.com>
Subject: [PATCH] misc: st_core: Fix skb double free corruption
Date: Sat, 28 Apr 2018 14:07:49 +0800	[thread overview]
Message-ID: <1524895669-47953-1-git-send-email-lipengcheng8@huawei.com> (raw)

When some failures happened in hci_recv_frame() function,
skb is freed by both hci_recv_frame and st_send_frame

Signed-off-by: Li Pengcheng <lipengcheng8@huawei.com>
Signed-off-by: Yao Baofeng <yaobaofeng@huawei.com>
Signed-off-by: Li Jiangxiong <lijiangxiong@hisilicon.com>
---
 drivers/misc/ti-st/st_core.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/misc/ti-st/st_core.c b/drivers/misc/ti-st/st_core.c
index 0005159..f4ce211 100644
--- a/drivers/misc/ti-st/st_core.c
+++ b/drivers/misc/ti-st/st_core.c
@@ -124,7 +124,6 @@ static void st_send_frame(unsigned char chnl_id, struct st_data_s *st_gdata)
 			(st_gdata->list[chnl_id]->priv_data, st_gdata->rx_skb)
 			     != 0)) {
 			pr_err(" proto stack %d's ->recv failed", chnl_id);
-			kfree_skb(st_gdata->rx_skb);
 			return;
 		}
 	} else {
-- 
2.8.0

             reply	other threads:[~2018-04-28  6:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-28  6:07 Pengcheng Li [this message]
2018-05-23  2:39 Pengcheng Li
2018-05-23  3:18 ` John Stultz

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=1524895669-47953-1-git-send-email-lipengcheng8@huawei.com \
    --to=lipengcheng8@huawei.com \
    --cc=kongfei@hisilicon.com \
    --cc=lijiangxiong@hisilicon.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=yaobaofeng@huawei.com \
    --subject='Re: [PATCH] misc: st_core: Fix skb double free corruption' \
    /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

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).