From: Greg KH <gregkh@linuxfoundation.org>
To: Tao Yu <tao1.yu@intel.com>
Cc: akpm@linux-foundation.org, dakr@kernel.org,
driver-core@lists.linux.dev, linux-kernel@vger.kernel.org,
rafael@kernel.org,
syzbot+c22bb42560ec86726aba@syzkaller.appspotmail.com
Subject: Re: [PATCH] kobject: avoid blocking allocation while holding uevent_sock_mutex
Date: Wed, 26 Aug 2026 09:28:57 +0200 [thread overview]
Message-ID: <2026082640-dormitory-spore-a2b3@gregkh> (raw)
In-Reply-To: <reply-20260826-kobject-uevent-v1@intel.com>
A: http://en.wikipedia.org/wiki/Top_post
Q: Were do I find info about this thing called top-posting?
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?
A: No.
Q: Should I include quotations after my reply?
http://daringfireball.net/2007/07/on_top
On Wed, Aug 26, 2026 at 03:17:58PM +0800, Tao Yu wrote:
> Hi Greg,
>
> Thanks for the review.
>
> Nothing changed in USB enumeration itself. What syzbot appears to be
> hitting is a long-standing latency problem in the untagged uevent path,
> not a recent USB-specific regression.
>
> The blocked task is in:
>
> usb_set_configuration()
> -> device_add()
> -> kobject_uevent_env()
> -> uevent_net_broadcast_untagged()
>
> so the contention point is the global untagged-uevent broadcast path in
> lib/kobject_uevent.c.
>
> Looking at the history, the locked allocation/broadcast pattern appears
> to date back to 16dff336b33d ("kobject: add kobject_uevent_net_broadcast()").
> Because of that, I did not add a Fixes tag or cc stable in v1. I do not
> have evidence that this is a recent regression, so I would rather not
> add those tags without a stronger justification.
But if this is something that userspace can trigger, as syzbot is
showing, then it should be backported to resolve the problem for people
hitting it like yourself.
> You are also right about the race in my listener pre-check. A listener
> can appear after the first unlock, so that part of v1 is not correct.
> I will drop that approach in the next revision.
>
> I also should have included the syzbot link and testing details. The
> report is here:
> https://syzkaller.appspot.com/bug?extid=c22bb42560ec86726aba
>
> syzbot has now tested the proposed patch and reported that the
> reproducer did not trigger the issue:
> https://groups.google.com/g/syzkaller-bugs/c/q6wmyA-hG6E/m/rLDsbLC-AQAJ
>
> So the patch now has:
> Tested-by: syzbot+c22bb42560ec86726aba@syzkaller.appspotmail.com
>
> I also compile-tested it with:
> make lib/kobject_uevent.o
But that doesn't actually test things locally. Please do so on your own
machine as obviously this is a path you can validate yourself.
thanks,
greg k-hh
prev parent reply other threads:[~2026-08-26 7:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-26 6:46 [PATCH] kobject: avoid blocking allocation while holding uevent_sock_mutex Tao Yu
2026-08-26 7:01 ` Greg KH
2026-08-26 7:17 ` Tao Yu
2026-08-26 7:28 ` Greg KH [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=2026082640-dormitory-spore-a2b3@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=akpm@linux-foundation.org \
--cc=dakr@kernel.org \
--cc=driver-core@lists.linux.dev \
--cc=linux-kernel@vger.kernel.org \
--cc=rafael@kernel.org \
--cc=syzbot+c22bb42560ec86726aba@syzkaller.appspotmail.com \
--cc=tao1.yu@intel.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