]> git.saurik.com Git - apple/libc.git/blame - mach.subproj/servers.subproj/ls_defs.h
Libc-186.tar.gz
[apple/libc.git] / mach.subproj / servers.subproj / ls_defs.h
CommitLineData
e9ce8d39
A
1/*
2 * Copyright (c) 1999 Apple Computer, Inc. All rights reserved.
3 *
4 * @APPLE_LICENSE_HEADER_START@
5 *
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.
11 *
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
14 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
15 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
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.
19 *
20 * @APPLE_LICENSE_HEADER_END@
21 */
22/*
23 * Mach Operating System
24 * Copyright (c) 1989 Carnegie-Mellon University
25 * Copyright (c) 1988 Carnegie-Mellon University
26 * Copyright (c) 1987 Carnegie-Mellon University
27 * All rights reserved. The CMU software License Agreement specifies
28 * the terms and conditions for use and redistribution.
29 */
30
31/*
32 * Definitions for the logstat module.
33 */
34
35
36#ifndef _LS_DEFS_
37#define _LS_DEFS_
38
39#include <sys/types.h>
40
41/*
42 * Definition for a log record.
43 */
44typedef struct {
45 long code;
46 long thread;
47 long a1;
48 long a2;
49 long a3;
50 long a4;
51 long a5;
52 long a6;
53} log_rec_t;
54
55typedef log_rec_t *log_ptr_t;
56
57/*
58 * Statistics record.
59 */
60typedef struct {
61 int datagram_pkts_sent;
62 int datagram_pkts_rcvd;
63 int srr_requests_sent;
64 int srr_bcasts_sent;
65 int srr_requests_rcvd;
66 int srr_bcasts_rcvd;
67 int srr_replies_sent;
68 int srr_replies_rcvd;
69 int srr_retries_sent;
70 int srr_retries_rcvd;
71 int srr_cfailures_sent;
72 int srr_cfailures_rcvd;
73 int deltat_dpkts_sent;
74 int deltat_acks_rcvd;
75 int deltat_dpkts_rcvd;
76 int deltat_acks_sent;
77 int deltat_oldpkts_rcvd;
78 int deltat_oospkts_rcvd;
79 int deltat_retries_sent;
80 int deltat_retries_rcvd;
81 int deltat_cfailures_sent;
82 int deltat_cfailures_rcvd;
83 int deltat_aborts_sent;
84 int deltat_aborts_rcvd;
85 int vmtp_requests_sent;
86 int vmtp_requests_rcvd;
87 int vmtp_replies_sent;
88 int vmtp_replies_rcvd;
89 int ipc_in_messages;
90 int ipc_out_messages;
91 int ipc_unblocks_sent;
92 int ipc_unblocks_rcvd;
93 int pc_requests_sent;
94 int pc_requests_rcvd;
95 int pc_replies_rcvd;
96 int pc_startups_rcvd;
97 int nn_requests_sent;
98 int nn_requests_rcvd;
99 int nn_replies_rcvd;
100 int po_ro_hints_sent;
101 int po_ro_hints_rcvd;
102 int po_token_requests_sent;
103 int po_token_requests_rcvd;
104 int po_token_replies_rcvd;
105 int po_xfer_requests_sent;
106 int po_xfer_requests_rcvd;
107 int po_xfer_replies_rcvd;
108 int po_deaths_sent;
109 int po_deaths_rcvd;
110 int ps_requests_sent;
111 int ps_requests_rcvd;
112 int ps_replies_rcvd;
113 int ps_auth_requests_sent;
114 int ps_auth_requests_rcvd;
115 int ps_auth_replies_rcvd;
116 int mallocs_or_vm_allocates;
117 int mem_allocs;
118 int mem_deallocs;
119 int mem_allocobjs;
120 int mem_deallocobjs;
121 int pkts_encrypted;
122 int pkts_decrypted;
123 int vmtp_segs_encrypted;
124 int vmtp_segs_decrypted;
125 int tcp_requests_sent;
126 int tcp_replies_sent;
127 int tcp_requests_rcvd;
128 int tcp_replies_rcvd;
129 int tcp_send;
130 int tcp_recv;
131 int tcp_connect;
132 int tcp_accept;
133 int tcp_close;
134} stat_t;
135
136typedef stat_t *stat_ptr_t;
137
138
139/*
140 * Debugging flags record.
141 */
142typedef struct {
143 int print_level;
144 int ipc_in;
145 int ipc_out;
146 int tracing;
147 int vmtp;
148 int netname;
149 int deltat;
150 int tcp;
151 int mem;
152} debug_t;
153
154typedef debug_t *debug_ptr_t;
155
156
157/*
158 * Parameters record.
159 */
160typedef struct {
161 int srr_max_tries;
162 int srr_retry_sec;
163 int srr_retry_usec;
164 int deltat_max_tries;
165 int deltat_retry_sec;
166 int deltat_retry_usec;
167 int deltat_msg_life;
168 int pc_checkup_interval;
169 int crypt_algorithm;
170 int transport_default;
171 int conf_network;
172 int conf_netport;
173 int timer_quantum;
174 int tcp_conn_steady;
175 int tcp_conn_opening;
176 int tcp_conn_max;
177 int compat;
178 int syslog;
179 int old_nmmonitor;
180} param_t;
181
182typedef param_t *param_ptr_t;
183
184
185/*
186 * Port statistics record.
187 */
188typedef struct {
189 u_int port_id;
190 u_int alive;
191 u_int nport_id_high;
192 u_int nport_id_low;
193 u_int nport_receiver;
194 u_int nport_owner;
195 u_int messages_sent;
196 u_int messages_rcvd;
197 u_int send_rights_sent;
198 u_int send_rights_rcvd_sender;
199 u_int send_rights_rcvd_recown;
200 u_int rcv_rights_xferd;
201 u_int own_rights_xferd;
202 u_int all_rights_xferd;
203 u_int tokens_sent;
204 u_int tokens_requested;
205 u_int xfer_hints_sent;
206 u_int xfer_hints_rcvd;
207} port_stat_t, *port_stat_ptr_t;
208
209extern port_stat_ptr_t port_stat_cur;
210extern port_stat_ptr_t port_stat_end;
211extern struct mutex port_stat_lock;
212
213
214/*
215 * Types for the mem_list operation.
216 *
217 * XXX These must be faked, because we cannot include mem.h here
218 * (mutual includes).
219 */
220typedef char *mem_class_ptr_t;
221typedef char *mem_nam_ptr_t;
222typedef int *mem_bucket_ptr_t;
223
224
225/*
226 * Definitions for print_level.
227 */
228#define LS_PRINT_NEVER 5
229#define LS_PRINT_LOG 3
230#define LS_PRINT_ALWAYS 0
231
232#endif /* _LS_DEFS_ */