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

Re: udev and Logitech mouse applet

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

As kcontrol does not use lmctl, I tried lines like:

SYSFS{idProduct}=="c025", SYSFS{idVendor}=="046d", 

The logitechmouse script changes the ownership and permissions of the 
relevant usbfs entry. I puzzled over why this did not work on bootup, but 
worked fine when hotplugged later. The wait loop fixed it. A rule like:

SYSFS{idProduct}=="0039", SYSFS{idVendor}=="045e", MODE="660", 

...changes the permissions of /dev/input/ nodes instead of usbfs entries, 
which isn't very helpful in this case.

> > I worked around the issue by borrowing an idea from libsane, namely
> > adding a loop that checks for the existence of the /proc/bus/usb entry
> > before making
> You should have asked for help instead of adding this crap to your
> package. :-(

Do you have another suggestion?

> > This problem also breaks coldplugging for cameras operated through
> > libgphoto, possibly scanners and libsane (#334068), and likely other
> I had no time to investigate this bug yet, but it's supposed to work
> fine.

I hope it does turn out to work.

Christopher Martin

Reply to: