xref: /onnv-gate/usr/src/lib/fm/libfmd_snmp/common/problem.h (revision 1303:6e5751a0b831)
1*1303Swesolows /*
2*1303Swesolows  * CDDL HEADER START
3*1303Swesolows  *
4*1303Swesolows  * The contents of this file are subject to the terms of the
5*1303Swesolows  * Common Development and Distribution License (the "License").
6*1303Swesolows  * You may not use this file except in compliance with the License.
7*1303Swesolows  *
8*1303Swesolows  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*1303Swesolows  * or http://www.opensolaris.org/os/licensing.
10*1303Swesolows  * See the License for the specific language governing permissions
11*1303Swesolows  * and limitations under the License.
12*1303Swesolows  *
13*1303Swesolows  * When distributing Covered Code, include this CDDL HEADER in each
14*1303Swesolows  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*1303Swesolows  * If applicable, add the following below this CDDL HEADER, with the
16*1303Swesolows  * fields enclosed by brackets "[]" replaced with your own identifying
17*1303Swesolows  * information: Portions Copyright [yyyy] [name of copyright owner]
18*1303Swesolows  *
19*1303Swesolows  * CDDL HEADER END
20*1303Swesolows  */
21*1303Swesolows 
22*1303Swesolows /*
23*1303Swesolows  * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
24*1303Swesolows  * Use is subject to license terms.
25*1303Swesolows  */
26*1303Swesolows 
27*1303Swesolows #ifndef	_PROBLEM_H
28*1303Swesolows #define	_PROBLEM_H
29*1303Swesolows 
30*1303Swesolows #pragma ident	"%Z%%M%	%I%	%E% SMI"
31*1303Swesolows 
32*1303Swesolows #ifdef	__cplusplus
33*1303Swesolows extern "C" {
34*1303Swesolows #endif
35*1303Swesolows 
36*1303Swesolows #include <sys/types.h>
37*1303Swesolows #include <libuutil.h>
38*1303Swesolows #include <libnvpair.h>
39*1303Swesolows 
40*1303Swesolows typedef struct sunFmProblem_data {
41*1303Swesolows 	int		d_valid;
42*1303Swesolows 	uu_avl_node_t	d_uuid_avl;
43*1303Swesolows 	const char	*d_aci_uuid;
44*1303Swesolows 	const char	*d_aci_code;
45*1303Swesolows 	const char	*d_aci_url;
46*1303Swesolows 	const char	*d_diag_engine;
47*1303Swesolows 	struct timeval	d_diag_time;
48*1303Swesolows 	ulong_t		d_nsuspects;
49*1303Swesolows 	nvlist_t	**d_suspects;
50*1303Swesolows 	nvlist_t	*d_aci_event;
51*1303Swesolows } sunFmProblem_data_t;
52*1303Swesolows 
53*1303Swesolows typedef struct sunFmProblem_update_ctx {
54*1303Swesolows 	const char	*uc_host;
55*1303Swesolows 	uint32_t	uc_prog;
56*1303Swesolows 	int		uc_version;
57*1303Swesolows 	const char	*uc_index;
58*1303Swesolows 	uint32_t	uc_type;
59*1303Swesolows } sunFmProblem_update_ctx_t;
60*1303Swesolows 
61*1303Swesolows typedef nvlist_t sunFmFaultEvent_data_t;
62*1303Swesolows 
63*1303Swesolows int sunFmProblemTable_init(void);
64*1303Swesolows int sunFmFaultEventTable_init(void);
65*1303Swesolows 
66*1303Swesolows #ifdef	__cplusplus
67*1303Swesolows }
68*1303Swesolows #endif
69*1303Swesolows 
70*1303Swesolows #endif	/* _PROBLEM_H */
71