freebsd-nq/share/man/man9/st.9
1997-03-07 02:53:37 +00:00

137 lines
4.1 KiB
Groff

.\" Copyright (c) 1997
.\" John-Mark Gurney. All rights reserved.
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" are met:
.\" 1. Redistributions of source code must retain the above copyright
.\" notice, this list of conditions and the following disclaimer.
.\" 2. Redistributions in binary form must reproduce the above copyright
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
.\" 3. Neither the name of the author nor the names of any co-contributors
.\" may be used to endorse or promote products derived from this software
.\" without specific prior written permission.
.\"
.\" THIS SOFTWARE IS PROVIDED BY John-Mark Gurney AND CONTRIBUTORS ``AS IS'' AND
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
.\" $Id$
.\"
.Dd February 1, 1997
.Dt ST 9
.Os FreeBSD
.Sh NAME
.Nm st
.Nd device driver for SCSI subsystem
.Sh DESCRIPTION
The
.Nm
driver is for Type 1
.Pq Dv T_SEQUENTIAL
scsi devices. These devices are normally tape drives. Some tape drives
require special handling by the device driver. See the QUIRKS section for
information on handling broken devices.
.Sh QUIRKS
Each SCSI device can have problems that the driver needs to work around. See
.Xr scsiconf 9
for more info on adding quirks.
.Bl -tag -width ST_Q_FORCE_FIXED_MODE
.It ST_Q_NEEDS_PAGE_0
This tells the driver that the device in question always requires a page
0 on each MODE SELECT operation.
.It ST_Q_FORCE_FIXED_MODE
Forces the drive into fixed block mode.
.It ST_Q_FORCE_VAR_MODE
Forces the drive into variable block mode.
.It ST_Q_SNS_HLP
Drive requires a read of the tape before the mode sense will return useful
information.
.It ST_Q_IGNORE_LOADS
Causes the driver to return without action when telling the drive to load
a tape.
.ig xx \" These seem to have become stale in the driver.
.It ST_Q_BLKSIZ
Use variable-block size even though media_blksiz is \&< 0.
.It ST_Q_CC_NOMSG
This drive doesn't accept message when in CC state.
.xx
.It ST_Q_NO_1024
Never use 1024-byte fixed blocks with this drive.
.It ST_Q_NO_SYNC
Disable synchronous negotiation with the drive.
.It ST_Q_NO_FAST
Disable fast negotiation with the drive.
.It ST_Q_NO_WIDE
Disable wide negotiation with the drive.
.El
The
.Xr st 4
driver uses the
.Dv void* devmodes
entry of
.Dv struct scsidevs
.Po
see
.Xr scsiconf 9
for more info
.Pc
to point to a
.Dv struct st_mode st_modes[4]
array.
This provides the four different modes for the subdevices accessible by the
.Nm
driver.
.Bd -literal -offset indent
struct st_mode {
u_int32_t blksiz;
u_int16_t quirks;
u_int8_t density;
u_int8_t spare[1];
};
.Ed
.Pp
.Bl -tag -width space[1] -compact
.It blksize
This is the fixed block size to use.
.It quirks
Specifies the quirk flags to use, overriding general quirk flags for
that drive.
.It density
Specifies the density used for this mode. See the file
.Pa /sys/scsi/scsiconf.h
for a list of the possible defines to use here.
.It spare[1]
Unused.
.El
.Sh FILES
.Bl -tag -width /sys/scsi/scsiconf.h -compact
.It Pa /sys/scsi/scsiconf.h
contains the
.Dv ST_Q_xxx
macro defines and the density defines
.It Pa /sys/scsi/st.c
files contains actual driver code
.El
.Sh SEE ALSO
.Xr st 4 ,
.Xr scsiconf 9
.Sh HISTORY
The
.Nm
manual page first appeared in
.Fx 2.2 .
.Sh AUTHOR
This
manual page was written by John-Mark Gurney
.Aq gurney_j@efn.org .