public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Hillf Danton <hdanton@sina.com>
To: syzbot <syzbot+6cf5652d3df49fae2e3f@syzkaller.appspotmail.com>
Cc: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [pm?] KASAN: use-after-free Read in netdev_unregister_kobject
Date: Wed, 24 Apr 2024 05:31:31 +0800	[thread overview]
Message-ID: <20240423213131.3040-1-hdanton@sina.com> (raw)
In-Reply-To: <000000000000afab690616b12f99@google.com>

On Mon, 22 Apr 2024 08:35:25 -0700
> syzbot found the following issue on:
> 
> HEAD commit:    3cdb45594619 Merge tag 's390-6.9-4' of git://git.kernel.or..
> git tree:       upstream
> C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=144067cb180000

#syz test https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git  3cdb45594619

--- x/net/bluetooth/bnep/core.c
+++ y/net/bluetooth/bnep/core.c
@@ -540,16 +540,6 @@ static int bnep_session(void *arg)
 	return 0;
 }
 
-static struct device *bnep_get_device(struct bnep_session *session)
-{
-	struct l2cap_conn *conn = l2cap_pi(session->sock->sk)->chan->conn;
-
-	if (!conn || !conn->hcon)
-		return NULL;
-
-	return &conn->hcon->dev;
-}
-
 static const struct device_type bnep_type = {
 	.name	= "bluetooth",
 };
@@ -618,7 +608,6 @@ int bnep_add_connection(struct bnep_conn
 	bnep_set_default_proto_filter(s);
 #endif
 
-	SET_NETDEV_DEV(dev, bnep_get_device(s));
 	SET_NETDEV_DEVTYPE(dev, &bnep_type);
 
 	err = register_netdev(dev);
--

  parent reply	other threads:[~2024-04-23 21:31 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-22 15:35 [syzbot] [pm?] KASAN: use-after-free Read in netdev_unregister_kobject syzbot
2024-04-22 23:16 ` Hillf Danton
2024-04-23  3:12   ` syzbot
2024-04-23 10:42 ` Hillf Danton
2024-04-23 13:25   ` syzbot
2024-04-23 21:31 ` Hillf Danton [this message]
2024-04-23 22:06   ` syzbot
2024-10-24 14:13 ` [syzbot] " syzbot
2024-10-24 14:14 ` syzbot
2024-11-01 11:57 ` syzbot
2024-11-01 11:59 ` syzbot
2024-11-01 15:01 ` [syzbot] Re: [PATCH v2] Bluetooth: fix use-after-free in device_for_each_child() syzbot
2024-11-01 19:30 ` syzbot
     [not found] <411d4343-0a1f-4629-9c81-56f7c2e363da@yandex.ru>
2024-10-24 18:30 ` [syzbot] [pm?] KASAN: use-after-free Read in netdev_unregister_kobject syzbot
     [not found] <17634403-3bc8-41c8-80a9-1cc10041b1ce@yandex.ru>
2024-10-24 18:30 ` syzbot
     [not found] <20241101115715.e3eQ9%dmantipov@yandex.ru>
2024-11-01 12:23 ` syzbot
     [not found] <20241101115926.vYGxC%dmantipov@yandex.ru>
2024-11-01 12:52 ` syzbot
     [not found] <CABBYNZK=H9JtzaQudQ1b7TGU5VaJ_qX_bbSJhKSwWKh+5_1uUQ@mail.gmail.com>
2024-11-01 16:57 ` syzbot
     [not found] <CABBYNZK3cVQ1nZbRDW2-VRTwOsJOW7hoRQEV26Qeh2juDjnMvA@mail.gmail.com>
2024-11-01 19:54 ` syzbot

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=20240423213131.3040-1-hdanton@sina.com \
    --to=hdanton@sina.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzbot+6cf5652d3df49fae2e3f@syzkaller.appspotmail.com \
    --cc=syzkaller-bugs@googlegroups.com \
    /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