ide-cs broken / udev magic

From: Damir Perisa
Date: Fri Nov 04 2005 - 18:22:41 EST


Le Friday 04 November 2005 08:19, Greg KH a écrit :
| <apologies for the broken threading>

no problem

@Judd + Tobias: this is a ide-cs trouble thing that exists in arch with
default udev rules as of 071-1

| > [17194333.620000] cs: memory probe 0xf0000000-0xf80fffff: excluding
| > 0xf0000000-0xf87fffff
| > [17194333.644000] pcmcia: Detected deprecated PCMCIA ioctl usage.
| > [17194333.644000] pcmcia: This interface will soon be removed from
| > the kernel; please expect breakage unless you upgrade to new tools.
| > [17194333.644000] pcmcia: see
| > http://www.kernel.org/pub/linux/utils/kernel/pcmcia/pcmcia.html for
| > details.
| > [17194334.032000] Probing IDE interface ide2...
| > [17194334.320000] hde: 1024MB Flash Card, CFA DISK drive
| > [17194334.992000] ide2 at 0x4100-0x4107,0x410e on irq 3
| > [17194334.992000] hde: max request size: 128KiB
| > [17194334.992000] hde: 2001888 sectors (1024 MB) w/1KiB Cache,
| > CHS=1986/16/63
| > [17194334.992000] hde: cache flushes not supported
| > [17194334.992000] hde: hde1
| > [17194335.004000] ide-cs: hde: Vcc = 3.3, Vpp = 0.0
| > [17194335.224000] hde: hde1
| > [17194335.632000] hde: hde1
| > [17194335.736000] hde: hde1
| > [17194335.744000] hde: hde1
| > ... ("hde: hde1" repeating)...
| >
| > ok, now the situation is less lethal, but still no proper ide-cs
| > working. there are no unknown symbols now, but the other output in
| > dmesg is the same. especially, the loop to output "hde: hde1" is
| > here, but if i remove the card, it stops and the system is still
| > responsible.
| >
| > /sys/block/hde/hde1/
| > presents itself fully normal like other ide drives. in
| > /sys/block/hde/hde1/sample.sh
| > i found "mknod /dev/hde1 b 33 1" and tried to run it. successfully!
| > the result is: in dmesg, the "hde: hde1" output loop stopped and my
| > card is working again!!!
|
| Heh, the poor-man's udev worked for someone :)

:D ... true, sometimes one has to do things manually to have it done.

| The problem is in your udev rules. You are running something in them
| that is opening up your ide-cs device, which causes another hotplug
| event to happen, which causes udev to run again, and so on.

thanx for the explaination. i'm using archlinux and it seems that i'm the
only one who uses ide-cs and therefore ran into this trouble. i just
added

BUS=="ide", SYSFS{removable}="1", GOTO="no_volume_id"
BUS=="ide", SYSFS{../removable}="1", GOTO="no_volume_id"

to /etc/udev/rules.d/udev.rules

as other distros use to ignore removable ide's. now i need to load the
ide-cs module by hand (bad thing, as module should be loaded
automagically with udev/hotplug) but on the other hand, no more
dmesg-spamming, no freezes and also the node is created successfully
after module is loaded.

is there some other rules that may be usefull adding in this case?

is there planed action to change ide-cs to work without making it being
ignored ... without this exception that needs to be specified in udev
rules?

thank you for the analysis and the workaround that i'm now using to have
ide-cs working again. making it behave like any other ide would be cool,
but is only aesthetical for me, as things work now :)

greetings,
Damir

--
Build a system that even a fool can use and only a fool will want to use
it.

Attachment: pgp00000.pgp
Description: PGP signature