0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012 typedef void (*mts_scsi_cmnd_callback)(struct scsi_cmnd *);
0013
0014
0015 struct mts_transfer_context
0016 {
0017 struct mts_desc *instance;
0018 mts_scsi_cmnd_callback final_callback;
0019 struct scsi_cmnd *srb;
0020
0021 void *data;
0022 unsigned data_length;
0023 int data_pipe;
0024 struct scatterlist *curr_sg;
0025
0026 u8 *scsi_status;
0027 };
0028
0029
0030 struct mts_desc {
0031 struct mts_desc *next;
0032 struct mts_desc *prev;
0033
0034 struct usb_device *usb_dev;
0035 struct usb_interface *usb_intf;
0036
0037
0038 u8 ep_out;
0039 u8 ep_response;
0040 u8 ep_image;
0041
0042 struct Scsi_Host *host;
0043
0044 struct urb *urb;
0045 struct mts_transfer_context context;
0046 };
0047
0048
0049 #define MTS_EP_OUT 0x1
0050 #define MTS_EP_RESPONSE 0x2
0051 #define MTS_EP_IMAGE 0x3
0052 #define MTS_EP_TOTAL 0x3
0053
0054 #define MTS_SCSI_ERR_MASK ~0x3fu
0055