]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/scsi/st.h
[SCSI] aic7xxx: fix byte I/O order in ahd_inw
[linux-2.6-omap-h63xx.git] / drivers / scsi / st.h
index 061da111398e98cbe097c3845c6686d3be7f9cad..05a5cae126ec06e8c75c632821f8a6d8548236eb 100644 (file)
@@ -3,7 +3,8 @@
 #define _ST_H
 
 #include <linux/completion.h>
-
+#include <linux/kref.h>
+#include <scsi/scsi_cmnd.h>
 
 /* Descriptor for analyzed sense data */
 struct st_cmdstatus {
@@ -17,9 +18,19 @@ struct st_cmdstatus {
        u8 deferred;
 };
 
+struct scsi_tape;
+
+/* scsi tape command */
+struct st_request {
+       unsigned char cmd[MAX_COMMAND_SIZE];
+       unsigned char sense[SCSI_SENSE_BUFFERSIZE];
+       int result;
+       struct scsi_tape *stp;
+       struct completion *waiting;
+};
+
 /* The tape buffer descriptor. */
 struct st_buffer {
-       unsigned char in_use;
        unsigned char dma;      /* DMA-able buffer */
        unsigned char do_dio;   /* direct i/o set up? */
        int buffer_size;
@@ -28,7 +39,7 @@ struct st_buffer {
        int read_pointer;
        int writing;
        int syscall_result;
-       struct scsi_request *last_SRpnt;
+       struct st_request *last_SRpnt;
        struct st_cmdstatus cmdstat;
        unsigned char *b_data;
        unsigned short use_sg;  /* zero or max number of s/g segments for this adapter */
@@ -156,6 +167,7 @@ struct scsi_tape {
        unsigned char last_sense[16];
 #endif
        struct gendisk *disk;
+       struct kref     kref;
 };
 
 /* Bit masks for use_pf */