From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Anthony L. Awtrey" Date: Wed, 26 Dec 2007 22:12:19 +0000 Subject: udev no longer passes USB device remove events Message-Id: <4772D1C3.3070309@awtrey.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org Hello the list, I've got a puzzler that I hope someone can help me with. When I upgraded from Debian Etch to the Debian Lenny pre-release, I noticed that a simple system tray app to indicate when a device was plugged into my various USB ports stopped working. It would light up, but never go off. I dug around and finally discovered that udev-114 no longer passed the 'remove' 'usb' events that udev-105 did without fail. I filed some additional details with the Debian BTS: http://bugs.debian.org/cgi-bin/bugreport.cgi?bugE7616 Note that 'udevmonitor --kernel' shows the remove event coming in, but that 'udevmonitor --udev' never shows the remove event being passed. I also dialed up the logging and traced an insertion and removal of a USB drive. The interesting bit is in the removal section: Dec 23 22:15:13 dhcp-141 udevd[2199]: udev_event_run: seq 2614 forked, pid [11386], 'remove' 'usb', 0 seconds old Dec 23 22:15:13 dhcp-141 udevd-event[11386]: udev_db_get_device: found a symlink as db file Dec 23 22:15:13 dhcp-141 udevd-event[11386]: name_index: removing index: ... 8< long dev name >8 ... Dec 23 22:15:13 dhcp-141 udevd-event[11386]: udev_event_run: seq 2614 finished with -1 Dec 23 22:15:13 dhcp-141 udevd[2199]: udev_done: seq 2614, pid [11386] exit with 1, 0 seconds old It looks, to my uneducated eye, that the udevd-event function fails. Note that this is the only time that particular function fails in all the activity associated with inserting and removing the USB device. I tried out the latest udev-118 to see if it still has this issue and found that about 1 in 4 times I inserted/removed the device I would get a remove event, but the other times it would fail like it does under udev-114. I noted that the few times it worked, the event happened to complete last (e.g. there were no other events processed after it) and every time it failed there were some additional remove events still processing, particularly 'remove' 'block' events. I found that udev-105 worked very reliably when I tried it with Lenny. Could this be some kind of timing issue? Does anyone with familiarity with the code see something that could help me? Thanks in advance. Tony ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel