From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Svetoslav Slavtchev" Date: Thu, 11 Dec 2003 01:31:34 +0000 Subject: Re: udev.rules.devfs + symlinks & a question Message-Id: List-Id: References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: linux-hotplug@vger.kernel.org > On Thu, Dec 11, 2003 at 12:19:57AM +0100, Svetoslav Slavtchev wrote: > > > On Wed, Dec 10, 2003 at 11:45:24PM +0100, Svetoslav Slavtchev wrote: > > > > > > and i'm not sure how can i distinguish a cd drive from a hard > drive > > > > >=20 > > > > > For scsi cdroms it's easy, look at the type file in sysfs. For > ide > > > > > cdroms, code needs to be added to the kernel to export that > > > information > > > > > for you to determine this. > > > >=20 > > > > hm, i was browsing the thread a while ago, but didnt get it fully > > > > there were some issues with using 2 rules for one device, > > >=20 > > > You would not need 2 rules. One a "is this a cdrom" rule. If not, > then > > > it would fall down into the "is this a disk" rule. Something like: > > > LABEL, BUS=3D"scsi", type=3D"cdrom", NAME=3D"cdrom%n" > > > LABEL, BUS=3D"scsi", type=3D"disk", NAME=3D"lun0/%D" > > > You get the idea... > >=20 > > and what if it is a tape, scanner, or smth else ? >=20 > I don't know the devfs naming scheme, so you will have to figure that > out yourself :) on second thought, i think you missunderstood me i ment that there shouldn't be a else clause eg=20 rule1 type=3Da name=3D.... rule2 type=3Db name=3D... so if i have devices type a, b, c, unknown i don't wont devices c & unknown to be named as device type b if i used rule1 type=3Da name=3D.... rule2 name=3D.. // catch all type b devices /* and sometimes other */ and i was asking wether all devices export their type=20 /* in the particular case about ide/scsi hd's */ svetljo --=20 +++ GMX - die erste Adresse f=FCr Mail, Message, More +++ Neu: Preissenkung f=FCr MMS und FreeMMS! http://www.gmx.net ------------------------------------------------------- This SF.net email is sponsored by: IBM Linux Tutorials. Become an expert in LINUX or just sharpen your skills. Sign up for IBM's Free Linux Tutorials. Learn everything from the bash shell to sys admin. Click now! http://ads.osdn.com/?ad_id=1278&alloc_id371&op=3Dclick _______________________________________________ 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