]> git.saurik.com Git - apple/xnu.git/blob - osfmk/mach/ppc/syscall_sw.h
xnu-517.tar.gz
[apple/xnu.git] / osfmk / mach / ppc / syscall_sw.h
1 /*
2 * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
3 *
4 * @APPLE_LICENSE_HEADER_START@
5 *
6 * Copyright (c) 1999-2003 Apple Computer, Inc. All Rights Reserved.
7 *
8 * This file contains Original Code and/or Modifications of Original Code
9 * as defined in and that are subject to the Apple Public Source License
10 * Version 2.0 (the 'License'). You may not use this file except in
11 * compliance with the License. Please obtain a copy of the License at
12 * http://www.opensource.apple.com/apsl/ and read it before using this
13 * file.
14 *
15 * The Original Code and all software distributed under the License are
16 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
17 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
18 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
19 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
20 * Please see the License for the specific language governing rights and
21 * limitations under the License.
22 *
23 * @APPLE_LICENSE_HEADER_END@
24 */
25 /*
26 * @OSF_COPYRIGHT@
27 */
28
29 #ifndef _MACH_PPC_SYSCALL_SW_H_
30 #define _MACH_PPC_SYSCALL_SW_H_
31
32 #include <mach/machine/asm.h>
33
34 #define kernel_trap(trap_name,trap_number,number_args) \
35 ENTRY(trap_name, TAG_NO_FRAME_USED) @\
36 li r0, trap_number @\
37 sc @\
38 blr
39
40 #define rpc_trap(trap_name,trap_number,number_args) \
41 ENTRY(trap_name, TAG_NO_FRAME_USED) @\
42 li r0, trap_number @\
43 sc @\
44 blr
45
46 /* CHECKME! What is this supposed to do? */
47 #define rpc_return_trap(trap_name,trap_number,number_args) \
48 ENTRY(trap_name, TAG_NO_FRAME_USED) @\
49 li r0, trap_number @\
50 sc @\
51 blr
52
53 #define ppc_trap(trap_name,trap_number) \
54 ENTRY(trap_name, TAG_NO_FRAME_USED) @\
55 li r0, trap_number @\
56 sc @\
57 blr
58
59 /*
60 * Put any definitions for PPC-only system calls in here (only if
61 * this file is being included from the one that instantiates the
62 * mach system calls).
63 *
64 * Note: PPC-only system calls are in the 0x6000 to 0x6FFF range
65 */
66 #ifdef _MACH_SYSCALL_SW_H_
67 ppc_trap(diagCall,0x6000)
68 ppc_trap(vmm_get_version,0x6001)
69 ppc_trap(vmm_get_features,0x6002)
70 ppc_trap(vmm_init_context,0x6003)
71 ppc_trap(vmm_dispatch,0x6004)
72 ppc_trap(bb_enable_bluebox,0x6005)
73 ppc_trap(bb_disable_bluebox,0x6006)
74 ppc_trap(bb_settaskenv,0x6007)
75 ppc_trap(vmm_stop_vm,0x6008)
76 ppc_trap(CHUDCall,0x6009)
77 ppc_trap(ppcNull,0x600A)
78 ppc_trap(perfmon_control,0x600B)
79 ppc_trap(ppcNullinst,0x600C)
80 #endif /* _MACH_SYSCALL_SW_H_ */
81
82 #endif /* _MACH_PPC_SYSCALL_SW_H_ */