xref: /titanic_44/usr/src/uts/common/sys/sysevent/eventdefs.h (revision 1ae0874509b6811fdde1dfd46f0d93fd09867a3f)
1 /*
2  * CDDL HEADER START
3  *
4  * The contents of this file are subject to the terms of the
5  * Common Development and Distribution License, Version 1.0 only
6  * (the "License").  You may not use this file except in compliance
7  * with the License.
8  *
9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10  * or http://www.opensolaris.org/os/licensing.
11  * See the License for the specific language governing permissions
12  * and limitations under the License.
13  *
14  * When distributing Covered Code, include this CDDL HEADER in each
15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16  * If applicable, add the following below this CDDL HEADER, with the
17  * fields enclosed by brackets "[]" replaced with your own identifying
18  * information: Portions Copyright [yyyy] [name of copyright owner]
19  *
20  * CDDL HEADER END
21  */
22 /*
23  * Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
24  * Use is subject to license terms.
25  */
26 
27 #ifndef	_SYS_SYSEVENT_EVENTDEFS_H
28 #define	_SYS_SYSEVENT_EVENTDEFS_H
29 
30 #pragma ident	"%Z%%M%	%I%	%E% SMI"
31 
32 #ifdef	__cplusplus
33 extern "C" {
34 #endif
35 
36 /*
37  * eventdefs.h contains public definitions for sysevent types (classes
38  * and subclasses).  All additions/removal/changes are subject
39  * to PSARC approval.
40  */
41 
42 /* Sysevent Class definitions */
43 #define	EC_NONE		"EC_none"
44 #define	EC_PRIV		"EC_priv"
45 #define	EC_PLATFORM	"EC_platform"	/* events private to platform */
46 #define	EC_DR		"EC_dr"	/* Dynamic reconfiguration event class */
47 #define	EC_ENV		"EC_env"	/* Environmental monitor event class */
48 #define	EC_DOMAIN	"EC_domain"	/* Domain event class */
49 #define	EC_AP_DRIVER	"EC_ap_driver"	/* Alternate Pathing event class */
50 #define	EC_IPMP		"EC_ipmp"	/* IP Multipathing event class */
51 #define	EC_DEV_ADD	"EC_dev_add"	/* device add event class */
52 #define	EC_DEV_REMOVE	"EC_dev_remove"	/* device remove event class */
53 #define	EC_DEV_BRANCH	"EC_dev_branch"	/* device tree branch event class */
54 #define	EC_FM		"EC_fm"		/* FMA error report event */
55 
56 /*
57  * The following event class is reserved for exclusive use
58  * by Sun Cluster software.
59  */
60 #define	EC_CLUSTER	"EC_Cluster"
61 
62 /*
63  * The following classes are exclusively reserved for use by the
64  * Solaris Volume Manager (SVM)
65  */
66 #define	EC_SVM_CONFIG	"EC_SVM_Config"
67 #define	EC_SVM_STATE	"EC_SVM_State"
68 
69 /*
70  * EC_SVM_CONFIG subclass definitions - supporting attributes (name/value pairs)
71  * are found in sys/sysevent/svm.h
72  */
73 #define	ESC_SVM_CREATE		"ESC_SVM_Create"
74 #define	ESC_SVM_DELETE		"ESC_SVM_Delete"
75 #define	ESC_SVM_ADD		"ESC_SVM_Add"
76 #define	ESC_SVM_REMOVE		"ESC_SVM_Remove"
77 #define	ESC_SVM_REPLACE		"ESC_SVM_Replace"
78 #define	ESC_SVM_GROW		"ESC_SVM_Grow"
79 #define	ESC_SVM_RENAME_SRC	"ESC_SVM_Rename_Src"
80 #define	ESC_SVM_RENAME_DST	"ESC_SVM_Rename_Dst"
81 #define	ESC_SVM_MEDIATOR_ADD	"ESC_SVM_Mediator_Add"
82 #define	ESC_SVM_MEDIATOR_DELETE	"ESC_SVM_Mediator_Delete"
83 #define	ESC_SVM_HOST_ADD	"ESC_SVM_Host_Add"
84 #define	ESC_SVM_HOST_DELETE	"ESC_SVM_Host_Delete"
85 #define	ESC_SVM_DRIVE_ADD	"ESC_SVM_Drive_Add"
86 #define	ESC_SVM_DRIVE_DELETE	"ESC_SVM_Drive_Delete"
87 #define	ESC_SVM_DETACH		"ESC_SVM_Detach"
88 #define	ESC_SVM_DETACHING	"ESC_SVM_Detaching"
89 #define	ESC_SVM_ATTACH		"ESC_SVM_Attach"
90 #define	ESC_SVM_ATTACHING	"ESC_SVM_Attaching"
91 
92 /*
93  * EC_SVM_STATE subclass definitions - supporting attributes (name/value pairs)
94  * are found in sys/sysevent/svm.h
95  */
96 #define	ESC_SVM_INIT_START	"ESC_SVM_Init_Start"
97 #define	ESC_SVM_INIT_FAILED	"ESC_SVM_Init_Failed"
98 #define	ESC_SVM_INIT_FATAL	"ESC_SVM_Init_Fatal"
99 #define	ESC_SVM_INIT_SUCCESS	"ESC_SVM_Init_Success"
100 #define	ESC_SVM_IOERR		"ESC_SVM_Ioerr"
101 #define	ESC_SVM_ERRED		"ESC_SVM_Erred"
102 #define	ESC_SVM_LASTERRED	"ESC_SVM_Lasterred"
103 #define	ESC_SVM_OK		"ESC_SVM_Ok"
104 #define	ESC_SVM_ENABLE		"ESC_SVM_Enable"
105 #define	ESC_SVM_RESYNC_START	"ESC_SVM_Resync_Start"
106 #define	ESC_SVM_RESYNC_FAILED	"ESC_SVM_Resync_Failed"
107 #define	ESC_SVM_RESYNC_SUCCESS	"ESC_SVM_Resync_Success"
108 #define	ESC_SVM_RESYNC_DONE	"ESC_SVM_Resync_Done"
109 #define	ESC_SVM_HOTSPARED	"ESC_SVM_Hotspared"
110 #define	ESC_SVM_HS_FREED	"ESC_SVM_HS_Freed"
111 #define	ESC_SVM_HS_CHANGED	"ESC_SVM_HS_Changed"
112 #define	ESC_SVM_TAKEOVER	"ESC_SVM_Takeover"
113 #define	ESC_SVM_RELEASE		"ESC_SVM_Release"
114 #define	ESC_SVM_OPEN_FAIL	"ESC_SVM_Open_Fail"
115 #define	ESC_SVM_OFFLINE		"ESC_SVM_Offline"
116 #define	ESC_SVM_ONLINE		"ESC_SVM_Online"
117 #define	ESC_SVM_CHANGE		"ESC_SVM_Change"
118 #define	ESC_SVM_EXCHANGE	"ESC_SVM_Exchange"
119 #define	ESC_SVM_REGEN_START	"ESC_SVM_Regen_Start"
120 #define	ESC_SVM_REGEN_DONE	"ESC_SVM_Regen_Done"
121 #define	ESC_SVM_REGEN_FAILED	"ESC_SVM_Regen_Failed"
122 
123 /*
124  * EC_DR subclass definitions - supporting attributes (name/value pairs)
125  * are found in sys/sysevent/dr.h
126  */
127 
128 /* Attachment point state change */
129 #define	ESC_DR_AP_STATE_CHANGE	"ESC_dr_ap_state_change"
130 #define	ESC_DR_REQ		"ESC_dr_req"	/* Request DR */
131 
132 /*
133  * EC_ENV subclass definitions - supporting attributes (name/value pairs)
134  * are found in sys/sysevent/env.h
135  */
136 #define	ESC_ENV_TEMP	"ESC_env_temp"	/* Temperature change event subclass */
137 #define	ESC_ENV_FAN	"ESC_env_fan"	/* Fan status change event subclass */
138 #define	ESC_ENV_POWER	"ESC_env_power"	/* Power supply change event subclass */
139 #define	ESC_ENV_LED	"ESC_env_led"	/* LED change event subclass */
140 
141 /*
142  * EC_DOMAIN subclass definitions - supporting attributes (name/value pairs)
143  * are found in sys/sysevent/domain.h
144  */
145 
146 /* Domain state change */
147 #define	ESC_DOMAIN_STATE_CHANGE		"ESC_domain_state_change"
148 /* Domain loghost name change */
149 #define	ESC_DOMAIN_LOGHOST_CHANGE	"ESC_domain_loghost_change"
150 
151 /*
152  * EC_AP_DRIVER subclass defintions - supporting attributes (name/value pairs)
153  * are found in sys/sysevent/ap_driver.h
154  */
155 
156 /* Alternate Pathing path switch */
157 #define	ESC_AP_DRIVER_PATHSWITCH	"ESC_ap_driver_pathswitch"
158 /* Alternate Pathing database commit */
159 #define	ESC_AP_DRIVER_COMMIT		"ESC_ap_driver_commit"
160 /* Alternate Pathing physical path status change */
161 #define	ESC_AP_DRIVER_PHYS_PATH_STATUS_CHANGE	\
162 	"ESC_ap_driver_phys_path_status_change"
163 
164 /*
165  * EC_IPMP subclass defintions - supporting attributes (name/value pairs)
166  * are found in sys/sysevent/ipmp.h
167  */
168 
169 /* IPMP group has changed state */
170 #define	ESC_IPMP_GROUP_STATE		"ESC_ipmp_group_state"
171 
172 /* IPMP group has been created or removed */
173 #define	ESC_IPMP_GROUP_CHANGE		"ESC_ipmp_group_change"
174 
175 /* IPMP group has had an interface added or removed */
176 #define	ESC_IPMP_GROUP_MEMBER_CHANGE	"ESC_ipmp_group_member_change"
177 
178 /* Interface within an IPMP group has changed state or type */
179 #define	ESC_IPMP_IF_CHANGE		"ESC_ipmp_if_change"
180 
181 
182 /*
183  * EC_DEV_ADD and EC_DEV_REMOVE subclass defintions - supporting attributes
184  * (name/value pairs) are found in sys/sysevent/dev.h
185  */
186 #define	ESC_DISK	"disk"		/* disk device */
187 #define	ESC_NETWORK	"network"	/* network interface */
188 
189 /*
190  * EC_DEV_BRANCH subclass defintions - supporting attributes (name/value pairs)
191  * are found in sys/sysevent/dev.h
192  */
193 
194 /* device tree branch added */
195 #define	ESC_DEV_BRANCH_ADD	"ESC_dev_branch_add"
196 
197 /* device tree branch removed */
198 #define	ESC_DEV_BRANCH_REMOVE	"ESC_dev_branch_remove"
199 
200 /* FMA Fault and Error event protocol subclass */
201 #define	ESC_FM_ERROR		"ESC_FM_error"
202 #define	ESC_FM_ERROR_REPLAY	"ESC_FM_error_replay"
203 #ifdef	__cplusplus
204 }
205 #endif
206 
207 #endif /* _SYS_SYSEVENT_EVENTDEFS_H */
208