]>
git.saurik.com Git - apple/xnu.git/blob - osfmk/kern/misc_protos.h
edd4eadcdb98ce4e4c1e3a5e10f0b2343a714b31
2 * Copyright (c) 2000-2004 Apple Computer, Inc. All rights reserved.
4 * @APPLE_LICENSE_HEADER_START@
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. Please obtain a copy of the License at
10 * http://www.opensource.apple.com/apsl/ and read it before using this
13 * The Original Code and all software distributed under the License are
14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
18 * Please see the License for the specific language governing rights and
19 * limitations under the License.
21 * @APPLE_LICENSE_HEADER_END@
27 #ifndef _MISC_PROTOS_H_
28 #define _MISC_PROTOS_H_
32 #include <machine/setjmp.h>
33 #include <mach/boolean.h>
34 #include <mach/message.h>
35 #include <mach/machine/vm_types.h>
36 #include <ipc/ipc_types.h>
37 #include <kern/debug.h>
39 /* Set a bit in a bit array */
44 /* Clear a bit in a bit array */
49 /* Find the first set bit in a bit array */
56 * Test if indicated bit is set in bit string.
62 /* Move arbitrarily-aligned data from a user space to kernel space */
64 const user_addr_t user_addr
,
68 /* Move a NUL-terminated string from a user space to kernel space */
70 const user_addr_t user_addr
,
75 /* Move arbitrarily-aligned data from a user space to kernel space */
77 const user_addr_t user_addr
,
79 mach_msg_size_t nbytes
);
81 /* Move arbitrarily-aligned data from a kernel space to user space */
83 const char *kernel_addr
,
84 user_addr_t user_addr
,
87 /* Move arbitrarily-aligned data from a kernel space to user space */
88 extern int copyoutmsg(
89 const char *kernel_addr
,
90 user_addr_t user_addr
,
91 mach_msg_size_t nbytes
);
93 extern int sscanf(const char *input
, const char *fmt
, ...);
95 extern integer_t
sprintf(char *buf
, const char *fmt
, ...);
97 extern void printf(const char *format
, ...);
99 extern void dbugprintf(const char *format
, ...);
101 extern void kdp_printf(const char *format
, ...);
103 extern void printf_init(void);
105 extern void log(int level
, char *fmt
, ...);
109 register const char *fmt
,
115 register const char *fmt
,
117 void (*putc
)(int, void *),
121 extern void safe_gets(
125 extern void cnputcusr(char);
127 extern void conslog_putc(char);
129 extern void consdebug_putc(char);
131 extern void cnputc(char);
133 extern int cngetc(void);
135 extern int cnmaygetc(void);
144 extern void bootstrap_create(void);
146 extern void Debugger(
147 const char * message
);
153 extern void norma_bootstrap(void);
156 extern boolean_t
no_bootstrap_task(void);
157 extern ipc_port_t
get_root_master_device_port(void);
160 extern kern_return_t
kernel_set_special_port(
161 host_priv_t host_priv
,
165 #endif /* _MISC_PROTOS_H_ */