diff options
Diffstat (limited to 'static/netbsd/man4/cd.4 4.html')
| -rw-r--r-- | static/netbsd/man4/cd.4 4.html | 274 |
1 files changed, 0 insertions, 274 deletions
diff --git a/static/netbsd/man4/cd.4 4.html b/static/netbsd/man4/cd.4 4.html deleted file mode 100644 index 3e30bd21..00000000 --- a/static/netbsd/man4/cd.4 4.html +++ /dev/null @@ -1,274 +0,0 @@ -<table class="head"> - <tr> - <td class="head-ltitle">CD(4)</td> - <td class="head-vol">Device Drivers Manual</td> - <td class="head-rtitle">CD(4)</td> - </tr> -</table> -<div class="manual-text"> -<section class="Sh"> -<h1 class="Sh" id="NAME"><a class="permalink" href="#NAME">NAME</a></h1> -<p class="Pp"><code class="Nm">cd</code> — <span class="Nd">SCSI and - ATAPI CD-ROM driver</span></p> -</section> -<section class="Sh"> -<h1 class="Sh" id="SYNOPSIS"><a class="permalink" href="#SYNOPSIS">SYNOPSIS</a></h1> -<p class="Pp"><code class="Cd">cd* at scsibus? target ? lun ?</code> - <br/> - <code class="Cd">cd1 at scsibus0 target 4 lun 0</code> - <br/> - <code class="Cd">cd* at atapibus? drive ? flags 0x0000</code></p> -</section> -<section class="Sh"> -<h1 class="Sh" id="DESCRIPTION"><a class="permalink" href="#DESCRIPTION">DESCRIPTION</a></h1> -<p class="Pp">The <code class="Nm">cd</code> driver provides support for a Small - Computer Systems Interface (SCSI) bus and Advanced Technology Attachment - Packet Interface (ATAPI) Compact Disc-Read Only Memory (CD-ROM) drive. In an - attempt to look like a regular disk, the <code class="Nm">cd</code> driver - synthesizes a partition table, with one partition covering the entire - CD-ROM. It is possible to modify this partition table using - <a class="Xr">disklabel(8)</a>, but it will only last until the CD-ROM is - unmounted. In general the interfaces are similar to those described by - <a class="Xr">wd(4)</a> and <a class="Xr">sd(4)</a>.</p> -<p class="Pp">As the SCSI adapter is probed during boot, the SCSI bus is scanned - for devices. Any devices found which answer as `Read-only' type devices will - be `attached' to the <code class="Nm">cd</code> driver.</p> -<p class="Pp">For the use of flags with ATAPI devices, see - <a class="Xr">wd(4)</a>.</p> -<p class="Pp">The system utility <a class="Xr">disklabel(8)</a> may be used to - read the synthesized disk label structure, which will contain correct - figures for the size of the CD-ROM should that information be required.</p> -</section> -<section class="Sh"> -<h1 class="Sh" id="KERNEL_CONFIGURATION"><a class="permalink" href="#KERNEL_CONFIGURATION">KERNEL - CONFIGURATION</a></h1> -<p class="Pp">Any number of CD-ROM devices may be attached to the system - regardless of system configuration as all resources are dynamically - allocated.</p> -</section> -<section class="Sh"> -<h1 class="Sh" id="IOCTLS"><a class="permalink" href="#IOCTLS">IOCTLS</a></h1> -<p class="Pp">The following <a class="Xr">ioctl(2)</a> calls which apply to SCSI - CD-ROM drives are defined in the header files - <code class="In"><<a class="In">sys/cdio.h</a>></code> and - <code class="In"><<a class="In">sys/disklabel.h</a>></code>.</p> -<dl class="Bl-tag"> - <dt id="DIOCGDINFO"><a class="permalink" href="#DIOCGDINFO"><code class="Dv">DIOCGDINFO</code></a></dt> - <dd style="width: auto;"> </dd> - <dt id="DIOCSDINFO"><a class="permalink" href="#DIOCSDINFO"><code class="Dv">DIOCSDINFO</code></a></dt> - <dd>(<code class="Li">struct disklabel</code>) Read or write the in-core copy - of the disklabel for the drive. The disklabel is initialized with - information read from the SCSI inquiry commands, and should be the same as - the information printed at boot. This structure is defined in - <a class="Xr">disklabel(5)</a>.</dd> - <dt id="CDIOCPLAYTRACKS"><a class="permalink" href="#CDIOCPLAYTRACKS"><code class="Dv">CDIOCPLAYTRACKS</code></a></dt> - <dd>(<code class="Li">struct ioc_play_track</code>) Start audio playback given - a track address and length. The structure is defined as follows: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_play_track -{ - u_char start_track; - u_char start_index; - u_char end_track; - u_char end_index; -};</pre> - </div> - </dd> - <dt id="CDIOCPLAYBLOCKS"><a class="permalink" href="#CDIOCPLAYBLOCKS"><code class="Dv">CDIOCPLAYBLOCKS</code></a></dt> - <dd>(<code class="Li">struct ioc_play_blocks</code>) Start audio playback - given a block address and length. The structure is defined as follows: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_play_blocks -{ - int blk; - int len; -};</pre> - </div> - </dd> - <dt id="CDIOCPLAYMSF"><a class="permalink" href="#CDIOCPLAYMSF"><code class="Dv">CDIOCPLAYMSF</code></a></dt> - <dd>(<code class="Li">struct ioc_play_msf</code>) Start audio playback given a - `minutes-seconds-frames' address and length. The structure is defined as - follows: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_play_msf -{ - u_char start_m; - u_char start_s; - u_char start_f; - u_char end_m; - u_char end_s; - u_char end_f; -};</pre> - </div> - </dd> - <dt id="CDIOCREADSUBCHANNEL"><a class="permalink" href="#CDIOCREADSUBCHANNEL"><code class="Dv">CDIOCREADSUBCHANNEL</code></a></dt> - <dd>(<code class="Li">struct ioc_read_subchannel</code>) Read information from - the subchannel at the location specified by this structure: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_read_subchannel { - u_char address_format; -#define CD_LBA_FORMAT 1 -#define CD_MSF_FORMAT 2 - u_char data_format; -#define CD_SUBQ_DATA 0 -#define CD_CURRENT_POSITION 1 -#define CD_MEDIA_CATALOG 2 -#define CD_TRACK_INFO 3 - u_char track; - int data_len; - struct cd_sub_channel_info *data; -};</pre> - </div> - </dd> - <dt id="CDIOREADTOCHEADER"><a class="permalink" href="#CDIOREADTOCHEADER"><code class="Dv">CDIOREADTOCHEADER</code></a></dt> - <dd>(<code class="Li">struct ioc_toc_header</code>) Return summary information - about the table of contents for the mounted CD-ROM. The information is - returned into the following structure: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_toc_header { - u_short len; - u_char starting_track; - u_char ending_track; -};</pre> - </div> - </dd> - <dt id="CDIOREADTOCENTRYS"><a class="permalink" href="#CDIOREADTOCENTRYS"><code class="Dv">CDIOREADTOCENTRYS</code></a></dt> - <dd>(<code class="Li">struct ioc_read_toc_entry</code>) Return information - from the table of contents entries mentioned. (Yes, this command name is - misspelled). The argument structure is defined as follows: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_read_toc_entry { - u_char address_format; - u_char starting_track; - u_short data_len; - struct cd_toc_entry *data; -};</pre> - </div> - The requested data is written into an area of size - <code class="Li">data_len</code> and pointed to by - <code class="Li">data</code>.</dd> - <dt id="CDIOCSETPATCH"><a class="permalink" href="#CDIOCSETPATCH"><code class="Dv">CDIOCSETPATCH</code></a></dt> - <dd>(<code class="Li">struct ioc_patch</code>) Attach various audio channels - to various output channels. The argument structure is defined thusly: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_patch { - u_char patch[4]; - /* one for each channel */ -};</pre> - </div> - </dd> - <dt id="CDIOCGETVOL"><a class="permalink" href="#CDIOCGETVOL"><code class="Dv">CDIOCGETVOL</code></a></dt> - <dd style="width: auto;"> </dd> - <dt id="CDIOCSETVOL"><a class="permalink" href="#CDIOCSETVOL"><code class="Dv">CDIOCSETVOL</code></a></dt> - <dd>(<code class="Li">struct ioc_vol</code>) Get (set) information about the - volume settings of the output channels. The argument structure is as - follows: - <div class="Bd Pp Bd-indent Li"> - <pre>struct ioc_vol -{ - u_char vol[4]; - /* one for each channel */ -};</pre> - </div> - </dd> - <dt id="CDIOCSETMONO"><a class="permalink" href="#CDIOCSETMONO"><code class="Dv">CDIOCSETMONO</code></a></dt> - <dd>Patch all output channels to all source channels.</dd> - <dt id="CDIOCSETSTEREO"><a class="permalink" href="#CDIOCSETSTEREO"><code class="Dv">CDIOCSETSTEREO</code></a></dt> - <dd>Patch left source channel to the left output channel and the right source - channel to the right output channel.</dd> - <dt id="CDIOCSETMUTE"><a class="permalink" href="#CDIOCSETMUTE"><code class="Dv">CDIOCSETMUTE</code></a></dt> - <dd>Mute output without changing the volume settings.</dd> - <dt id="CDIOCSETLEFT"><a class="permalink" href="#CDIOCSETLEFT"><code class="Dv">CDIOCSETLEFT</code></a></dt> - <dd style="width: auto;"> </dd> - <dt id="CDIOCSETRIGHT"><a class="permalink" href="#CDIOCSETRIGHT"><code class="Dv">CDIOCSETRIGHT</code></a></dt> - <dd>Attach both output channels to the left (right) source channel.</dd> - <dt id="CDIOCSETDEBUG"><a class="permalink" href="#CDIOCSETDEBUG"><code class="Dv">CDIOCSETDEBUG</code></a></dt> - <dd style="width: auto;"> </dd> - <dt id="CDIOCCLRDEBUG"><a class="permalink" href="#CDIOCCLRDEBUG"><code class="Dv">CDIOCCLRDEBUG</code></a></dt> - <dd>Turn on (off) debugging for the appropriate device.</dd> - <dt id="CDIOCPAUSE"><a class="permalink" href="#CDIOCPAUSE"><code class="Dv">CDIOCPAUSE</code></a></dt> - <dd style="width: auto;"> </dd> - <dt id="CDIOCRESUME"><a class="permalink" href="#CDIOCRESUME"><code class="Dv">CDIOCRESUME</code></a></dt> - <dd>Pause (resume) audio play, without resetting the location of the - read-head.</dd> - <dt id="CDIOCRESET"><a class="permalink" href="#CDIOCRESET"><code class="Dv">CDIOCRESET</code></a></dt> - <dd>Reset the drive.</dd> - <dt id="CDIOCSTART"><a class="permalink" href="#CDIOCSTART"><code class="Dv">CDIOCSTART</code></a></dt> - <dd style="width: auto;"> </dd> - <dt id="CDIOCSTOP"><a class="permalink" href="#CDIOCSTOP"><code class="Dv">CDIOCSTOP</code></a></dt> - <dd>Tell the drive to spin-up (-down) the CD-ROM.</dd> - <dt id="CDIOCALLOW"><a class="permalink" href="#CDIOCALLOW"><code class="Dv">CDIOCALLOW</code></a></dt> - <dd style="width: auto;"> </dd> - <dt id="CDIOCPREVENT"><a class="permalink" href="#CDIOCPREVENT"><code class="Dv">CDIOCPREVENT</code></a></dt> - <dd>Tell the drive to allow (prevent) manual ejection of the CD-ROM disc. Not - all drives support this feature.</dd> - <dt id="CDIOCEJECT"><a class="permalink" href="#CDIOCEJECT"><code class="Dv">CDIOCEJECT</code></a></dt> - <dd>Eject the CD-ROM.</dd> - <dt id="CDIOCLOADUNLOAD"><a class="permalink" href="#CDIOCLOADUNLOAD"><code class="Dv">CDIOCLOADUNLOAD</code></a></dt> - <dd>Cause the ATAPI changer to load or unload discs.</dd> - <dt id="CDIOCCLOSE"><a class="permalink" href="#CDIOCCLOSE"><code class="Dv">CDIOCCLOSE</code></a></dt> - <dd>Tell the drive to close its door and load the media. Not all drives - support this feature.</dd> - <dt id="DIOCTUR"><a class="permalink" href="#DIOCTUR"><code class="Dv">DIOCTUR</code></a></dt> - <dd>Test unit ready - to allow userland to silently check for presence of - media.</dd> -</dl> -<p class="Pp">In addition the general <a class="Xr">scsi(4)</a> ioctls may be - used with the <code class="Nm">cd</code> driver, if used against the `whole - disk' partition (i.e. <span class="Pa">/dev/rcd0d</span> for the bebox and - i386 port, <span class="Pa">/dev/rcd0c</span> for all other ports).</p> -</section> -<section class="Sh"> -<h1 class="Sh" id="NOTES"><a class="permalink" href="#NOTES">NOTES</a></h1> -<p class="Pp">When a CD-ROM is changed in a drive controlled by the - <code class="Nm">cd</code> driver, then the act of changing the media will - invalidate the disklabel and information held within the kernel. To stop - corruption, all accesses to the device will be discarded until there are no - more open file descriptors referencing the device. During this period, all - new open attempts will be rejected. When no more open file descriptors - reference the device, the first next open will load a new set of parameters - (including disklabel) for the drive.</p> -<p class="Pp">The audio code in the <code class="Nm">cd</code> driver only - support SCSI-2 standard audio commands. Because many CD-ROM manufacturers - have not followed the standard, there are many CD-ROM drives for which audio - will not work. Some work is planned to support some of the more common - `broken' CD-ROM drives; however, this is not yet under way.</p> -</section> -<section class="Sh"> -<h1 class="Sh" id="FILES"><a class="permalink" href="#FILES">FILES</a></h1> -<dl class="Bl-tag Bl-compact"> - <dt><span class="Pa">/dev/cd[0-9][a-h]</span></dt> - <dd>block mode CD-ROM devices</dd> - <dt><span class="Pa">/dev/rcd[0-9][a-h]</span></dt> - <dd>raw mode CD-ROM devices</dd> -</dl> -</section> -<section class="Sh"> -<h1 class="Sh" id="DIAGNOSTICS"><a class="permalink" href="#DIAGNOSTICS">DIAGNOSTICS</a></h1> -<p class="Pp">None.</p> -</section> -<section class="Sh"> -<h1 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE - ALSO</a></h1> -<p class="Pp"><a class="Xr">intro(4)</a>, <a class="Xr">scsi(4)</a>, - <a class="Xr">sd(4)</a>, <a class="Xr">wd(4)</a>, - <a class="Xr">disklabel(5)</a>, <a class="Xr">disklabel(8)</a></p> -</section> -<section class="Sh"> -<h1 class="Sh" id="HISTORY"><a class="permalink" href="#HISTORY">HISTORY</a></h1> -<p class="Pp">The <code class="Nm">cd</code> driver appeared in 386BSD 0.1.</p> -</section> -<section class="Sh"> -<h1 class="Sh" id="BUGS"><a class="permalink" href="#BUGS">BUGS</a></h1> -<p class="Pp">The names of the structures used for the third argument to - <code class="Fn">ioctl</code>() were poorly chosen, and a number of spelling - errors have survived in the names of the <code class="Fn">ioctl</code>() - commands.</p> -</section> -</div> -<table class="foot"> - <tr> - <td class="foot-date">June 23, 2012</td> - <td class="foot-os">NetBSD 10.1</td> - </tr> -</table> |
