linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* problem with a specific ACTION=="remove" udev rule
@ 2006-11-14 13:35 Ludovic Rousseau
  2006-11-14 15:33 ` Kay Sievers
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: Ludovic Rousseau @ 2006-11-14 13:35 UTC (permalink / raw)
  To: linux-hotplug

Hello,

I use udev to run a program when a USB device is connected or removed.
The USB device is a CCID smart card reader [1] and the program is a
smart card resource manager. I use udev to dynamically add and remove
smart card reader to/from the smart card resource manager.

My rules file is:
ACTION="remove", RUN+="/usr/sbin/pcscd --hotplug"

BUS="usb", SYSFS{bInterfaceClass}="0b", ACTION="add",
RUN+="/usr/sbin/pcscd --hotplug"

I do not need any kernel driver to use the device. Everything is in user space.

I would like to also specify SYSFS{bInterfaceClass}="0b" (specific to
CCID smart card readers) for the remove action but that does not work.
The rule is then not executed. Of course, if I do not use
SYSFS{bInterfaceClass}="0b" the rule is executed every time a USB
device is removed, even if it is not a smart card reader.

Why can't I specify the SYSFS{bInterfaceClass} = "0b" in a remove rule?

Am I doing something wrong?

I use udev 079-0ubuntu34 on a Ubuntu Dapper system (Linux 2.6.15-23-686).
I also tried with a more recent udev version, version 100 on Debian
testing, with Linux 2.6.18 but with the same results.

Thanks,

[1] http://pcsclite.alioth.debian.org/ccid.html

-- 
  Dr. Ludovic Rousseau

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid\x120709&bid&3057&dat\x121642
_______________________________________________
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] 10+ messages in thread

end of thread, other threads:[~2006-11-20 16:03 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-14 13:35 problem with a specific ACTION=="remove" udev rule Ludovic Rousseau
2006-11-14 15:33 ` Kay Sievers
2006-11-14 16:00 ` Ludovic Rousseau
2006-11-14 16:04 ` Andreas Jellinghaus
2006-11-14 18:13 ` Andrey Borzenkov
2006-11-15  9:06 ` Ludovic Rousseau
2006-11-15 19:14 ` Andrey Borzenkov
2006-11-15 20:33 ` Ludovic Rousseau
2006-11-16  3:49 ` Andrey Borzenkov
2006-11-20 16:03 ` Ludovic Rousseau

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