Bug 105276 - Stale files in /etc/hotplug/usb
Summary: Stale files in /etc/hotplug/usb
Status: RESOLVED FIXED
Alias: None
Product: SUSE LINUX 10.0
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: Beta 2
Hardware: Other All
: P5 - None : Normal
Target Milestone: ---
Assignee: Stefan Fent
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-17 17:29 UTC by Christian Zoz
Modified: 2005-09-05 14:41 UTC (History)
2 users (show)

See Also:
Found By: Development
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Zoz 2005-08-17 17:29:19 UTC
Hi all,

there are stale files in /etc/hotplug/usb:
/etc/hotplug/usb/kino-jogshuttle:    kino-0.7.6-3                   sf
/etc/hotplug/usb/openct:             openct-0.6.5-2                 okir
/etc/hotplug/usb/tascam_fpga:        alsa-tools-1.0.9-4             tiwai
/etc/hotplug/usb/tascam_fw:          alsa-tools-1.0.9-4             tiwai
/etc/hotplug/usb/tascam_fw.usermap:  alsa-tools-1.0.9-4             tiwai
/etc/hotplug/usb/usb.usermap:        kino-0.7.6-3                   sf
/etc/hotplug/usb/usbcam.usermap:     libgphoto2-2.1.99.head.0-8     meissner

I guess all these files are obsolete. At least the *usermaps are not used any
longer, because usb.agent has gone. What abot the rest?
If you use a script for another purpose, please move it somewhere else.

Tell me if it is (or has to be) called via udev. But even in this case we should
move it to /sbin.
Comment 1 Marcus Meissner 2005-08-18 07:46:12 UTC
libbgphoto2 now has a HAL FDI map which is used by resmgr. IU removed the 
files from libgphoto2 
Comment 2 Olaf Kirch 2005-08-18 09:47:10 UTC
In order for openct to handle any USB tokens and card readers, someone 
needs to start an openct driver process for each device detected. 
Comment 3 Christian Zoz 2005-08-18 10:56:34 UTC
Then you have to start openct via udev or hal. A file lying around in
/etc/hotplug/usb/ has no effect.
Comment 4 Olaf Kirch 2005-08-18 11:55:41 UTC
I guessed so :) 
Can you give me a clue how to do this? When a USB token is detected, 
we need to run openct-control attach $DEVICE usb:$PRODUCT 
Comment 5 Christian Zoz 2005-08-18 12:51:29 UTC
Since openct-control lies in /usr you cannot go for udev. Via udev the event
_may_ be triggered before boot.localfs and more probably before nfs.
So you want to be called from hal and Timo will be very happy to tell you how. ;)
Comment 6 Christian Zoz 2005-08-18 12:53:17 UTC
Timo, please help.
Comment 7 Timo Hoenig 2005-08-18 13:06:00 UTC
We could hald let do the callout for openct-control.

It *should* be it's as easy as writing an fdi file. Have a look at the example fdi files in /usr/share/hal/
fdi/policy (e.g. 10osvendor/90-block-subfs.fdi). Let me know if you need help.
Comment 8 Olaf Kirch 2005-08-25 10:56:50 UTC
I'm new to hal. should the following information file work? 
 
<?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- --> 
 
<deviceinfo version="0.2"> 
  <device> 
    <match key="info.bus" string="usb_device"> 
      <!-- egate --> 
      <match key="usb_device.vendor_id" int="0x0973"> 
        <match key="usb_device.product_id" int="0x0001"> 
          <merge key="info.category" type="string">smart_card</merge> 
          <append key="info.addons" type="strlist">hald-addon-openct</append> 
        </match> 
      </match> 
    </match> 
  </device> 
</deviceinfo> 
 
And a hald-add-openct script that just invokes openct-control with the 
appropriate parameters. 
 
Is this how it's supposed to work? 
Comment 9 Olaf Kirch 2005-08-25 11:19:09 UTC
I've submitted an updated openct package with the above change, which 
seems to work. 
Comment 10 Timo Hoenig 2005-08-25 11:59:58 UTC
(In reply to comment #8)

[...]

> Is this how it's supposed to work? 

Looks good to me.
Comment 11 Takashi Iwai 2005-08-30 14:04:22 UTC
The files in alsa-tools were already removed...
Comment 12 Christian Zoz 2005-08-31 10:26:55 UTC
So kino is the only remainig part.
Comment 13 Stefan Fent 2005-09-05 14:41:55 UTC
Kino is fixed and submitted, Hannes will do the hal part