From: "John L. Fjellstad" <john-hotplug@fjellstad.org>
To: linux-hotplug@vger.kernel.org
Subject: udev.rules.devfs patch
Date: Thu, 15 Jan 2004 14:23:55 +0000 [thread overview]
Message-ID: <200401151523.58821.john-hotplug@fjellstad.org> (raw)
[-- Attachment #1: clearsigned data --]
[-- Type: Text/Plain, Size: 493 bytes --]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Here is a patch for udev.rules.devfs to make it closer to devfs layout.
Basically, added discs/disc? directories, and the cdrom directory
- --
John L. Fjellstad
web: http://www.fjellstad.org/ Quis custodiet ipsos custodes
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
iEYEARECAAYFAkAGon4ACgkQkz0vhQtHHRhGlACgyGxHvvwnhlHsmTl11C32NHkB
1WwAoMBdiMwkWmtg7FKkDTOc+QYRGltt
=mOcE
-----END PGP SIGNATURE-----
[-- Attachment #2: patch --]
[-- Type: text/x-diff, Size: 1737 bytes --]
--- udev.rules.devfs.orig 2004-01-15 15:14:53.000000000 +0100
+++ udev.rules.devfs 2004-01-15 15:19:49.000000000 +0100
@@ -16,11 +16,19 @@
# If this is not a partition, it will result in 'disc'
#
+# if this is an ide cdrom, put it in the cdroms directory and create symlinks
+# first matching rule decides the name
+BUS="ide", PROGRAM="/bin/cat /proc/ide/%k/media", RESULT="cdrom", NAME="cdroms/cdrom%m", SYMLINK="cdrom dvd"
+
# ide block devices
-BUS="ide", id="0.0", NAME="ide/host0/bus0/target0/lun0/%D"
-BUS="ide", id="0.1", NAME="ide/host0/bus0/target1/lun0/%D"
-BUS="ide", id="1.0", NAME="ide/host0/bus1/target0/lun0/%D"
-BUS="ide", id="1.1", NAME="ide/host0/bus1/target1/lun0/%D"
+BUS="ide", id="0.0", NAME="ide/host0/bus0/target0/lun0/%D", SYMLINK="discs/disc0/%D"
+BUS="ide", id="0.1", NAME="ide/host0/bus0/target1/lun0/%D", SYMLINK="discs/disc1/%D"
+BUS="ide", id="1.0", NAME="ide/host0/bus1/target0/lun0/%D", SYMLINK="discs/disc2/%D"
+BUS="ide", id="1.1", NAME="ide/host0/bus1/target1/lun0/%D", SYMLINK="discs/disc3/%D"
+
+# scsi block devices
+BUS="scsi", id="0:0:0:0", NAME="scsi/host0/bus0/target0/lun0/%D", SYMLINK="discs/disc4/%D"
+BUS="scsi", id="0:0:0:1", NAME="scsi/host0/bus0/target0/lun0/%D", SYMLINK="discs/disc5/%D"
# md block devices
KERNEL="md[0-9]*", NAME="md/%n"
@@ -49,13 +57,13 @@
KERNEL="i2c-[0-9]*", NAME="i2c/%n", SYMLINK="%k"
# loop devices
-KERNEL="loop[0-9]*", NAME="loop/%n", SYMLINK="%k"
+KERNEL="loop[0-9]*", NAME="loop/%n"
# ramdisks
-KERNEL="ram[0-9]*", NAME="rd/%n", SYMLINK="%k"
+KERNEL="ram[0-9]*", NAME="rd/%n"
# framebuffer devices
-KERNEL="fb[0-9]*", NAME="fb/%n", SYMLINK="%k"
+KERNEL="fb[0-9]*", NAME="fb/%n"
# misc
KERNEL="rtc", NAME="misc/%k", SYMLINK="%k"
next reply other threads:[~2004-01-15 14:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-15 14:23 John L. Fjellstad [this message]
2004-01-15 14:49 ` udev.rules.devfs patch Kay Sievers
2004-01-15 15:00 ` Martin Hicks
2004-01-15 15:07 ` Kay Sievers
2004-01-15 21:43 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200401151523.58821.john-hotplug@fjellstad.org \
--to=john-hotplug@fjellstad.org \
--cc=linux-hotplug@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).