Print this page
12315 errors in section 7i of the manual

Split Close
Expand all
Collapse all
          --- old/usr/src/man/man7i/mtio.7i
          +++ new/usr/src/man/man7i/mtio.7i
↓ open down ↓ 6 lines elided ↑ open up ↑
   7    7  .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   8    8  .\" or http://www.opensolaris.org/os/licensing.
   9    9  .\" See the License for the specific language governing permissions
  10   10  .\" and limitations under the License.
  11   11  .\"
  12   12  .\" When distributing Covered Code, include this CDDL HEADER in each
  13   13  .\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  14   14  .\" If applicable, add the following below this CDDL HEADER, with the
  15   15  .\" fields enclosed by brackets "[]" replaced with your own identifying
  16   16  .\" information: Portions Copyright [yyyy] [name of copyright owner]
  17      -.Dd August 31, 2018
       17 +.Dd February 17, 2020
  18   18  .Dt MTIO 7I
  19   19  .Os
  20   20  .Sh NAME
  21   21  .Nm mtio
  22   22  .Nd general magnetic tape interface
  23   23  .Sh SYNOPSIS
  24   24  .In sys/types.h
  25   25  .In sys/ioctl.h
  26   26  .In sys/mtio.h
  27   27  .Sh DESCRIPTION
↓ open down ↓ 131 lines elided ↑ open up ↑
 159  159  completed.
 160  160  Applications should wait for all outstanding operations to complete
 161  161  before disabling persistent error handling.
 162  162  Closing the device will also
 163  163  disable persistent error handling and clear any errors or exceptions.
 164  164  .Pp
 165  165  The
 166  166  .Sx Read Operation
 167  167  and
 168  168  .Sx Write Operation
 169      -subsections contain more pertinent information reguarding persistent error handling.
      169 +subsections contain more pertinent information regarding persistent error handling.
 170  170  .Ss "Read Operation"
 171  171  The
 172  172  .Xr read 2
 173  173  function reads the next record on the tape.
 174  174  The record size is passed back as the number of bytes read, provided it is not
 175  175  greater than the number requested.
 176  176  When a tape mark or end of data is read, a zero byte count is
 177  177  returned; all successive reads after the zero read will return an error and
 178  178  .Va errno
 179  179  will be set to
↓ open down ↓ 14 lines elided ↑ open up ↑
 194  194  behavior) in the final component should be used.
 195  195  If persistent error handling
 196  196  was enabled with either the BSD or SVR4 tape device behavior, all operations
 197  197  after this read error will return
 198  198  .Er EIO
 199  199  errors until the
 200  200  .Dv MTIOCLRERR
 201  201  ioctl is issued.
 202  202  An
 203  203  .Dv MTFSF
 204      -ioctl can then he issued.
      204 +ioctl can then be issued.
 205  205  .Pp
 206  206  Two successful successive reads that both return zero byte counts indicate
 207  207  .Sy EOM
 208  208  on the tape.
 209  209  No further reading should be performed past the
 210  210  .Sy EOM .
 211  211  .Pp
 212  212  Fixed-length I/O tape devices require the number of bytes read to be a multiple
 213  213  of the physical record size.
 214  214  For example, 1/4\(dq cartridge tape devices only read
↓ open down ↓ 860 lines elided ↑ open up ↑
1075 1075  ioctl(fd, MTIOREADIGNOREILI, &off);
1076 1076  .Ed
1077 1077  .Pp
1078 1078  The
1079 1079  .Dv MTIOCREADIGNOREEOFS
1080 1080  ioctl enables or disables support for reading
1081 1081  past double EOF marks which otherwise indicate End-Of-recorded-media (EOM) in
1082 1082  the case of 1/2\(dq reel tape drives.
1083 1083  As an argument, it takes a pointer to an integer.
1084 1084  If 0 (zero) is the specified integer, then double EOF marks indicate
1085      -End-Of-recodred-media (EOD).
     1085 +End-Of-recorded-media (EOD).
1086 1086  If 1 is the specified integer, the double EOF marks no longer indicate EOM,
1087 1087  thus allowing applications to read past two EOF marks.
1088 1088  In this case it is the responsibility of the application to detect
1089 1089  end-of-recorded-media (EOM).
1090 1090  The specified tape behavior will be in effect until the device is closed.
1091 1091  .Pp
1092 1092  For example:
1093 1093  .Bd -literal -offset 2n
1094 1094  int on = 1;
1095 1095  int off = 0;
↓ open down ↓ 95 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX