]> git.saurik.com Git - apple/xnu.git/blame - osfmk/ppc/misc_protos.h
xnu-792.6.22.tar.gz
[apple/xnu.git] / osfmk / ppc / misc_protos.h
CommitLineData
1c79356b 1/*
91447636 2 * Copyright (c) 2000-2004 Apple Computer, Inc. All rights reserved.
1c79356b
A
3 *
4 * @APPLE_LICENSE_HEADER_START@
5 *
e5568f75
A
6 * The contents of this file constitute Original Code as defined in and
7 * are subject to the Apple Public Source License Version 1.1 (the
8 * "License"). You may not use this file except in compliance with the
9 * License. Please obtain a copy of the License at
10 * http://www.apple.com/publicsource and read it before using this file.
1c79356b 11 *
e5568f75
A
12 * This Original Code and all software distributed under the License are
13 * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
1c79356b
A
14 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
15 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
e5568f75
A
16 * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
17 * License for the specific language governing rights and limitations
18 * under the License.
1c79356b
A
19 *
20 * @APPLE_LICENSE_HEADER_END@
21 */
22/*
23 * @OSF_COPYRIGHT@
24 */
25
26#ifndef _PPC_MISC_PROTOS_H_
27#define _PPC_MISC_PROTOS_H_
28
1c79356b
A
29#include <debug.h>
30#include <mach_kdb.h>
31#include <mach_kgdb.h>
32#include <mach_kdp.h>
33#include <mach_debug.h>
34
1c79356b 35#include <ppc/boot.h>
91447636 36#include <kern/thread.h>
1c79356b
A
37#include <mach/vm_types.h>
38#include <kern/cpu_data.h>
91447636 39#include <ppc/savearea.h>
1c79356b
A
40#include <mach/ppc/thread_status.h>
41#include <stdarg.h>
91447636 42#include <string.h>
1c79356b 43
91447636
A
44/* uncached-safe */
45extern void bzero_nc(
46 char *buf,
47 int size);
1c79356b 48
91447636
A
49/* uncached-safe */
50extern void bcopy_nc(
51 char *from,
52 char *to,
53 int size);
1c79356b 54
91447636
A
55/* Physical to physical copy (ints must be disabled) */
56extern void bcopy_phys(
57 addr64_t from,
58 addr64_t to,
59 int size);
1c79356b 60
91447636
A
61/* Physical to physical copy virtually (ints must be disabled) */
62extern void bcopy_physvir_32(
63 addr64_t from,
64 addr64_t to,
65 int size);
1c79356b 66
91447636
A
67extern void phys_copy(
68 addr64_t from,
69 addr64_t to,
70 vm_size_t size);
55e303ae 71
91447636
A
72extern void machine_conf(
73 void);
1c79356b 74
91447636
A
75extern void machine_startup(
76 boot_args *args);
1c79356b 77
91447636
A
78extern void ppc_vm_init(
79 uint64_t ppc_mem_size,
80 boot_args *args);
1c79356b 81
91447636
A
82extern int ppcNull(
83 struct savearea *asavearea);
1c79356b 84
91447636
A
85extern int ppcNullinst(
86 struct savearea *asavearea);
1c79356b 87
91447636
A
88extern void disable_bluebox_internal(
89 thread_t act);
1c79356b 90
91447636
A
91extern uint64_t hid0get64(
92 void);
9bccf70c 93
91447636
A
94extern void hid5set64(
95 uint64_t);
55e303ae 96
91447636
A
97extern void Load_context(
98 thread_t th);
1c79356b 99
91447636
A
100extern thread_t Switch_context(
101 thread_t old,
102 void (*cont)(void),
103 thread_t new);
104
105extern void fpu_save(
106 struct facility_context *fpu_fc);
107
108extern void vec_save(
109 struct facility_context *vec_fc);
110
111extern void toss_live_fpu(
112 struct facility_context *fpu_fc);
113
114extern void toss_live_vec(
115 struct facility_context *vec_fc);
116
117extern struct savearea *enterDebugger(
118 unsigned int trap,
119 struct savearea *state,
120 unsigned int dsisr);
121
122extern void draw_panic_dialog(
123 void);
1c79356b
A
124
125#ifdef DEBUG
126#define DPRINTF(x) { printf("%s : ",__FUNCTION__);printf x; }
127#endif /* DEBUG */
128
129#if MACH_ASSERT
91447636
A
130extern void dump_thread(
131 thread_t th);
1c79356b
A
132#endif
133
1c79356b 134#endif /* _PPC_MISC_PROTOS_H_ */