summaryrefslogtreecommitdiffstats
path: root/usr.bin/mt
diff options
context:
space:
mode:
authormjacob <mjacob@FreeBSD.org>1998-12-22 17:28:25 +0000
committermjacob <mjacob@FreeBSD.org>1998-12-22 17:28:25 +0000
commit247c297d5ae726b4cd78f8c25d57f1cfe7786474 (patch)
treecd85e1979ec7945f2d67cf1d7609584b87546ddb /usr.bin/mt
parent9dfd874676ef672ddb2a015ba326cd5b6b97a7bb (diff)
downloadFreeBSD-src-247c297d5ae726b4cd78f8c25d57f1cfe7786474.zip
FreeBSD-src-247c297d5ae726b4cd78f8c25d57f1cfe7786474.tar.gz
Print out latched cdb's correlated to latched errors in MTIOCERRSTAT case.
Complete the addition of the setmark support (from Martin.Birgmeier@aon.at).
Diffstat (limited to 'usr.bin/mt')
-rw-r--r--usr.bin/mt/mt.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/usr.bin/mt/mt.c b/usr.bin/mt/mt.c
index 9436990..7f27b7f 100644
--- a/usr.bin/mt/mt.c
+++ b/usr.bin/mt/mt.c
@@ -42,7 +42,7 @@ static const char copyright[] =
static char sccsid[] = "@(#)mt.c 8.2 (Berkeley) 5/4/95";
#endif
static const char rcsid[] =
- "$Id: mt.c,v 1.18 1998/12/18 18:16:35 mjacob Exp $";
+ "$Id: mt.c,v 1.19 1998/12/19 20:23:37 mjacob Exp $";
#endif /* not lint */
/*
@@ -112,6 +112,10 @@ struct commands {
{ "density", MTSETDNSTY, 0, NEED_2ARGS|ZERO_ALLOWED|IS_DENSITY },
{ "eom", MTEOD, 1 },
{ "eod", MTEOD, 1 },
+ { "smk", MTWSS, 0 },
+ { "wss", MTWSS, 0 },
+ { "fss", MTFSS, 1 },
+ { "bss", MTBSS, 1 },
{ "comp", MTCOMP, 0, NEED_2ARGS|ZERO_ALLOWED|IS_COMP },
{ "retension", MTRETENS, 1 },
{ "rdhpos", MTIOCRDHPOS, 0 },
@@ -235,6 +239,10 @@ main(argc, argv)
if (ioctl(mtfd, comp->c_code, (caddr_t)&umn) < 0)
err(2, "%s", tape);
(void)printf("Last I/O Residual: %u\n", s->io_resid);
+ (void)printf(" Last I/O Command:");
+ for (i = 0; i < sizeof (s->io_cdb); i++)
+ (void)printf(" %02X", s->io_cdb[i]);
+ (void)printf("\n");
(void)printf(" Last I/O Sense:\n\n\t");
for (i = 0; i < sizeof (s->io_sense); i++) {
(void)printf(" %02X", s->io_sense[i]);
@@ -245,6 +253,10 @@ main(argc, argv)
(void)printf("\n");
(void)printf("Last Control Residual: %u\n",
s->ctl_resid);
+ (void)printf(" Last Control Command:");
+ for (i = 0; i < sizeof (s->ctl_cdb); i++)
+ (void)printf(" %02X", s->ctl_cdb[i]);
+ (void)printf("\n");
(void)printf(" Last Control Sense:\n\n\t");
for (i = 0; i < sizeof (s->ctl_sense); i++) {
(void)printf(" %02X", s->ctl_sense[i]);
OpenPOWER on IntegriCloud