Lines Matching +full:0 +full:us
73 static void cypress_atacb_passthrough(struct scsi_cmnd *srb, struct us_data *us) in cypress_atacb_passthrough() argument
77 if (likely(srb->cmnd[0] != ATA_16 && srb->cmnd[0] != ATA_12)) { in cypress_atacb_passthrough()
78 usb_stor_transparent_scsi_command(srb, us); in cypress_atacb_passthrough()
83 memset(srb->cmnd, 0, MAX_COMMAND_SIZE); in cypress_atacb_passthrough()
89 switch ((save_cmnd[1] >> 1) & 0xf) { in cypress_atacb_passthrough()
101 srb->cmnd[0] = 0x24; /* in cypress_atacb_passthrough()
104 * keep the cypress default : 0x24 in cypress_atacb_passthrough()
106 srb->cmnd[1] = 0x24; /* bVSCBSubCommand : 0x24 for ATACB */ in cypress_atacb_passthrough()
108 srb->cmnd[3] = 0xff - 1; /* in cypress_atacb_passthrough()
114 if (save_cmnd[0] == ATA_16) { in cypress_atacb_passthrough()
123 if (save_cmnd[1] & 0x01) {/* extended bit set for LBA48 */ in cypress_atacb_passthrough()
148 usb_stor_transparent_scsi_command(srb, us); in cypress_atacb_passthrough()
153 sizeof(usb_stor_sense_invalidCDB)) == 0) { in cypress_atacb_passthrough()
154 usb_stor_dbg(us, "cypress atacb not supported ???\n"); in cypress_atacb_passthrough()
164 save_cmnd[2] & 0x20) { in cypress_atacb_passthrough()
172 scsi_eh_prep_cmnd(srb, &ses, NULL, 0, sizeof(regs)); in cypress_atacb_passthrough()
182 usb_stor_transparent_scsi_command(srb, us); in cypress_atacb_passthrough()
191 memset(sb, 0, SCSI_SENSE_BUFFERSIZE); in cypress_atacb_passthrough()
195 sb[2] = 0; /* ATA PASS THROUGH INFORMATION AVAILABLE */ in cypress_atacb_passthrough()
196 sb[3] = 0x1D; in cypress_atacb_passthrough()
206 sb[0] = 0x72; in cypress_atacb_passthrough()
207 desc[0] = 0x09; /* ATA_RETURN_DESCRIPTOR */ in cypress_atacb_passthrough()
214 desc[ 2] = 0x00; in cypress_atacb_passthrough()
234 if (srb->cmnd[0] == ATA_12) in cypress_atacb_passthrough()
243 struct us_data *us; in cypress_probe() local
247 result = usb_stor_probe1(&us, intf, id, in cypress_probe()
258 if (device->descriptor.iManufacturer != 0x38 || in cypress_probe()
259 device->descriptor.iProduct != 0x4e || in cypress_probe()
260 device->descriptor.iSerialNumber != 0x64) { in cypress_probe()
261 us->protocol_name = "Transparent SCSI with Cypress ATACB"; in cypress_probe()
262 us->proto_handler = cypress_atacb_passthrough; in cypress_probe()
264 us->protocol_name = "Transparent SCSI"; in cypress_probe()
265 us->proto_handler = usb_stor_transparent_scsi_command; in cypress_probe()
268 result = usb_stor_probe2(us); in cypress_probe()