Package: udev Version: 0.114-2 Severity: normal Tags: patch
Hello, sg*|*) NAME=generic ;; So for sg* _and_ all targets so far without a rule NAME=generic is used. On the specific system we have a tape-library attached and the ch.ko driver uses ch* as device names. When the device was detected first the sg-driver created its /dev entries and then the ch-driver took over and called udev for the very same host-id, bus, id and lun. Since scsi-devfs.sh now didn't have a rule for ch* it gracefully overwrote the sg scsi/host$HOST/bus$BUS/target$TARGET/lun$LUN/generic entries with ch major and minors. Of course, the /dev/sg* still existed, but just pointed to wrong device. The tape software trying to access the sg devices with sg ioctls got rather confused (you have no idea how much trouble this caused...). Here are two patches, entirely untested though, since we solved it on the specific system differently. 01_dev_ch.patch: Rule for media changer devices Index: udev/scsi-devfs.sh =================================================================== --- udev.orig/scsi-devfs.sh 2008-03-02 14:14:18.000000000 +0100 +++ udev/scsi-devfs.sh 2008-03-02 14:19:03.000000000 +0100 @@ -74,6 +74,9 @@ NAME=$(echo "$1" | sed -e 's/st0m/mt/') [ $NAME = "mt0" ] && LINK=tape ;; +ch*) + NAME=ch + ;; sg*|*) NAME=generic ;; 02_no_default_generic.patch: Abort if a device name is unknown. Better no devfs-style rule than a harmful rule. Index: udev/scsi-devfs.sh =================================================================== --- udev.orig/scsi-devfs.sh 2008-03-02 14:19:53.000000000 +0100 +++ udev/scsi-devfs.sh 2008-03-02 14:21:58.000000000 +0100 @@ -77,9 +77,13 @@ ch*) NAME=ch ;; -sg*|*) +sg*) NAME=generic ;; +*) + echo "Unknown device-type $1" + exit 1 + ;; esac echo scsi/host$HOST/bus$BUS/target$TARGET/lun$LUN/$NAME $LINK Cheers, Bernd -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]