From: syzbot <syzbot+1e3edf922962b5ea40a4@syzkaller.appspotmail.com>
To: ipravdin.official@gmail.com
Cc: ipravdin.official@gmail.com, linux-kernel@vger.kernel.org,
linux-usb@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [usb?] KASAN: slab-use-after-free Read in raw_event_queue_add
Date: Thu, 05 Jun 2025 22:16:17 -0700 [thread overview]
Message-ID: <684279a1.050a0220.2461cf.0038.GAE@google.com> (raw)
In-Reply-To: <4a7f4d21-8b1c-4616-82bb-210395215035@gmail.com>
> #syz test
This crash does not have a reproducer. I cannot test it.
>
> diff --git a/drivers/usb/gadget/legacy/raw_gadget.c b/drivers/usb/gadget/legacy/raw_gadget.c
> index 20165e1582d9..d7fca01afbf1 100644
> --- a/drivers/usb/gadget/legacy/raw_gadget.c
> +++ b/drivers/usb/gadget/legacy/raw_gadget.c
> @@ -120,9 +120,13 @@ static struct usb_raw_event *raw_event_queue_fetch(
> static void raw_event_queue_destroy(struct raw_event_queue *queue)
> {
> int i;
> + unsigned long flags;
>
> + spin_lock_irqsave(&queue->lock, flags);
> for (i = 0; i < queue->size; i++)
> kfree(queue->events[i]);
> + spin_unlock_irqrestore(&queue->lock, flags);
> +
> queue->size = 0;
> }
>
> Ivan Pravdin
>
prev parent reply other threads:[~2025-06-06 5:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-03 11:09 [syzbot] [usb?] KASAN: slab-use-after-free Read in raw_event_queue_add syzbot
2025-06-06 5:16 ` Ivan Pravdin
2025-06-06 5:16 ` syzbot [this message]
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=684279a1.050a0220.2461cf.0038.GAE@google.com \
--to=syzbot+1e3edf922962b5ea40a4@syzkaller.appspotmail.com \
--cc=ipravdin.official@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--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