xref: /illumos-gate/usr/src/uts/common/sys/bustypes.h (revision 2d6eb4a5e0a47d30189497241345dc5466bb68ab)
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 (c) 1989-1998 by Sun Microsystems, Inc.
24  * All rights reserved.
25  */
26 
27 #ifndef _SYS_BUSTYPES_H
28 #define	_SYS_BUSTYPES_H
29 
30 #ifdef	__cplusplus
31 extern "C" {
32 #endif
33 
34 /*
35  * Defines for bus types.  These are magic cookies passed between drivers
36  * and their parents to describe their address space.  Configuration mechanisms
37  * use this as well.  Root nexus drivers on implementations using
38  * "generic-addressing" also use these to describe register properties.
39  * Generally, this will be non-self configuring architectures.
40  *
41  *
42  * On machines supporting "generic-addressing" in the root nexus,
43  * the generic cookies described in the bootom of the file are used
44  * to distinguish the spaces described by device regsiters.
45  *
46  * Sun machines generally support OBMEM and OBIO spaces.
47  */
48 
49 #define	SP_VIRTUAL	0x0100		/* virtual address */
50 #define	SP_OBMEM	0x0200		/* on board memory */
51 #define	SP_OBIO		0x0210		/* on board i/o */
52 
53 /*
54  * The following are some Cookie name/value suggestions...
55  * and are not necessarily supported at all (nexi for these devices
56  * must handle and convert any requests for these spaces.)
57  */
58 
59 #define	SP_SBUS		0x0400		/* SBus device bus */
60 #define	SB_XBOX		0x0500		/* XBox device bus */
61 
62 #define	SP_MBMEM	0x1000		/* MultiBus memory */
63 #define	SP_MBIO		0x1100		/* MultiBus IO */
64 
65 #define	SP_ATMEM	0x2000		/* AT Bus Memory */
66 #define	SP_ATIO		0x2100		/* AT IO */
67 
68 #define	SP_FBMEM	0x3000		/* FutureBus Memory */
69 #define	SP_FBIO		0x3100		/* FutureBus IO */
70 
71 #define	SP_UBMEM	0x4000		/* Arbitrary user bus memory space */
72 #define	SP_UBIO		0x4100		/* Arbitrary user bus IO space */
73 
74 #define	SP_INVALID	((unsigned)-1)	/* This value reserved */
75 
76 /*
77  * Anything in the range 0x4000 - 0x4FFF reserved for arbitrary 3rd party use.
78  */
79 
80 #ifdef	__cplusplus
81 }
82 #endif
83 
84 #endif /* _SYS_BUSTYPES_H */
85