linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Ozan Çağlayan" <ozan@pardus.org.tr>
To: linux-hotplug@vger.kernel.org
Subject: Weird race-like problem in udev
Date: Mon, 21 Jun 2010 16:47:28 +0000	[thread overview]
Message-ID: <4C1F97A0.2040905@pardus.org.tr> (raw)

Hi,

I have a bug report from a user which complains about udev not correctly hotplugging the devices. The symptoms are quite racy and random:

* When he starts the OS and plugs a USB device, udev doesn't load the necessary kernel driver,
* He then unplugs/plugs it several times:
  * Sometimes it starts to work correctly, the module gets inserted
  * Sometimes it still doesn't modprobe the module
* He discovered that spawning a 2nd udevd by hand resolves the issue

I suggested him to set the udevd log level to "debug" and we've found out that setting the log level through udevadm control heals the issue as well. So I proposed to edit the udev.conf and set the log level there and reboot. Upon reboot, after a cycle of 2-3 failed plug/unplug attempt, the problem seems fixed/disappeared too.

I grabbed full syslog with udevd running log-priorityfibug, took a look and found out that the events are correctly dispatched to the worker threads but the modprobe is called on a very late plug/unplug attempt.

Here's the full log:
  http://bugs.pardus.org.tr/attachment.cgi?idT50

* The device is first plugged @ 16:50:54 (VENDOR=_USB_MF_)
* worker[541] being able to spawn modprobe is @ 16:53:21
* Between those timestamps you can see several "seq xxxx queued 'add' 'usb' which doesn't lead to a modprobe.

udev version is 146. I know that it's a little bit outdated but I'd be glad if you can help me debugging the issue. Any commit id from the git tree that is known to fix the issue is also very appreciated.

Thanks,
Ozan Caglayan
--

http://www.pardus.org.tr/eng
--
To unsubscribe from this list: send the line "unsubscribe linux-hotplug" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

             reply	other threads:[~2010-06-21 16:47 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-21 16:47 Ozan Çağlayan [this message]
2010-06-22 11:31 ` Weird race-like problem in udev Kay Sievers
2010-06-22 12:06 ` Ozan Çağlayan
2010-06-22 13:40 ` Kay Sievers

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=4C1F97A0.2040905@pardus.org.tr \
    --to=ozan@pardus.org.tr \
    --cc=linux-hotplug@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).