root/drivers/scsi/st.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 
   2 #ifndef _ST_H
   3         #define _ST_H
   4 /*
   5         $Header: /usr/src/linux/kernel/blk_drv/scsi/RCS/st.h,v 1.1 1992/04/24 18:01:50 root Exp root $
   6 */
   7 
   8 #ifndef _SCSI_H
   9 #include "scsi.h"
  10 #endif
  11 
  12 typedef struct {
  13   int in_use;
  14   int buffer_size;
  15   int buffer_blocks;
  16   int buffer_bytes;
  17   int read_pointer;
  18   int writing;
  19   int last_result;
  20   int last_result_fatal;
  21   unsigned char *b_data;
  22   int orig_size;
  23   unsigned char *orig_b_data;
  24 } ST_buffer;
  25 
  26 typedef struct {
  27   kdev_t devt;
  28   unsigned capacity;
  29   struct wait_queue * waiting;
  30   Scsi_Device* device;
  31   unsigned char dirty;
  32   unsigned char rw;
  33   unsigned char ready;
  34   unsigned char eof;
  35   unsigned char write_prot;
  36   unsigned char drv_write_prot;
  37   unsigned char in_use;
  38   unsigned char eof_hit;
  39   unsigned char drv_buffer;
  40   unsigned char do_buffer_writes;
  41   unsigned char do_async_writes;
  42   unsigned char do_read_ahead;
  43   unsigned char do_auto_lock;
  44   unsigned char two_fm;
  45   unsigned char fast_mteom;
  46   unsigned char density;
  47   unsigned char door_locked;
  48   unsigned char rew_at_close;
  49   ST_buffer * buffer;
  50   struct semaphore sem;
  51   int block_size;
  52   int min_block;
  53   int max_block;
  54   int write_threshold;
  55   int recover_count;
  56   int drv_block;        /* The block where the drive head is */
  57   unsigned char moves_after_eof;
  58   unsigned char at_sm;
  59   struct mtget * mt_status;
  60   Scsi_Cmnd SCpnt;
  61 #if DEBUG
  62   unsigned char write_pending;
  63   int nbr_finished;
  64   int nbr_waits;
  65 #endif
  66 } Scsi_Tape;
  67 
  68 extern Scsi_Tape * scsi_tapes;
  69 
  70 /* Values of eof */
  71 #define ST_NOEOF        0
  72 #define ST_FM           1
  73 #define ST_EOM_OK       2
  74 #define ST_EOM_ERROR    3
  75 #define ST_EOD          4
  76 
  77 /* Values of rw */
  78 #define ST_IDLE         0
  79 #define ST_READING      1
  80 #define ST_WRITING      2
  81 
  82 /* Values of ready state */
  83 #define ST_READY        0
  84 #define ST_NOT_READY    1
  85 #define ST_NO_TAPE      2
  86 
  87 /* Values for door lock state */
  88 #define ST_UNLOCKED     0
  89 #define ST_LOCKED_EXPLICIT 1
  90 #define ST_LOCKED_AUTO  2
  91 #define ST_LOCK_FAILS   3
  92 
  93 /* Positioning SCSI-commands for Tandberg, etc. drives */
  94 #define QFA_REQUEST_BLOCK       0x02
  95 #define QFA_SEEK_BLOCK          0x0c
  96 
  97 #endif
  98 

/* [previous][next][first][last][top][bottom][index][help] */