xref: /titanic_50/usr/src/uts/common/sys/nexusdefs.h (revision 7a286c471efbab8562f7655a82931904703fffe0)
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 2005 Sun Microsystems, Inc.  All rights reserved.
24  * Use is subject to license terms.
25  */
26 
27 #ifndef	_SYS_NEXUSDEFS_H
28 #define	_SYS_NEXUSDEFS_H
29 
30 #pragma ident	"%Z%%M%	%I%	%E% SMI"
31 
32 #ifdef	__cplusplus
33 extern "C" {
34 #endif
35 
36 /*
37  * Bus Nexus Control Operations
38  */
39 
40 typedef enum {
41 	DDI_CTLOPS_DMAPMAPC,
42 	DDI_CTLOPS_INITCHILD,
43 	DDI_CTLOPS_UNINITCHILD,
44 	DDI_CTLOPS_REPORTDEV,
45 	DDI_CTLOPS_REPORTINT,
46 	DDI_CTLOPS_REGSIZE,
47 	DDI_CTLOPS_NREGS,
48 	DDI_CTLOPS_RESERVED0,	/* Originally DDI_CTLOPS_NINTRS, obsolete */
49 	DDI_CTLOPS_SIDDEV,
50 	DDI_CTLOPS_SLAVEONLY,
51 	DDI_CTLOPS_AFFINITY,
52 	DDI_CTLOPS_IOMIN,
53 	DDI_CTLOPS_PTOB,
54 	DDI_CTLOPS_BTOP,
55 	DDI_CTLOPS_BTOPR,
56 	DDI_CTLOPS_RESERVED1,	/* Originally DDI_CTLOPS_POKE_INIT, obsolete */
57 	DDI_CTLOPS_RESERVED2,	/* Originally DDI_CTLOPS_POKE_FLUSH, obsolete */
58 	DDI_CTLOPS_RESERVED3,	/* Originally DDI_CTLOPS_POKE_FINI, obsolete */
59 	DDI_CTLOPS_RESERVED4, /* Originally DDI_CTLOPS_INTR_HILEVEL, obsolete */
60 	DDI_CTLOPS_RESERVED5, /* Originally DDI_CTLOPS_XLATE_INTRS, obsolete */
61 	DDI_CTLOPS_DVMAPAGESIZE,
62 	DDI_CTLOPS_POWER,
63 	DDI_CTLOPS_ATTACH,
64 	DDI_CTLOPS_DETACH,
65 	DDI_CTLOPS_QUIESCE,
66 	DDI_CTLOPS_UNQUIESCE,
67 	DDI_CTLOPS_PEEK,
68 	DDI_CTLOPS_POKE
69 } ddi_ctl_enum_t;
70 
71 /*
72  * For source compatibility, we define the following obsolete code:
73  * Do NOT use this, use the real constant name.
74  */
75 #define	DDI_CTLOPS_REMOVECHILD	DDI_CTLOPS_UNINITCHILD
76 
77 /*
78  * Bus config ops
79  */
80 typedef enum {
81 	BUS_ENUMERATE = 0,
82 	BUS_CONFIG_ONE,
83 	BUS_CONFIG_ALL,
84 	BUS_CONFIG_AP,
85 	BUS_CONFIG_DRIVER,
86 	BUS_UNCONFIG_ONE,
87 	BUS_UNCONFIG_DRIVER,
88 	BUS_UNCONFIG_ALL,
89 	BUS_UNCONFIG_AP,
90 	BUS_CONFIG_OBP_ARGS
91 } ddi_bus_config_op_t;
92 
93 /*
94  * Bus Power Operations
95  */
96 typedef enum {
97 	BUS_POWER_CHILD_PWRCHG = 0,
98 	BUS_POWER_NEXUS_PWRUP,
99 	BUS_POWER_PRE_NOTIFICATION,
100 	BUS_POWER_POST_NOTIFICATION,
101 	BUS_POWER_HAS_CHANGED,
102 	BUS_POWER_NOINVOL
103 } pm_bus_power_op_t;
104 
105 #ifdef	__cplusplus
106 }
107 #endif
108 
109 #endif	/* _SYS_NEXUSDEFS_H */
110