[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: udev and Logitech mouse applet

reassign 334068 libsane

On Oct 17, Christopher Martin <christopher.martin@utoronto.ca> wrote:

> On October 17, 2005 13:03, Marco d'Itri wrote:
> > > The problem seems to be that udev runs lmctl before the usbfs entry
> > > corresponding to your mouse has been created under /proc/bus/usb. The
> >
> > By design. The correct rule would be:
> >
> > BUS=="usb", SYSFS{idVendor}=="046d", SYSFS{idProduct}=="c025", \
> > 	RUN+="/usr/bin/lmctl -8 --sms"
> I doubt that switching from PROGRAM= to RUN+= will make a difference, as it 
> certainly didn't resolve the issue with kdebase. Perhaps you're not running 
OK, as it turns out I was half wrong: /proc/bus/ is not syncronous, so
scripts still need to wait (they may use the wait_for_file function from
/lib/hotplug/hotplug.functions). OTOH, RUN is still the correct keyword
to use, because PROGRAM has different semantics (and you must always use
+= unless you know better).

This looks like the same issue of #334068, which I am reassigning for
libsane (I'm sorry for not getting it right the first time).

> a modular kernel? I did notice that a homebrew everything-built-in kernel 
> did not suffer from this problem. I just took it for granted that the 
> udev/hotplug maintainer would be testing against a stock Debian kernel, or 
> at least something similarly modularized.
I need newer kernels before a debian package is available, and anyway I
will not use debian kernels again as long as they will break drivers
by removing uploadable firmwares.

> worked fine when hotplugged later. The wait loop fixed it. A rule like:
> SYSFS{idProduct}=="0039", SYSFS{idVendor}=="045e", MODE="660", 
> GROUP="plugdev"
> ...changes the permissions of /dev/input/ nodes instead of usbfs entries, 
> which isn't very helpful in this case.
Because the rule matches on many events, among them BUS=="usb".
The correct rule to change the /dev/bus/usb/ device permissions would

SUBSYSTEM=="usb_device", SYSFS{idProduct}=="0039", SYSFS{idVendor}=="045e", \

(660 is the default.)


Attachment: signature.asc
Description: Digital signature

Reply to: