docs: admin: devices: /dev/sr<N> for SCSI CD-ROM
Subsystems (2)
PATCH 1/1 docs: admin: devices: /dev/sr<N> for SCSI CD-ROM
Don't claim that /dev/sr<N> device names for SCSI CD-ROM drives are deprecated and don't recommend /dev/scd<N> alternate names for them.
/dev/scd<N> device names for SCSI CD-ROM drives are not in use for more than a decade, see commit [1] that was a part of udev release 174. Earlier related rules were volatile, sometimes /dev/scd<N> were syminks to /dev/sr<N>, sometimes vice versa.
Recognizing of root=/dev/scd<N> kernel command line argument was removed in kernel 2.5.45 [2].
In the docs /dev/scd<N> are recommended names since 2.6.9 [3]. Mention of these names appeared much earlier in 1.3.22 [4].
[1] https://git.kernel.org/pub/scm/linux/hotplug/udev.git/commit/?id=d132be4d58
2011-08-12 14:05:19 +0200 Kay Sievers.
rules: remove legacy rules for cdrom and usb printer 2002-10-29 00:47:58 -0800 Alexander Viro.
[PATCH] removal of root_dev_names[] 2004-03-16 15:09:38 -0800 Andrew Morton:
[PATCH] devices.txt: typos and removal of dead devices[4] https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/tree/Documentation/devices.txt?h=v2.6.9-rc4&id=8f0ec1f9369
Linus Torvalds: Import 1.3.22
---
I hope, the suggested changes make kernel docs more close to reality.
During discussion of a bug in wodim (a fork of cdrecord) I was confused that docs recommend /dev/scd<N> as SCSI CD-ROM name. The following thread did not clarify the issue:
https://lore.kernel.org/lkml/[email protected]/
Scsi cdrom naming confusion; sr or scd? Sun, 5 Nov 2006 10:09:26 +0000
If I'm not mistaken, "sr" was always used internally in the driver "scd" were limited to log strings. I have added SCSI subsystem to CC to confirm that there is no objection from their side.
It seems, de-facto /dev/sr<N> names are used and I think, /dev/scd<N> should be avoided. I may be completely wrong though.
I wouldn't mind if you discard this patch and to commit another one with better wording instead.
--- Documentation/admin-guide/devices.rst | 4 +++- Documentation/admin-guide/devices.txt | 6 +++--- 2 files changed, 6 insertions(+), 4 deletions(-)
Documentation/admin-guide/devices.rst +3 -1
@@ -97,9 +97,11 @@ It is recommended that these links exist on all systems: /dev/bttv0 video0 symbolic Backward compatibility /dev/radio radio0 symbolic Backward compatibility /dev/i2o* /dev/i2o/* symbolic Backward compatibility -/dev/scd? sr? hard Alternate SCSI CD-ROM name =============== =============== =============== =============================== +Usage of ``/dev/scd?`` as alternate SCSI CD-ROM names for ``sr?`` devices +ended around year 2011. + Locally defined links +++++++++++++++++++++
Documentation/admin-guide/devices.txt +3 -3
@@ -389,11 +389,11 @@ ... 11 block SCSI CD-ROM devices - 0 = /dev/scd0 First SCSI CD-ROM - 1 = /dev/scd1 Second SCSI CD-ROM + 0 = /dev/sr0 First SCSI CD-ROM + 1 = /dev/sr1 Second SCSI CD-ROM ... - The prefix /dev/sr (instead of /dev/scd) has been deprecated. + In the past the prefix /dev/scd (instead of /dev/sr) was used and even recommended. 12 char QIC-02 tape 2 = /dev/ntpqic11 QIC-11, no rewind-on-close
Signature · 1 line
2.39.5
Documentation/admin-guide/devices.rst It is recommended that these links exist on all systems: · line 103
Quoted 2 lines · Max Nikulin
Documentation/admin-guide/devices.rst +2
-0+Usage of ``/dev/scd?`` as alternate SCSI CD-ROM names for ``sr?`` devices +ended around year 2011.
What about "Support for /dev/scd? as alternative names for /dev/sr? has been removed in 2011"?
Thanks.
Signature · 1 line
An old man doll... just what I always wanted! - Clara
Quoted 6 lines · Bagas Sanjaya
Documentation/admin-guide/devices.rst It is recommended that these links exist on all systems: · line 103
Quoted 2 lines · Max Nikulin
Documentation/admin-guide/devices.rst +2
-0+Usage of ``/dev/scd?`` as alternate SCSI CD-ROM names for ``sr?`` devices +ended around year 2011.What about "Support for
/dev/scd? as alternative names for/dev/sr? has been removed in 2011"?
If others support your suggestion then I do not mind. Feel free to commit preferred variant ignoring my patch.
I would be more verbose however by adding that it was removed namely from udev:
Creation of ``/dev/scd?`` alternative names for ``sr?`` CD-ROM and other optical drives (using SCSI commands) was removed in ``udev-174`` (released in 2011).
Perhaps I am biased by my confusion. Noticed that wodim tries to access currently absent /dev/scd0 for kernels >= X.6, I tried git blame game in kernel repository to find kernel version when scd<N> were renamed to sr<N>. It took some time for me to realize that it is impossible to determine scd vs. sr from kernel version. That is why I would consider adding explicit mention of udev. Otherwise for me it sounds like that scd? names were removed from kernel. I am not a native English speaker, so I do not insist on my variant.
How long I should wait for comments before submitting another revision of the patch? I hope, pending changes are not an obstacle for those who are tempting to review the whole devices.rst file.
Quoted 11 lines · Max Nikulin
Quoted 6 lines · Bagas Sanjaya
Documentation/admin-guide/devices.rst It is recommended that these links exist on all systems: · line 103
Quoted 2 lines · Max Nikulin
Documentation/admin-guide/devices.rst +2
-0+Usage of ``/dev/scd?`` as alternate SCSI CD-ROM names for ``sr?`` devices +ended around year 2011.What about "Support for
/dev/scd? as alternative names for/dev/sr? has been removed in 2011"?If others support your suggestion then I do not mind. Feel free to commit preferred variant ignoring my patch.
Quoted 6 lines
I would be more verbose however by adding that it was removed namely from udev:
Creation of ``/dev/scd?`` alternative names for ``sr?`` CD-ROM and other optical drives (using SCSI commands) was removed in ``udev-174`` (released in 2011).
This one looks better.
Quoted 10 lines
Perhaps I am biased by my confusion. Noticed that wodim tries to access currently absent
/dev/scd0for kernels >= X.6, I tried git blame game in kernel repository to find kernel version when scd<N> were renamed to sr<N>. It took some time for me to realize that it is impossible to determine scd vs. sr from kernel version. That is why I would consider adding explicit mention of udev. Otherwise for me it sounds like that scd? names were removed from kernel. I am not a native English speaker, so I do not insist on my variant.
Quoted 3 lines
How long I should wait for comments before submitting another revision of the patch? I hope, pending changes are not an obstacle for those who are tempting to review the whole
devices.rstfile.
Since we're in rc7 (and 6.18 release is tomorrow), you need to wait until at least two weeks later (when 6.19 merge window closes) and repost. Don't forget to Cc me anyway.
Thanks.
Signature · 1 line
An old man doll... just what I always wanted! - Clara
PATCH v2 1/2 docs: admin: devices: /dev/sr<N> for SCSI CD-ROM
Don't claim that /dev/sr<N> device names for SCSI CD-ROM drives are deprecated and don't recommend /dev/scd<N> alternate names for them.
/dev/scd<N> device names for SCSI CD-ROM drives are not in use for more than a decade, see commit [1] that was a part of udev release 174. Earlier, related rules were volatile, sometimes /dev/scd<N> were syminks to /dev/sr<N>, sometimes vice versa.
Recognizing of root=/dev/scd<N> kernel command line argument was removed in kernel 2.5.45 [2].
In the docs /dev/scd<N> became recommended names in 2.6.9 [3]. Mention of these names appeared much earlier in 1.3.22 [4].
[1] https://git.kernel.org/pub/scm/linux/hotplug/udev.git/commit/?id=d132be4d58
2011-08-12 14:05:19 +0200 Kay Sievers.
rules: remove legacy rules for cdrom and usb printer 2002-10-29 00:47:58 -0800 Alexander Viro.
[PATCH] removal of root_dev_names[] 2004-03-16 15:09:38 -0800 Andrew Morton:
[PATCH] devices.txt: typos and removal of dead devices1995-09-01 Linus Torvalds: Import 1.3.22
---
I hope, the suggested changes make kernel docs more close to reality.
During discussion of a bug in wodim (a fork of cdrecord) I was confused that docs recommend /dev/scd<N> as SCSI CD-ROM name. The following thread did not clarify the issue:
https://lore.kernel.org/lkml/[email protected]/
Scsi cdrom naming confusion; sr or scd? Sun, 5 Nov 2006 10:09:26 +0000
If I'm not mistaken, "sr" was always used internally in the driver while "scd" were limited to log strings. I have added SCSI subsystem to CC to confirm that there is no objection from their side.
It seems, de-facto /dev/sr<N> names are used and I think, /dev/scd<N> should be avoided. I may be completely wrong though.
I wouldn't mind if you discard this patch and to commit another one with better wording instead.
Patch v2:
- More verbose note on removal of /dev/scd? names.
--- Documentation/admin-guide/devices.rst | 5 ++++- Documentation/admin-guide/devices.txt | 6 +++--- 2 files changed, 7 insertions(+), 4 deletions(-)
Documentation/admin-guide/devices.rst +4 -1
@@ -97,9 +97,12 @@ It is recommended that these links exist on all systems: /dev/bttv0 video0 symbolic Backward compatibility /dev/radio radio0 symbolic Backward compatibility /dev/i2o* /dev/i2o/* symbolic Backward compatibility -/dev/scd? sr? hard Alternate SCSI CD-ROM name =============== =============== =============== =============================== +Suggested earlier ``/dev/scd?`` alternative names for ``/dev/sr?`` +CD-ROM and other optical drives (using SCSI commands) were removed +in ``udev`` version 174 that was released in 2011. + Locally defined links +++++++++++++++++++++
Documentation/admin-guide/devices.txt +3 -3
@@ -389,11 +389,11 @@ ... 11 block SCSI CD-ROM devices - 0 = /dev/scd0 First SCSI CD-ROM - 1 = /dev/scd1 Second SCSI CD-ROM + 0 = /dev/sr0 First SCSI CD-ROM + 1 = /dev/sr1 Second SCSI CD-ROM ... - The prefix /dev/sr (instead of /dev/scd) has been deprecated. + In the past the prefix /dev/scd (instead of /dev/sr) was used and even recommended. 12 char QIC-02 tape 2 = /dev/ntpqic11 QIC-11, no rewind-on-close
base-commit: 464257baf99200d1be1c053f15aa617056361e81
Signature · 1 line
2.39.5
Max,
Quoted 2 lines
Don't claim that /dev/sr<N> device names for SCSI CD-ROM drives are deprecated and don't recommend /dev/scd<N> alternate names for them.
OK with me. I haven't seen /dev/scd in use for a very long time.
Signature · 1 line
Martin K. Petersen
Quoted 8 lines · Max Nikulin
Don't claim that /dev/sr<N> device names for SCSI CD-ROM drives are deprecated and don't recommend /dev/scd<N> alternate names for them.
/dev/scd<N> device names for SCSI CD-ROM drives are not in use for more than a decade, see commit [1] that was a part of udev release 174. Earlier, related rules were volatile, sometimes /dev/scd<N> were syminks to /dev/sr<N>, sometimes vice versa.
Quoted 5 lines
Recognizing of root=/dev/scd<N> kernel command line argument was removed in kernel 2.5.45 [2].
In the docs /dev/scd<N> became recommended names in 2.6.9 [3]. Mention of these names appeared much earlier in 1.3.22 [4].
I've applied this one, thanks.
jon
PATCH v2 2/2 docs: admin: devices: remove /dev/cdwriter
In reply to Bagas SanjayaRemove /dev/cdwriter from the local symlinks table and change the related note that this alias was removed long time ago.
Creation of the symlink was removed from udev in commit [1] that became a part of release 115 in 2007 [2].
The altered text was added in 1995 [3].
[1] https://git.kernel.org/pub/scm/linux/hotplug/udev.git/commit/?id=b1a2b83f2d
2007-08-11 14:06:03 +0200 Kay Sievers.
rules: update Fedora rules[2] https://git.kernel.org/pub/scm/linux/hotplug/udev.git/commit/?h=7e599863919
2007-08-24 01:29:54 +0200 Kay Sievers.
release 115 1995-11-21 Linus Torvalds.
Import 1.3.43---
I hope, I have not missed something important and this patch removes another discrepancy of documentation and current contents of the /dev directory.
I wouldn't mind if you discard this patch and to commit another one with better wording instead.
Earlier I submitted first variant of the /dev/sdc<N> patch without this chunk.
--- Documentation/admin-guide/devices.rst | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)
Documentation/admin-guide/devices.rst +5 -3
@@ -115,7 +115,6 @@ exist, they should have the following uses. /dev/mouse mouse port symbolic Current mouse device /dev/tape tape device symbolic Current tape device /dev/cdrom CD-ROM device symbolic Current CD-ROM device -/dev/cdwriter CD-writer symbolic Current CD-writer device /dev/scanner scanner symbolic Current scanner device /dev/modem modem port symbolic Current dialout device /dev/root root device symbolic Current root filesystem
@@ -129,8 +128,11 @@ exists, ``/dev/modem`` should point to the appropriate primary TTY device For SCSI devices, ``/dev/tape`` and ``/dev/cdrom`` should point to the *cooked* devices (``/dev/st*`` and ``/dev/sr*``, respectively), whereas -``/dev/cdwriter`` and /dev/scanner should point to the appropriate generic -SCSI devices (/dev/sg*). +``/dev/scanner`` should point to the appropriate generic +SCSI device (``/dev/sg*``). In the past the current CD-writer drive +had the ``/dev/cdwriter`` convenience symbolic link to a ``/dev/sg*`` +generic SCSI device, but its creation was removed in ``udev`` version 115 +released in 2007. ``/dev/mouse`` may point to a primary serial TTY device, a hardware mouse device, or a socket for a mouse driver program (e.g. ``/dev/gpmdata``).
Signature · 1 line
2.39.5
Jonathan Corbet
maintainerRe: [PATCH v2 2/2] docs: admin: devices: remove /dev/cdwriter
Quoted 6 lines · Max Nikulin
Remove
/dev/cdwriterfrom the local symlinks table and change the related note that this alias was removed long time ago.Creation of the symlink was removed from udev in commit [1] that became a part of release 115 in 2007 [2].
[...]
Documentation/admin-guide/devices.rst exists, ``/dev/modem`` should point to the appropriate primary TTY device · line 135
Quoted 10 lines
For SCSI devices, ``/dev/tape`` and ``/dev/cdrom`` should point to the *cooked* devices (``/dev/st*`` and ``/dev/sr*``, respectively), whereas
-``/dev/cdwriter`` and/dev/scannershould point to the appropriate genericDocumentation/admin-guide/devices.rst +5
-1-SCSI devices (/dev/sg*). +``/dev/scanner`` should point to the appropriate generic +SCSI device (``/dev/sg*``). In the past the current CD-writer drive +had the ``/dev/cdwriter`` convenience symbolic link to a ``/dev/sg*`` +generic SCSI device, but its creation was removed in ``udev`` version 115 +released in 2007.
As a general rule, kernel documentation should describe the kernel we have now; if we try to fill it with all of the history of what once was, the end result will not be pleasing. So can I get a version just removing the obsolete material?
Thanks,
jon
PATCH v3 1/1 docs: admin: devices: remove /dev/cdwriter
Remove /dev/cdwriter from the local symlinks table and from the related note.
Creation of the symlink was removed from udev in commit [1] that became a part of release 115 in 2007 [2].
The altered text was added in 1995 [3].
[1] https://git.kernel.org/pub/scm/linux/hotplug/udev.git/commit/?id=b1a2b83f2d
2007-08-11 14:06:03 +0200 Kay Sievers.
rules: update Fedora rules[2] https://git.kernel.org/pub/scm/linux/hotplug/udev.git/commit/?h=7e599863919
2007-08-24 01:29:54 +0200 Kay Sievers.
release 115 1995-11-21 Linus Torvalds.
Import 1.3.43---
Patch set v3 (second revision of this patch) changes:
- do not add comment when cdwriter was removed from udev,
- adjust commit message accordingly.
Despite in this particular case I disagree with
Quoted 3 lines · Jonathan Corbet Mon, 22 Dec 2025 14:58:25 -0700 wrote:
As a general rule, kernel documentation should describe the kernel we have now; if we try to fill it with all of the history of what once was, the end result will not be pleasing.
- The note was related to recommendations to other projects rather than documenting kernel.
- The obsolete recommendation was here for too long time, so it is better to keep the reason to change for some period of time. It may help to those who seen "cdwriter" earlier and now they may be confused. On the other hand the change is minor and there is no point to prominently advertise it.
- Git history is incomplete making "git blame" game not so trivial.
Quoted 2 lines
So can I get a version just
removing the obsolete material?
Earlier I added the following exactly for this case. The change is minor, so alternative commit may save some time.
Quoted 2 lines
Quoted 2 lines
I wouldn't mind if you discard this patch and to commit another one with better wording instead.
--- Documentation/admin-guide/devices.rst | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
Documentation/admin-guide/devices.rst +2 -3
@@ -115,7 +115,6 @@ exist, they should have the following uses. /dev/mouse mouse port symbolic Current mouse device /dev/tape tape device symbolic Current tape device /dev/cdrom CD-ROM device symbolic Current CD-ROM device -/dev/cdwriter CD-writer symbolic Current CD-writer device /dev/scanner scanner symbolic Current scanner device /dev/modem modem port symbolic Current dialout device /dev/root root device symbolic Current root filesystem
@@ -129,8 +128,8 @@ exists, ``/dev/modem`` should point to the appropriate primary TTY device For SCSI devices, ``/dev/tape`` and ``/dev/cdrom`` should point to the *cooked* devices (``/dev/st*`` and ``/dev/sr*``, respectively), whereas -``/dev/cdwriter`` and /dev/scanner should point to the appropriate generic -SCSI devices (/dev/sg*). +``/dev/scanner`` should point to the appropriate generic +SCSI device (``/dev/sg*``). ``/dev/mouse`` may point to a primary serial TTY device, a hardware mouse device, or a socket for a mouse driver program (e.g. ``/dev/gpmdata``).
base-commit: 7f3c3a0a9103dc92c823f27db3284ac2914e7558
Signature · 1 line
2.39.5
Re: [PATCH v3] docs: admin: devices: remove /dev/cdwriter
Quoted 7 lines · Max Nikulin
Remove
/dev/cdwriterfrom the local symlinks table and from the related note.Creation of the symlink was removed from udev in commit [1] that became a part of release 115 in 2007 [2].
The altered text was added in 1995 [3].
Applied, thanks.
jon
Re: [PATCH v2 2/2] docs: admin: devices: remove /dev/cdwriter
In reply to Jonathan CorbetThank you for your work on kernel docs.
Feel free to ignore the following comment.
Quoted 4 lines · Jonathan Corbet
As a general rule, kernel documentation should describe the kernel we have now; if we try to fill it with all of the history of what once was, the end result will not be pleasing.
Actually I was considering adding a history section at the end ofDocumentation/admin-guide/devices.rst. It seems, mentions of LANANA and FHS in opening paragraphs are not actual any more. I have not noticed references to the devices doc in the latest revision of FHS. The note on LANANA was important a decade ago when it was added.
Currently perhaps it is better to move these remarks to the end of the document. They will be available for search engines, effort invested into maintenance of that docs in the past is recognized, but these references will not distract readers interested in current state of affairs.
Mentions of /dev/scd<N> and /dev/cdwriter may be moved to the new section on history as well. The idea to to help those, who find old device names in old docs or code, to resolve their uncertainty.
I have no plan to submit more patches though.