summaryrefslogtreecommitdiff
path: root/extras/multipath/devinfo.h
diff options
context:
space:
mode:
authorchristophe.varoqui@free.fr <christophe.varoqui@free.fr>2004-02-13 00:53:10 -0800
committerGreg KH <gregkh@suse.de>2005-04-26 21:32:27 -0700
commit09b7985cf611df26fc756e0b8025a260fc4a4948 (patch)
tree325dc91c30ef2673b3ca0515081fe8966a4191bb /extras/multipath/devinfo.h
parentcbb576b91dea8bd84a9fdd147b6b4cbe757dd198 (diff)
[PATCH] more udev-016/extras/multipath
incremental to udev-016/extras/multipath-0.0.16.3, * add a GROUP_BY_SERIAL flag. This should be useful for controlers that activate their spare paths on simple IO submition with a penalty. The StorageWorks HW defaults to this mode, even if the MULTIBUS mode is OK. * remove unused sg_err.c * big restructuring : split devinfo.c from main.c. Export : * void basename (char *, char *); * int get_serial (int, char *); * int get_lun_strings (char *, char *, char *, char *); * int get_evpd_wwid(char *, char *); * long get_disk_size (char *); Now we see clearly what is expected from an external package like scsi_id. * stop passing struct env as param
Diffstat (limited to 'extras/multipath/devinfo.h')
-rw-r--r--extras/multipath/devinfo.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/extras/multipath/devinfo.h b/extras/multipath/devinfo.h
new file mode 100644
index 0000000000..53f2473027
--- /dev/null
+++ b/extras/multipath/devinfo.h
@@ -0,0 +1,19 @@
+#define INQUIRY_CMDLEN 6
+#define INQUIRY_CMD 0x12
+#define SENSE_BUFF_LEN 32
+#define DEF_TIMEOUT 60000
+#define RECOVERED_ERROR 0x01
+#define MX_ALLOC_LEN 255
+#define WWID_SIZE 33
+#define BLKGETSIZE _IO(0x12,96)
+
+/* exerpt from "sg_err.h" */
+#define SCSI_CHECK_CONDITION 0x2
+#define SCSI_COMMAND_TERMINATED 0x22
+#define SG_ERR_DRIVER_SENSE 0x08
+
+void basename (char *, char *);
+int get_serial (char *, char *);
+int get_lun_strings (char *, char *, char *, char *);
+int get_evpd_wwid(char *, char *);
+long get_disk_size (char *);