xref: /trueos/sys/sys/mach/device/device_types.defs (revision f400d8bd6cd915f42abab9ef3e7d34ff49bcb125)
1/*
2 * Copyright 1991-1998 by Open Software Foundation, Inc.
3 *              All Rights Reserved
4 *
5 * Permission to use, copy, modify, and distribute this software and
6 * its documentation for any purpose and without fee is hereby granted,
7 * provided that the above copyright notice appears in all copies and
8 * that both the copyright notice and this permission notice appear in
9 * supporting documentation.
10 *
11 * OSF DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
12 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
13 * FOR A PARTICULAR PURPOSE.
14 *
15 * IN NO EVENT SHALL OSF BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
16 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
17 * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
18 * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
19 * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
20 */
21/*
22 * MkLinux
23 */
24/* CMU_HIST */
25/*
26 * Revision 2.8  91/06/25  10:26:40  rpd
27 * 	Changed the port-based type declarations
28 * 	to use mach_port_t as the C type name.
29 * 	[91/05/23            rpd]
30 *
31 * Revision 2.7  91/05/14  15:43:07  mrt
32 * 	Correcting copyright
33 *
34 * Revision 2.6  91/03/16  14:42:54  rpd
35 * 	Added filter_t.
36 * 	[91/02/12            rpd]
37 *
38 * Revision 2.5  91/02/05  17:09:10  mrt
39 * 	Changed to new Mach copyright
40 * 	[91/01/31  17:28:27  mrt]
41 *
42 * Revision 2.4  90/06/02  14:47:48  rpd
43 * 	Converted to new IPC.
44 * 	[90/03/26  21:53:33  rpd]
45 *
46 * Revision 2.3  89/09/08  11:23:52  dbg
47 * 	Add device_t and translation functions.
48 * 	[89/08/01            dbg]
49 *
50 * Revision 2.2  89/08/05  16:06:27  rwd
51 * 	Added io_buf_ptr_inband_t
52 * 	[89/08/04            rwd]
53 *
54 * 	Created.
55 * 	[89/03/03            dbg]
56 *
57 */
58/* CMU_ENDHIST */
59/*
60 * Mach Operating System
61 * Copyright (c) 1991,1990,1989 Carnegie Mellon University
62 * All Rights Reserved.
63 *
64 * Permission to use, copy, modify and distribute this software and its
65 * documentation is hereby granted, provided that both the copyright
66 * notice and this permission notice appear in all copies of the
67 * software, derivative works or modified versions, and any portions
68 * thereof, and that both notices appear in supporting documentation.
69 *
70 * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
71 * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
72 * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
73 *
74 * Carnegie Mellon requests users of this software to return to
75 *
76 *  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
77 *  School of Computer Science
78 *  Carnegie Mellon University
79 *  Pittsburgh PA 15213-3890
80 *
81 * any improvements or extensions that they make and grant Carnegie Mellon
82 * the rights to redistribute these changes.
83 */
84/*
85 */
86/*
87 *	Author: David B. Golub, Carnegie Mellon University
88 *	Date: 	3/89
89 *
90 *	Common definitions for device interface types.
91 */
92
93#ifndef	_DEVICE_DEVICE_TYPES_DEFS_
94#define	_DEVICE_DEVICE_TYPES_DEFS_
95
96/*
97 *	Basic types
98 */
99
100#include <mach/std_types.defs>
101
102type recnum_t		= unsigned32;
103type dev_mode_t		= unsigned32;
104type dev_flavor_t	= unsigned32;
105type dev_name_t         = c_string[*:128];
106type dev_status_t	= array[*:1024] of int;
107type io_buf_len_t	= integer_t;
108type io_buf_ptr_t	= ^array[] of MACH_MSG_TYPE_INTEGER_8;
109type io_buf_ptr_inband_t= array[*:128] of char;
110type filter_t		= short;
111type filter_array_t	= array[*:64] of filter_t;
112
113type device_t = mach_port_t
114		ctype: mach_port_t
115#if	KERNEL_SERVER
116		intran: device_t dev_port_lookup(mach_port_t)
117		outtran: mach_port_t convert_device_to_port(device_t)
118		destructor: device_deallocate(device_t)
119#endif	/* KERNEL_SERVER */
120		;
121
122type io_done_queue_t	= mach_port_t
123		ctype: mach_port_t
124#if	KERNEL_SERVER
125		intran: io_done_queue_t io_done_queue_port_lookup(mach_port_t)
126		outtran: mach_port_t convert_io_done_queue_to_port(io_done_queue_t)
127#endif	KERNEL_SERVER
128		;
129
130import <device/device_types.h>;
131import <device/net_status.h>;
132
133#endif	/* _DEVICE_DEVICE_TYPES_DEFS_ */
134