Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/pmax/dev Handle the MTOFFL request to actually offl...
details: https://anonhg.NetBSD.org/src/rev/48bd9392b7ac
branches: trunk
changeset: 475953:48bd9392b7ac
user: simonb <simonb%NetBSD.org@localhost>
date: Tue Aug 31 01:12:51 1999 +0000
description:
Handle the MTOFFL request to actually offline a tape rather than just
rewinding it. Tested with an Exabyte 8500 on a 5900/260 (the asc scsi
driver).
diffstat:
sys/arch/pmax/dev/scsi.h | 10 +++++++++-
sys/arch/pmax/dev/tz.c | 10 +++++++---
2 files changed, 16 insertions(+), 4 deletions(-)
diffs (60 lines):
diff -r 3b7ab81da4e5 -r 48bd9392b7ac sys/arch/pmax/dev/scsi.h
--- a/sys/arch/pmax/dev/scsi.h Mon Aug 30 21:18:17 1999 +0000
+++ b/sys/arch/pmax/dev/scsi.h Tue Aug 31 01:12:51 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: scsi.h,v 1.8 1999/04/24 08:01:07 simonb Exp $ */
+/* $NetBSD: scsi.h,v 1.9 1999/08/31 01:12:51 simonb Exp $ */
/*
* Copyright (c) 1992, 1993
@@ -99,6 +99,14 @@
#define SCSI_PREVENT_ALLOW 0x1e
/*
+ * Arguments to SCSI_LOAD_UNLOAD command. These are passed in byte
+ * 5 (the blockCount) of a Group0 command block.
+ */
+#define SCSI_LD_UNLOAD 0x00
+#define SCSI_LD_LOAD 0x01
+#define SCSI_LD_RETENSION 0x02
+
+/*
* Group1 commands are all 10 bytes and have a format according to
* struct ScsiGroup1Cmd.
*/
diff -r 3b7ab81da4e5 -r 48bd9392b7ac sys/arch/pmax/dev/tz.c
--- a/sys/arch/pmax/dev/tz.c Mon Aug 30 21:18:17 1999 +0000
+++ b/sys/arch/pmax/dev/tz.c Tue Aug 31 01:12:51 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: tz.c,v 1.19 1999/04/24 08:01:08 simonb Exp $ */
+/* $NetBSD: tz.c,v 1.20 1999/08/31 01:12:52 simonb Exp $ */
/*
* Copyright (c) 1992, 1993
@@ -785,7 +785,7 @@
int code, count;
static int tzops[] = {
SCSI_WRITE_EOF, SCSI_SPACE, SCSI_SPACE, SCSI_SPACE, SCSI_SPACE,
- SCSI_REWIND, SCSI_REWIND, SCSI_TEST_UNIT_READY
+ SCSI_REWIND, SCSI_LOAD_UNLOAD, SCSI_TEST_UNIT_READY
};
switch (cmd) {
@@ -822,12 +822,16 @@
break;
case MTREW:
- case MTOFFL:
case MTNOP:
code = 0;
count = 0;
break;
+ case MTOFFL:
+ code = 0;
+ count = SCSI_LD_UNLOAD;
+ break;
+
default:
return (EINVAL);
}
Home |
Main Index |
Thread Index |
Old Index