xref: /titanic_52/usr/src/uts/common/sys/fm/io/ddi.h (revision b60f2a0b921611326383e4789e0874e9e8a2e708)
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 (the "License").
6  * You may not use this file except in compliance with the License.
7  *
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.
12  *
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]
18  *
19  * CDDL HEADER END
20  */
21 /*
22  * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
23  * Use is subject to license terms.
24  */
25 
26 #ifndef	_SYS_FM_IO_DDI_H
27 #define	_SYS_FM_IO_DDI_H
28 
29 #pragma ident	"%Z%%M%	%I%	%E% SMI"
30 
31 #ifdef	__cplusplus
32 extern "C" {
33 #endif
34 
35 #define	DDI_DVR_MAX_CLASS		32
36 
37 /* IO-specific FMA ereport class defintions */
38 #define	DDI_IO_CLASS			"io"
39 
40 /* leaf driver detected ereport definitions */
41 #define	DDI_FM_DEVICE			"device"
42 #define	DDI_FM_DEVICE_INVAL_STATE	"inval_state"
43 #define	DDI_FM_DEVICE_NO_RESPONSE	"no_response"
44 #define	DDI_FM_DEVICE_STALL		"stall"
45 #define	DDI_FM_DEVICE_BADINT_LIMIT	"badint_limit"
46 #define	DDI_FM_DEVICE_INTERN_CORR	"intern_corr"
47 #define	DDI_FM_DEVICE_INTERN_UNCORR	"intern_uncorr"
48 
49 /* service impact ereport definitions */
50 #define	DDI_FM_SERVICE_IMPACT		"service"
51 #define	DDI_FM_SERVICE_LOST		"lost"
52 #define	DDI_FM_SERVICE_DEGRADED		"degraded"
53 #define	DDI_FM_SERVICE_RESTORED		"restored"
54 #define	DDI_FM_SERVICE_UNAFFECTED	"unaffected"
55 
56 /* Driver defect ereport specifications */
57 #define	DVR_ERPT		"ddi."
58 #define	DVR_ECONTEXT		"context"	/* Invalid calling context */
59 #define	DVR_EINVAL		"einval"	/* Invalid calling semantic */
60 #define	DVR_EFMCAP		"fm-capability"	/* Improper FM capability */
61 #define	DVR_EVER		"version"	/* Invalid structure version */
62 
63 /* Required payload member names */
64 #define	DVR_NAME		"dvr-name"
65 #define	DVR_STACK		"dvr-stack"
66 #define	DVR_STACK_DEPTH		"dvr-stack-depth"
67 #define	DVR_ERR_SPECIFIC	"dvr-error-specific"
68 
69 #ifdef	__cplusplus
70 }
71 #endif
72 
73 #endif	/* _SYS_FM_IO_DDI_H */
74