Skip to contentSkip to conversation

Bug#389892: writing_udev_rules: just unplug the card reader and

DISCUSSION Dan Jacobson 1 participant 1 message Sep 28, 2006

lore
Share & tools
lore
#0 lore raw

X-debbugs-cc: [email protected], [email protected], [email protected]
Package: udev
Version: 0.100-1
Severity: normal
File: /usr/share/doc/udev/writing_udev_rules/index.html

Regarding

USB Card Reader

These devices typically do not inform the host computer upon media change. So, if you plug in the device with no media, and then insert a card, the computer does not realise, and you do not have your mountable sdb1 partition node for the media.

One possible solution is to take advantage of the all_partitions option, which will create 16 partition nodes for every block device that the rule matches:

BUS="usb", SYSFS{product}="USB 2.0 CompactFlash Reader", SYMLINK+="cfrdr%n", OPTIONS+="all_partitions"

You will now have nodes named: cfrdr, cfrdr1, cfrdr2, cfrdr3, ..., cfrdr15.

I would say 10000 times less complicated would be to tell the user to forget trying to understand all this, and

1. umount(8) cards already mounted on the reader, if any.
2. Unplug the reader from the USB socket.
3. Insert any additional cards into the reader.
4. Plug the reader back into the USB socket.
5. mount(8) your cards again.

That's all.

Sorry, but that's the view from us less sophisticated users.

=======
(By the way, one even wonders if BUS above should be SUBSYSTEMS. and one also wants to match all card readers, no matter the brand.

Also say what one has to do after one writes a rule. restart udevd? reboot? for it to take effect.

But never mind. It is 10000 times easier to forget trying to understand all this.)

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CIDÞVDEV
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel