]>
Commit | Line | Data |
---|---|---|
c521693b GKH |
1 | /* |
2 | * scsi_id.h | |
3 | * | |
4 | * General defines and such for scsi_id | |
5 | * | |
6 | * Copyright (C) IBM Corp. 2003 | |
7 | * | |
3d94fb87 KS |
8 | * This program is free software; you can redistribute it and/or modify it |
9 | * under the terms of the GNU General Public License as published by the | |
10 | * Free Software Foundation version 2 of the License. | |
c521693b GKH |
11 | */ |
12 | ||
6ecd4d1e | 13 | #define MAX_PATH_LEN 512 |
c521693b | 14 | |
e996d978 PM |
15 | /* |
16 | * MAX_ATTR_LEN: maximum length of the result of reading a sysfs | |
17 | * attribute. | |
18 | */ | |
19 | #define MAX_ATTR_LEN 256 | |
20 | ||
1bed1db4 PM |
21 | /* |
22 | * MAX_SERIAL_LEN: the maximum length of the serial number, including | |
23 | * added prefixes such as vendor and product (model) strings. | |
24 | */ | |
062db23d | 25 | #define MAX_SERIAL_LEN 256 |
1bed1db4 PM |
26 | |
27 | /* | |
28 | * MAX_BUFFER_LEN: maximum buffer size and line length used while reading | |
29 | * the config file. | |
30 | */ | |
31 | #define MAX_BUFFER_LEN 256 | |
32 | ||
87cf9f5a HR |
33 | extern int scsi_std_inquiry(struct sysfs_device *dev_scsi, const char *devname, |
34 | char *vendor, char *model, char *rev, char *type); | |
1aa1e248 | 35 | extern int scsi_get_serial (struct sysfs_device *dev_scsi, const char *devname, |
11678eff | 36 | int page_code, char *serial, char *serial_short, int len); |
50be1401 EG |
37 | |
38 | /* | |
39 | * Page code values. | |
40 | */ | |
41 | enum page_code { | |
42 | PAGE_83_PRE_SPC3 = -0x83, | |
43 | PAGE_UNSPECIFIED = 0x00, | |
44 | PAGE_80 = 0x80, | |
45 | PAGE_83 = 0x83, | |
46 | }; |