On Thu, 2006-09-28 at 16:40 +0800, Dan Jacobson wrote:
> 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.

Ick, no, just use a reasonable setup, where HAL will poll the device for
you and this is no issue at all. Nobody should write udev rules for
things like this these days.

> ===============
> 
> (By the way, one even wonders if BUS above should be SUBSYSTEMS.

Both work the same way. Yes, the document should be updated to use the
new key names.

> and one also wants to match all card readers, no matter the brand.

No recent system should need any of these udev rules to make
card-readers work. Udev rules or disconnect/reconnect advices are the
totally wrong solution for this problem.

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

Nothing is needed. Udevd will notice any rules change by watching the
directory with inotify.

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

As said, everybody can try to fiddle around with stuff like this if he's
interested in seeing how that works, we all do this sometimes. But
nothing of this should be needed today to get things working, if you
don't cripple your system or work in a very special environment and you
are expected to have that kind of special knowledge anyway.

Kay



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to