xref: /openbsd/share/man/man4/mtio.4 (revision cecf84d4)
1.\"	$OpenBSD: mtio.4,v 1.15 2014/01/21 03:15:46 schwarze Exp $
2.\"	$NetBSD: mtio.4,v 1.4 1996/03/03 17:13:54 thorpej Exp $
3.\"
4.\" Copyright (c) 1983, 1991 The Regents of the University of California.
5.\" All rights reserved.
6.\"
7.\" Redistribution and use in source and binary forms, with or without
8.\" modification, are permitted provided that the following conditions
9.\" are met:
10.\" 1. Redistributions of source code must retain the above copyright
11.\"    notice, this list of conditions and the following disclaimer.
12.\" 2. Redistributions in binary form must reproduce the above copyright
13.\"    notice, this list of conditions and the following disclaimer in the
14.\"    documentation and/or other materials provided with the distribution.
15.\" 3. Neither the name of the University nor the names of its contributors
16.\"    may be used to endorse or promote products derived from this software
17.\"    without specific prior written permission.
18.\"
19.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
20.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
23.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
25.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
26.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
27.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
28.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29.\" SUCH DAMAGE.
30.\"
31.\"     from: @(#)mtio.4	6.5 (Berkeley) 3/27/91
32.\"
33.Dd $Mdocdate: January 21 2014 $
34.Dt MTIO 4
35.Os
36.Sh NAME
37.Nm mtio
38.Nd magtape interface
39.Sh SYNOPSIS
40.Fd #include <sys/mtio.h>
41.Sh DESCRIPTION
42This interface concerns devices which are typical tape block devices,
43see
44.Xr physio 9 .
45.Pp
46The conventional device letters/numbers
47is applicable to any of the transport/controller pairs.
48(But note that only 1600
49.Tn BPI
50is available with the
51.Tn TS11 ,
52and that 800
53.Tn BPI
54is not applicable to
55.Tn TM78 . )
56.Pp
57When the device last number is between
58.Em 0-7
59the device will operate at 800
60.Tn BPI
61(or its lowest density), between
62.Em 8-15
63it will operate at 1600
64.Tn BPI
65(or its second density), and between
66.Em 16-23
67it will operate at 6250
68.Tn BPI .
69.Pp
70The rewind devices automatically rewind
71when the last requested read, write or seek has finished, or the end of the tape
72has been reached.
73The letter
74.Ql n
75is usually prepended to
76the name of the no-rewind devices.
77.Pp
78Unix tapes are written in multiples of 1024 byte block
79records.
80Two end-of-file markers mark the end of a tape, and
81one end-of-file marker marks the end of a tape file.
82If the tape is not to be rewound it is positioned with the
83head in between the two tape marks, where the next write
84will overwrite the second end-of-file marker.
85.Pp
86All of the magtape devices may be manipulated with the
87.Xr mt 1
88command.
89.Pp
90The include file
91.In sys/mtio.h
92defines the various
93.Xr ioctl 2
94operations available on raw magnetic tape.
95.Sh FILES
96.Bl -tag -width /dev/rmt? -compact
97.It Pa /dev/mt?
98.It Pa /dev/rmt?
99.El
100.Sh SEE ALSO
101.Xr mt 1 ,
102.Xr tar 1 ,
103.Xr intro 4 ,
104.Xr st 4
105.Sh HISTORY
106The
107.Nm
108manual appeared in
109.Bx 4.2 .
110.Sh BUGS
111The status should be returned in a device independent format.
112