patch-2.1.20 linux/drivers/scsi/st.h

Next file: linux/fs/buffer.c
Previous file: linux/drivers/scsi/st.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.19/linux/drivers/scsi/st.h linux/drivers/scsi/st.h
@@ -29,6 +29,7 @@
 /* The tape mode definition */
 typedef struct {
   unsigned char defined;
+  unsigned char sysv;   /* SYS V semantics? */
   unsigned char do_async_writes;
   unsigned char do_buffer_writes;
   unsigned char do_read_ahead;
@@ -46,10 +47,12 @@
 /* The status related to each partition */
 typedef struct {
   unsigned char rw;
-  unsigned char moves_after_eof;
+  unsigned char eof;
   unsigned char at_sm;
   unsigned char last_block_valid;
   u32 last_block_visited;
+  int drv_block;	/* The block where the drive head is */
+  int drv_file;
 } ST_partstat;
 
 #define ST_NBR_PARTITIONS 4
@@ -87,11 +90,9 @@
   ST_partstat ps[ST_NBR_PARTITIONS];
   unsigned char dirty;
   unsigned char ready;
-  unsigned char eof;
   unsigned char write_prot;
   unsigned char drv_write_prot;
   unsigned char in_use;
-  unsigned char eof_hit;
   unsigned char blksize_changed;
   unsigned char density_changed;
   unsigned char compression_changed;
@@ -103,13 +104,14 @@
   int min_block;
   int max_block;
   int recover_count;
-  int drv_block;	/* The block where the drive head is */
   struct mtget * mt_status;
 
 #if DEBUG
   unsigned char write_pending;
   int nbr_finished;
   int nbr_waits;
+  unsigned char last_cmnd[6];
+  unsigned char last_sense[16];
 #endif
 } Scsi_Tape;
 
@@ -117,10 +119,15 @@
 
 /* Values of eof */
 #define	ST_NOEOF	0
-#define	ST_FM		1
-#define	ST_EOM_OK	2
-#define ST_EOM_ERROR	3
-#define ST_EOD		4
+#define ST_FM_HIT       1
+#define ST_FM           2
+#define ST_EOM_OK       3
+#define ST_EOM_ERROR	4
+#define	ST_EOD_1        5
+#define ST_EOD_2        6
+#define ST_EOD		7
+/* EOD hit while reading => ST_EOD_1 => return zero => ST_EOD_2 =>
+   return zero => ST_EOD, return ENOSPC */
 
 /* Values of rw */
 #define	ST_IDLE		0

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov