Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Nov 2005 17:43:46 +0100
From:      "Petr Holub" <hopet@ics.muni.cz>
To:        <stable@freebsd.org>
Subject:   usbd.conf
Message-ID:  <007601c5e615$eb7f0900$2603fb93@KLOBOUCEK>

next in thread | raw e-mail | index | archive | help
Hi,

I've found that usbd on 6.0-RELEASE doesn't react on detach event properly:

usbd.conf:

device "iKey 3000 Series Token"
    vendor  0x04b9
    product 0x1300
    detach "/usr/local/etc/rc.d/openct.sh stop"
    attach "/usr/local/etc/rc.d/openct.sh start"


what happens (usbd -d -vvvv):

usbd: opened /dev/usb0
usbd: opened /dev/usb1
usbd: opened /dev/usb2
usbd: opened /dev/usb3
usbd: reading configuration file /etc/usbd.conf
usbd: action 1: ActiveWire board, firmware download
  vndr=0x0854 prdct=0x0100 rlse=0x0000
  attach='/usr/local/bin/ezdownload -f
/usr/local/share/usb/firmware/0854.0100.0_01.hex ${DEVNAME}'
usbd: action 2: Entrega Serial with UART
  vndr=0x1645 prdct=0x8001 rlse=0x0101
  attach='/usr/sbin/ezdownload -v -f /usr/share/usb/firmware/1645.8001.0101
/dev/${DEVNAME}'
usbd: action 3: Handspring Visor
  vndr=0x082d prdct=0x0100 rlse=0x0100
  devname: ugen[0-9]+
  attach='/usr/local/bin/coldsync -md -p /dev/${DEVNAME} -t usb'
usbd: action 4: iKey 3000 Series Token
  vndr=0x04b9 prdct=0x1300
  attach='/usr/local/etc/rc.d/openct.sh start'
  detach='/usr/local/etc/rc.d/openct.sh stop'
usbd: action 5: USB device
usbd: 5 actions
usbd: opened /dev/usb
usbd: processing event queue on /dev/usb
usbd: device-attach event at 1131639766.674323000, iKey 3000 Series Token,
vendor 0x04b9:
  vndr=0x04b9 prdct=0x1300 rlse=0x0100 clss=0x00ff subclss=0x0000 prtcl=0x0000
  device names: ugen0
  === match attempt: ugen0
usbd: Found action 'iKey 3000 Series Token' for iKey 3000 Series Token, vendor
0x04b9 at ugen0
usbd: action 0: iKey 3000 Series Token
  vndr=0x04b9 prdct=0x1300
  attach='/usr/local/etc/rc.d/openct.sh start'
  detach='/usr/local/etc/rc.d/openct.sh stop'
usbd: Setting DEVNAME='ugen0'
usbd: Executing '/usr/local/etc/rc.d/openct.sh start'
Starting smart card terminal framework: OpenCTDebug: ifd_scan_usb: BSD:
ifd_scan_usb
Debug: ifd_scan_usb: BSD: ifd_scan_usb: ifd_driver_for(vendor
0x04b9[0x04b9].iKey 3000 Series Token[0x1300)
Debug: ifd_spawn_handler: driver=ikey3k, device=/dev/ugen0, index=-1
usbd: '/usr/local/etc/rc.d/openct.sh start' is ok
usbd: processing event queue on /dev/usb
usbd: device-detach event at 1131639769.712468000, product 0x1300, vendor
0x04b9:
  vndr=0x04b9 prdct=0x1300 rlse=0x0100 clss=0x00ff subclss=0x0000 prtcl=0x0000


So attach event works correctly, but even though detach is noted by
usbd, it doesn't launch the action. Any hint before diving into
sources and ktracing?

Thanks,
Petr

================================================================
                            Petr Holub
CESNET z.s.p.o.                       Supercomputing Center Brno
Zikova 4                             Institute of Compt. Science
162 00 Praha 6, CZ                            Masaryk University
Czech Republic                     Botanicka 68a, 60200 Brno, CZ
e-mail: Petr.Holub@cesnet.cz               phone: +420-549493944
                                             fax: +420-541212747
                                       e-mail: hopet@ics.muni.cz






Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?007601c5e615$eb7f0900$2603fb93>