mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Edward Adam Davis <eadavis@qq.com>
To: syzbot+8ed98cbd0161632bce95@syzkaller.appspotmail.com
Cc: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [can?] general protection fault in can_rx_unregister (2)
Date: Mon, 25 May 2026 11:35:50 +0800	[thread overview]
Message-ID: <tencent_E820E80EECC6CDFC793A6DA02D696CD8940A@qq.com> (raw)
In-Reply-To: <6a124882.050a0220.30ba69.0009.GAE@google.com>

#syz test

diff --git a/net/can/af_can.c b/net/can/af_can.c
index 7bc86b176b4d..c9a79e087ed3 100644
--- a/net/can/af_can.c
+++ b/net/can/af_can.c
@@ -528,6 +528,8 @@ void can_rx_unregister(struct net *net, struct net_device *dev, canid_t can_id,
 	spin_lock_bh(&net->can.rcvlists_lock);
 
 	dev_rcv_lists = can_dev_rcv_lists_find(net, dev);
+	if (!dev_rcv_lists)
+		goto out;
 	rcv_list = can_rcv_list_find(&can_id, &mask, dev_rcv_lists);
 
 	/* Search the receiver list for the item to delete.  This should


  reply	other threads:[~2026-05-25  3:36 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-24  0:38 syzbot
2026-05-25  3:35 ` Edward Adam Davis [this message]
2026-05-25  4:32   ` syzbot
2026-05-25 11:48 ` Edward Adam Davis
2026-05-25 13:30   ` syzbot
2026-05-25 13:56 ` [PATCH] can: af_can: reject can rx unregister if dev is not can Edward Adam Davis
2026-05-25 18:15   ` Oliver Hartkopp
2026-05-25 23:46     ` Edward Adam Davis
2026-05-26 14:16       ` Oliver Hartkopp

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=tencent_E820E80EECC6CDFC793A6DA02D696CD8940A@qq.com \
    --to=eadavis@qq.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzbot+8ed98cbd0161632bce95@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

all inboxes | Powered by JetHome®