public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Hillf Danton <hdanton@sina.com>
To: syzbot <syzbot+827272712bd6d12c79a4@syzkaller.appspotmail.com>
Cc: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [net?] KASAN: slab-use-after-free Read in handle_tx (2)
Date: Sat, 18 Jan 2025 19:05:54 +0800	[thread overview]
Message-ID: <20250118110555.1978-1-hdanton@sina.com> (raw)
In-Reply-To: <678a8f3d.050a0220.303755.000f.GAE@google.com>

On Fri, 17 Jan 2025 09:11:25 -0800
> syzbot has found a reproducer for the following issue on:
> 
> HEAD commit:    9bffa1ad25b8 Merge tag 'drm-fixes-2025-01-17' of https://g..
> git tree:       upstream
> C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=17d6c2b0580000

#syz test

--- x/drivers/net/caif/caif_serial.c
+++ y/drivers/net/caif/caif_serial.c
@@ -304,11 +304,14 @@ static void ser_release(struct work_stru
 	spin_unlock(&ser_lock);
 
 	if (!list_empty(&list)) {
+		struct tty_struct *tty;
 		rtnl_lock();
 		list_for_each_entry_safe(ser, tmp, &list, node) {
+			tty = ser->tty;
 			dev_close(ser->dev);
 			unregister_netdevice(ser->dev);
 			debugfs_deinit(ser);
+			tty_kref_put(tty);
 		}
 		rtnl_unlock();
 	}
@@ -369,8 +372,6 @@ static void ldisc_close(struct tty_struc
 {
 	struct ser_device *ser = tty->disc_data;
 
-	tty_kref_put(ser->tty);
-
 	spin_lock(&ser_lock);
 	list_move(&ser->node, &ser_release_list);
 	spin_unlock(&ser_lock);
--

  reply	other threads:[~2025-01-18 11:06 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-21 10:58 [syzbot] [net?] KASAN: slab-use-after-free Read in handle_tx (2) syzbot
2024-02-21 11:05 ` Eric Dumazet
2025-01-14  1:26 ` syzbot
2025-01-17 17:11 ` syzbot
2025-01-18 11:05   ` Hillf Danton [this message]
2025-01-18 11:21     ` syzbot
2025-11-06 14:36 ` Forwarded: " syzbot
2025-11-06 15:08 ` Forwarded: KASAN: slab-use-after-free Read in handle_tx (2) Inbox syzbot
     [not found] <CAPrAcgMMMYxF=Cw+rwEHuPJJ=4bCyukCh8ptS9M4iQTbWEd+yw@mail.gmail.com>
2025-11-06 14:50 ` [syzbot] [net?] KASAN: slab-use-after-free Read in handle_tx (2) syzbot
     [not found] <CAPrAcgOWmK1FLk8r0LszmPO3ysPi4G+EJw=YcSg3o6Ozy1wGbw@mail.gmail.com>
2025-11-06 15:28 ` 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=20250118110555.1978-1-hdanton@sina.com \
    --to=hdanton@sina.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzbot+827272712bd6d12c79a4@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