Commit | Line | Data |
---|---|---|
34e49164 C |
1 | struct SHT usb_stor_host_template = { |
2 | /* basic userland interface stuff */ | |
3 | .name = "usb-storage", | |
4 | .proc_name = "usb-storage", | |
5 | .proc_info = usb_storage_proc_info, | |
6 | .proc_dir = NULL, | |
7 | .info = usb_storage_info, | |
8 | .ioctl = NULL, | |
9 | ||
10 | /* old-style detect and release */ | |
11 | .detect = NULL, | |
12 | .release = NULL, | |
13 | ||
14 | /* command interface -- queued only */ | |
15 | .command = NULL, | |
16 | .queuecommand = usb_storage_queuecommand, | |
17 | ||
18 | /* error and abort handlers */ | |
19 | .eh_abort_handler = usb_storage_command_abort, | |
20 | .eh_device_reset_handler = usb_storage_device_reset, | |
21 | .eh_bus_reset_handler = usb_storage_bus_reset, | |
22 | .eh_host_reset_handler = NULL, | |
23 | .eh_strategy_handler = NULL, | |
24 | ||
25 | /* queue commands only, only one command per LUN */ | |
26 | .can_queue = 1, | |
27 | .cmd_per_lun = 1, | |
28 | ||
29 | /* unknown initiator id */ | |
30 | .this_id = -1, | |
31 | ||
32 | /* no limit on commands */ | |
33 | .max_sectors = 0, | |
34 | ||
35 | /* pre- and post- device scan functions */ | |
36 | .slave_alloc = NULL, | |
37 | .slave_configure = NULL, | |
38 | .slave_destroy = NULL, | |
39 | ||
40 | /* lots of sg segments can be handled */ | |
41 | .sg_tablesize = SG_ALL, | |
42 | ||
43 | /* use 32-bit address space for DMA */ | |
44 | .unchecked_isa_dma = FALSE, | |
45 | .highmem_io = FALSE, | |
46 | ||
47 | /* merge commands... this seems to help performance, but | |
48 | * periodically someone should test to see which setting is more | |
49 | * optimal. | |
50 | */ | |
51 | .use_clustering = TRUE, | |
52 | ||
53 | /* emulated HBA */ | |
54 | .emulated = TRUE, | |
55 | ||
56 | /* sorry, no BIOS to help us */ | |
57 | .bios_param = NULL, | |
58 | ||
59 | /* module management */ | |
60 | .module = THIS_MODULE | |
61 | }; | |
62 | ||
63 | /* For a device that is "Not Ready" */ | |
64 | unsigned char usb_stor_sense_notready[18] = { | |
65 | [0] = 0x70, /* current error */ | |
66 | [2] = 0x02, /* not ready */ | |
67 | [7] = 0x0a, /* additional length */ | |
68 | [12] = 0x04, /* not ready */ | |
69 | [13] = 0x03 /* manual intervention */ | |
70 | }; |