8322 nl: misleading-indentation
[unleashed/tickless.git] / usr / src / lib / fm / libfmd_snmp / common / fmd_snmp.h
blobb6f3a488a38b09432c0579f628c16c637f1bc956
1 /*
2 * CDDL HEADER START
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
19 * CDDL HEADER END
23 * Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
26 #ifndef _FMD_SNMP_H
27 #define _FMD_SNMP_H
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
34 * These values are derived from, and must remain consistent with, the
35 * MIB definitions in SUN-FM-MIB.
37 #define MODNAME_STR "sunFM"
38 #define SUNFM_OID 1, 3, 6, 1, 4, 1, 42, 2, 195, 1
40 #define SUNFMPROBLEMTABLE_OID SUNFM_OID, 1
42 #define SUNFMPROBLEM_COL_UUIDINDEX 1
43 #define SUNFMPROBLEM_COL_UUID 2
44 #define SUNFMPROBLEM_COL_CODE 3
45 #define SUNFMPROBLEM_COL_URL 4
46 #define SUNFMPROBLEM_COL_DIAGENGINE 5
47 #define SUNFMPROBLEM_COL_DIAGTIME 6
48 #define SUNFMPROBLEM_COL_SUSPECTCOUNT 7
50 #define SUNFMPROBLEM_COLMIN SUNFMPROBLEM_COL_UUID
51 #define SUNFMPROBLEM_COLMAX SUNFMPROBLEM_COL_SUSPECTCOUNT
53 #define SUNFMFAULTEVENTTABLE_OID SUNFM_OID, 2
55 #define SUNFMFAULTEVENT_COL_UUIDINDEX 1
56 #define SUNFMFAULTEVENT_COL_INDEX 2
57 #define SUNFMFAULTEVENT_COL_PROBLEMUUID 3
58 #define SUNFMFAULTEVENT_COL_CLASS 4
59 #define SUNFMFAULTEVENT_COL_CERTAINTY 5
60 #define SUNFMFAULTEVENT_COL_ASRU 6
61 #define SUNFMFAULTEVENT_COL_FRU 7
62 #define SUNFMFAULTEVENT_COL_RESOURCE 8
63 #define SUNFMFAULTEVENT_COL_STATUS 9
64 #define SUNFMFAULTEVENT_COL_LOCATION 10
66 #define SUNFMFAULTEVENT_COLMIN SUNFMFAULTEVENT_COL_PROBLEMUUID
67 #define SUNFMFAULTEVENT_COLMAX SUNFMFAULTEVENT_COL_LOCATION
69 #define SUNFMFAULTEVENT_STATE_OTHER 1
70 #define SUNFMFAULTEVENT_STATE_FAULTY 2
71 #define SUNFMFAULTEVENT_STATE_REMOVED 3
72 #define SUNFMFAULTEVENT_STATE_REPLACED 4
73 #define SUNFMFAULTEVENT_STATE_REPAIRED 5
74 #define SUNFMFAULTEVENT_STATE_ACQUITTED 6
76 #define SUNFMMODULETABLE_OID SUNFM_OID, 3
78 #define SUNFMMODULE_COL_INDEX 1
79 #define SUNFMMODULE_COL_NAME 2
80 #define SUNFMMODULE_COL_VERSION 3
81 #define SUNFMMODULE_COL_STATUS 4
82 #define SUNFMMODULE_COL_DESCRIPTION 5
84 #define SUNFMMODULE_COLMIN SUNFMMODULE_COL_NAME
85 #define SUNFMMODULE_COLMAX SUNFMMODULE_COL_DESCRIPTION
87 #define SUNFMMODULE_STATE_OTHER 1
88 #define SUNFMMODULE_STATE_ACTIVE 2
89 #define SUNFMMODULE_STATE_FAILED 3
91 #define SUNFMRESOURCECOUNT_OID SUNFM_OID, 4
93 #define SUNFMRESOURCETABLE_OID SUNFM_OID, 5
95 #define SUNFMRESOURCE_COL_INDEX 1
96 #define SUNFMRESOURCE_COL_FMRI 2
97 #define SUNFMRESOURCE_COL_STATUS 3
98 #define SUNFMRESOURCE_COL_DIAGNOSISUUID 4
100 #define SUNFMRESOURCE_COLMIN SUNFMRESOURCE_COL_FMRI
101 #define SUNFMRESOURCE_COLMAX SUNFMRESOURCE_COL_DIAGNOSISUUID
103 #define SUNFMRESOURCE_STATE_OTHER 1
104 #define SUNFMRESOURCE_STATE_OK 2
105 #define SUNFMRESOURCE_STATE_DEGRADED 3
106 #define SUNFMRESOURCE_STATE_UNKNOWN 4
107 #define SUNFMRESOURCE_STATE_FAULTED 5
109 #define SUNFMTRAPS_OID SUNFM_OID, 7, 0
110 #define SUNFMPROBLEMTRAP_OID SUNFMTRAPS_OID, 1
112 #define SNMP_URL_MSG "snmp-url"
115 * Definitions from SUN-IREPORT-MIB
117 #define SUNIREPORT_OID 1, 3, 6, 1, 4, 1, 42, 2, 197, 1
119 #define SUNIREPORTNOTIFICATIONENTRY SUNIREPORT_OID, 1
121 #define SUNIREPORTHOSTNAME_OID SUNIREPORTNOTIFICATIONENTRY, 1
122 #define SUNIREPORTMSGID_OID SUNIREPORTNOTIFICATIONENTRY, 2
123 #define SUNIREPORTDESCRIPTION_OID SUNIREPORTNOTIFICATIONENTRY, 3
124 #define SUNIREPORTTIME_OID SUNIREPORTNOTIFICATIONENTRY, 4
125 #define SUNIREPORTSMFFMRI_OID SUNIREPORTNOTIFICATIONENTRY, 5
126 #define SUNIREPORTSMFFROMSTATE_OID SUNIREPORTNOTIFICATIONENTRY, 6
127 #define SUNIREPORTSMFTOSTATE_OID SUNIREPORTNOTIFICATIONENTRY, 7
128 #define SUNIREPORTTRANSITIONREASON_OID SUNIREPORTNOTIFICATIONENTRY, 8
130 #define SUNIREPORTTRAPS_OID SUNIREPORT_OID, 2, 0
131 #define SUNIREPORTTRAP_OID SUNIREPORTTRAPS_OID, 1
134 extern int init_sunFM(void);
136 #ifdef __cplusplus
138 #endif
140 #endif /* _FMD_SNMP_H */