From: Moshe Yudkowsky <msha5_17@bl.com>
To: linux-hotplug@vger.kernel.org
Subject: USB camera not hotplugging because SYSFS{ID_VENDOR} etc. not available
Date: Mon, 10 Apr 2006 15:16:37 +0000 [thread overview]
Message-ID: <443A76D5.60208@bl.com> (raw)
In *both* the patched version of udev that I was running, and in the new
official release of 0.089, I don't have SYSFS{ID_VENDOR} available when
the device is plugged in. This in turn means that the libgphoto2.rules
do not execute and the camera group is not set.
HOWEVER, the SYSFS variables for the MP3 player *are* available!
libgphoto2.rules:
> SYSFS{idVendor}="04a9", SYSFS{idProduct}="3051", MODE="0660", GROUP="camera"
udevmonitor --evn output for plugin of camera:
> UEVENT[1144681428.413283] add@/devices/pci0000:00/0000:00:10.0/usb1/1-1
> ACTIONd
> DEVPATH=/devices/pci0000:00/0000:00:10.0/usb1/1-1
> SUBSYSTEM=usb
> SEQNUM453
> PHYSDEVBUS=usb
> PHYSDEVDRIVER=usb
>
> UDEV [1144681428.414601] add@/devices/pci0000:00/0000:00:10.0/usb1/1-1
> UDEV_LOG=3
> ACTIONd
> DEVPATH=/devices/pci0000:00/0000:00:10.0/usb1/1-1
> SUBSYSTEM=usb
> SEQNUM453
> PHYSDEVBUS=usb
> PHYSDEVDRIVER=usb
> UDEVD_EVENT=1
>
> UEVENT[1144681428.421787] add@/devices/pci0000:00/0000:00:10.0/usb1/1-1/1-1:1.0
> ACTIONd
> DEVPATH=/devices/pci0000:00/0000:00:10.0/usb1/1-1/1-1:1.0
> SUBSYSTEM=usb
> SEQNUM454
> PHYSDEVBUS=usb
> DEVICE=/proc/bus/usb/001/008
> PRODUCTJ9/3051/1
> TYPE%5/255/255
> INTERFACE%5/255/255
> MODALIAS=usb:v04A9p3051d0001dcFFdscFFdpFFicFFiscFFipFF
>
> UEVENT[1144681428.430368] add@/class/usb_device/usbdev1.8
> ACTIONd
> DEVPATH=/class/usb_device/usbdev1.8
> SUBSYSTEM=usb_device
> SEQNUM455
> PHYSDEVPATH=/devices/pci0000:00/0000:00:10.0/usb1/1-1
> PHYSDEVBUS=usb
> PHYSDEVDRIVER=usb
> MAJOR\x189
> MINOR=7
>
> UDEV [1144681428.486187] add@/devices/pci0000:00/0000:00:10.0/usb1/1-1/1-1:1.0
> UDEV_LOG=3
> ACTIONd
> DEVPATH=/devices/pci0000:00/0000:00:10.0/usb1/1-1/1-1:1.0
> SUBSYSTEM=usb
> SEQNUM454
> PHYSDEVBUS=usb
> DEVICE=/proc/bus/usb/001/008
> PRODUCTJ9/3051/1
> TYPE%5/255/255
> INTERFACE%5/255/255
> MODALIAS=usb:v04A9p3051d0001dcFFdscFFdpFFicFFiscFFipFF
> UDEVD_EVENT=1
>
> UDEV [1144681428.584855] add@/class/usb_device/usbdev1.8
> UDEV_LOG=3
> ACTIONd
> DEVPATH=/class/usb_device/usbdev1.8
> SUBSYSTEM=usb_device
> SEQNUM455
> PHYSDEVPATH=/devices/pci0000:00/0000:00:10.0/usb1/1-1
> PHYSDEVBUS=usb
> PHYSDEVDRIVER=usb
> MAJOR\x189
> MINOR=7
> UDEVD_EVENT=1
> DEVNAME=/dev/bus/usb/001/008
And the device /dev/bus/usb/001/008 has group set to root, and that's
the problem.
If I plug in the USB-based mp3 player, I get in part:
> UDEV [1144681853.831681] add@/block/sdb
> UDEV_LOG=3
> ACTIONd
> DEVPATH=/block/sdb
> SUBSYSTEM=block
> SEQNUM464
> MINOR\x16
> MAJOR=8
> PHYSDEVPATH=/devices/pci0000:00/0000:00:10.3/usb4/4-4/4-4:1.0/host24/target24:0:0/24:0:0:0
> PHYSDEVBUS=scsi
> PHYSDEVDRIVER=sd
> UDEVD_EVENT=1
> ID_VENDOR=iriver
> ID_MODEL=MassStorage_Disc
> ID_REVISION\001
> ID_SERIAL=iriver_MassStorage_Disc
> ID_TYPE=disk
> ID_BUS=usb
> ID_PATH=pci-0000:00:10.3-usb-0:4:1.0-scsi-0:0:0:0
> REMOVE_CMD=/etc/hotplug/usb/iriver remove
> DEVNAME=/dev/scsi/host24/bus0/target0/lun0/disc
> DEVLINKS=/dev/sdb /dev/discs/disc2/disc /dev/disk/by-id/usb-iriver_MassStorage_Disc /dev/disk/by-path/pci-0000:00:10.3-usb-0:4:1.0-scsi-0:0:0:0 /dev/iriver
and the rules based on SYSFS{ID_VENDOR} work as expected. (Well, there's
one bug that I'm chasing down -- REMOVE_CMD did *not* execute, and
neither did the other remove rules. I don't know why just yet.)
So, in summary, SYSFS is available but only for some USB items.
Please let me know if you need any further information.
--
Moshe Yudkowsky
work: http://www.Disaggregate.com
book: http://www.PebbleAndAvalanche.com
-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid\x110944&bid$1720&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
next reply other threads:[~2006-04-10 15:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-10 15:16 Moshe Yudkowsky [this message]
2006-04-10 17:02 ` USB camera not hotplugging because SYSFS{ID_VENDOR} etc. not available Andrey Borzenkov
2006-04-10 19:02 ` USB camera not hotplugging because SYSFS{ID_VENDOR} etc. not Moshe Yudkowsky
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=443A76D5.60208@bl.com \
--to=msha5_17@bl.com \
--cc=linux-hotplug@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).