From: "Kay Sievers" Date: Sun, 08 Apr 2007 19:37:11 +0000 Subject: Re: My udev rule doesn't work Message-Id: <3ae72650704081237t65a9facejc9c2408937fb06fd@mail.gmail.com> List-Id: References: <200704071544.36669.mb@bu3sch.de> In-Reply-To: <200704071544.36669.mb@bu3sch.de> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: linux-hotplug@vger.kernel.org On 4/7/07, Michael Buesch wrote: > I have the following rule: > > mb@powermac:/etc/udev/rules.d$ cat 01-deathadder.rules > # Configure the Razer DeathAdder mouse > ACTION=3D"add", SUBSYSTEM=3D"usb_device", SYSFS{idVendor}=3D"1532", SYSFS= {idProduct}=3D"0007", RUN+=3D"deathaddercfg -C" > > It's for autoconfiguration of the mouse when it's hotplugged. > But somehow this doesn't work. It seems like > the program is not called. > Does someone have an idea what could cause this? > > mb@powermac:~$ udevtest /class/usb_device/usbdev1.8/ > main: looking at device '/class/usb_device/usbdev1.8' from subsystem 'usb= _device' > run_program: 'usb_device_name --export usbdev1.8' > run_program: '/lib/udev/usb_device_name' (stdout) 'USB_BUS=001' > run_program: '/lib/udev/usb_device_name' (stdout) 'USB_DEV=008' > run_program: '/lib/udev/usb_device_name' returned with status 0 > udev_rules_get_name: rule applied, 'usbdev1.8' becomes 'bus/usb/001/008' > udev_device_event: device '/class/usb_device/usbdev1.8' already known, re= move possible symlinks > udev_node_add: creating device node '/dev/bus/usb/001/008', major =3D '18= 9', minor =3D '7', mode =3D '0664', uid =3D '0', gid =3D '0' > main: run: 'deathaddercfg -C' > main: run: 'socket:/org/freedesktop/hal/udev_event' > main: run: 'socket:/org/kernel/udev/monitor' Hmm, udevtest is working fine, I fear that this is another indication, that some USB-attributes are not readable at event time. We've seen something similar with a new process scheduler recently. If you add: ACTION=3D"add", SUBSYSTEM=3D"usb_device", PROGRAM=3D"/bin/sleep 1" before your rule, does it work? Kay ------------------------------------------------------------------------- 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=3Djoin.php&p=3Dsourceforge&CID=DEVD= EV _______________________________________________ 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