1 /*
2 * Mach Operating System
3 * Copyright (c) 1993,1992,1991,1990,1989 Carnegie Mellon University
4 * All Rights Reserved.
5 *
6 * Permission to use, copy, modify and distribute this software and its
7 * documentation is hereby granted, provided that both the copyright
8 * notice and this permission notice appear in all copies of the
9 * software, derivative works or modified versions, and any portions
10 * thereof, and that both notices appear in supporting documentation.
11 *
12 * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
13 * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
14 * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
15 *
16 * Carnegie Mellon requests users of this software to return to
17 *
18 * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
19 * School of Computer Science
20 * Carnegie Mellon University
21 * Pittsburgh PA 15213-3890
22 *
23 * any improvements or extensions that they make and grant Carnegie Mellon
24 * the rights to redistribute these changes.
25 */
26 /*
27 * HISTORY
28 * $Log: device_init.c,v $
29 * Revision 2.15 93/11/17 16:32:10 dbg
30 * Cleaned up lint.
31 * [93/06/16 dbg]
32 *
33 * Revision 2.14 93/02/01 09:46:41 danner
34 * Added call to chario_init.
35 * [93/01/25 danner]
36 *
37 * Revision 2.13 92/08/03 17:33:28 jfriedl
38 * removed silly prototypes
39 * [92/08/02 jfriedl]
40 *
41 * Revision 2.12 92/05/21 17:09:11 jfriedl
42 * tried prototypes.
43 * [92/05/20 jfriedl]
44 *
45 * Revision 2.11 91/08/03 18:17:30 jsb
46 * Removed NORMA hooks.
47 * [91/07/17 23:06:14 jsb]
48 *
49 * Revision 2.10 91/06/17 15:43:55 jsb
50 * Renamed NORMA conditionals.
51 * [91/06/17 09:58:32 jsb]
52 *
53 * Revision 2.9 91/06/06 17:03:56 jsb
54 * NORMA_BOOT: master_device_port initialization change.
55 * [91/05/13 16:51:18 jsb]
56 *
57 * Revision 2.8 91/05/14 15:42:08 mrt
58 * Correcting copyright
59 *
60 * Revision 2.7 91/03/16 14:42:48 rpd
61 * Changed net_rcv_msg_thread to net_thread.
62 * [91/02/13 rpd]
63 *
64 * Revision 2.6 91/02/05 17:08:54 mrt
65 * Changed to new Mach copyright
66 * [91/01/31 17:27:56 mrt]
67 *
68 * Revision 2.5 90/12/14 10:59:35 jsb
69 * Added NORMA_BOOT support.
70 * [90/12/13 21:06:19 jsb]
71 *
72 * Revision 2.4 90/08/27 21:55:11 dbg
73 * Removed call to cinit.
74 * [90/07/09 dbg]
75 *
76 * Revision 2.3 90/06/02 14:47:29 rpd
77 * Converted to new IPC.
78 * [90/03/26 21:51:02 rpd]
79 *
80 * Revision 2.2 89/09/08 11:23:33 dbg
81 * Created.
82 * [89/08/02 dbg]
83 *
84 */
85 /*
86 * Author: David B. Golub, Carnegie Mellon University
87 * Date: 8/89
88 *
89 * Initialize device service as part of kernel task.
90 */
91 #include <ipc/ipc_port.h>
92 #include <ipc/ipc_space.h>
93 #include <kern/task.h>
94
95 #include <device/device_types.h>
96 #include <device/device_port.h>
97
98
99
100 extern void ds_init(void);
101 extern void dev_lookup_init(void);
102 extern void net_io_init(void);
103 extern void device_pager_init(void);
104 extern void chario_init(void);
105
106 extern no_return io_done_thread(void);
107 extern no_return net_thread(void);
108
109 ipc_port_t master_device_port;
110
111 void
112 device_service_create(void)
113 {
114 master_device_port = ipc_port_alloc_kernel();
115 if (master_device_port == IP_NULL)
116 panic("can't allocate master device port");
117
118 ds_init();
119 dev_lookup_init();
120 net_io_init();
121 device_pager_init();
122 chario_init();
123
124 (void) kernel_thread(kernel_task, io_done_thread, 0);
125 (void) kernel_thread(kernel_task, net_thread, 0);
126 }
Cache object: 0aebd914f83554fbf5ddc12d0d4e1edb
|