1 | #ifndef _kextd_kernel_request_user_ |
2 | #define _kextd_kernel_request_user_ |
3 | |
4 | /* Module kextd_kernel_request */ |
5 | |
6 | #include <string.h> |
7 | #include <mach/ndr.h> |
8 | #include <mach/boolean.h> |
9 | #include <mach/kern_return.h> |
10 | #include <mach/notify.h> |
11 | #include <mach/mach_types.h> |
12 | #include <mach/message.h> |
13 | #include <mach/mig_errors.h> |
14 | #include <mach/port.h> |
15 | |
16 | /* BEGIN MIG_STRNCPY_ZEROFILL CODE */ |
17 | |
18 | #if defined(__has_include) |
19 | #if __has_include(<mach/mig_strncpy_zerofill_support.h>) |
20 | #ifndef USING_MIG_STRNCPY_ZEROFILL |
21 | #define USING_MIG_STRNCPY_ZEROFILL |
22 | #endif |
23 | #ifndef __MIG_STRNCPY_ZEROFILL_FORWARD_TYPE_DECLS__ |
24 | #define __MIG_STRNCPY_ZEROFILL_FORWARD_TYPE_DECLS__ |
25 | #ifdef __cplusplus |
26 | extern "C" { |
27 | #endif |
28 | extern int mig_strncpy_zerofill(char *dest, const char *src, int len) __attribute__((weak_import)); |
29 | #ifdef __cplusplus |
30 | } |
31 | #endif |
32 | #endif /* __MIG_STRNCPY_ZEROFILL_FORWARD_TYPE_DECLS__ */ |
33 | #endif /* __has_include(<mach/mig_strncpy_zerofill_support.h>) */ |
34 | #endif /* __has_include */ |
35 | |
36 | /* END MIG_STRNCPY_ZEROFILL CODE */ |
37 | |
38 | #if (__MigKernelSpecificCode) || (_MIG_KERNEL_SPECIFIC_CODE_) |
39 | #include <kern/ipc_mig.h> |
40 | #endif /* __MigKernelSpecificCode */ |
41 | |
42 | #ifdef AUTOTEST |
43 | #ifndef FUNCTION_PTR_T |
44 | #define FUNCTION_PTR_T |
45 | typedef void (*function_ptr_t)(mach_port_t, char *, mach_msg_type_number_t); |
46 | typedef struct { |
47 | char *name; |
48 | function_ptr_t function; |
49 | } function_table_entry; |
50 | typedef function_table_entry *function_table_t; |
51 | #endif /* FUNCTION_PTR_T */ |
52 | #endif /* AUTOTEST */ |
53 | |
54 | #ifndef kextd_kernel_request_MSG_COUNT |
55 | #define kextd_kernel_request_MSG_COUNT 1 |
56 | #endif /* kextd_kernel_request_MSG_COUNT */ |
57 | |
58 | #include <mach/std_types.h> |
59 | #include <mach/mig.h> |
60 | #include <mach/mig.h> |
61 | #include <mach/mach_types.h> |
62 | |
63 | #ifdef __BeforeMigUserHeader |
64 | __BeforeMigUserHeader |
65 | #endif /* __BeforeMigUserHeader */ |
66 | |
67 | #include <sys/cdefs.h> |
68 | __BEGIN_DECLS |
69 | |
70 | |
71 | /* SimpleRoutine kextd_ping */ |
72 | #ifdef mig_external |
73 | mig_external |
74 | #else |
75 | extern |
76 | #endif /* mig_external */ |
77 | kern_return_t kextd_ping |
78 | ( |
79 | mach_port_t server |
80 | ); |
81 | |
82 | __END_DECLS |
83 | |
84 | /********************** Caution **************************/ |
85 | /* The following data types should be used to calculate */ |
86 | /* maximum message sizes only. The actual message may be */ |
87 | /* smaller, and the position of the arguments within the */ |
88 | /* message layout may vary from what is presented here. */ |
89 | /* For example, if any of the arguments are variable- */ |
90 | /* sized, and less than the maximum is sent, the data */ |
91 | /* will be packed tight in the actual message to reduce */ |
92 | /* the presence of holes. */ |
93 | /********************** Caution **************************/ |
94 | |
95 | /* typedefs for all requests */ |
96 | |
97 | #ifndef __Request__kextd_kernel_request_subsystem__defined |
98 | #define __Request__kextd_kernel_request_subsystem__defined |
99 | |
100 | #ifdef __MigPackStructs |
101 | #pragma pack(4) |
102 | #endif |
103 | typedef struct { |
104 | mach_msg_header_t Head; |
105 | } __Request__kextd_ping_t __attribute__((unused)); |
106 | #ifdef __MigPackStructs |
107 | #pragma pack() |
108 | #endif |
109 | #endif /* !__Request__kextd_kernel_request_subsystem__defined */ |
110 | |
111 | /* union of all requests */ |
112 | |
113 | #ifndef __RequestUnion__kextd_kernel_request_subsystem__defined |
114 | #define __RequestUnion__kextd_kernel_request_subsystem__defined |
115 | union __RequestUnion__kextd_kernel_request_subsystem { |
116 | __Request__kextd_ping_t Request_kextd_ping; |
117 | }; |
118 | #endif /* !__RequestUnion__kextd_kernel_request_subsystem__defined */ |
119 | /* typedefs for all replies */ |
120 | |
121 | #ifndef __Reply__kextd_kernel_request_subsystem__defined |
122 | #define __Reply__kextd_kernel_request_subsystem__defined |
123 | |
124 | #ifdef __MigPackStructs |
125 | #pragma pack(4) |
126 | #endif |
127 | typedef struct { |
128 | mach_msg_header_t Head; |
129 | NDR_record_t NDR; |
130 | kern_return_t RetCode; |
131 | } __Reply__kextd_ping_t __attribute__((unused)); |
132 | #ifdef __MigPackStructs |
133 | #pragma pack() |
134 | #endif |
135 | #endif /* !__Reply__kextd_kernel_request_subsystem__defined */ |
136 | |
137 | /* union of all replies */ |
138 | |
139 | #ifndef __ReplyUnion__kextd_kernel_request_subsystem__defined |
140 | #define __ReplyUnion__kextd_kernel_request_subsystem__defined |
141 | union __ReplyUnion__kextd_kernel_request_subsystem { |
142 | __Reply__kextd_ping_t Reply_kextd_ping; |
143 | }; |
144 | #endif /* !__RequestUnion__kextd_kernel_request_subsystem__defined */ |
145 | |
146 | #ifndef subsystem_to_name_map_kextd_kernel_request |
147 | #define subsystem_to_name_map_kextd_kernel_request \ |
148 | { "kextd_ping", 77000 } |
149 | #endif |
150 | |
151 | #ifdef __AfterMigUserHeader |
152 | __AfterMigUserHeader |
153 | #endif /* __AfterMigUserHeader */ |
154 | |
155 | #endif /* _kextd_kernel_request_user_ */ |
156 | |