linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* udev or kernel broken with rsdl 0.30 patch [u]
@ 2007-03-15 10:46 Andreas Jellinghaus [c]
  2007-03-15 15:22 ` Kay Sievers
                   ` (17 more replies)
  0 siblings, 18 replies; 19+ messages in thread
From: Andreas Jellinghaus [c] @ 2007-03-15 10:46 UTC (permalink / raw)
  To: linux-hotplug

the rsdl patch only changes the scheduler, so I really wonder
why udev/kernel emit less events when the kernel is patched
with it. maybe a race condition or other bug in this area
only exposed by the rsdl 0.30 patch?

here is my analysis so far:
udev events on 2.6.20.2 (without rsdl):
( "$ACTION - $DEVICE - $DEVNAME - $PRODUCT - $$ - $PPID")
add - /proc/bus/usb/002/016 -  - 8e6/3438/100 - 6071 - 6065
add -  - /dev/usbdev2.16_ep02 -  - 6116 - 6113
add -  - /dev/usbdev2.16_ep82 -  - 6118 - 6114
add -  - /dev/usbdev2.16_ep81 -  - 6120 - 6115

udev events on 2.6.20.2 (with rsdl): 
( "$ACTION - $DEVICE - $DEVNAME - $PRODUCT - $$ - $PPID")
add -  - /dev/usbdev2.8_ep02 -  - 5287 - 5286
add -  - /dev/usbdev2.8_ep82 -  - 5290 - 5288
add -  - /dev/usbdev2.8_ep81 -  - 5291 - 5289

the /proc event is missing. in both cases /proc/ was mounted.

syslog with udev on debugging (only the /proc event from the kernel w/o
rsdl):

Mar 15 11:19:06 localhost udevd[2622]: udev_event_run: seq 2869 forked, pid
[6065], 'add' 'usb', 0 seconds old
Mar 15 11:19:06 localhost udevd-event[6065]: wait_for_sysfs:
file '/sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.5/2-1.5:1.0/bus'
appeared after 0 loops
Mar 15 11:19:06 localhost udevd-event[6065]:
run_program: '/lib/udev/openct_usb'
Mar 15 11:19:07 localhost udevd-event[6065]:
run_program: '/lib/udev/openct_usb' returned with status 0
Mar 15 11:19:07 localhost udevd-event[6065]: pass_env_to_socket: passed 338
bytes to socket '/org/freedesktop/hal/udev_event', 
Mar 15 11:19:07 localhost udevd-event[6065]: run_program: '/sbin/modprobe -Q
usb:v08E6p3438d0100dc00dsc00dp00ic0Bisc00ip00'
Mar 15 11:19:07 localhost udevd-event[6065]: run_program: '/sbin/modprobe'
returned with status 1
Mar 15 11:19:07 localhost udevd-event[6065]: pass_env_to_socket: passed -1
bytes to socket '/org/kernel/udev/monitor', 
Mar 15 11:19:07 localhost udevd-event[6065]: udev_event_run: seq 2869
finished
Mar 15 11:19:07 localhost udevd[2622]: udev_done: seq 2869, pid [6065] exit
with 1, 1 seconds old

there is something similar in syslog (on the rsdl kernel):
Mar 15 11:24:32 localhost udevd[2607]: udev_event_run: seq 2717 forked, pid
[5284], 'add' 'usb', 0 seconds old
Mar 15 11:24:32 localhost udevd-event[5284]: wait_for_sysfs:
file '/sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.5/2-1.5:1.0/bus'
appeared after 0 loops
Mar 15 11:24:32 localhost udevd-event[5284]: pass_env_to_socket: passed 338
bytes to socket '/org/freedesktop/hal/udev_event', 
Mar 15 11:24:32 localhost udevd-event[5284]: run_program: '/sbin/modprobe -Q
usb:v08E6p3438d0100dc00dsc00dp00ic0Bisc00ip00'
Mar 15 11:24:32 localhost udevd-event[5284]: run_program: '/sbin/modprobe'
returned with status 1
Mar 15 11:24:32 localhost udevd-event[5284]: pass_env_to_socket: passed -1
bytes to socket '/org/kernel/udev/monitor', 
Mar 15 11:24:32 localhost udevd-event[5284]: udev_event_run: seq 2717
finished
Mar 15 11:24:32 localhost udevd[2607]: udev_done: seq 2717, pid [5284] exit
with 1, 0 seconds old

the machine and the usb device are 100% the same, except that the first
kernel is 2.6.20.2 plain and the second was patched with rsdl 0.30.
the machine is a thinkpad t40 running ubuntu edgy (093-0ubuntu18.0edgy2).
the config was unchanged. the hardware is a usb smart card reader.

also maybe someone knows: what happened to the /dev/bus/usb events?
for a while I got two events from udev (guess that was dapper / much
older kernel and udev) and thus spawned two processed - one for handling
the device file in /proc/bus/usb and one for the device file
in /dev/bus/usb. now I see I'm no longer getting events for /dev/bus/usb/
at all. why that? so if /proc/bus/usb/ is no longer mounted, my application
will fail?

the udev config is quite simple:

BUS!="usb", ACTION!="add", GOTO="openct_usb_rules_end"

..
SYSFS{bInterfaceClass}="0b", SYSFS{bInterfaceSubClass}="00",
SYSFS{bInterfaceProtocol}="00" RUN+="/lib/udev/openct_usb"
..

LABEL="openct_usb_rules_end"

.. (pcmcia stuff)

Thanks for your help.

Regards, Andreas


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CIDÞVDEV
_______________________________________________
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

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2007-03-16 15:39 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-15 10:46 udev or kernel broken with rsdl 0.30 patch [u] Andreas Jellinghaus [c]
2007-03-15 15:22 ` Kay Sievers
2007-03-15 17:03 ` udev or kernel broken with rsdl 0.30 patch Andreas Jellinghaus
2007-03-15 19:57 ` Kay Sievers
2007-03-16 10:06 ` Andreas Jellinghaus
2007-03-16 10:35 ` Kay Sievers
2007-03-16 10:59 ` Andreas Jellinghaus
2007-03-16 11:34 ` Kay Sievers
2007-03-16 11:45 ` Andreas Jellinghaus
2007-03-16 12:08 ` Kay Sievers
2007-03-16 12:32 ` Andreas Jellinghaus
2007-03-16 12:48 ` Kay Sievers
2007-03-16 13:35 ` Andreas Jellinghaus
2007-03-16 13:38 ` Andreas Jellinghaus
2007-03-16 13:58 ` Kay Sievers
2007-03-16 14:39 ` Andreas Jellinghaus
2007-03-16 14:59 ` Kay Sievers
2007-03-16 15:20 ` Andreas Jellinghaus
2007-03-16 15:39 ` Kay Sievers

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).