2010/9/13 Kay Sievers <kay.sievers@xxxxxxxx>: > On Fri, Sep 10, 2010 at 17:14, Ludovic Rousseau > <ludovic.rousseau@xxxxxxxxx> wrote: >> 2010/9/9 Kay Sievers <kay.sievers@xxxxxxxx>: > >>> Udev parses the usb descriptors and makes them available in a >>> property. That's the only way to access usb_interface properties from >>> the usb_device event. >>> >>> Something like: >>> SUBSYSTEM=="usb", ENV{ID_USB_INTERFACES}="*:0b0000:*", GROUP= ... >>> should do it. >> >> It works but is not what I need. >> - Why do you use = instead of == for ENV{ID_USB_INTERFACES}? I want to >> check the value of ID_USB_INTERFACES, not set it. >> - Why use "*" in "*:0b0000:*"? >> >> Instead I used a == >> SUBSYSTEM=="usb", ENV{ID_USB_INTERFACES}=="*:0b0000:*", GROUP="pcscd" >> or >> SUBSYSTEM=="usb", ENV{ID_USB_INTERFACES}==":0b0000:", GROUP="pcscd" >> But it does not work :-( > > Sure, it should be ==. Make sure that your rule file sorts after > 50-udev-default-rules, which calls usb_id, and sets this property. My 50-udev-default-rules files does not use usb_id (file attached). But other files in /lib/udev/rules.d/ do. The first one is 60-persistent-alsa.rules I renamed my rule file from 50_pcscd_ccid.rules to 51_pcscd_ccid.rules to be sorted after 50-udev-default-rules but the rule still do not work. I can see the "ID_USB_INTERFACES=:0b0000:" line in "udevadm monitor --env --kernel udev" output but that is for an interface, not for the device itself. Maybe that is because my 50-udev-default-rules file is not using usb_id? What is the use of GROUP="" supposed to do on an interface? Is it possible to propagate the group change on the parent device node? Thanks -- Dr. Ludovic Rousseau
Attachment:
50-udev-default.rules
Description: Binary data