xref: /illumos-gate/usr/src/stand/sys/saio.h (revision 657a8c206b913d1ee578fd725f0b25eca5b77253)
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_SAIO_H
28 #define	_SYS_SAIO_H
29 
30 #pragma ident	"%Z%%M%	%I%	%E% SMI" /* from SunOS 4.1 */
31 
32 /*
33  * NOTE: This header file is a vestige from a previous era.  The RESOURCES
34  *	 enum should be move somewhere more appropriate (with an accompanying
35  *	 proper prototype for resalloc()) and this should be removed.
36  */
37 
38 #include <sys/types.h>
39 #include <stdio.h>
40 
41 #ifdef __cplusplus
42 extern "C" {
43 #endif
44 
45 /*
46  * Types of resources that can be allocated by resalloc().
47  */
48 enum RESOURCES {
49 	RES_MAINMEM,		/* Main memory, accessible to CPU */
50 	RES_RAWVIRT,		/* Raw addr space that can be mapped */
51 	RES_DMAMEM,		/* Memory acc. by CPU and by all DMA I/O */
52 	RES_DMAVIRT,		/* Raw addr space accessible by DMA I/O */
53 	RES_PHYSICAL,		/* Physical address */
54 	RES_VIRTALLOC,		/* Virtual addresses used */
55 	RES_BOOTSCRATCH,	/* Memory <4MB used only by boot. */
56 #ifdef	__sparc
57 	RES_CHILDVIRT,		/* Virt anywhere, phys > 4MB */
58 	RES_BOOTSCRATCH_NOFAIL
59 #else
60 	RES_CHILDVIRT		/* Virt anywhere, phys > 4MB */
61 #endif
62 };
63 
64 #ifdef __cplusplus
65 }
66 #endif
67 
68 #endif /* _SYS_SAIO_H */
69