]>
Commit | Line | Data |
---|---|---|
832b75ed GG |
1 | /* |
2 | * extern.h | |
3 | * | |
4 | * Home page of code is: http://smartmontools.sourceforge.net | |
5 | * | |
a37e7145 | 6 | * Copyright (C) 2002-7 Bruce Allen <smartmontools-support@lists.sourceforge.net> |
832b75ed GG |
7 | * Copyright (C) 1999-2000 Michael Cornwell <cornwell@acm.org> |
8 | * | |
9 | * This program is free software; you can redistribute it and/or modify | |
10 | * it under the terms of the GNU General Public License as published by | |
11 | * the Free Software Foundation; either version 2, or (at your option) | |
12 | * any later version. | |
13 | * | |
14 | * You should have received a copy of the GNU General Public License | |
15 | * (for example COPYING); if not, write to the Free | |
16 | * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | |
17 | * | |
18 | * This code was originally developed as a Senior Thesis by Michael Cornwell | |
19 | * at the Concurrent Systems Laboratory (now part of the Storage Systems | |
20 | * Research Center), Jack Baskin School of Engineering, University of | |
21 | * California, Santa Cruz. http://ssrc.soe.ucsc.edu/ | |
22 | * | |
23 | */ | |
24 | ||
25 | #ifndef EXTERN_H_ | |
26 | #define EXTERN_H_ | |
27 | ||
a37e7145 | 28 | #define EXTERN_H_CVSID "$Id: extern.h,v 1.53 2007/07/21 20:59:41 chrfranke Exp $\n" |
832b75ed | 29 | |
a37e7145 | 30 | // Possible values for fixfirmwarebug. If user has NOT specified -F at |
832b75ed GG |
31 | // all, then value is 0. |
32 | #define FIX_NOTSPECIFIED 0 | |
33 | #define FIX_NONE 1 | |
34 | #define FIX_SAMSUNG 2 | |
35 | #define FIX_SAMSUNG2 3 | |
a37e7145 | 36 | #define FIX_SAMSUNG3 4 |
832b75ed GG |
37 | |
38 | // Block used for global control/communications. If you need more | |
39 | // global variables, this should be the only place that you need to | |
40 | // add them. | |
41 | typedef struct smartmonctrl_s { | |
42 | // spans for selective self-test | |
43 | uint64_t smartselectivespan[5][2]; | |
a37e7145 GG |
44 | // mode for each span, see SEL_* in utility.h |
45 | char smartselectivemode[5]; | |
832b75ed GG |
46 | // number of spans |
47 | int smartselectivenumspans; | |
48 | int testcase; | |
a37e7145 | 49 | unsigned scttempint; |
832b75ed GG |
50 | // one plus time in minutes to wait after powerup before restarting |
51 | // interrupted offline scan after selective self-test. | |
52 | int pendingtime; | |
53 | // run offline scan after selective self-test. 0: don't change, 1: | |
54 | // turn off scan after selective self-test, 2: turn on scan after | |
55 | // selective self-test. | |
56 | unsigned char scanafterselect; | |
4d59bff9 GG |
57 | // skip check, if disk in idle or standby mode |
58 | unsigned char powermode; | |
832b75ed GG |
59 | unsigned char driveinfo; |
60 | unsigned char checksmart; | |
61 | unsigned char smartvendorattrib; | |
62 | unsigned char generalsmartvalues; | |
63 | unsigned char smartlogdirectory; | |
64 | unsigned char smartselftestlog; | |
65 | unsigned char selectivetestlog; | |
66 | unsigned char smarterrorlog; | |
4d59bff9 | 67 | unsigned char smartbackgroundlog; |
a37e7145 GG |
68 | unsigned char scttempsts; |
69 | unsigned char scttemphist; | |
70 | unsigned char scttempintp; | |
832b75ed GG |
71 | unsigned char smartdisable; |
72 | unsigned char smartenable; | |
73 | unsigned char smartstatus; | |
74 | unsigned char smartexeoffimmediate; | |
75 | unsigned char smartshortselftest; | |
76 | unsigned char smartextendselftest; | |
77 | unsigned char smartconveyanceselftest; | |
78 | unsigned char smartselectiveselftest; | |
79 | unsigned char smartshortcapselftest; | |
80 | unsigned char smartextendcapselftest; | |
81 | unsigned char smartconveyancecapselftest; | |
82 | unsigned char smartselectivecapselftest; | |
83 | unsigned char smartselftestabort; | |
84 | unsigned char smartautoofflineenable; | |
85 | unsigned char smartautoofflinedisable; | |
86 | unsigned char smartautosaveenable; | |
87 | unsigned char smartautosavedisable; | |
88 | unsigned char printing_switchable; | |
89 | unsigned char dont_print; | |
a37e7145 | 90 | unsigned char dont_print_serial; |
832b75ed GG |
91 | unsigned char permissive; |
92 | unsigned char conservative; | |
93 | unsigned char checksumfail; | |
94 | unsigned char checksumignore; | |
95 | unsigned char reportataioctl; | |
96 | unsigned char reportscsiioctl; | |
97 | unsigned char fixfirmwarebug; | |
a37e7145 | 98 | unsigned char fixswappedid; |
4d59bff9 GG |
99 | unsigned char satpassthrulen; |
100 | // Controller type (device type) has been specified explicitly | |
101 | unsigned char controller_explicit; | |
832b75ed GG |
102 | // 3Ware controller type, but also extensible to other contoller types |
103 | unsigned char controller_type; | |
104 | // For 3Ware controllers, nonzero value is 1 plus the disk number | |
105 | unsigned char controller_port; | |
4d59bff9 GG |
106 | // combined controller/channle/pmport for highpoint rocketraid controller |
107 | unsigned char hpt_data[3]; | |
832b75ed GG |
108 | unsigned char ignorepresets; |
109 | unsigned char showpresets; | |
110 | // The i'th entry in this array will modify the printed meaning of | |
111 | // the i'th SMART attribute. The default definitions of the | |
112 | // Attributes are obtained by having the array be all zeros. If | |
113 | // attributedefs[i] is nonzero, it means that the i'th attribute has | |
114 | // a non-default meaning. See the ataPrintSmartAttribName and | |
115 | // and parse_attribute_def functions. | |
116 | unsigned char attributedefs[256]; | |
117 | } smartmonctrl; | |
118 | ||
119 | #endif |