diff options
Diffstat (limited to 'utils/scsi/rbscsi.h')
-rw-r--r-- | utils/scsi/rbscsi.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/utils/scsi/rbscsi.h b/utils/scsi/rbscsi.h index c7345a6cdf..322d94ec53 100644 --- a/utils/scsi/rbscsi.h +++ b/utils/scsi/rbscsi.h | |||
@@ -89,6 +89,31 @@ void rb_scsi_decode_sense(rb_scsi_device_t dev, void *sense, int sense_len); | |||
89 | /* close a device */ | 89 | /* close a device */ |
90 | void rb_scsi_close(rb_scsi_device_t dev); | 90 | void rb_scsi_close(rb_scsi_device_t dev); |
91 | 91 | ||
92 | /* SCSI device reported by rb_scsi_list() */ | ||
93 | struct rb_scsi_devent_t | ||
94 | { | ||
95 | /* device path to the raw SCSI device, typically: | ||
96 | * - Linux: /dev/sgX | ||
97 | * - Windows: TODO | ||
98 | * This path can be used directly with scsi_rb_open(), and is guaranteed to | ||
99 | * be valid. */ | ||
100 | char *scsi_path; | ||
101 | /* device path to the corresponding block device, if it exists, typically: | ||
102 | * - Linux: /dev/sdX | ||
103 | * - Windows: TODO | ||
104 | * If this path is not-NULL, then it can used directly with scsi_rb_open() */ | ||
105 | char *block_path; | ||
106 | /* various information about the device, can be NULL on error */ | ||
107 | char *vendor; | ||
108 | char *model; | ||
109 | char *rev; | ||
110 | }; | ||
111 | /* try to list all SCSI devices, returns a list of devices or NULL on error | ||
112 | * the list is terminated by an entry with scsi_path=NULL */ | ||
113 | struct rb_scsi_devent_t *rb_scsi_list(void); | ||
114 | /* free the list returned by rb_scsi_list */ | ||
115 | void rb_scsi_free_list(struct rb_scsi_devent_t *list); | ||
116 | |||
92 | #ifdef __cplusplus | 117 | #ifdef __cplusplus |
93 | } | 118 | } |
94 | #endif | 119 | #endif |