Print this page
3665 Implement O_CLOEXEC as an open() flag
Reviewed by: Robert Mustacchi <rm@joyent.com>
Reviewed by: Gordon Ross <gwr@nexenta.com>
Reviewed by: Dan McDonald <danmcd@nexenta.com>
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/cmd/truss/codes.c
+++ new/usr/src/cmd/truss/codes.c
1 1 /*
2 2 * CDDL HEADER START
3 3 *
4 4 * The contents of this file are subject to the terms of the
5 5 * Common Development and Distribution License (the "License").
6 6 * You may not use this file except in compliance with the License.
7 7 *
8 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 * or http://www.opensolaris.org/os/licensing.
10 10 * See the License for the specific language governing permissions
11 11 * and limitations under the License.
12 12 *
13 13 * When distributing Covered Code, include this CDDL HEADER in each
14 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 15 * If applicable, add the following below this CDDL HEADER, with the
16 16 * fields enclosed by brackets "[]" replaced with your own identifying
↓ open down ↓ |
16 lines elided |
↑ open up ↑ |
17 17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 18 *
19 19 * CDDL HEADER END
20 20 */
21 21
22 22 /*
23 23 * Copyright (c) 1989, 2010, Oracle and/or its affiliates. All rights reserved.
24 24 * Copyright (c) 2012 by Delphix. All rights reserved.
25 25 * Copyright 2011 Nexenta Systems, Inc. All rights reserved.
26 26 * Copyright (c) 2012, Joyent, Inc. All rights reserved.
27 + * Copyright (c) 2013, OmniTI Computer Consulting, Inc. All rights reserved.
27 28 */
28 29
29 30 /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
30 31 /* All Rights Reserved */
31 32
32 33
33 34 #include <stdio.h>
34 35 #include <stdlib.h>
35 36 #include <unistd.h>
36 37 #include <sys/types.h>
37 38 #include <libproc.h>
38 39
39 40 #include <ctype.h>
40 41 #include <string.h>
41 42 #include <sys/dlpi.h>
42 43 #include <sys/ipc.h>
43 44 #include <sys/ipc_impl.h>
44 45 #include <sys/msg.h>
45 46 #include <sys/sem.h>
46 47 #include <sys/shm.h>
47 48 #include <sys/fstyp.h>
48 49 #if defined(__i386) || defined(__amd64)
49 50 #include <sys/sysi86.h>
50 51 #endif /* __i386 */
51 52 #include <sys/unistd.h>
52 53 #include <sys/file.h>
53 54 #include <sys/tiuser.h>
54 55 #include <sys/timod.h>
55 56 #include <sys/stream.h>
56 57 #include <sys/stropts.h>
57 58 #include <sys/termios.h>
58 59 #include <sys/termiox.h>
59 60 #include <sys/jioctl.h>
60 61 #include <sys/filio.h>
61 62 #include <fcntl.h>
62 63 #include <sys/termio.h>
63 64 #include <sys/stermio.h>
64 65 #include <sys/ttold.h>
65 66 #include <sys/mount.h>
66 67 #include <sys/utssys.h>
67 68 #include <sys/sysconfig.h>
68 69 #include <sys/statvfs.h>
69 70 #include <sys/kstat.h>
70 71 #include <sys/audio.h>
71 72 #include <sys/mixer.h>
72 73 #include <sys/cpc_impl.h>
73 74 #include <sys/devpoll.h>
74 75 #include <sys/strredir.h>
75 76 #include <sys/sockio.h>
76 77 #include <netinet/ip_mroute.h>
77 78 #include <net/if.h>
78 79 #include <net/if_arp.h>
79 80 #include <sys/ptyvar.h>
80 81 #include <sys/des.h>
81 82 #include <sys/prnio.h>
82 83 #include <sys/dtrace.h>
83 84 #include <sys/crypto/ioctladmin.h>
84 85 #include <sys/crypto/ioctl.h>
85 86 #include <sys/kbio.h>
86 87 #include <sys/ptms.h>
87 88 #include <sys/aggr.h>
88 89 #include <sys/dld.h>
89 90 #include <net/simnet.h>
90 91 #include <sys/vnic.h>
91 92 #include <sys/fs/zfs.h>
92 93 #include <inet/kssl/kssl.h>
93 94 #include <sys/dkio.h>
94 95 #include <sys/fdio.h>
95 96 #include <sys/cdio.h>
96 97 #include <sys/scsi/impl/uscsi.h>
97 98 #include <sys/devinfo_impl.h>
98 99 #include <sys/dumpadm.h>
99 100 #include <sys/mntio.h>
100 101 #include <inet/iptun.h>
101 102 #include <sys/zcons.h>
102 103 #include <sys/usb/clients/hid/hid.h>
103 104 #include <sys/pm.h>
104 105 #include <sys/soundcard.h>
105 106
106 107 #include "ramdata.h"
107 108 #include "proto.h"
108 109
109 110 #define FCNTLMIN F_DUPFD
110 111 #define FCNTLMAX F_BADFD
111 112 const char *const FCNTLname[] = {
112 113 "F_DUPFD",
113 114 "F_GETFD",
114 115 "F_SETFD",
115 116 "F_GETFL",
116 117 "F_SETFL",
117 118 "F_O_GETLK",
118 119 "F_SETLK",
119 120 "F_SETLKW",
120 121 "F_CHKFL",
121 122 "F_DUP2FD",
122 123 "F_ALLOCSP",
123 124 "F_FREESP",
124 125 NULL, /* 12 */
125 126 NULL, /* 13 */
126 127 "F_GETLK",
127 128 NULL, /* 15 */
128 129 NULL, /* 16 */
129 130 NULL, /* 17 */
130 131 NULL, /* 18 */
131 132 NULL, /* 19 */
132 133 NULL, /* 20 */
133 134 NULL, /* 21 */
134 135 NULL, /* 22 */
135 136 "F_GETOWN",
136 137 "F_SETOWN",
137 138 "F_REVOKE",
138 139 "F_HASREMOTELOCKS",
139 140 "F_FREESP64",
140 141 NULL, /* 28 */
141 142 NULL, /* 29 */
142 143 NULL, /* 30 */
143 144 NULL, /* 31 */
144 145 NULL, /* 32 */
145 146 "F_GETLK64",
146 147 "F_SETLK64",
147 148 "F_SETLKW64",
148 149 NULL, /* 36 */
149 150 NULL, /* 37 */
150 151 NULL, /* 38 */
151 152 NULL, /* 39 */
152 153 "F_SHARE",
153 154 "F_UNSHARE",
154 155 "F_SETLK_NBMAND",
155 156 "F_SHARE_NBMAND",
156 157 "F_SETLK64_NBMAND",
157 158 NULL, /* 45 */
158 159 "F_BADFD"
159 160 };
160 161
161 162 #define SYSFSMIN GETFSIND
162 163 #define SYSFSMAX GETNFSTYP
163 164 const char *const SYSFSname[] = {
164 165 "GETFSIND",
165 166 "GETFSTYP",
166 167 "GETNFSTYP"
167 168 };
168 169
169 170 #define SCONFMIN _CONFIG_NGROUPS
170 171 #define SCONFMAX _CONFIG_EPHID_MAX
171 172 const char *const SCONFname[] = {
172 173 "_CONFIG_NGROUPS", /* 2 */
173 174 "_CONFIG_CHILD_MAX", /* 3 */
174 175 "_CONFIG_OPEN_FILES", /* 4 */
175 176 "_CONFIG_POSIX_VER", /* 5 */
176 177 "_CONFIG_PAGESIZE", /* 6 */
177 178 "_CONFIG_CLK_TCK", /* 7 */
178 179 "_CONFIG_XOPEN_VER", /* 8 */
179 180 "_CONFIG_HRESCLK_TCK", /* 9 */
180 181 "_CONFIG_PROF_TCK", /* 10 */
181 182 "_CONFIG_NPROC_CONF", /* 11 */
182 183 "_CONFIG_NPROC_ONLN", /* 12 */
183 184 "_CONFIG_AIO_LISTIO_MAX", /* 13 */
184 185 "_CONFIG_AIO_MAX", /* 14 */
185 186 "_CONFIG_AIO_PRIO_DELTA_MAX", /* 15 */
186 187 "_CONFIG_DELAYTIMER_MAX", /* 16 */
187 188 "_CONFIG_MQ_OPEN_MAX", /* 17 */
188 189 "_CONFIG_MQ_PRIO_MAX", /* 18 */
189 190 "_CONFIG_RTSIG_MAX", /* 19 */
190 191 "_CONFIG_SEM_NSEMS_MAX", /* 20 */
191 192 "_CONFIG_SEM_VALUE_MAX", /* 21 */
192 193 "_CONFIG_SIGQUEUE_MAX", /* 22 */
193 194 "_CONFIG_SIGRT_MIN", /* 23 */
194 195 "_CONFIG_SIGRT_MAX", /* 24 */
195 196 "_CONFIG_TIMER_MAX", /* 25 */
196 197 "_CONFIG_PHYS_PAGES", /* 26 */
197 198 "_CONFIG_AVPHYS_PAGES", /* 27 */
198 199 "_CONFIG_COHERENCY", /* 28 */
199 200 "_CONFIG_SPLIT_CACHE", /* 29 */
200 201 "_CONFIG_ICACHESZ", /* 30 */
201 202 "_CONFIG_DCACHESZ", /* 31 */
202 203 "_CONFIG_ICACHELINESZ", /* 32 */
203 204 "_CONFIG_DCACHELINESZ", /* 33 */
204 205 "_CONFIG_ICACHEBLKSZ", /* 34 */
205 206 "_CONFIG_DCACHEBLKSZ", /* 35 */
206 207 "_CONFIG_DCACHETBLKSZ", /* 36 */
207 208 "_CONFIG_ICACHE_ASSOC", /* 37 */
208 209 "_CONFIG_DCACHE_ASSOC", /* 38 */
209 210 NULL, /* 39 */
210 211 NULL, /* 40 */
211 212 NULL, /* 41 */
212 213 "_CONFIG_MAXPID", /* 42 */
213 214 "_CONFIG_STACK_PROT", /* 43 */
214 215 "_CONFIG_NPROC_MAX", /* 44 */
215 216 "_CONFIG_CPUID_MAX", /* 45 */
216 217 "_CONFIG_SYMLOOP_MAX", /* 46 */
217 218 "_CONFIG_EPHID_MAX", /* 47 */
218 219 };
219 220
220 221 #define PATHCONFMIN _PC_LINK_MAX
221 222 #define PATHCONFMAX _PC_XATTR_EXISTS
222 223 const char *const PATHCONFname[] = {
223 224 "_PC_LINK_MAX", /* 1 */
224 225 "_PC_MAX_CANON", /* 2 */
225 226 "_PC_MAX_INPUT", /* 3 */
226 227 "_PC_NAME_MAX", /* 4 */
227 228 "_PC_PATH_MAX", /* 5 */
228 229 "_PC_PIPE_BUF", /* 6 */
229 230 "_PC_NO_TRUNC", /* 7 */
230 231 "_PC_VDISABLE", /* 8 */
231 232 "_PC_CHOWN_RESTRICTED", /* 9 */
232 233 "_PC_ASYNC_IO", /* 10 */
233 234 "_PC_PRIO_IO", /* 11 */
234 235 "_PC_SYNC_IO", /* 12 */
235 236 "_PC_ALLOC_SIZE_MIN", /* 13 */
236 237 "_PC_REC_INCR_XFER_SIZE", /* 14 */
237 238 "_PC_REC_MAX_XFER_SIZE", /* 15 */
238 239 "_PC_REC_MIN_XFER_SIZE", /* 16 */
239 240 "_PC_REC_XFER_ALIGN", /* 17 */
240 241 "_PC_SYMLINK_MAX", /* 18 */
241 242 "_PC_2_SYMLINKS", /* 19 */
242 243 "_PC_ACL_ENABLED", /* 20 */
243 244 "_PC_MIN_HOLE_SIZE", /* 21 */
244 245 "_PC_CASE_BEHAVIOR", /* 22 */
245 246 "_PC_SATTR_ENABLED", /* 23 */
246 247 "_PC_SATTR_EXISTS", /* 24 */
247 248 "_PC_ACCESS_FILTERING", /* 25 */
248 249 "_PC_TIMESTAMP_RESOLUTION", /* 26 */
249 250 NULL, /* 27 */
250 251 NULL, /* 28 */
251 252 NULL, /* 29 */
252 253 NULL, /* 30 */
253 254 NULL, /* 31 */
254 255 NULL, /* 32 */
255 256 NULL, /* 33 */
256 257 NULL, /* 34 */
257 258 NULL, /* 35 */
258 259 NULL, /* 36 */
259 260 NULL, /* 37 */
260 261 NULL, /* 38 */
261 262 NULL, /* 39 */
262 263 NULL, /* 40 */
263 264 NULL, /* 41 */
264 265 NULL, /* 42 */
265 266 NULL, /* 43 */
266 267 NULL, /* 44 */
267 268 NULL, /* 45 */
268 269 NULL, /* 46 */
269 270 NULL, /* 47 */
270 271 NULL, /* 48 */
271 272 NULL, /* 49 */
272 273 NULL, /* 50 */
273 274 NULL, /* 51 */
274 275 NULL, /* 52 */
275 276 NULL, /* 53 */
276 277 NULL, /* 54 */
277 278 NULL, /* 55 */
278 279 NULL, /* 56 */
279 280 NULL, /* 57 */
280 281 NULL, /* 58 */
281 282 NULL, /* 59 */
282 283 NULL, /* 60 */
283 284 NULL, /* 61 */
284 285 NULL, /* 62 */
285 286 NULL, /* 63 */
286 287 NULL, /* 64 */
287 288 NULL, /* 65 */
288 289 NULL, /* 66 */
289 290 "_PC_FILESIZEBITS", /* 67 */
290 291 NULL, /* 68 */
291 292 NULL, /* 69 */
292 293 NULL, /* 70 */
293 294 NULL, /* 71 */
294 295 NULL, /* 72 */
295 296 NULL, /* 73 */
296 297 NULL, /* 74 */
297 298 NULL, /* 75 */
298 299 NULL, /* 76 */
299 300 NULL, /* 77 */
300 301 NULL, /* 78 */
301 302 NULL, /* 79 */
302 303 NULL, /* 80 */
303 304 NULL, /* 81 */
304 305 NULL, /* 82 */
305 306 NULL, /* 83 */
306 307 NULL, /* 84 */
307 308 NULL, /* 85 */
308 309 NULL, /* 86 */
309 310 NULL, /* 87 */
310 311 NULL, /* 88 */
311 312 NULL, /* 89 */
312 313 NULL, /* 90 */
313 314 NULL, /* 91 */
314 315 NULL, /* 92 */
315 316 NULL, /* 93 */
316 317 NULL, /* 94 */
317 318 NULL, /* 95 */
318 319 NULL, /* 96 */
319 320 NULL, /* 97 */
320 321 NULL, /* 98 */
321 322 NULL, /* 99 */
322 323 "_PC_XATTR_ENABLED", /* 100 */
323 324 "_PC_XATTR_EXISTS", /* 101, _PC_LAST */
324 325 };
325 326
326 327 const struct ioc {
327 328 uint_t code;
328 329 const char *name;
329 330 const char *datastruct;
330 331 } ioc[] = {
331 332 { (uint_t)TCGETA, "TCGETA", NULL },
332 333 { (uint_t)TCSETA, "TCSETA", NULL },
333 334 { (uint_t)TCSETAW, "TCSETAW", NULL },
334 335 { (uint_t)TCSETAF, "TCSETAF", NULL },
335 336 { (uint_t)TCFLSH, "TCFLSH", NULL },
336 337 { (uint_t)TIOCKBON, "TIOCKBON", NULL },
337 338 { (uint_t)TIOCKBOF, "TIOCKBOF", NULL },
338 339 { (uint_t)KBENABLED, "KBENABLED", NULL },
339 340 { (uint_t)TCGETS, "TCGETS", NULL },
340 341 { (uint_t)TCSETS, "TCSETS", NULL },
341 342 { (uint_t)TCSETSW, "TCSETSW", NULL },
342 343 { (uint_t)TCSETSF, "TCSETSF", NULL },
343 344 { (uint_t)TCXONC, "TCXONC", NULL },
344 345 { (uint_t)TCSBRK, "TCSBRK", NULL },
345 346 { (uint_t)TCDSET, "TCDSET", NULL },
346 347 { (uint_t)RTS_TOG, "RTS_TOG", NULL },
347 348 { (uint_t)TIOCSWINSZ, "TIOCSWINSZ", NULL },
348 349 { (uint_t)TIOCGWINSZ, "TIOCGWINSZ", NULL },
349 350 { (uint_t)TIOCGETD, "TIOCGETD", NULL },
350 351 { (uint_t)TIOCSETD, "TIOCSETD", NULL },
351 352 { (uint_t)TIOCHPCL, "TIOCHPCL", NULL },
352 353 { (uint_t)TIOCGETP, "TIOCGETP", NULL },
353 354 { (uint_t)TIOCSETP, "TIOCSETP", NULL },
354 355 { (uint_t)TIOCSETN, "TIOCSETN", NULL },
355 356 { (uint_t)TIOCEXCL, "TIOCEXCL", NULL },
356 357 { (uint_t)TIOCNXCL, "TIOCNXCL", NULL },
357 358 { (uint_t)TIOCFLUSH, "TIOCFLUSH", NULL },
358 359 { (uint_t)TIOCSETC, "TIOCSETC", NULL },
359 360 { (uint_t)TIOCGETC, "TIOCGETC", NULL },
360 361 { (uint_t)TIOCGPGRP, "TIOCGPGRP", NULL },
361 362 { (uint_t)TIOCSPGRP, "TIOCSPGRP", NULL },
362 363 { (uint_t)TIOCGSID, "TIOCGSID", NULL },
363 364 { (uint_t)TIOCSTI, "TIOCSTI", NULL },
364 365 { (uint_t)TIOCMSET, "TIOCMSET", NULL },
365 366 { (uint_t)TIOCMBIS, "TIOCMBIS", NULL },
366 367 { (uint_t)TIOCMBIC, "TIOCMBIC", NULL },
367 368 { (uint_t)TIOCMGET, "TIOCMGET", NULL },
368 369 { (uint_t)TIOCREMOTE, "TIOCREMOTE", NULL },
369 370 { (uint_t)TIOCSIGNAL, "TIOCSIGNAL", NULL },
370 371 { (uint_t)TIOCSTART, "TIOCSTART", NULL },
371 372 { (uint_t)TIOCSTOP, "TIOCSTOP", NULL },
372 373 { (uint_t)TIOCNOTTY, "TIOCNOTTY", NULL },
373 374 { (uint_t)TIOCSCTTY, "TIOCSCTTY", NULL },
374 375 { (uint_t)TIOCOUTQ, "TIOCOUTQ", NULL },
375 376 { (uint_t)TIOCGLTC, "TIOCGLTC", NULL },
376 377 { (uint_t)TIOCSLTC, "TIOCSLTC", NULL },
377 378 { (uint_t)TIOCCDTR, "TIOCCDTR", NULL },
378 379 { (uint_t)TIOCSDTR, "TIOCSDTR", NULL },
379 380 { (uint_t)TIOCCBRK, "TIOCCBRK", NULL },
380 381 { (uint_t)TIOCSBRK, "TIOCSBRK", NULL },
381 382 { (uint_t)TIOCLGET, "TIOCLGET", NULL },
382 383 { (uint_t)TIOCLSET, "TIOCLSET", NULL },
383 384 { (uint_t)TIOCLBIC, "TIOCLBIC", NULL },
384 385 { (uint_t)TIOCLBIS, "TIOCLBIS", NULL },
385 386
386 387 { (uint_t)TIOCSILOOP, "TIOCSILOOP", NULL },
387 388 { (uint_t)TIOCCILOOP, "TIOCSILOOP", NULL },
388 389
389 390 { (uint_t)TIOCGPPS, "TIOCGPPS", NULL },
390 391 { (uint_t)TIOCSPPS, "TIOCSPPS", NULL },
391 392 { (uint_t)TIOCGPPSEV, "TIOCGPPSEV", NULL },
392 393
393 394 { (uint_t)TIOCPKT, "TIOCPKT", NULL }, /* ptyvar.h */
394 395 { (uint_t)TIOCUCNTL, "TIOCUCNTL", NULL },
395 396 { (uint_t)TIOCTCNTL, "TIOCTCNTL", NULL },
396 397 { (uint_t)TIOCISPACE, "TIOCISPACE", NULL },
397 398 { (uint_t)TIOCISIZE, "TIOCISIZE", NULL },
398 399 { (uint_t)TIOCSSIZE, "TIOCSSIZE", "ttysize" },
399 400 { (uint_t)TIOCGSIZE, "TIOCGSIZE", "ttysize" },
400 401
401 402 /*
402 403 * Unfortunately, the DLIOC and LDIOC codes overlap. Since the LDIOC
403 404 * ioctls (for xenix compatibility) are far less likely to be used, we
404 405 * give preference to DLIOC.
405 406 */
406 407 { (uint_t)DLIOCRAW, "DLIOCRAW", NULL },
407 408 { (uint_t)DLIOCNATIVE, "DLIOCNATIVE", NULL },
408 409 { (uint_t)DLIOCIPNETINFO, "DLIOCIPNETINFO", NULL},
409 410 { (uint_t)DLIOCLOWLINK, "DLIOCLOWLINK", NULL },
410 411
411 412 { (uint_t)LDOPEN, "LDOPEN", NULL },
412 413 { (uint_t)LDCLOSE, "LDCLOSE", NULL },
413 414 { (uint_t)LDCHG, "LDCHG", NULL },
414 415 { (uint_t)LDGETT, "LDGETT", NULL },
415 416 { (uint_t)LDSETT, "LDSETT", NULL },
416 417 { (uint_t)LDSMAP, "LDSMAP", NULL },
417 418 { (uint_t)LDGMAP, "LDGMAP", NULL },
418 419 { (uint_t)LDNMAP, "LDNMAP", NULL },
419 420 { (uint_t)TCGETX, "TCGETX", NULL },
420 421 { (uint_t)TCSETX, "TCSETX", NULL },
421 422 { (uint_t)TCSETXW, "TCSETXW", NULL },
422 423 { (uint_t)TCSETXF, "TCSETXF", NULL },
423 424 { (uint_t)FIORDCHK, "FIORDCHK", NULL },
424 425 { (uint_t)FIOCLEX, "FIOCLEX", NULL },
425 426 { (uint_t)FIONCLEX, "FIONCLEX", NULL },
426 427 { (uint_t)FIONREAD, "FIONREAD", NULL },
427 428 { (uint_t)FIONBIO, "FIONBIO", NULL },
428 429 { (uint_t)FIOASYNC, "FIOASYNC", NULL },
429 430 { (uint_t)FIOSETOWN, "FIOSETOWN", NULL },
430 431 { (uint_t)FIOGETOWN, "FIOGETOWN", NULL },
431 432 #ifdef DIOCGETP
432 433 { (uint_t)DIOCGETP, "DIOCGETP", NULL },
433 434 { (uint_t)DIOCSETP, "DIOCSETP", NULL },
434 435 #endif
435 436 #ifdef DIOCGETC
436 437 { (uint_t)DIOCGETC, "DIOCGETC", NULL },
437 438 { (uint_t)DIOCGETB, "DIOCGETB", NULL },
438 439 { (uint_t)DIOCSETE, "DIOCSETE", NULL },
439 440 #endif
440 441 #ifdef IFFORMAT
441 442 { (uint_t)IFFORMAT, "IFFORMAT", NULL },
442 443 { (uint_t)IFBCHECK, "IFBCHECK", NULL },
443 444 { (uint_t)IFCONFIRM, "IFCONFIRM", NULL },
444 445 #endif
445 446 #ifdef LIOCGETP
446 447 { (uint_t)LIOCGETP, "LIOCGETP", NULL },
447 448 { (uint_t)LIOCSETP, "LIOCSETP", NULL },
448 449 { (uint_t)LIOCGETS, "LIOCGETS", NULL },
449 450 { (uint_t)LIOCSETS, "LIOCSETS", NULL },
450 451 #endif
451 452 #ifdef JBOOT
452 453 { (uint_t)JBOOT, "JBOOT", NULL },
453 454 { (uint_t)JTERM, "JTERM", NULL },
454 455 { (uint_t)JMPX, "JMPX", NULL },
455 456 #ifdef JTIMO
456 457 { (uint_t)JTIMO, "JTIMO", NULL },
457 458 #endif
458 459 { (uint_t)JWINSIZE, "JWINSIZE", NULL },
459 460 { (uint_t)JTIMOM, "JTIMOM", NULL },
460 461 { (uint_t)JZOMBOOT, "JZOMBOOT", NULL },
461 462 { (uint_t)JAGENT, "JAGENT", NULL },
462 463 { (uint_t)JTRUN, "JTRUN", NULL },
463 464 { (uint_t)JXTPROTO, "JXTPROTO", NULL },
464 465 #endif
465 466 { (uint_t)KSTAT_IOC_CHAIN_ID, "KSTAT_IOC_CHAIN_ID", NULL },
466 467 { (uint_t)KSTAT_IOC_READ, "KSTAT_IOC_READ", NULL },
467 468 { (uint_t)KSTAT_IOC_WRITE, "KSTAT_IOC_WRITE", NULL },
468 469 { (uint_t)STGET, "STGET", NULL },
469 470 { (uint_t)STSET, "STSET", NULL },
470 471 { (uint_t)STTHROW, "STTHROW", NULL },
471 472 { (uint_t)STWLINE, "STWLINE", NULL },
472 473 { (uint_t)STTSV, "STTSV", NULL },
473 474 { (uint_t)I_NREAD, "I_NREAD", NULL },
474 475 { (uint_t)I_PUSH, "I_PUSH", NULL },
475 476 { (uint_t)I_POP, "I_POP", NULL },
476 477 { (uint_t)I_LOOK, "I_LOOK", NULL },
477 478 { (uint_t)I_FLUSH, "I_FLUSH", NULL },
478 479 { (uint_t)I_SRDOPT, "I_SRDOPT", NULL },
479 480 { (uint_t)I_GRDOPT, "I_GRDOPT", NULL },
480 481 { (uint_t)I_STR, "I_STR", NULL },
481 482 { (uint_t)I_SETSIG, "I_SETSIG", NULL },
482 483 { (uint_t)I_GETSIG, "I_GETSIG", NULL },
483 484 { (uint_t)I_FIND, "I_FIND", NULL },
484 485 { (uint_t)I_LINK, "I_LINK", NULL },
485 486 { (uint_t)I_UNLINK, "I_UNLINK", NULL },
486 487 { (uint_t)I_PEEK, "I_PEEK", NULL },
487 488 { (uint_t)I_FDINSERT, "I_FDINSERT", NULL },
488 489 { (uint_t)I_SENDFD, "I_SENDFD", NULL },
489 490 { (uint_t)I_RECVFD, "I_RECVFD", NULL },
490 491 { (uint_t)I_SWROPT, "I_SWROPT", NULL },
491 492 { (uint_t)I_GWROPT, "I_GWROPT", NULL },
492 493 { (uint_t)I_LIST, "I_LIST", NULL },
493 494 { (uint_t)I_PLINK, "I_PLINK", NULL },
494 495 { (uint_t)I_PUNLINK, "I_PUNLINK", NULL },
495 496 { (uint_t)I_FLUSHBAND, "I_FLUSHBAND", NULL },
496 497 { (uint_t)I_CKBAND, "I_CKBAND", NULL },
497 498 { (uint_t)I_GETBAND, "I_GETBAND", NULL },
498 499 { (uint_t)I_ATMARK, "I_ATMARK", NULL },
499 500 { (uint_t)I_SETCLTIME, "I_SETCLTIME", NULL },
500 501 { (uint_t)I_GETCLTIME, "I_GETCLTIME", NULL },
501 502 { (uint_t)I_CANPUT, "I_CANPUT", NULL },
502 503 { (uint_t)I_ANCHOR, "I_ANCHOR", NULL },
503 504 { (uint_t)_I_CMD, "_I_CMD", NULL },
504 505 #ifdef TI_GETINFO
505 506 { (uint_t)TI_GETINFO, "TI_GETINFO", NULL },
506 507 { (uint_t)TI_OPTMGMT, "TI_OPTMGMT", NULL },
507 508 { (uint_t)TI_BIND, "TI_BIND", NULL },
508 509 { (uint_t)TI_UNBIND, "TI_UNBIND", NULL },
509 510 #endif
510 511 #ifdef TI_CAPABILITY
511 512 { (uint_t)TI_CAPABILITY, "TI_CAPABILITY", NULL },
512 513 #endif
513 514 #ifdef TI_GETMYNAME
514 515 { (uint_t)TI_GETMYNAME, "TI_GETMYNAME", NULL },
515 516 { (uint_t)TI_GETPEERNAME, "TI_GETPEERNAME", NULL },
516 517 { (uint_t)TI_SETMYNAME, "TI_SETMYNAME", NULL },
517 518 { (uint_t)TI_SETPEERNAME, "TI_SETPEERNAME", NULL },
518 519 #endif
519 520 #ifdef V_PREAD
520 521 { (uint_t)V_PREAD, "V_PREAD", NULL },
521 522 { (uint_t)V_PWRITE, "V_PWRITE", NULL },
522 523 { (uint_t)V_PDREAD, "V_PDREAD", NULL },
523 524 { (uint_t)V_PDWRITE, "V_PDWRITE", NULL },
524 525 #if !defined(__i386) && !defined(__amd64)
525 526 { (uint_t)V_GETSSZ, "V_GETSSZ", NULL },
526 527 #endif /* !__i386 */
527 528 #endif
528 529 /* audio */
529 530 { (uint_t)AUDIO_GETINFO, "AUDIO_GETINFO", NULL },
530 531 { (uint_t)AUDIO_SETINFO, "AUDIO_SETINFO", NULL },
531 532 { (uint_t)AUDIO_DRAIN, "AUDIO_DRAIN", NULL },
532 533 { (uint_t)AUDIO_GETDEV, "AUDIO_GETDEV", NULL },
533 534 { (uint_t)AUDIO_DIAG_LOOPBACK, "AUDIO_DIAG_LOOPBACK", NULL },
534 535 { (uint_t)AUDIO_GET_CH_NUMBER, "AUDIO_GET_CH_NUMBER", NULL },
535 536 { (uint_t)AUDIO_GET_CH_TYPE, "AUDIO_GET_CH_TYPE", NULL },
536 537 { (uint_t)AUDIO_GET_NUM_CHS, "AUDIO_GET_NUM_CHS", NULL },
537 538 { (uint_t)AUDIO_GET_AD_DEV, "AUDIO_GET_AD_DEV", NULL },
538 539 { (uint_t)AUDIO_GET_APM_DEV, "AUDIO_GET_APM_DEV", NULL },
539 540 { (uint_t)AUDIO_GET_AS_DEV, "AUDIO_GET_AS_DEV", NULL },
540 541 { (uint_t)AUDIO_MIXER_MULTIPLE_OPEN, "AUDIO_MIXER_MULTIPLE_OPEN",
541 542 NULL },
542 543 { (uint_t)AUDIO_MIXER_SINGLE_OPEN, "AUDIO_MIXER_SINGLE_OPEN",
543 544 NULL },
544 545 { (uint_t)AUDIO_MIXER_GET_SAMPLE_RATES, "AUDIO_MIXER_GET_SAMPLE_RATES",
545 546 NULL },
546 547 { (uint_t)AUDIO_MIXERCTL_GETINFO, "AUDIO_MIXERCTL_GETINFO",
547 548 NULL },
548 549 { (uint_t)AUDIO_MIXERCTL_SETINFO, "AUDIO_MIXERCTL_SETINFO",
549 550 NULL },
550 551 { (uint_t)AUDIO_MIXERCTL_GET_CHINFO, "AUDIO_MIXERCTL_GET_CHINFO",
551 552 NULL },
552 553 { (uint_t)AUDIO_MIXERCTL_SET_CHINFO, "AUDIO_MIXERCTL_SET_CHINFO",
553 554 NULL },
554 555 { (uint_t)AUDIO_MIXERCTL_GET_MODE, "AUDIO_MIXERCTL_GET_MODE",
555 556 NULL },
556 557 { (uint_t)AUDIO_MIXERCTL_SET_MODE, "AUDIO_MIXERCTL_SET_MODE",
557 558 NULL },
558 559 /* new style Boomer (OSS) ioctls */
559 560 { (uint_t)SNDCTL_SYSINFO, "SNDCTL_SYSINFO", NULL },
560 561 { (uint_t)SNDCTL_AUDIOINFO, "SNDCTL_AUDIOINFO", NULL },
561 562 { (uint_t)SNDCTL_AUDIOINFO_EX, "SNDCTL_AUDIOINFO_EX", NULL },
562 563 { (uint_t)SNDCTL_MIXERINFO, "SNDCTL_MIXERINFO", NULL },
563 564 { (uint_t)SNDCTL_CARDINFO, "SNDCTL_CARDINFO", NULL },
564 565 { (uint_t)SNDCTL_ENGINEINFO, "SNDCTL_ENGINEINFO", NULL },
565 566 { (uint_t)SNDCTL_MIX_NRMIX, "SNDCTL_MIX_NRMIX", NULL },
566 567 { (uint_t)SNDCTL_MIX_NREXT, "SNDCTL_MIX_NREXT", NULL },
567 568 { (uint_t)SNDCTL_MIX_EXTINFO, "SNDCTL_MIX_EXTINFO", NULL },
568 569 { (uint_t)SNDCTL_MIX_READ, "SNDCTL_MIX_READ", NULL },
569 570 { (uint_t)SNDCTL_MIX_WRITE, "SNDCTL_MIX_WRITE", NULL },
570 571 { (uint_t)SNDCTL_MIX_ENUMINFO, "SNDCTL_MIX_ENUMINFO", NULL },
571 572 { (uint_t)SNDCTL_MIX_DESCRIPTION, "SNDCTL_MIX_DESCRIPTION",
572 573 NULL },
573 574 { (uint_t)SNDCTL_SETSONG, "SNDCTL_SETSONG", NULL },
574 575 { (uint_t)SNDCTL_GETSONG, "SNDCTL_GETSONG", NULL },
575 576 { (uint_t)SNDCTL_SETNAME, "SNDCTL_SETNAME", NULL },
576 577 { (uint_t)SNDCTL_SETLABEL, "SNDCTL_SETLABEL", NULL },
577 578 { (uint_t)SNDCTL_GETLABEL, "SNDCTL_GETLABEL", NULL },
578 579 { (uint_t)SNDCTL_DSP_HALT, "SNDCTL_DSP_HALT", NULL },
579 580 { (uint_t)SNDCTL_DSP_RESET, "SNDCTL_DSP_RESET", NULL },
580 581 { (uint_t)SNDCTL_DSP_SYNC, "SNDCTL_DSP_SYNC", NULL },
581 582 { (uint_t)SNDCTL_DSP_SPEED, "SNDCTL_DSP_SPEED", NULL },
582 583 { (uint_t)SNDCTL_DSP_STEREO, "SNDCTL_DSP_STEREO", NULL },
583 584 { (uint_t)SNDCTL_DSP_GETBLKSIZE, "SNDCTL_DSP_GETBLKSIZE",
584 585 NULL },
585 586 { (uint_t)SNDCTL_DSP_SAMPLESIZE, "SNDCTL_DSP_SAMPLESIZE",
586 587 NULL },
587 588 { (uint_t)SNDCTL_DSP_CHANNELS, "SNDCTL_DSP_CHANNELS", NULL },
588 589 { (uint_t)SNDCTL_DSP_POST, "SNDCTL_DSP_POST", NULL },
589 590 { (uint_t)SNDCTL_DSP_SUBDIVIDE, "SNDCTL_DSP_SUBDIVIDE", NULL },
590 591 { (uint_t)SNDCTL_DSP_SETFRAGMENT, "SNDCTL_DSP_SETFRAGMENT",
591 592 NULL },
592 593 { (uint_t)SNDCTL_DSP_GETFMTS, "SNDCTL_DSP_GETFMTS", NULL },
593 594 { (uint_t)SNDCTL_DSP_SETFMT, "SNDCTL_DSP_SETFMT", NULL },
594 595 { (uint_t)SNDCTL_DSP_GETOSPACE, "SNDCTL_DSP_GETOSPACE", NULL },
595 596 { (uint_t)SNDCTL_DSP_GETISPACE, "SNDCTL_DSP_GETISPACE", NULL },
596 597 { (uint_t)SNDCTL_DSP_GETCAPS, "SNDCTL_DSP_CAPS", NULL },
597 598 { (uint_t)SNDCTL_DSP_GETTRIGGER, "SNDCTL_DSP_GETTRIGGER",
598 599 NULL },
599 600 { (uint_t)SNDCTL_DSP_SETTRIGGER, "SNDCTL_DSP_SETTRIGGER",
600 601 NULL },
601 602 { (uint_t)SNDCTL_DSP_GETIPTR, "SNDCTL_DSP_GETIPTR", NULL },
602 603 { (uint_t)SNDCTL_DSP_GETOPTR, "SNDCTL_DSP_GETOPTR", NULL },
603 604 { (uint_t)SNDCTL_DSP_SETSYNCRO, "SNDCTL_DSP_SETSYNCRO", NULL },
604 605 { (uint_t)SNDCTL_DSP_SETDUPLEX, "SNDCTL_DSP_SETDUPLEX", NULL },
605 606 { (uint_t)SNDCTL_DSP_PROFILE, "SNDCTL_DSP_PROFILE", NULL },
606 607 { (uint_t)SNDCTL_DSP_GETODELAY, "SNDCTL_DSP_GETODELAY", NULL },
607 608 { (uint_t)SNDCTL_DSP_GETPLAYVOL, "SNDCTL_DSP_GETPLAYVOL",
608 609 NULL },
609 610 { (uint_t)SNDCTL_DSP_SETPLAYVOL, "SNDCTL_DSP_SETPLAYVOL",
610 611 NULL },
611 612 { (uint_t)SNDCTL_DSP_GETERROR, "SNDCTL_DSP_GETERROR", NULL },
612 613 { (uint_t)SNDCTL_DSP_READCTL, "SNDCTL_DSP_READCTL", NULL },
613 614 { (uint_t)SNDCTL_DSP_WRITECTL, "SNDCTL_DSP_WRITECTL", NULL },
614 615 { (uint_t)SNDCTL_DSP_SYNCGROUP, "SNDCTL_DSP_SYNCGROUP", NULL },
615 616 { (uint_t)SNDCTL_DSP_SYNCSTART, "SNDCTL_DSP_SYNCSTART", NULL },
616 617 { (uint_t)SNDCTL_DSP_COOKEDMODE, "SNDCTL_DSP_COOKEDMODE",
617 618 NULL },
618 619 { (uint_t)SNDCTL_DSP_SILENCE, "SNDCTL_DSP_SILENCE", NULL },
619 620 { (uint_t)SNDCTL_DSP_SKIP, "SNDCTL_DSP_SKIP", NULL },
620 621 { (uint_t)SNDCTL_DSP_HALT_INPUT, "SNDCTL_DSP_HALT_INPUT",
621 622 NULL },
622 623 { (uint_t)SNDCTL_DSP_HALT_OUTPUT, "SNDCTL_DSP_HALT_OUTPUT",
623 624 NULL },
624 625 { (uint_t)SNDCTL_DSP_LOW_WATER, "SNDCTL_DSP_LOW_WATER", NULL },
625 626 { (uint_t)SNDCTL_DSP_CURRENT_OPTR, "SNDCTL_DSP_CURRENT_OPTR",
626 627 NULL },
627 628 { (uint_t)SNDCTL_DSP_CURRENT_IPTR, "SNDCTL_DSP_CURRENT_IPTR",
628 629 NULL },
629 630 { (uint_t)SNDCTL_DSP_GET_RECSRC_NAMES, "SNDCTL_DSP_GET_RECSRC_NAMES",
630 631 NULL },
631 632 { (uint_t)SNDCTL_DSP_GET_RECSRC, "SNDCTL_DSP_GET_RECSRC",
632 633 NULL },
633 634 { (uint_t)SNDCTL_DSP_SET_RECSRC, "SNDCTL_DSP_SET_RECSRC",
634 635 NULL },
635 636 { (uint_t)SNDCTL_DSP_GET_PLAYTGT_NAMES, "SNDCTL_DSP_GET_PLAYTGT_NAMES",
636 637 NULL },
637 638 { (uint_t)SNDCTL_DSP_GET_PLAYTGT, "SNDCTL_DSP_GET_PLAYTGT",
638 639 NULL },
639 640 { (uint_t)SNDCTL_DSP_SET_PLAYTGT, "SNDCTL_DSP_SET_PLAYTGT",
640 641 NULL },
641 642 { (uint_t)SNDCTL_DSP_GETRECVOL, "SNDCTL_DSP_GETRECVOL",
642 643 NULL },
643 644 { (uint_t)SNDCTL_DSP_SETRECVOL, "SNDCTL_DSP_SETRECVOL",
644 645 NULL },
645 646 { (uint_t)SNDCTL_DSP_GET_CHNORDER, "SNDCTL_DSP_GET_CHNORDER",
646 647 NULL },
647 648 { (uint_t)SNDCTL_DSP_SET_CHNORDER, "SNDCTL_DSP_SET_CHNORDER",
648 649 NULL },
649 650 { (uint_t)SNDCTL_DSP_GETIPEAKS, "SNDCTL_DSP_GETIPEAKS", NULL },
650 651 { (uint_t)SNDCTL_DSP_GETOPEAKS, "SNDCTL_DSP_GETOPEAKS", NULL },
651 652 { (uint_t)SNDCTL_DSP_POLICY, "SNDCTL_DSP_POLICY", NULL },
652 653 { (uint_t)SNDCTL_DSP_GETCHANNELMASK, "SNDCTL_DSP_GETCHANNELMASK",
653 654 NULL },
654 655 { (uint_t)SNDCTL_DSP_BIND_CHANNEL, "SNDCTL_DSP_BIND_CHANNEL",
655 656 NULL },
656 657 { (uint_t)SOUND_MIXER_READ_VOLUME, "SOUND_MIXER_READ_VOLUME",
657 658 NULL },
658 659 { (uint_t)SOUND_MIXER_READ_OGAIN, "SOUND_MIXER_READ_OGAIN",
659 660 NULL },
660 661 { (uint_t)SOUND_MIXER_READ_PCM, "SOUND_MIXER_READ_PCM", NULL },
661 662 { (uint_t)SOUND_MIXER_READ_IGAIN, "SOUND_MIXER_READ_IGAIN",
662 663 NULL },
663 664 { (uint_t)SOUND_MIXER_READ_RECLEV, "SOUND_MIXER_READ_RECLEV",
664 665 NULL },
665 666 { (uint_t)SOUND_MIXER_READ_RECSRC, "SOUND_MIXER_READ_RECSRC",
666 667 NULL },
667 668 { (uint_t)SOUND_MIXER_READ_DEVMASK, "SOUND_MIXER_READ_DEVMASK",
668 669 NULL },
669 670 { (uint_t)SOUND_MIXER_READ_RECMASK, "SOUND_MIXER_READ_RECMASK",
670 671 NULL },
671 672 { (uint_t)SOUND_MIXER_READ_CAPS, "SOUND_MIXER_READ_CAPS",
672 673 NULL },
673 674 { (uint_t)SOUND_MIXER_READ_STEREODEVS, "SOUND_MIXER_READ_STEREODEVS",
674 675 NULL },
675 676 { (uint_t)SOUND_MIXER_READ_RECGAIN, "SOUND_MIXER_READ_RECGAIN",
676 677 NULL },
677 678 { (uint_t)SOUND_MIXER_READ_MONGAIN, "SOUND_MIXER_READ_MONGAIN",
678 679 NULL },
679 680 { (uint_t)SOUND_MIXER_WRITE_VOLUME, "SOUND_MIXER_WRITE_VOLUME",
680 681 NULL },
681 682 { (uint_t)SOUND_MIXER_WRITE_OGAIN, "SOUND_MIXER_WRITE_OGAIN",
682 683 NULL },
683 684 { (uint_t)SOUND_MIXER_WRITE_PCM, "SOUND_MIXER_WRITE_PCM",
684 685 NULL },
685 686 { (uint_t)SOUND_MIXER_WRITE_IGAIN, "SOUND_MIXER_WRITE_IGAIN",
686 687 NULL },
687 688 { (uint_t)SOUND_MIXER_WRITE_RECLEV, "SOUND_MIXER_WRITE_RECLEV",
688 689 NULL },
689 690 { (uint_t)SOUND_MIXER_WRITE_RECSRC, "SOUND_MIXER_WRITE_RECSRC",
690 691 NULL },
691 692 { (uint_t)SOUND_MIXER_WRITE_RECGAIN, "SOUND_MIXER_WRITE_RECGAIN",
692 693 NULL },
693 694 { (uint_t)SOUND_MIXER_WRITE_MONGAIN, "SOUND_MIXER_WRITE_MONGAIN",
694 695 NULL },
695 696
696 697 /* STREAMS redirection ioctls */
697 698 { (uint_t)SRIOCSREDIR, "SRIOCSREDIR", NULL },
698 699 { (uint_t)SRIOCISREDIR, "SRIOCISREDIR", NULL },
699 700 { (uint_t)CPCIO_BIND, "CPCIO_BIND", NULL },
700 701 { (uint_t)CPCIO_SAMPLE, "CPCIO_SAMPLE", NULL },
701 702 { (uint_t)CPCIO_RELE, "CPCIO_RELE", NULL },
702 703 /* /dev/poll ioctl() control codes */
703 704 { (uint_t)DP_POLL, "DP_POLL", NULL },
704 705 { (uint_t)DP_ISPOLLED, "DP_ISPOLLED", NULL },
705 706 /* the old /proc ioctl() control codes */
706 707 #define PIOC ('q'<<8)
707 708 { (uint_t)(PIOC|1), "PIOCSTATUS", NULL },
708 709 { (uint_t)(PIOC|2), "PIOCSTOP", NULL },
709 710 { (uint_t)(PIOC|3), "PIOCWSTOP", NULL },
710 711 { (uint_t)(PIOC|4), "PIOCRUN", NULL },
711 712 { (uint_t)(PIOC|5), "PIOCGTRACE", NULL },
712 713 { (uint_t)(PIOC|6), "PIOCSTRACE", NULL },
713 714 { (uint_t)(PIOC|7), "PIOCSSIG", NULL },
714 715 { (uint_t)(PIOC|8), "PIOCKILL", NULL },
715 716 { (uint_t)(PIOC|9), "PIOCUNKILL", NULL },
716 717 { (uint_t)(PIOC|10), "PIOCGHOLD", NULL },
717 718 { (uint_t)(PIOC|11), "PIOCSHOLD", NULL },
718 719 { (uint_t)(PIOC|12), "PIOCMAXSIG", NULL },
719 720 { (uint_t)(PIOC|13), "PIOCACTION", NULL },
720 721 { (uint_t)(PIOC|14), "PIOCGFAULT", NULL },
721 722 { (uint_t)(PIOC|15), "PIOCSFAULT", NULL },
722 723 { (uint_t)(PIOC|16), "PIOCCFAULT", NULL },
723 724 { (uint_t)(PIOC|17), "PIOCGENTRY", NULL },
724 725 { (uint_t)(PIOC|18), "PIOCSENTRY", NULL },
725 726 { (uint_t)(PIOC|19), "PIOCGEXIT", NULL },
726 727 { (uint_t)(PIOC|20), "PIOCSEXIT", NULL },
727 728 { (uint_t)(PIOC|21), "PIOCSFORK", NULL },
728 729 { (uint_t)(PIOC|22), "PIOCRFORK", NULL },
729 730 { (uint_t)(PIOC|23), "PIOCSRLC", NULL },
730 731 { (uint_t)(PIOC|24), "PIOCRRLC", NULL },
731 732 { (uint_t)(PIOC|25), "PIOCGREG", NULL },
732 733 { (uint_t)(PIOC|26), "PIOCSREG", NULL },
733 734 { (uint_t)(PIOC|27), "PIOCGFPREG", NULL },
734 735 { (uint_t)(PIOC|28), "PIOCSFPREG", NULL },
735 736 { (uint_t)(PIOC|29), "PIOCNICE", NULL },
736 737 { (uint_t)(PIOC|30), "PIOCPSINFO", NULL },
737 738 { (uint_t)(PIOC|31), "PIOCNMAP", NULL },
738 739 { (uint_t)(PIOC|32), "PIOCMAP", NULL },
739 740 { (uint_t)(PIOC|33), "PIOCOPENM", NULL },
740 741 { (uint_t)(PIOC|34), "PIOCCRED", NULL },
741 742 { (uint_t)(PIOC|35), "PIOCGROUPS", NULL },
742 743 { (uint_t)(PIOC|36), "PIOCGETPR", NULL },
743 744 { (uint_t)(PIOC|37), "PIOCGETU", NULL },
744 745 { (uint_t)(PIOC|38), "PIOCSET", NULL },
745 746 { (uint_t)(PIOC|39), "PIOCRESET", NULL },
746 747 { (uint_t)(PIOC|43), "PIOCUSAGE", NULL },
747 748 { (uint_t)(PIOC|44), "PIOCOPENPD", NULL },
748 749 { (uint_t)(PIOC|45), "PIOCLWPIDS", NULL },
749 750 { (uint_t)(PIOC|46), "PIOCOPENLWP", NULL },
750 751 { (uint_t)(PIOC|47), "PIOCLSTATUS", NULL },
751 752 { (uint_t)(PIOC|48), "PIOCLUSAGE", NULL },
752 753 { (uint_t)(PIOC|49), "PIOCNAUXV", NULL },
753 754 { (uint_t)(PIOC|50), "PIOCAUXV", NULL },
754 755 { (uint_t)(PIOC|51), "PIOCGXREGSIZE", NULL },
755 756 { (uint_t)(PIOC|52), "PIOCGXREG", NULL },
756 757 { (uint_t)(PIOC|53), "PIOCSXREG", NULL },
757 758 { (uint_t)(PIOC|101), "PIOCGWIN", NULL },
758 759 { (uint_t)(PIOC|103), "PIOCNLDT", NULL },
759 760 { (uint_t)(PIOC|104), "PIOCLDT", NULL },
760 761
761 762 /* ioctl's applicable on sockets */
762 763 { (uint_t)SIOCSHIWAT, "SIOCSHIWAT", NULL },
763 764 { (uint_t)SIOCGHIWAT, "SIOCGHIWAT", NULL },
764 765 { (uint_t)SIOCSLOWAT, "SIOCSLOWAT", NULL },
765 766 { (uint_t)SIOCGLOWAT, "SIOCGLOWAT", NULL },
766 767 { (uint_t)SIOCATMARK, "SIOCATMARK", NULL },
767 768 { (uint_t)SIOCSPGRP, "SIOCSPGRP", NULL },
768 769 { (uint_t)SIOCGPGRP, "SIOCGPGRP", NULL },
769 770 { (uint_t)SIOCADDRT, "SIOCADDRT", "rtentry" },
770 771 { (uint_t)SIOCDELRT, "SIOCDELRT", "rtentry" },
771 772 { (uint_t)SIOCGETVIFCNT, "SIOCGETVIFCNT", "sioc_vif_req" },
772 773 { (uint_t)SIOCGETSGCNT, "SIOCGETSGCNT", "sioc_sg_req" },
773 774 { (uint_t)SIOCGETLSGCNT, "SIOCGETLSGCNT", "sioc_lsg_req" },
774 775 { (uint_t)SIOCSIFADDR, "SIOCSIFADDR", "ifreq" },
775 776 { (uint_t)SIOCGIFADDR, "SIOCGIFADDR", "ifreq" },
776 777 { (uint_t)SIOCSIFDSTADDR, "SIOCSIFDSTADDR", "ifreq" },
777 778 { (uint_t)SIOCGIFDSTADDR, "SIOCGIFDSTADDR", "ifreq" },
778 779 { (uint_t)SIOCSIFFLAGS, "SIOCSIFFLAGS", "ifreq" },
779 780 { (uint_t)SIOCGIFFLAGS, "SIOCGIFFLAGS", "ifreq" },
780 781 { (uint_t)SIOCSIFMEM, "SIOCSIFMEM", "ifreq" },
781 782 { (uint_t)SIOCGIFMEM, "SIOCGIFMEM", "ifreq" },
782 783 { (uint_t)SIOCGIFCONF, "SIOCGIFCONF", "ifconf" },
783 784 { (uint_t)SIOCSIFMTU, "SIOCSIFMTU", "ifreq" },
784 785 { (uint_t)SIOCGIFMTU, "SIOCGIFMTU", "ifreq" },
785 786 { (uint_t)SIOCGIFBRDADDR, "SIOCGIFBRDADDR", "ifreq" },
786 787 { (uint_t)SIOCSIFBRDADDR, "SIOCSIFBRDADDR", "ifreq" },
787 788 { (uint_t)SIOCGIFNETMASK, "SIOCGIFNETMASK", "ifreq" },
788 789 { (uint_t)SIOCSIFNETMASK, "SIOCSIFNETMASK", "ifreq" },
789 790 { (uint_t)SIOCGIFMETRIC, "SIOCGIFMETRIC", "ifreq" },
790 791 { (uint_t)SIOCSIFMETRIC, "SIOCSIFMETRIC", "ifreq" },
791 792 { (uint_t)SIOCSARP, "SIOCSARP", "arpreq" },
792 793 { (uint_t)SIOCGARP, "SIOCGARP", "arpreq" },
793 794 { (uint_t)SIOCDARP, "SIOCDARP", "arpreq" },
794 795 { (uint_t)SIOCUPPER, "SIOCUPPER", "ifreq" },
795 796 { (uint_t)SIOCLOWER, "SIOCLOWER", "ifreq" },
796 797 { (uint_t)SIOCSETSYNC, "SIOCSETSYNC", "ifreq" },
797 798 { (uint_t)SIOCGETSYNC, "SIOCGETSYNC", "ifreq" },
798 799 { (uint_t)SIOCSSDSTATS, "SIOCSSDSTATS", "ifreq" },
799 800 { (uint_t)SIOCSSESTATS, "SIOCSSESTATS", "ifreq" },
800 801 { (uint_t)SIOCSPROMISC, "SIOCSPROMISC", NULL },
801 802 { (uint_t)SIOCADDMULTI, "SIOCADDMULTI", "ifreq" },
802 803 { (uint_t)SIOCDELMULTI, "SIOCDELMULTI", "ifreq" },
803 804 { (uint_t)SIOCGETNAME, "SIOCGETNAME", "sockaddr" },
804 805 { (uint_t)SIOCGETPEER, "SIOCGETPEER", "sockaddr" },
805 806 { (uint_t)IF_UNITSEL, "IF_UNITSEL", NULL },
806 807 { (uint_t)SIOCXPROTO, "SIOCXPROTO", NULL },
807 808 { (uint_t)SIOCIFDETACH, "SIOCIFDETACH", "ifreq" },
808 809 { (uint_t)SIOCGENPSTATS, "SIOCGENPSTATS", "ifreq" },
809 810 { (uint_t)SIOCX25XMT, "SIOCX25XMT", "ifreq" },
810 811 { (uint_t)SIOCX25RCV, "SIOCX25RCV", "ifreq" },
811 812 { (uint_t)SIOCX25TBL, "SIOCX25TBL", "ifreq" },
812 813 { (uint_t)SIOCSLGETREQ, "SIOCSLGETREQ", "ifreq" },
813 814 { (uint_t)SIOCSLSTAT, "SIOCSLSTAT", "ifreq" },
814 815 { (uint_t)SIOCSIFNAME, "SIOCSIFNAME", "ifreq" },
815 816 { (uint_t)SIOCGENADDR, "SIOCGENADDR", "ifreq" },
816 817 { (uint_t)SIOCGIFNUM, "SIOCGIFNUM", NULL },
817 818 { (uint_t)SIOCGIFMUXID, "SIOCGIFMUXID", "ifreq" },
818 819 { (uint_t)SIOCSIFMUXID, "SIOCSIFMUXID", "ifreq" },
819 820 { (uint_t)SIOCGIFINDEX, "SIOCGIFINDEX", "ifreq" },
820 821 { (uint_t)SIOCSIFINDEX, "SIOCSIFINDEX", "ifreq" },
821 822 { (uint_t)SIOCLIFREMOVEIF, "SIOCLIFREMOVEIF", "lifreq" },
822 823 { (uint_t)SIOCLIFADDIF, "SIOCLIFADDIF", "lifreq" },
823 824 { (uint_t)SIOCSLIFADDR, "SIOCSLIFADDR", "lifreq" },
824 825 { (uint_t)SIOCGLIFADDR, "SIOCGLIFADDR", "lifreq" },
825 826 { (uint_t)SIOCSLIFDSTADDR, "SIOCSLIFDSTADDR", "lifreq" },
826 827 { (uint_t)SIOCGLIFDSTADDR, "SIOCGLIFDSTADDR", "lifreq" },
827 828 { (uint_t)SIOCSLIFFLAGS, "SIOCSLIFFLAGS", "lifreq" },
828 829 { (uint_t)SIOCGLIFFLAGS, "SIOCGLIFFLAGS", "lifreq" },
829 830 { (uint_t)SIOCGLIFCONF, "SIOCGLIFCONF", "lifconf" },
830 831 { (uint_t)SIOCSLIFMTU, "SIOCSLIFMTU", "lifreq" },
831 832 { (uint_t)SIOCGLIFMTU, "SIOCGLIFMTU", "lifreq" },
832 833 { (uint_t)SIOCGLIFBRDADDR, "SIOCGLIFBRDADDR", "lifreq" },
833 834 { (uint_t)SIOCSLIFBRDADDR, "SIOCSLIFBRDADDR", "lifreq" },
834 835 { (uint_t)SIOCGLIFNETMASK, "SIOCGLIFNETMASK", "lifreq" },
835 836 { (uint_t)SIOCSLIFNETMASK, "SIOCSLIFNETMASK", "lifreq" },
836 837 { (uint_t)SIOCGLIFMETRIC, "SIOCGLIFMETRIC", "lifreq" },
837 838 { (uint_t)SIOCSLIFMETRIC, "SIOCSLIFMETRIC", "lifreq" },
838 839 { (uint_t)SIOCSLIFNAME, "SIOCSLIFNAME", "lifreq" },
839 840 { (uint_t)SIOCGLIFNUM, "SIOCGLIFNUM", "lifnum" },
840 841 { (uint_t)SIOCGLIFMUXID, "SIOCGLIFMUXID", "lifreq" },
841 842 { (uint_t)SIOCSLIFMUXID, "SIOCSLIFMUXID", "lifreq" },
842 843 { (uint_t)SIOCGLIFINDEX, "SIOCGLIFINDEX", "lifreq" },
843 844 { (uint_t)SIOCSLIFINDEX, "SIOCSLIFINDEX", "lifreq" },
844 845 { (uint_t)SIOCSLIFTOKEN, "SIOCSLIFTOKEN", "lifreq" },
845 846 { (uint_t)SIOCGLIFTOKEN, "SIOCGLIFTOKEN", "lifreq" },
846 847 { (uint_t)SIOCSLIFSUBNET, "SIOCSLIFSUBNET", "lifreq" },
847 848 { (uint_t)SIOCGLIFSUBNET, "SIOCGLIFSUBNET", "lifreq" },
848 849 { (uint_t)SIOCSLIFLNKINFO, "SIOCSLIFLNKINFO", "lifreq" },
849 850 { (uint_t)SIOCGLIFLNKINFO, "SIOCGLIFLNKINFO", "lifreq" },
850 851 { (uint_t)SIOCLIFDELND, "SIOCLIFDELND", "lifreq" },
851 852 { (uint_t)SIOCLIFGETND, "SIOCLIFGETND", "lifreq" },
852 853 { (uint_t)SIOCLIFSETND, "SIOCLIFSETND", "lifreq" },
853 854 { (uint_t)SIOCTMYADDR, "SIOCTMYADDR", "sioc_addrreq" },
854 855 { (uint_t)SIOCTONLINK, "SIOCTONLINK", "sioc_addrreq" },
855 856 { (uint_t)SIOCTMYSITE, "SIOCTMYSITE", "sioc_addrreq" },
856 857 { (uint_t)SIOCFIPSECONFIG, "SIOCFIPSECONFIG", NULL },
857 858 { (uint_t)SIOCSIPSECONFIG, "SIOCSIPSECONFIG", NULL },
858 859 { (uint_t)SIOCDIPSECONFIG, "SIOCDIPSECONFIG", NULL },
859 860 { (uint_t)SIOCLIPSECONFIG, "SIOCLIPSECONFIG", NULL },
860 861 { (uint_t)SIOCGLIFBINDING, "SIOCGLIFBINDING", "lifreq" },
861 862 { (uint_t)SIOCSLIFGROUPNAME, "SIOCSLIFGROUPNAME", "lifreq" },
862 863 { (uint_t)SIOCGLIFGROUPNAME, "SIOCGLIFGROUPNAME", "lifreq" },
863 864 { (uint_t)SIOCGLIFGROUPINFO, "SIOCGLIFGROUPINFO", "lifgroupinfo" },
864 865 { (uint_t)SIOCGDSTINFO, "SIOCGDSTINFO", NULL },
865 866 { (uint_t)SIOCGIP6ADDRPOLICY, "SIOCGIP6ADDRPOLICY", NULL },
866 867 { (uint_t)SIOCSIP6ADDRPOLICY, "SIOCSIP6ADDRPOLICY", NULL },
867 868 { (uint_t)SIOCSXARP, "SIOCSXARP", "xarpreq" },
868 869 { (uint_t)SIOCGXARP, "SIOCGXARP", "xarpreq" },
869 870 { (uint_t)SIOCDXARP, "SIOCDXARP", "xarpreq" },
870 871 { (uint_t)SIOCGLIFZONE, "SIOCGLIFZONE", "lifreq" },
871 872 { (uint_t)SIOCSLIFZONE, "SIOCSLIFZONE", "lifreq" },
872 873 { (uint_t)SIOCSCTPSOPT, "SIOCSCTPSOPT", NULL },
873 874 { (uint_t)SIOCSCTPGOPT, "SIOCSCTPGOPT", NULL },
874 875 { (uint_t)SIOCSCTPPEELOFF, "SIOPCSCTPPEELOFF", "int" },
875 876 { (uint_t)SIOCGLIFUSESRC, "SIOCGLIFUSESRC", "lifreq" },
876 877 { (uint_t)SIOCSLIFUSESRC, "SIOCSLIFUSESRC", "lifreq" },
877 878 { (uint_t)SIOCGLIFSRCOF, "SIOCGLIFSRCOF", "lifsrcof" },
878 879 { (uint_t)SIOCGMSFILTER, "SIOCGMSFILTER", "group_filter" },
879 880 { (uint_t)SIOCSMSFILTER, "SIOCSMSFILTER", "group_filter" },
880 881 { (uint_t)SIOCGIPMSFILTER, "SIOCGIPMSFILTER", "ip_msfilter" },
881 882 { (uint_t)SIOCSIPMSFILTER, "SIOCSIPMSFILTER", "ip_msfilter" },
882 883 { (uint_t)SIOCGLIFDADSTATE, "SIOCGLIFDADSTATE", "lifreq" },
883 884 { (uint_t)SIOCSLIFPREFIX, "SIOCSLIFPREFIX", "lifreq" },
884 885 { (uint_t)SIOCGSTAMP, "SIOCGSTAMP", "timeval" },
885 886 { (uint_t)SIOCGIFHWADDR, "SIOCGIFHWADDR", "ifreq" },
886 887 { (uint_t)SIOCGLIFHWADDR, "SIOCGLIFHWADDR", "lifreq" },
887 888
888 889 /* DES encryption */
889 890 { (uint_t)DESIOCBLOCK, "DESIOCBLOCK", "desparams" },
890 891 { (uint_t)DESIOCQUICK, "DESIOCQUICK", "desparams" },
891 892
892 893 /* Printing system */
893 894 { (uint_t)PRNIOC_GET_IFCAP, "PRNIOC_GET_IFCAP", NULL },
894 895 { (uint_t)PRNIOC_SET_IFCAP, "PRNIOC_SET_IFCAP", NULL },
895 896 { (uint_t)PRNIOC_GET_IFINFO, "PRNIOC_GET_IFINFO",
896 897 "prn_interface_info" },
897 898 { (uint_t)PRNIOC_GET_STATUS, "PRNIOC_GET_STATUS", NULL },
898 899 { (uint_t)PRNIOC_GET_1284_DEVID, "PRNIOC_GET_1284_DEVID",
899 900 "prn_1284_device_id" },
900 901 { (uint_t)PRNIOC_GET_1284_STATUS,
901 902 "PRNIOC_GET_IFCANIOC_GET_1284_STATUS", NULL },
902 903 { (uint_t)PRNIOC_GET_TIMEOUTS, "PRNIOC_GET_TIMEOUTS",
903 904 "prn_timeouts" },
904 905 { (uint_t)PRNIOC_SET_TIMEOUTS, "PRNIOC_SET_TIMEOUTS",
905 906 "prn_timeouts" },
906 907 { (uint_t)PRNIOC_RESET, "PRNIOC_RESET", NULL },
907 908
908 909 /* DTrace */
909 910 { (uint_t)DTRACEIOC_PROVIDER, "DTRACEIOC_PROVIDER", NULL },
910 911 { (uint_t)DTRACEIOC_PROBES, "DTRACEIOC_PROBES", NULL },
911 912 { (uint_t)DTRACEIOC_BUFSNAP, "DTRACEIOC_BUFSNAP", NULL },
912 913 { (uint_t)DTRACEIOC_PROBEMATCH, "DTRACEIOC_PROBEMATCH", NULL },
913 914 { (uint_t)DTRACEIOC_ENABLE, "DTRACEIOC_ENABLE", NULL },
914 915 { (uint_t)DTRACEIOC_AGGSNAP, "DTRACEIOC_AGGSNAP", NULL },
915 916 { (uint_t)DTRACEIOC_EPROBE, "DTRACEIOC_EPROBE", NULL },
916 917 { (uint_t)DTRACEIOC_PROBEARG, "DTRACEIOC_PROBEARG", NULL },
917 918 { (uint_t)DTRACEIOC_CONF, "DTRACEIOC_CONF", NULL },
918 919 { (uint_t)DTRACEIOC_STATUS, "DTRACEIOC_STATUS", NULL },
919 920 { (uint_t)DTRACEIOC_GO, "DTRACEIOC_GO", NULL },
920 921 { (uint_t)DTRACEIOC_STOP, "DTRACEIOC_STOP", NULL },
921 922 { (uint_t)DTRACEIOC_AGGDESC, "DTRACEIOC_AGGDESC", NULL },
922 923 { (uint_t)DTRACEIOC_FORMAT, "DTRACEIOC_FORMAT", NULL },
923 924 { (uint_t)DTRACEIOC_DOFGET, "DTRACEIOC_DOFGET", NULL },
924 925 { (uint_t)DTRACEIOC_REPLICATE, "DTRACEIOC_REPLICATE", NULL },
925 926
926 927 { (uint_t)DTRACEHIOC_ADD, "DTRACEHIOC_ADD", NULL },
927 928 { (uint_t)DTRACEHIOC_REMOVE, "DTRACEHIOC_REMOVE", NULL },
928 929 { (uint_t)DTRACEHIOC_ADDDOF, "DTRACEHIOC_ADDDOF", NULL },
929 930
930 931 /* /dev/cryptoadm ioctl() control codes */
931 932 { (uint_t)CRYPTO_GET_VERSION, "CRYPTO_GET_VERSION", NULL },
932 933 { (uint_t)CRYPTO_GET_DEV_LIST, "CRYPTO_GET_DEV_LIST", NULL },
933 934 { (uint_t)CRYPTO_GET_SOFT_LIST, "CRYPTO_GET_SOFT_LIST", NULL },
934 935 { (uint_t)CRYPTO_GET_DEV_INFO, "CRYPTO_GET_DEV_INFO", NULL },
935 936 { (uint_t)CRYPTO_GET_SOFT_INFO, "CRYPTO_GET_SOFT_INFO", NULL },
936 937 { (uint_t)CRYPTO_LOAD_DEV_DISABLED, "CRYPTO_LOAD_DEV_DISABLED",
937 938 NULL },
938 939 { (uint_t)CRYPTO_LOAD_SOFT_DISABLED, "CRYPTO_LOAD_SOFT_DISABLED",
939 940 NULL },
940 941 { (uint_t)CRYPTO_UNLOAD_SOFT_MODULE, "CRYPTO_UNLOAD_SOFT_MODULE",
941 942 NULL },
942 943 { (uint_t)CRYPTO_LOAD_SOFT_CONFIG, "CRYPTO_LOAD_SOFT_CONFIG",
943 944 NULL },
944 945 { (uint_t)CRYPTO_POOL_CREATE, "CRYPTO_POOL_CREATE", NULL },
945 946 { (uint_t)CRYPTO_POOL_WAIT, "CRYPTO_POOL_WAIT", NULL },
946 947 { (uint_t)CRYPTO_POOL_RUN, "CRYPTO_POOL_RUN", NULL },
947 948 { (uint_t)CRYPTO_LOAD_DOOR, "CRYPTO_LOAD_DOOR", NULL },
948 949
949 950 /* /dev/crypto ioctl() control codes */
950 951 { (uint_t)CRYPTO_GET_FUNCTION_LIST, "CRYPTO_GET_FUNCTION_LIST",
951 952 NULL },
952 953 { (uint_t)CRYPTO_GET_MECHANISM_NUMBER, "CRYPTO_GET_MECHANISM_NUMBER",
953 954 NULL },
954 955 { (uint_t)CRYPTO_OPEN_SESSION, "CRYPTO_OPEN_SESSION", NULL },
955 956 { (uint_t)CRYPTO_CLOSE_SESSION, "CRYPTO_CLOSE_SESSION", NULL },
956 957 { (uint_t)CRYPTO_CLOSE_ALL_SESSIONS, "CRYPTO_CLOSE_ALL_SESSIONS",
957 958 NULL },
958 959 { (uint_t)CRYPTO_LOGIN, "CRYPTO_LOGIN", NULL },
959 960 { (uint_t)CRYPTO_LOGOUT, "CRYPTO_LOGOUT", NULL },
960 961 { (uint_t)CRYPTO_ENCRYPT, "CRYPTO_ENCRYPT", NULL },
961 962 { (uint_t)CRYPTO_ENCRYPT_INIT, "CRYPTO_ENCRYPT_INIT", NULL },
962 963 { (uint_t)CRYPTO_ENCRYPT_UPDATE, "CRYPTO_ENCRYPT_UPDATE",
963 964 NULL },
964 965 { (uint_t)CRYPTO_ENCRYPT_FINAL, "CRYPTO_ENCRYPT_FINAL", NULL },
965 966 { (uint_t)CRYPTO_DECRYPT, "CRYPTO_DECRYPT", NULL },
966 967 { (uint_t)CRYPTO_DECRYPT_INIT, "CRYPTO_DECRYPT_INIT", NULL },
967 968 { (uint_t)CRYPTO_DECRYPT_UPDATE, "CRYPTO_DECRYPT_UPDATE",
968 969 NULL },
969 970 { (uint_t)CRYPTO_DECRYPT_FINAL, "CRYPTO_DECRYPT_FINAL", NULL },
970 971 { (uint_t)CRYPTO_DIGEST, "CRYPTO_DIGEST", NULL },
971 972 { (uint_t)CRYPTO_DIGEST_INIT, "CRYPTO_DIGEST_INIT", NULL },
972 973 { (uint_t)CRYPTO_DIGEST_UPDATE, "CRYPTO_DIGEST_UPDATE", NULL },
973 974 { (uint_t)CRYPTO_DIGEST_KEY, "CRYPTO_DIGEST_KEY", NULL },
974 975 { (uint_t)CRYPTO_DIGEST_FINAL, "CRYPTO_DIGEST_FINAL", NULL },
975 976 { (uint_t)CRYPTO_MAC, "CRYPTO_MAC", NULL },
976 977 { (uint_t)CRYPTO_MAC_INIT, "CRYPTO_MAC_INIT", NULL },
977 978 { (uint_t)CRYPTO_MAC_UPDATE, "CRYPTO_MAC_UPDATE", NULL },
978 979 { (uint_t)CRYPTO_MAC_FINAL, "CRYPTO_MAC_FINAL", NULL },
979 980 { (uint_t)CRYPTO_SIGN, "CRYPTO_SIGN", NULL },
980 981 { (uint_t)CRYPTO_SIGN_INIT, "CRYPTO_SIGN_INIT", NULL },
981 982 { (uint_t)CRYPTO_SIGN_UPDATE, "CRYPTO_SIGN_UPDATE", NULL },
982 983 { (uint_t)CRYPTO_SIGN_FINAL, "CRYPTO_SIGN_FINAL", NULL },
983 984 { (uint_t)CRYPTO_SIGN_RECOVER_INIT, "CRYPTO_SIGN_RECOVER_INIT",
984 985 NULL },
985 986 { (uint_t)CRYPTO_SIGN_RECOVER, "CRYPTO_SIGN_RECOVER", NULL },
986 987 { (uint_t)CRYPTO_VERIFY, "CRYPTO_VERIFY", NULL },
987 988 { (uint_t)CRYPTO_VERIFY_INIT, "CRYPTO_VERIFY_INIT", NULL },
988 989 { (uint_t)CRYPTO_VERIFY_UPDATE, "CRYPTO_VERIFY_UPDATE", NULL },
989 990 { (uint_t)CRYPTO_VERIFY_FINAL, "CRYPTO_VERIFY_FINAL", NULL },
990 991 { (uint_t)CRYPTO_VERIFY_RECOVER_INIT, "CRYPTO_VERIFY_RECOVER_INIT",
991 992 NULL },
992 993 { (uint_t)CRYPTO_VERIFY_RECOVER, "CRYPTO_VERIFY_RECOVER",
993 994 NULL },
994 995 { (uint_t)CRYPTO_DIGEST_ENCRYPT_UPDATE, "CRYPTO_DIGEST_ENCRYPT_UPDATE",
995 996 NULL },
996 997 { (uint_t)CRYPTO_DECRYPT_DIGEST_UPDATE, "CRYPTO_DECRYPT_DIGEST_UPDATE",
997 998 NULL },
998 999 { (uint_t)CRYPTO_SIGN_ENCRYPT_UPDATE, "CRYPTO_SIGN_ENCRYPT_UPDATE",
999 1000 NULL },
1000 1001 { (uint_t)CRYPTO_DECRYPT_VERIFY_UPDATE, "CRYPTO_DECRYPT_VERIFY_UPDATE",
1001 1002 NULL },
1002 1003 { (uint_t)CRYPTO_SEED_RANDOM, "CRYPTO_SEED_RANDOM", NULL },
1003 1004 { (uint_t)CRYPTO_GENERATE_RANDOM, "CRYPTO_GENERATE_RANDOM",
1004 1005 NULL },
1005 1006 { (uint_t)CRYPTO_OBJECT_CREATE, "CRYPTO_OBJECT_CREATE", NULL },
1006 1007 { (uint_t)CRYPTO_OBJECT_COPY, "CRYPTO_OBJECT_COPY", NULL },
1007 1008 { (uint_t)CRYPTO_OBJECT_DESTROY, "CRYPTO_OBJECT_DESTROY",
1008 1009 NULL },
1009 1010 { (uint_t)CRYPTO_OBJECT_GET_ATTRIBUTE_VALUE,
1010 1011 "CRYPTO_OBJECT_GET_ATTRIBUTE_VALUE", NULL },
1011 1012 { (uint_t)CRYPTO_OBJECT_GET_SIZE, "CRYPTO_OBJECT_GET_SIZE", NULL },
1012 1013 { (uint_t)CRYPTO_OBJECT_SET_ATTRIBUTE_VALUE,
1013 1014 "CRYPTO_OBJECT_SET_ATTRIBUTE_VALUE", NULL },
1014 1015 { (uint_t)CRYPTO_OBJECT_FIND_INIT, "CRYPTO_OBJECT_FIND_INIT",
1015 1016 NULL },
1016 1017 { (uint_t)CRYPTO_OBJECT_FIND_UPDATE, "CRYPTO_OBJECT_FIND_UPDATE",
1017 1018 NULL },
1018 1019 { (uint_t)CRYPTO_OBJECT_FIND_FINAL, "CRYPTO_OBJECT_FIND_FINAL",
1019 1020 NULL },
1020 1021 { (uint_t)CRYPTO_GENERATE_KEY, "CRYPTO_GENERATE_KEY", NULL },
1021 1022 { (uint_t)CRYPTO_GENERATE_KEY_PAIR, "CRYPTO_GENERATE_KEY_PAIR",
1022 1023 NULL },
1023 1024 { (uint_t)CRYPTO_WRAP_KEY, "CRYPTO_WRAP_KEY", NULL },
1024 1025 { (uint_t)CRYPTO_UNWRAP_KEY, "CRYPTO_UNWRAP_KEY", NULL },
1025 1026 { (uint_t)CRYPTO_DERIVE_KEY, "CRYPTO_DERIVE_KEY", NULL },
1026 1027 { (uint_t)CRYPTO_GET_PROVIDER_LIST, "CRYPTO_GET_PROVIDER_LIST",
1027 1028 NULL },
1028 1029 { (uint_t)CRYPTO_GET_PROVIDER_INFO, "CRYPTO_GET_PROVIDER_INFO",
1029 1030 NULL },
1030 1031 { (uint_t)CRYPTO_GET_PROVIDER_MECHANISMS,
1031 1032 "CRYPTO_GET_PROVIDER_MECHANISMS", NULL },
1032 1033 { (uint_t)CRYPTO_GET_PROVIDER_MECHANISM_INFO,
1033 1034 "CRYPTO_GET_PROVIDER_MECHANISM_INFO", NULL },
1034 1035 { (uint_t)CRYPTO_INIT_TOKEN, "CRYPTO_INIT_TOKEN", NULL },
1035 1036 { (uint_t)CRYPTO_INIT_PIN, "CRYPTO_INIT_PIN", NULL },
1036 1037 { (uint_t)CRYPTO_SET_PIN, "CRYPTO_SET_PIN", NULL },
1037 1038 { (uint_t)CRYPTO_NOSTORE_GENERATE_KEY,
1038 1039 "CRYPTO_NOSTORE_GENERATE_KEY", NULL },
1039 1040 { (uint_t)CRYPTO_NOSTORE_GENERATE_KEY_PAIR,
1040 1041 "CRYPTO_NOSTORE_GENERATE_KEY_PAIR", NULL },
1041 1042 { (uint_t)CRYPTO_NOSTORE_DERIVE_KEY,
1042 1043 "CRYPTO_NOSTORE_DERIVE_KEY", NULL },
1043 1044 { (uint_t)CRYPTO_FIPS140_STATUS, "CRYPTO_FIPS140_STATUS", NULL },
1044 1045 { (uint_t)CRYPTO_FIPS140_SET, "CRYPTO_FIPS140_SET", NULL },
1045 1046
1046 1047 /* kbio ioctls */
1047 1048 { (uint_t)KIOCTRANS, "KIOCTRANS", NULL },
1048 1049 { (uint_t)KIOCGTRANS, "KIOCGTRANS", NULL },
1049 1050 { (uint_t)KIOCTRANSABLE, "KIOCTRANSABLE", NULL },
1050 1051 { (uint_t)KIOCGTRANSABLE, "KIOCGTRANSABLE", NULL },
1051 1052 { (uint_t)KIOCSETKEY, "KIOCSETKEY", NULL },
1052 1053 { (uint_t)KIOCGETKEY, "KIOCGETKEY", NULL },
1053 1054 { (uint_t)KIOCCMD, "KIOCCMD", NULL },
1054 1055 { (uint_t)KIOCTYPE, "KIOCTYPE", NULL },
1055 1056 { (uint_t)KIOCSDIRECT, "KIOCSDIRECT", NULL },
1056 1057 { (uint_t)KIOCGDIRECT, "KIOCGDIRECT", NULL },
1057 1058 { (uint_t)KIOCSKEY, "KIOCSKEY", NULL },
1058 1059 { (uint_t)KIOCGKEY, "KIOCGKEY", NULL },
1059 1060 { (uint_t)KIOCSLED, "KIOCSLED", NULL },
1060 1061 { (uint_t)KIOCGLED, "KIOCGLED", NULL },
1061 1062 { (uint_t)KIOCSCOMPAT, "KIOCSCOMPAT", NULL },
1062 1063 { (uint_t)KIOCGCOMPAT, "KIOCGCOMPAT", NULL },
1063 1064 { (uint_t)KIOCSLAYOUT, "KIOCSLAYOUT", NULL },
1064 1065 { (uint_t)KIOCLAYOUT, "KIOCLAYOUT", NULL },
1065 1066 { (uint_t)KIOCSKABORTEN, "KIOCSKABORTEN", NULL },
1066 1067 { (uint_t)KIOCGRPTDELAY, "KIOCGRPTDELAY", NULL },
1067 1068 { (uint_t)KIOCSRPTDELAY, "KIOCSRPTDELAY", NULL },
1068 1069 { (uint_t)KIOCGRPTRATE, "KIOCGRPTRATE", NULL },
1069 1070 { (uint_t)KIOCSRPTRATE, "KIOCSRPTRATE", NULL },
1070 1071 { (uint_t)KIOCSETFREQ, "KIOCSETFREQ", NULL },
1071 1072 { (uint_t)KIOCMKTONE, "KIOCMKTONE", NULL },
1072 1073
1073 1074 /* ptm/pts driver I_STR ioctls */
1074 1075 { (uint_t)ISPTM, "ISPTM", NULL},
1075 1076 { (uint_t)UNLKPT, "UNLKPT", NULL},
1076 1077 { (uint_t)PTSSTTY, "PTSSTTY", NULL},
1077 1078 { (uint_t)ZONEPT, "ZONEPT", NULL},
1078 1079 { (uint_t)OWNERPT, "OWNERPT", NULL},
1079 1080
1080 1081 /* aggr link aggregation pseudo driver ioctls */
1081 1082 { (uint_t)LAIOC_CREATE, "LAIOC_CREATE", "laioc_create"},
1082 1083 { (uint_t)LAIOC_DELETE, "LAIOC_DELETE", "laioc_delete"},
1083 1084 { (uint_t)LAIOC_INFO, "LAIOC_INFO", "laioc_info"},
1084 1085 { (uint_t)LAIOC_ADD, "LAIOC_ADD",
1085 1086 "laioc_add_rem"},
1086 1087 { (uint_t)LAIOC_REMOVE, "LAIOC_REMOVE",
1087 1088 "laioc_add_rem"},
1088 1089 { (uint_t)LAIOC_MODIFY, "LAIOC_MODIFY", "laioc_modify"},
1089 1090
1090 1091 /* dld data-link ioctls */
1091 1092 { (uint_t)DLDIOC_ATTR, "DLDIOC_ATTR", "dld_ioc_attr"},
1092 1093 { (uint_t)DLDIOC_PHYS_ATTR, "DLDIOC_PHYS_ATTR",
1093 1094 "dld_ioc_phys_attr"},
1094 1095 { (uint_t)DLDIOC_DOORSERVER, "DLDIOC_DOORSERVER", "dld_ioc_door"},
1095 1096 { (uint_t)DLDIOC_RENAME, "DLDIOC_RENAME", "dld_ioc_rename"},
1096 1097 { (uint_t)DLDIOC_SECOBJ_GET, "DLDIOC_SECOBJ_GET",
1097 1098 "dld_ioc_secobj_get"},
1098 1099 { (uint_t)DLDIOC_SECOBJ_SET, "DLDIOC_SECOBJ_SET",
1099 1100 "dld_ioc_secobj_set"},
1100 1101 { (uint_t)DLDIOC_SECOBJ_UNSET, "DLDIOC_SECOBJ_UNSET",
1101 1102 "dld_ioc_secobj_unset"},
1102 1103 { (uint_t)DLDIOC_MACADDRGET, "DLDIOC_MACADDRGET",
1103 1104 "dld_ioc_macaddrget"},
1104 1105 { (uint_t)DLDIOC_SETMACPROP, "DLDIOC_SETMACPROP",
1105 1106 "dld_ioc_macprop_s"},
1106 1107 { (uint_t)DLDIOC_GETMACPROP, "DLDIOC_GETMACPROP",
1107 1108 "dld_ioc_macprop_s"},
1108 1109 { (uint_t)DLDIOC_ADDFLOW, "DLDIOC_ADDFLOW",
1109 1110 "dld_ioc_addflow"},
1110 1111 { (uint_t)DLDIOC_REMOVEFLOW, "DLDIOC_REMOVEFLOW",
1111 1112 "dld_ioc_removeflow"},
1112 1113 { (uint_t)DLDIOC_MODIFYFLOW, "DLDIOC_MODIFYFLOW",
1113 1114 "dld_ioc_modifyflow"},
1114 1115 { (uint_t)DLDIOC_WALKFLOW, "DLDIOC_WALKFLOW",
1115 1116 "dld_ioc_walkflow"},
1116 1117 { (uint_t)DLDIOC_USAGELOG, "DLDIOC_USAGELOG",
1117 1118 "dld_ioc_usagelog"},
1118 1119
1119 1120 /* simnet ioctls */
1120 1121 { (uint_t)SIMNET_IOC_CREATE, "SIMNET_IOC_CREATE",
1121 1122 "simnet_ioc_create"},
1122 1123 { (uint_t)SIMNET_IOC_DELETE, "SIMNET_IOC_DELETE",
1123 1124 "simnet_ioc_delete"},
1124 1125 { (uint_t)SIMNET_IOC_INFO, "SIMNET_IOC_INFO",
1125 1126 "simnet_ioc_info"},
1126 1127 { (uint_t)SIMNET_IOC_MODIFY, "SIMNET_IOC_MODIFY",
1127 1128 "simnet_ioc_info"},
1128 1129
1129 1130 /* vnic ioctls */
1130 1131 { (uint_t)VNIC_IOC_CREATE, "VNIC_IOC_CREATE",
1131 1132 "vnic_ioc_create"},
1132 1133 { (uint_t)VNIC_IOC_DELETE, "VNIC_IOC_DELETE",
1133 1134 "vnic_ioc_delete"},
1134 1135 { (uint_t)VNIC_IOC_INFO, "VNIC_IOC_INFO",
1135 1136 "vnic_ioc_info"},
1136 1137
1137 1138 /* ZFS ioctls */
1138 1139 { (uint_t)ZFS_IOC_POOL_CREATE, "ZFS_IOC_POOL_CREATE",
1139 1140 "zfs_cmd_t" },
1140 1141 { (uint_t)ZFS_IOC_POOL_DESTROY, "ZFS_IOC_POOL_DESTROY",
1141 1142 "zfs_cmd_t" },
1142 1143 { (uint_t)ZFS_IOC_POOL_IMPORT, "ZFS_IOC_POOL_IMPORT",
1143 1144 "zfs_cmd_t" },
1144 1145 { (uint_t)ZFS_IOC_POOL_EXPORT, "ZFS_IOC_POOL_EXPORT",
1145 1146 "zfs_cmd_t" },
1146 1147 { (uint_t)ZFS_IOC_POOL_CONFIGS, "ZFS_IOC_POOL_CONFIGS",
1147 1148 "zfs_cmd_t" },
1148 1149 { (uint_t)ZFS_IOC_POOL_STATS, "ZFS_IOC_POOL_STATS",
1149 1150 "zfs_cmd_t" },
1150 1151 { (uint_t)ZFS_IOC_POOL_TRYIMPORT, "ZFS_IOC_POOL_TRYIMPORT",
1151 1152 "zfs_cmd_t" },
1152 1153 { (uint_t)ZFS_IOC_POOL_SCAN, "ZFS_IOC_POOL_SCAN",
1153 1154 "zfs_cmd_t" },
1154 1155 { (uint_t)ZFS_IOC_POOL_FREEZE, "ZFS_IOC_POOL_FREEZE",
1155 1156 "zfs_cmd_t" },
1156 1157 { (uint_t)ZFS_IOC_POOL_UPGRADE, "ZFS_IOC_POOL_UPGRADE",
1157 1158 "zfs_cmd_t" },
1158 1159 { (uint_t)ZFS_IOC_POOL_GET_HISTORY, "ZFS_IOC_POOL_GET_HISTORY",
1159 1160 "zfs_cmd_t" },
1160 1161 { (uint_t)ZFS_IOC_VDEV_ADD, "ZFS_IOC_VDEV_ADD",
1161 1162 "zfs_cmd_t" },
1162 1163 { (uint_t)ZFS_IOC_VDEV_REMOVE, "ZFS_IOC_VDEV_REMOVE",
1163 1164 "zfs_cmd_t" },
1164 1165 { (uint_t)ZFS_IOC_VDEV_SET_STATE, "ZFS_IOC_VDEV_SET_STATE",
1165 1166 "zfs_cmd_t" },
1166 1167 { (uint_t)ZFS_IOC_VDEV_ATTACH, "ZFS_IOC_VDEV_ATTACH",
1167 1168 "zfs_cmd_t" },
1168 1169 { (uint_t)ZFS_IOC_VDEV_DETACH, "ZFS_IOC_VDEV_DETACH",
1169 1170 "zfs_cmd_t" },
1170 1171 { (uint_t)ZFS_IOC_VDEV_SETPATH, "ZFS_IOC_VDEV_SETPATH",
1171 1172 "zfs_cmd_t" },
1172 1173 { (uint_t)ZFS_IOC_VDEV_SETFRU, "ZFS_IOC_VDEV_SETFRU",
1173 1174 "zfs_cmd_t" },
1174 1175 { (uint_t)ZFS_IOC_OBJSET_STATS, "ZFS_IOC_OBJSET_STATS",
1175 1176 "zfs_cmd_t" },
1176 1177 { (uint_t)ZFS_IOC_OBJSET_ZPLPROPS, "ZFS_IOC_OBJSET_ZPLPROPS",
1177 1178 "zfs_cmd_t" },
1178 1179 { (uint_t)ZFS_IOC_DATASET_LIST_NEXT, "ZFS_IOC_DATASET_LIST_NEXT",
1179 1180 "zfs_cmd_t" },
1180 1181 { (uint_t)ZFS_IOC_SNAPSHOT_LIST_NEXT, "ZFS_IOC_SNAPSHOT_LIST_NEXT",
1181 1182 "zfs_cmd_t" },
1182 1183 { (uint_t)ZFS_IOC_SET_PROP, "ZFS_IOC_SET_PROP",
1183 1184 "zfs_cmd_t" },
1184 1185 { (uint_t)ZFS_IOC_CREATE, "ZFS_IOC_CREATE",
1185 1186 "zfs_cmd_t" },
1186 1187 { (uint_t)ZFS_IOC_DESTROY, "ZFS_IOC_DESTROY",
1187 1188 "zfs_cmd_t" },
1188 1189 { (uint_t)ZFS_IOC_ROLLBACK, "ZFS_IOC_ROLLBACK",
1189 1190 "zfs_cmd_t" },
1190 1191 { (uint_t)ZFS_IOC_RENAME, "ZFS_IOC_RENAME",
1191 1192 "zfs_cmd_t" },
1192 1193 { (uint_t)ZFS_IOC_RECV, "ZFS_IOC_RECV",
1193 1194 "zfs_cmd_t" },
1194 1195 { (uint_t)ZFS_IOC_SEND, "ZFS_IOC_SEND",
1195 1196 "zfs_cmd_t" },
1196 1197 { (uint_t)ZFS_IOC_INJECT_FAULT, "ZFS_IOC_INJECT_FAULT",
1197 1198 "zfs_cmd_t" },
1198 1199 { (uint_t)ZFS_IOC_CLEAR_FAULT, "ZFS_IOC_CLEAR_FAULT",
1199 1200 "zfs_cmd_t" },
1200 1201 { (uint_t)ZFS_IOC_INJECT_LIST_NEXT, "ZFS_IOC_INJECT_LIST_NEXT",
1201 1202 "zfs_cmd_t" },
1202 1203 { (uint_t)ZFS_IOC_ERROR_LOG, "ZFS_IOC_ERROR_LOG",
1203 1204 "zfs_cmd_t" },
1204 1205 { (uint_t)ZFS_IOC_CLEAR, "ZFS_IOC_CLEAR",
1205 1206 "zfs_cmd_t" },
1206 1207 { (uint_t)ZFS_IOC_PROMOTE, "ZFS_IOC_PROMOTE",
1207 1208 "zfs_cmd_t" },
1208 1209 { (uint_t)ZFS_IOC_SNAPSHOT, "ZFS_IOC_SNAPSHOT",
1209 1210 "zfs_cmd_t" },
1210 1211 { (uint_t)ZFS_IOC_DSOBJ_TO_DSNAME, "ZFS_IOC_DSOBJ_TO_DSNAME",
1211 1212 "zfs_cmd_t" },
1212 1213 { (uint_t)ZFS_IOC_OBJ_TO_PATH, "ZFS_IOC_OBJ_TO_PATH",
1213 1214 "zfs_cmd_t" },
1214 1215 { (uint_t)ZFS_IOC_POOL_SET_PROPS, "ZFS_IOC_POOL_SET_PROPS",
1215 1216 "zfs_cmd_t" },
1216 1217 { (uint_t)ZFS_IOC_POOL_GET_PROPS, "ZFS_IOC_POOL_GET_PROPS",
1217 1218 "zfs_cmd_t" },
1218 1219 { (uint_t)ZFS_IOC_SET_FSACL, "ZFS_IOC_SET_FSACL",
1219 1220 "zfs_cmd_t" },
1220 1221 { (uint_t)ZFS_IOC_GET_FSACL, "ZFS_IOC_GET_FSACL",
1221 1222 "zfs_cmd_t" },
1222 1223 { (uint_t)ZFS_IOC_SHARE, "ZFS_IOC_SHARE",
1223 1224 "zfs_cmd_t" },
1224 1225 { (uint_t)ZFS_IOC_INHERIT_PROP, "ZFS_IOC_INHERIT_PROP",
1225 1226 "zfs_cmd_t" },
1226 1227 { (uint_t)ZFS_IOC_SMB_ACL, "ZFS_IOC_SMB_ACL",
1227 1228 "zfs_cmd_t" },
1228 1229 { (uint_t)ZFS_IOC_USERSPACE_ONE, "ZFS_IOC_USERSPACE_ONE",
1229 1230 "zfs_cmd_t" },
1230 1231 { (uint_t)ZFS_IOC_USERSPACE_MANY, "ZFS_IOC_USERSPACE_MANY",
1231 1232 "zfs_cmd_t" },
1232 1233 { (uint_t)ZFS_IOC_USERSPACE_UPGRADE, "ZFS_IOC_USERSPACE_UPGRADE",
1233 1234 "zfs_cmd_t" },
1234 1235 { (uint_t)ZFS_IOC_HOLD, "ZFS_IOC_HOLD",
1235 1236 "zfs_cmd_t" },
1236 1237 { (uint_t)ZFS_IOC_RELEASE, "ZFS_IOC_RELEASE",
1237 1238 "zfs_cmd_t" },
1238 1239 { (uint_t)ZFS_IOC_GET_HOLDS, "ZFS_IOC_GET_HOLDS",
1239 1240 "zfs_cmd_t" },
1240 1241 { (uint_t)ZFS_IOC_OBJSET_RECVD_PROPS, "ZFS_IOC_OBJSET_RECVD_PROPS",
1241 1242 "zfs_cmd_t" },
1242 1243 { (uint_t)ZFS_IOC_VDEV_SPLIT, "ZFS_IOC_VDEV_SPLIT",
1243 1244 "zfs_cmd_t" },
1244 1245 { (uint_t)ZFS_IOC_NEXT_OBJ, "ZFS_IOC_NEXT_OBJ",
1245 1246 "zfs_cmd_t" },
1246 1247 { (uint_t)ZFS_IOC_DIFF, "ZFS_IOC_DIFF",
1247 1248 "zfs_cmd_t" },
1248 1249 { (uint_t)ZFS_IOC_TMP_SNAPSHOT, "ZFS_IOC_TMP_SNAPSHOT",
1249 1250 "zfs_cmd_t" },
1250 1251 { (uint_t)ZFS_IOC_OBJ_TO_STATS, "ZFS_IOC_OBJ_TO_STATS",
1251 1252 "zfs_cmd_t" },
1252 1253 { (uint_t)ZFS_IOC_SPACE_WRITTEN, "ZFS_IOC_SPACE_WRITTEN",
1253 1254 "zfs_cmd_t" },
1254 1255 { (uint_t)ZFS_IOC_DESTROY_SNAPS, "ZFS_IOC_DESTROY_SNAPS",
1255 1256 "zfs_cmd_t" },
1256 1257 { (uint_t)ZFS_IOC_POOL_REGUID, "ZFS_IOC_POOL_REGUID",
1257 1258 "zfs_cmd_t" },
1258 1259 { (uint_t)ZFS_IOC_POOL_REOPEN, "ZFS_IOC_POOL_REOPEN",
1259 1260 "zfs_cmd_t" },
1260 1261 { (uint_t)ZFS_IOC_SEND_PROGRESS, "ZFS_IOC_SEND_PROGRESS",
1261 1262 "zfs_cmd_t" },
1262 1263 { (uint_t)ZFS_IOC_LOG_HISTORY, "ZFS_IOC_LOG_HISTORY",
1263 1264 "zfs_cmd_t" },
1264 1265 { (uint_t)ZFS_IOC_SEND_NEW, "ZFS_IOC_SEND_NEW",
1265 1266 "zfs_cmd_t" },
1266 1267 { (uint_t)ZFS_IOC_SEND_SPACE, "ZFS_IOC_SEND_SPACE",
1267 1268 "zfs_cmd_t" },
1268 1269 { (uint_t)ZFS_IOC_CLONE, "ZFS_IOC_CLONE",
1269 1270 "zfs_cmd_t" },
1270 1271
1271 1272 /* kssl ioctls */
1272 1273 { (uint_t)KSSL_ADD_ENTRY, "KSSL_ADD_ENTRY",
1273 1274 "kssl_params_t"},
1274 1275 { (uint_t)KSSL_DELETE_ENTRY, "KSSL_DELETE_ENTRY",
1275 1276 "sockaddr_in"},
1276 1277
1277 1278 /* disk ioctls - (0x04 << 8) - dkio.h */
1278 1279 { (uint_t)DKIOCGGEOM, "DKIOCGGEOM",
1279 1280 "struct dk_geom"},
1280 1281 { (uint_t)DKIOCINFO, "DKIOCINFO",
1281 1282 "struct dk_info"},
1282 1283 { (uint_t)DKIOCEJECT, "DKIOCEJECT",
1283 1284 NULL},
1284 1285 { (uint_t)DKIOCGVTOC, "DKIOCGVTOC",
1285 1286 "struct vtoc"},
1286 1287 { (uint_t)DKIOCSVTOC, "DKIOCSVTOC",
1287 1288 "struct vtoc"},
1288 1289 { (uint_t)DKIOCGEXTVTOC, "DKIOCGEXTVTOC",
1289 1290 "struct extvtoc"},
1290 1291 { (uint_t)DKIOCSEXTVTOC, "DKIOCSEXTVTOC",
1291 1292 "struct extvtoc"},
1292 1293 { (uint_t)DKIOCFLUSHWRITECACHE, "DKIOCFLUSHWRITECACHE",
1293 1294 NULL},
1294 1295 { (uint_t)DKIOCGETWCE, "DKIOCGETWCE",
1295 1296 NULL},
1296 1297 { (uint_t)DKIOCSETWCE, "DKIOCSETWCE",
1297 1298 NULL},
1298 1299 { (uint_t)DKIOCSGEOM, "DKIOCSGEOM",
1299 1300 "struct dk_geom"},
1300 1301 { (uint_t)DKIOCSAPART, "DKIOCSAPART",
1301 1302 "struct dk_allmap"},
1302 1303 { (uint_t)DKIOCGAPART, "DKIOCGAPART",
1303 1304 "struct dk_allmap"},
1304 1305 { (uint_t)DKIOCG_PHYGEOM, "DKIOCG_PHYGEOM",
1305 1306 "struct dk_geom"},
1306 1307 { (uint_t)DKIOCG_VIRTGEOM, "DKIOCG_VIRTGEOM",
1307 1308 "struct dk_geom"},
1308 1309 { (uint_t)DKIOCLOCK, "DKIOCLOCK",
1309 1310 NULL},
1310 1311 { (uint_t)DKIOCUNLOCK, "DKIOCUNLOCK",
1311 1312 NULL},
1312 1313 { (uint_t)DKIOCSTATE, "DKIOCSTATE",
1313 1314 NULL},
1314 1315 { (uint_t)DKIOCREMOVABLE, "DKIOCREMOVABLE",
1315 1316 NULL},
1316 1317 { (uint_t)DKIOCHOTPLUGGABLE, "DKIOCHOTPLUGGABLE",
1317 1318 NULL},
1318 1319 { (uint_t)DKIOCADDBAD, "DKIOCADDBAD",
1319 1320 NULL},
1320 1321 { (uint_t)DKIOCGETDEF, "DKIOCGETDEF",
1321 1322 NULL},
1322 1323 { (uint_t)DKIOCPARTINFO, "DKIOCPARTINFO",
1323 1324 "struct part_info"},
1324 1325 { (uint_t)DKIOCEXTPARTINFO, "DKIOCEXTPARTINFO",
1325 1326 "struct extpart_info"},
1326 1327 { (uint_t)DKIOCGMEDIAINFO, "DKIOCGMEDIAINFO",
1327 1328 "struct dk_minfo"},
1328 1329 { (uint_t)DKIOCGMBOOT, "DKIOCGMBOOT",
1329 1330 NULL},
1330 1331 { (uint_t)DKIOCSMBOOT, "DKIOCSMBOOT",
1331 1332 NULL},
1332 1333 { (uint_t)DKIOCSETEFI, "DKIOCSETEFI",
1333 1334 "struct dk_efi"},
1334 1335 { (uint_t)DKIOCGETEFI, "DKIOCGETEFI",
1335 1336 "struct dk_efi"},
1336 1337 { (uint_t)DKIOCPARTITION, "DKIOCPARTITION",
1337 1338 "struct partition64"},
1338 1339 { (uint_t)DKIOCGETVOLCAP, "DKIOCGETVOLCAP",
1339 1340 "struct volcap_t"},
1340 1341 { (uint_t)DKIOCSETVOLCAP, "DKIOCSETVOLCAP",
1341 1342 "struct volcap_t"},
1342 1343 { (uint_t)DKIOCDMR, "DKIOCDMR",
1343 1344 "struct vol_directed_rd"},
1344 1345 { (uint_t)DKIOCDUMPINIT, "DKIOCDUMPINIT",
1345 1346 NULL},
1346 1347 { (uint_t)DKIOCDUMPFINI, "DKIOCDUMPFINI",
1347 1348 NULL},
1348 1349 { (uint_t)DKIOCREADONLY, "DKIOCREADONLY",
1349 1350 NULL},
1350 1351
1351 1352 /* disk ioctls - (0x04 << 8) - fdio.h */
1352 1353 { (uint_t)FDIOGCHAR, "FDIOGCHAR",
1353 1354 "struct fd_char"},
1354 1355 { (uint_t)FDIOSCHAR, "FDIOSCHAR",
1355 1356 "struct fd_char"},
1356 1357 { (uint_t)FDEJECT, "FDEJECT",
1357 1358 NULL},
1358 1359 { (uint_t)FDGETCHANGE, "FDGETCHANGE",
1359 1360 NULL},
1360 1361 { (uint_t)FDGETDRIVECHAR, "FDGETDRIVECHAR",
1361 1362 "struct fd_drive"},
1362 1363 { (uint_t)FDSETDRIVECHAR, "FDSETDRIVECHAR",
1363 1364 "struct fd_drive"},
1364 1365 { (uint_t)FDGETSEARCH, "FDGETSEARCH",
1365 1366 NULL},
1366 1367 { (uint_t)FDSETSEARCH, "FDSETSEARCH",
1367 1368 NULL},
1368 1369 { (uint_t)FDIOCMD, "FDIOCMD",
1369 1370 "struct fd_cmd"},
1370 1371 { (uint_t)FDRAW, "FDRAW",
1371 1372 "struct fd_raw"},
1372 1373 { (uint_t)FDDEFGEOCHAR, "FDDEFGEOCHAR",
1373 1374 NULL},
1374 1375
1375 1376 /* disk ioctls - (0x04 << 8) - cdio.h */
1376 1377 { (uint_t)CDROMPAUSE, "CDROMPAUSE",
1377 1378 NULL},
1378 1379 { (uint_t)CDROMRESUME, "CDROMRESUME",
1379 1380 NULL},
1380 1381 { (uint_t)CDROMPLAYMSF, "CDROMPLAYMSF",
1381 1382 "struct cdrom_msf"},
1382 1383 { (uint_t)CDROMPLAYTRKIND, "CDROMPLAYTRKIND",
1383 1384 "struct cdrom_ti"},
1384 1385 { (uint_t)CDROMREADTOCHDR, "CDROMREADTOCHDR",
1385 1386 "struct cdrom_tochdr"},
1386 1387 { (uint_t)CDROMREADTOCENTRY, "CDROMREADTOCENTRY",
1387 1388 "struct cdrom_tocentry"},
1388 1389 { (uint_t)CDROMSTOP, "CDROMSTOP",
1389 1390 NULL},
1390 1391 { (uint_t)CDROMSTART, "CDROMSTART",
1391 1392 NULL},
1392 1393 { (uint_t)CDROMEJECT, "CDROMEJECT",
1393 1394 NULL},
1394 1395 { (uint_t)CDROMVOLCTRL, "CDROMVOLCTRL",
1395 1396 "struct cdrom_volctrl"},
1396 1397 { (uint_t)CDROMSUBCHNL, "CDROMSUBCHNL",
1397 1398 "struct cdrom_subchnl"},
1398 1399 { (uint_t)CDROMREADMODE2, "CDROMREADMODE2",
1399 1400 "struct cdrom_read"},
1400 1401 { (uint_t)CDROMREADMODE1, "CDROMREADMODE1",
1401 1402 "struct cdrom_read"},
1402 1403 { (uint_t)CDROMREADOFFSET, "CDROMREADOFFSET",
1403 1404 NULL},
1404 1405 { (uint_t)CDROMGBLKMODE, "CDROMGBLKMODE",
1405 1406 NULL},
1406 1407 { (uint_t)CDROMSBLKMODE, "CDROMSBLKMODE",
1407 1408 NULL},
1408 1409 { (uint_t)CDROMCDDA, "CDROMCDDA",
1409 1410 "struct cdrom_cdda"},
1410 1411 { (uint_t)CDROMCDXA, "CDROMCDXA",
1411 1412 "struct cdrom_cdxa"},
1412 1413 { (uint_t)CDROMSUBCODE, "CDROMSUBCODE",
1413 1414 "struct cdrom_subcode"},
1414 1415 { (uint_t)CDROMGDRVSPEED, "CDROMGDRVSPEED",
1415 1416 NULL},
1416 1417 { (uint_t)CDROMSDRVSPEED, "CDROMSDRVSPEED",
1417 1418 NULL},
1418 1419 { (uint_t)CDROMCLOSETRAY, "CDROMCLOSETRAY",
1419 1420 NULL},
1420 1421
1421 1422 /* disk ioctls - (0x04 << 8) - uscsi.h */
1422 1423 { (uint_t)USCSICMD, "USCSICMD",
1423 1424 "struct uscsi_cmd"},
1424 1425
1425 1426 /* dumpadm ioctls - (0xdd << 8) */
1426 1427 { (uint_t)DIOCGETDEV, "DIOCGETDEV",
1427 1428 NULL},
1428 1429
1429 1430 /* mntio ioctls - ('m' << 8) */
1430 1431 { (uint_t)MNTIOC_NMNTS, "MNTIOC_NMNTS",
1431 1432 NULL},
1432 1433 { (uint_t)MNTIOC_GETDEVLIST, "MNTIOC_GETDEVLIST",
1433 1434 NULL},
1434 1435 { (uint_t)MNTIOC_SETTAG, "MNTIOC_SETTAG",
1435 1436 "struct mnttagdesc"},
1436 1437 { (uint_t)MNTIOC_CLRTAG, "MNTIOC_CLRTAG",
1437 1438 "struct mnttagdesc"},
1438 1439 { (uint_t)MNTIOC_SHOWHIDDEN, "MNTIOC_SHOWHIDDEN",
1439 1440 NULL},
1440 1441 { (uint_t)MNTIOC_GETMNTENT, "MNTIOC_GETMNTENT",
1441 1442 "struct mnttab"},
1442 1443 { (uint_t)MNTIOC_GETEXTMNTENT, "MNTIOC_GETEXTMNTENT",
1443 1444 "struct extmnttab"},
1444 1445 { (uint_t)MNTIOC_GETMNTANY, "MNTIOC_GETMNTANY",
1445 1446 "struct mnttab"},
1446 1447
1447 1448 /* devinfo ioctls - ('df' << 8) - devinfo_impl.h */
1448 1449 { (uint_t)DINFOUSRLD, "DINFOUSRLD",
1449 1450 NULL},
1450 1451 { (uint_t)DINFOLODRV, "DINFOLODRV",
1451 1452 NULL},
1452 1453 { (uint_t)DINFOIDENT, "DINFOIDENT",
1453 1454 NULL},
1454 1455
1455 1456 { (uint_t)IPTUN_CREATE, "IPTUN_CREATE", "iptun_kparams_t"},
1456 1457 { (uint_t)IPTUN_DELETE, "IPTUN_DELETE", "datalink_id_t"},
1457 1458 { (uint_t)IPTUN_MODIFY, "IPTUN_MODIFY", "iptun_kparams_t"},
1458 1459 { (uint_t)IPTUN_INFO, "IPTUN_INFO", NULL},
1459 1460 { (uint_t)IPTUN_SET_6TO4RELAY, "IPTUN_SET_6TO4RELAY", NULL},
1460 1461 { (uint_t)IPTUN_GET_6TO4RELAY, "IPTUN_GET_6TO4RELAY", NULL},
1461 1462
1462 1463 /* zcons ioctls */
1463 1464 { (uint_t)ZC_HOLDSLAVE, "ZC_HOLDSLAVE", NULL },
1464 1465 { (uint_t)ZC_RELEASESLAVE, "ZC_RELEASESLAVE", NULL },
1465 1466
1466 1467 /* hid ioctls - ('h' << 8) - hid.h */
1467 1468 { (uint_t)HIDIOCKMGDIRECT, "HIDIOCKMGDIRECT", NULL },
1468 1469 { (uint_t)HIDIOCKMSDIRECT, "HIDIOCKMSDIRECT", NULL },
1469 1470
1470 1471 /* pm ioctls */
1471 1472 { (uint_t)PM_SCHEDULE, "PM_SCHEDULE", NULL },
1472 1473 { (uint_t)PM_GET_IDLE_TIME, "PM_GET_IDLE_TIME", NULL },
1473 1474 { (uint_t)PM_GET_NUM_CMPTS, "PM_GET_NUM_CMPTS", NULL },
1474 1475 { (uint_t)PM_GET_THRESHOLD, "PM_GET_THRESHOLD", NULL },
1475 1476 { (uint_t)PM_SET_THRESHOLD, "PM_SET_THRESHOLD", NULL },
1476 1477 { (uint_t)PM_GET_NORM_PWR, "PM_GET_NORM_PWR", NULL },
1477 1478 { (uint_t)PM_SET_CUR_PWR, "PM_SET_CUR_PWR", NULL },
1478 1479 { (uint_t)PM_GET_CUR_PWR, "PM_GET_CUR_PWR", NULL },
1479 1480 { (uint_t)PM_GET_NUM_DEPS, "PM_GET_NUM_DEPS", NULL },
1480 1481 { (uint_t)PM_GET_DEP, "PM_GET_DEP", NULL },
1481 1482 { (uint_t)PM_ADD_DEP, "PM_ADD_DEP", NULL },
1482 1483 { (uint_t)PM_REM_DEP, "PM_REM_DEP", NULL },
1483 1484 { (uint_t)PM_REM_DEVICE, "PM_REM_DEVICE", NULL },
1484 1485 { (uint_t)PM_REM_DEVICES, "PM_REM_DEVICES", NULL },
1485 1486 { (uint_t)PM_DISABLE_AUTOPM, "PM_DISABLE_AUTOPM", NULL },
1486 1487 { (uint_t)PM_REENABLE_AUTOPM, "PM_REENABLE_AUTOPM", NULL },
1487 1488 { (uint_t)PM_SET_NORM_PWR, "PM_SET_NORM_PWR", NULL },
1488 1489 { (uint_t)PM_GET_SYSTEM_THRESHOLD, "PM_GET_SYSTEM_THRESHOLD",
1489 1490 NULL },
1490 1491 { (uint_t)PM_GET_DEFAULT_SYSTEM_THRESHOLD,
1491 1492 "PM_GET_DEFAULT_SYSTEM_THRESHOLD", NULL },
1492 1493 { (uint_t)PM_SET_SYSTEM_THRESHOLD, "PM_SET_SYSTEM_THRESHOLD",
1493 1494 NULL },
1494 1495 { (uint_t)PM_START_PM, "PM_START_PM", NULL },
1495 1496 { (uint_t)PM_STOP_PM, "PM_STOP_PM", NULL },
1496 1497 { (uint_t)PM_RESET_PM, "PM_RESET_PM", NULL },
1497 1498 { (uint_t)PM_GET_PM_STATE, "PM_GET_PM_STATE", NULL },
1498 1499 { (uint_t)PM_GET_AUTOS3_STATE, "PM_GET_AUTOS3_STATE", NULL },
1499 1500 { (uint_t)PM_GET_S3_SUPPORT_STATE, "PM_GET_S3_SUPPORT_STATE",
1500 1501 NULL },
1501 1502 { (uint_t)PM_IDLE_DOWN, "PM_IDLE_DOWN", NULL },
1502 1503 { (uint_t)PM_START_CPUPM, "PM_START_CPUPM", NULL },
1503 1504 { (uint_t)PM_START_CPUPM_EV, "PM_START_CPUPM_EV", NULL },
1504 1505 { (uint_t)PM_START_CPUPM_POLL, "PM_START_CPUPM_POLL", NULL },
1505 1506 { (uint_t)PM_STOP_CPUPM, "PM_STOP_CPUPM", NULL },
1506 1507 { (uint_t)PM_GET_CPU_THRESHOLD, "PM_GET_CPU_THRESHOLD", NULL },
1507 1508 { (uint_t)PM_SET_CPU_THRESHOLD, "PM_SET_CPU_THRESHOLD", NULL },
1508 1509 { (uint_t)PM_GET_CPUPM_STATE, "PM_GET_CPUPM_STATE", NULL },
1509 1510 { (uint_t)PM_START_AUTOS3, "PM_START_AUTOS3", NULL },
1510 1511 { (uint_t)PM_STOP_AUTOS3, "PM_STOP_AUTOS3", NULL },
1511 1512 { (uint_t)PM_ENABLE_S3, "PM_ENABLE_S3", NULL },
1512 1513 { (uint_t)PM_DISABLE_S3, "PM_DISABLE_S3", NULL },
1513 1514 { (uint_t)PM_ENTER_S3, "PM_ENTER_S3", NULL },
1514 1515 { (uint_t)PM_DISABLE_CPU_DEEP_IDLE, "PM_DISABLE_CPU_DEEP_IDLE",
1515 1516 NULL },
1516 1517 { (uint_t)PM_ENABLE_CPU_DEEP_IDLE, "PM_START_CPU_DEEP_IDLE",
1517 1518 NULL },
1518 1519 { (uint_t)PM_DEFAULT_CPU_DEEP_IDLE, "PM_DFLT_CPU_DEEP_IDLE",
1519 1520 NULL },
1520 1521 #ifdef _SYSCALL32
1521 1522 { (uint_t)PM_GET_STATE_CHANGE, "PM_GET_STATE_CHANGE",
1522 1523 "pm_state_change32_t" },
1523 1524 { (uint_t)PM_GET_STATE_CHANGE_WAIT, "PM_GET_STATE_CHANGE_WAIT",
1524 1525 "pm_state_change32_t" },
1525 1526 { (uint_t)PM_DIRECT_NOTIFY, "PM_DIRECT_NOTIFY",
1526 1527 "pm_state_change32_t" },
1527 1528 { (uint_t)PM_DIRECT_NOTIFY_WAIT, "PM_DIRECT_NOTIFY_WAIT",
1528 1529 "pm_state_change32_t" },
1529 1530 { (uint_t)PM_REPARSE_PM_PROPS, "PM_REPARSE_PM_PROPS",
1530 1531 "pm_req32_t" },
1531 1532 { (uint_t)PM_SET_DEVICE_THRESHOLD, "PM_SET_DEVICE_THRESHOLD",
1532 1533 "pm_req32_t" },
1533 1534 { (uint_t)PM_GET_STATS, "PM_GET_STATS",
1534 1535 "pm_req32_t" },
1535 1536 { (uint_t)PM_GET_DEVICE_THRESHOLD, "PM_GET_DEVICE_THRESHOLD",
1536 1537 "pm_req32_t" },
1537 1538 { (uint_t)PM_GET_POWER_NAME, "PM_GET_POWER_NAME",
1538 1539 "pm_req32_t" },
1539 1540 { (uint_t)PM_GET_POWER_LEVELS, "PM_GET_POWER_LEVELS",
1540 1541 "pm_req32_t" },
1541 1542 { (uint_t)PM_GET_NUM_COMPONENTS, "PM_GET_NUM_COMPONENTS",
1542 1543 "pm_req32_t" },
1543 1544 { (uint_t)PM_GET_COMPONENT_NAME, "PM_GET_COMPONENT_NAME",
1544 1545 "pm_req32_t" },
1545 1546 { (uint_t)PM_GET_NUM_POWER_LEVELS, "PM_GET_NUM_POWER_LEVELS",
1546 1547 "pm_req32_t" },
1547 1548 { (uint_t)PM_DIRECT_PM, "PM_DIRECT_PM",
1548 1549 "pm_req32_t" },
1549 1550 { (uint_t)PM_RELEASE_DIRECT_PM, "PM_RELEASE_DIRECT_PM",
1550 1551 "pm_req32_t" },
1551 1552 { (uint_t)PM_RESET_DEVICE_THRESHOLD, "PM_RESET_DEVICE_THRESHOLD",
1552 1553 "pm_req32_t" },
1553 1554 { (uint_t)PM_GET_DEVICE_TYPE, "PM_GET_DEVICE_TYPE",
1554 1555 "pm_req32_t" },
1555 1556 { (uint_t)PM_SET_COMPONENT_THRESHOLDS, "PM_SET_COMPONENT_THRESHOLDS",
1556 1557 "pm_req32_t" },
1557 1558 { (uint_t)PM_GET_COMPONENT_THRESHOLDS, "PM_GET_COMPONENT_THRESHOLDS",
1558 1559 "pm_req32_t" },
1559 1560 { (uint_t)PM_GET_DEVICE_THRESHOLD_BASIS,
1560 1561 "PM_GET_DEVICE_THRESHOLD_BASIS", "pm_req32_t" },
1561 1562 { (uint_t)PM_SET_CURRENT_POWER, "PM_SET_CURRENT_POWER",
1562 1563 "pm_req32_t" },
1563 1564 { (uint_t)PM_GET_CURRENT_POWER, "PM_GET_CURRENT_POWER",
1564 1565 "pm_req32_t" },
1565 1566 { (uint_t)PM_GET_FULL_POWER, "PM_GET_FULL_POWER",
1566 1567 "pm_req32_t" },
1567 1568 { (uint_t)PM_ADD_DEPENDENT, "PM_ADD_DEPENDENT",
1568 1569 "pm_req32_t" },
1569 1570 { (uint_t)PM_GET_TIME_IDLE, "PM_GET_TIME_IDLE",
1570 1571 "pm_req32_t" },
1571 1572 { (uint_t)PM_ADD_DEPENDENT_PROPERTY, "PM_ADD_DEPENDENT_PROPERTY",
1572 1573 "pm_req32_t" },
1573 1574 { (uint_t)PM_GET_CMD_NAME, "PM_GET_CMD_NAME",
1574 1575 "pm_req32_t" },
1575 1576 { (uint_t)PM_SEARCH_LIST, "PM_SEARCH_LIST",
1576 1577 "pm_searchargs32_t" },
1577 1578 #else /* _SYSCALL32 */
1578 1579 { (uint_t)PM_GET_STATE_CHANGE, "PM_GET_STATE_CHANGE",
1579 1580 "pm_state_change_t" },
1580 1581 { (uint_t)PM_GET_STATE_CHANGE_WAIT, "PM_GET_STATE_CHANGE_WAIT",
1581 1582 "pm_state_change_t" },
1582 1583 { (uint_t)PM_DIRECT_NOTIFY, "PM_DIRECT_NOTIFY",
1583 1584 "pm_state_change_t" },
1584 1585 { (uint_t)PM_DIRECT_NOTIFY_WAIT, "PM_DIRECT_NOTIFY_WAIT",
1585 1586 "pm_state_change_t" },
1586 1587 { (uint_t)PM_REPARSE_PM_PROPS, "PM_REPARSE_PM_PROPS",
1587 1588 "pm_req_t" },
1588 1589 { (uint_t)PM_SET_DEVICE_THRESHOLD, "PM_SET_DEVICE_THRESHOLD",
1589 1590 "pm_req_t" },
1590 1591 { (uint_t)PM_GET_STATS, "PM_GET_STATS",
1591 1592 "pm_req_t" },
1592 1593 { (uint_t)PM_GET_DEVICE_THRESHOLD, "PM_GET_DEVICE_THRESHOLD",
1593 1594 "pm_req_t" },
1594 1595 { (uint_t)PM_GET_POWER_NAME, "PM_GET_POWER_NAME",
1595 1596 "pm_req_t" },
1596 1597 { (uint_t)PM_GET_POWER_LEVELS, "PM_GET_POWER_LEVELS",
1597 1598 "pm_req_t" },
1598 1599 { (uint_t)PM_GET_NUM_COMPONENTS, "PM_GET_NUM_COMPONENTS",
1599 1600 "pm_req_t" },
1600 1601 { (uint_t)PM_GET_COMPONENT_NAME, "PM_GET_COMPONENT_NAME",
1601 1602 "pm_req_t" },
1602 1603 { (uint_t)PM_GET_NUM_POWER_LEVELS, "PM_GET_NUM_POWER_LEVELS",
1603 1604 "pm_req_t" },
1604 1605 { (uint_t)PM_DIRECT_PM, "PM_DIRECT_PM",
1605 1606 "pm_req_t" },
1606 1607 { (uint_t)PM_RELEASE_DIRECT_PM, "PM_RELEASE_DIRECT_PM",
1607 1608 "pm_req_t" },
1608 1609 { (uint_t)PM_RESET_DEVICE_THRESHOLD, "PM_RESET_DEVICE_THRESHOLD",
1609 1610 "pm_req_t" },
1610 1611 { (uint_t)PM_GET_DEVICE_TYPE, "PM_GET_DEVICE_TYPE",
1611 1612 "pm_req_t" },
1612 1613 { (uint_t)PM_SET_COMPONENT_THRESHOLDS, "PM_SET_COMPONENT_THRESHOLDS",
1613 1614 "pm_req_t" },
1614 1615 { (uint_t)PM_GET_COMPONENT_THRESHOLDS, "PM_GET_COMPONENT_THRESHOLDS",
1615 1616 "pm_req_t" },
1616 1617 { (uint_t)PM_GET_DEVICE_THRESHOLD_BASIS,
1617 1618 "PM_GET_DEVICE_THRESHOLD_BASIS", "pm_req_t" },
1618 1619 { (uint_t)PM_SET_CURRENT_POWER, "PM_SET_CURRENT_POWER",
1619 1620 "pm_req_t" },
1620 1621 { (uint_t)PM_GET_CURRENT_POWER, "PM_GET_CURRENT_POWER",
1621 1622 "pm_req_t" },
1622 1623 { (uint_t)PM_GET_FULL_POWER, "PM_GET_FULL_POWER",
1623 1624 "pm_req_t" },
1624 1625 { (uint_t)PM_ADD_DEPENDENT, "PM_ADD_DEPENDENT",
1625 1626 "pm_req_t" },
1626 1627 { (uint_t)PM_GET_TIME_IDLE, "PM_GET_TIME_IDLE",
1627 1628 "pm_req_t" },
1628 1629 { (uint_t)PM_ADD_DEPENDENT_PROPERTY, "PM_ADD_DEPENDENT_PROPERTY",
1629 1630 "pm_req_t" },
1630 1631 { (uint_t)PM_GET_CMD_NAME, "PM_GET_CMD_NAME",
1631 1632 "pm_req_t" },
1632 1633 { (uint_t)PM_SEARCH_LIST, "PM_SEARCH_LIST",
1633 1634 "pm_searchargs_t" },
1634 1635 #endif /* _SYSCALL */
1635 1636
1636 1637 { (uint_t)0, NULL, NULL }
1637 1638 };
1638 1639
1639 1640 void
1640 1641 ioctl_ioccom(char *buf, size_t size, uint_t code, int nbytes, int x, int y)
1641 1642 {
1642 1643 const char *inoutstr;
1643 1644
1644 1645 if (code & IOC_VOID)
1645 1646 inoutstr = "";
1646 1647 else if ((code & IOC_INOUT) == IOC_INOUT)
1647 1648 inoutstr = "WR";
1648 1649 else
1649 1650 inoutstr = code & IOC_IN ? "W" : "R";
1650 1651
1651 1652 if (isascii(x) && isprint(x))
1652 1653 (void) snprintf(buf, size, "_IO%sN('%c', %d, %d)", inoutstr,
1653 1654 x, y, nbytes);
1654 1655 else
1655 1656 (void) snprintf(buf, size, "_IO%sN(0x%x, %d, %d)", inoutstr,
1656 1657 x, y, nbytes);
1657 1658 }
1658 1659
1659 1660
1660 1661 const char *
1661 1662 ioctlname(private_t *pri, uint_t code)
1662 1663 {
1663 1664 const struct ioc *ip;
1664 1665 const char *str = NULL;
1665 1666
1666 1667 for (ip = &ioc[0]; ip->name; ip++) {
1667 1668 if (code == ip->code) {
1668 1669 str = ip->name;
1669 1670 break;
1670 1671 }
1671 1672 }
1672 1673
1673 1674 /*
1674 1675 * Developers hide ascii ioctl names in the ioctl subcode; for example
1675 1676 * 0x445210 should be printed 'D'<<16|'R'<<8|10. We allow for all
1676 1677 * three high order bytes (called hi, mid and lo) to contain ascii
1677 1678 * characters.
1678 1679 */
1679 1680 if (str == NULL) {
1680 1681 int c_hi = code >> 24;
1681 1682 int c_mid = (code >> 16) & 0xff;
1682 1683 int c_mid_nm = (code >> 16);
1683 1684 int c_lo = (code >> 8) & 0xff;
1684 1685 int c_lo_nm = code >> 8;
1685 1686
1686 1687 if (isascii(c_lo) && isprint(c_lo) &&
1687 1688 isascii(c_mid) && isprint(c_mid) &&
1688 1689 isascii(c_hi) && isprint(c_hi))
1689 1690 (void) sprintf(pri->code_buf,
1690 1691 "(('%c'<<24)|('%c'<<16)|('%c'<<8)|%d)",
1691 1692 c_hi, c_mid, c_lo, code & 0xff);
1692 1693 else if (isascii(c_lo) && isprint(c_lo) &&
1693 1694 isascii(c_mid_nm) && isprint(c_mid_nm))
1694 1695 (void) sprintf(pri->code_buf,
1695 1696 "(('%c'<<16)|('%c'<<8)|%d)", c_mid, c_lo,
1696 1697 code & 0xff);
1697 1698 else if (isascii(c_lo_nm) && isprint(c_lo_nm))
1698 1699 (void) sprintf(pri->code_buf, "(('%c'<<8)|%d)",
1699 1700 c_lo_nm, code & 0xff);
1700 1701 else if (code & (IOC_VOID|IOC_INOUT))
1701 1702 ioctl_ioccom(pri->code_buf, sizeof (pri->code_buf),
1702 1703 code, c_mid, c_lo, code & 0xff);
1703 1704 else
1704 1705 (void) sprintf(pri->code_buf, "0x%.4X", code);
1705 1706 str = (const char *)pri->code_buf;
1706 1707 }
1707 1708
1708 1709 return (str);
1709 1710 }
1710 1711
1711 1712
1712 1713 const char *
1713 1714 ioctldatastruct(uint_t code)
1714 1715 {
1715 1716 const struct ioc *ip;
1716 1717 const char *str = NULL;
1717 1718
1718 1719 for (ip = &ioc[0]; ip->name != NULL; ip++) {
1719 1720 if (code == ip->code) {
1720 1721 str = ip->datastruct;
1721 1722 break;
1722 1723 }
1723 1724 }
1724 1725 return (str);
1725 1726 }
1726 1727
1727 1728
1728 1729 const char *
1729 1730 fcntlname(int code)
1730 1731 {
1731 1732 const char *str = NULL;
1732 1733
1733 1734 if (code >= FCNTLMIN && code <= FCNTLMAX)
1734 1735 str = FCNTLname[code-FCNTLMIN];
1735 1736 return (str);
1736 1737 }
1737 1738
1738 1739 const char *
1739 1740 sfsname(int code)
1740 1741 {
1741 1742 const char *str = NULL;
1742 1743
1743 1744 if (code >= SYSFSMIN && code <= SYSFSMAX)
1744 1745 str = SYSFSname[code-SYSFSMIN];
1745 1746 return (str);
1746 1747 }
1747 1748
1748 1749 /* ARGSUSED */
1749 1750 const char *
1750 1751 si86name(int code)
1751 1752 {
1752 1753 const char *str = NULL;
1753 1754
1754 1755 #if defined(__i386) || defined(__amd64)
1755 1756 switch (code) {
1756 1757 case SI86SWPI: str = "SI86SWPI"; break;
1757 1758 case SI86SYM: str = "SI86SYM"; break;
1758 1759 case SI86CONF: str = "SI86CONF"; break;
1759 1760 case SI86BOOT: str = "SI86BOOT"; break;
1760 1761 case SI86AUTO: str = "SI86AUTO"; break;
1761 1762 case SI86EDT: str = "SI86EDT"; break;
1762 1763 case SI86SWAP: str = "SI86SWAP"; break;
1763 1764 case SI86FPHW: str = "SI86FPHW"; break;
1764 1765 case SI86FPSTART: str = "SI86FPSTART"; break;
1765 1766 case GRNON: str = "GRNON"; break;
1766 1767 case GRNFLASH: str = "GRNFLASH"; break;
1767 1768 case STIME: str = "STIME"; break;
1768 1769 case SETNAME: str = "SETNAME"; break;
1769 1770 case RNVR: str = "RNVR"; break;
1770 1771 case WNVR: str = "WNVR"; break;
1771 1772 case RTODC: str = "RTODC"; break;
1772 1773 case CHKSER: str = "CHKSER"; break;
1773 1774 case SI86NVPRT: str = "SI86NVPRT"; break;
1774 1775 case SANUPD: str = "SANUPD"; break;
1775 1776 case SI86KSTR: str = "SI86KSTR"; break;
1776 1777 case SI86MEM: str = "SI86MEM"; break;
1777 1778 case SI86TODEMON: str = "SI86TODEMON"; break;
1778 1779 case SI86CCDEMON: str = "SI86CCDEMON"; break;
1779 1780 case SI86CACHE: str = "SI86CACHE"; break;
1780 1781 case SI86DELMEM: str = "SI86DELMEM"; break;
1781 1782 case SI86ADDMEM: str = "SI86ADDMEM"; break;
1782 1783 /* 71 through 74 reserved for VPIX */
1783 1784 case SI86V86: str = "SI86V86"; break;
1784 1785 case SI86SLTIME: str = "SI86SLTIME"; break;
1785 1786 case SI86DSCR: str = "SI86DSCR"; break;
1786 1787 case RDUBLK: str = "RDUBLK"; break;
1787 1788 /* NFA entry point */
1788 1789 case SI86NFA: str = "SI86NFA"; break;
1789 1790 case SI86VM86: str = "SI86VM86"; break;
1790 1791 case SI86VMENABLE: str = "SI86VMENABLE"; break;
1791 1792 case SI86LIMUSER: str = "SI86LIMUSER"; break;
1792 1793 case SI86RDID: str = "SI86RDID"; break;
1793 1794 case SI86RDBOOT: str = "SI86RDBOOT"; break;
1794 1795 /* Merged Product defines */
1795 1796 case SI86SHFIL: str = "SI86SHFIL"; break;
1796 1797 case SI86PCHRGN: str = "SI86PCHRGN"; break;
1797 1798 case SI86BADVISE: str = "SI86BADVISE"; break;
1798 1799 case SI86SHRGN: str = "SI86SHRGN"; break;
1799 1800 case SI86CHIDT: str = "SI86CHIDT"; break;
1800 1801 case SI86EMULRDA: str = "SI86EMULRDA"; break;
1801 1802 /* RTC commands */
1802 1803 case WTODC: str = "WTODC"; break;
1803 1804 case SGMTL: str = "SGMTL"; break;
1804 1805 case GGMTL: str = "GGMTL"; break;
1805 1806 case RTCSYNC: str = "RTCSYNC"; break;
1806 1807 }
1807 1808 #endif /* __i386 */
1808 1809
1809 1810 return (str);
1810 1811 }
1811 1812
1812 1813 const char *
1813 1814 utscode(int code)
1814 1815 {
1815 1816 const char *str = NULL;
1816 1817
1817 1818 switch (code) {
1818 1819 case UTS_UNAME: str = "UNAME"; break;
1819 1820 case UTS_USTAT: str = "USTAT"; break;
1820 1821 case UTS_FUSERS: str = "FUSERS"; break;
1821 1822 }
1822 1823
1823 1824 return (str);
1824 1825 }
1825 1826
1826 1827 const char *
1827 1828 rctlsyscode(int code)
1828 1829 {
1829 1830 const char *str = NULL;
1830 1831 switch (code) {
1831 1832 case 0: str = "GETRCTL"; break;
1832 1833 case 1: str = "SETRCTL"; break;
1833 1834 case 2: str = "RCTLSYS_LST"; break;
1834 1835 case 3: str = "RCTLSYS_CTL"; break;
1835 1836 case 4: str = "RCTLSYS_SETPROJ"; break;
1836 1837 default: str = "UNKNOWN"; break;
1837 1838 }
1838 1839 return (str);
1839 1840 }
1840 1841
1841 1842 const char *
1842 1843 rctl_local_action(private_t *pri, uint_t val)
1843 1844 {
1844 1845 uint_t action = val & (~RCTL_LOCAL_ACTION_MASK);
1845 1846
1846 1847 char *s = pri->code_buf;
1847 1848
1848 1849 *s = '\0';
1849 1850
1850 1851 if (action & RCTL_LOCAL_NOACTION) {
1851 1852 action ^= RCTL_LOCAL_NOACTION;
1852 1853 (void) strlcat(s, "|RCTL_LOCAL_NOACTION",
1853 1854 sizeof (pri->code_buf));
1854 1855 }
1855 1856 if (action & RCTL_LOCAL_SIGNAL) {
1856 1857 action ^= RCTL_LOCAL_SIGNAL;
1857 1858 (void) strlcat(s, "|RCTL_LOCAL_SIGNAL",
1858 1859 sizeof (pri->code_buf));
1859 1860 }
1860 1861 if (action & RCTL_LOCAL_DENY) {
1861 1862 action ^= RCTL_LOCAL_DENY;
1862 1863 (void) strlcat(s, "|RCTL_LOCAL_DENY",
1863 1864 sizeof (pri->code_buf));
1864 1865 }
1865 1866
1866 1867 if ((action & (~RCTL_LOCAL_ACTION_MASK)) != 0)
1867 1868 return (NULL);
1868 1869 else if (*s != '\0')
1869 1870 return (s+1);
1870 1871 else
1871 1872 return (NULL);
1872 1873 }
1873 1874
1874 1875
1875 1876 const char *
1876 1877 rctl_local_flags(private_t *pri, uint_t val)
1877 1878 {
1878 1879 uint_t pval = val & RCTL_LOCAL_ACTION_MASK;
1879 1880 char *s = pri->code_buf;
1880 1881
1881 1882 *s = '\0';
1882 1883
1883 1884 if (pval & RCTL_LOCAL_MAXIMAL) {
1884 1885 pval ^= RCTL_LOCAL_MAXIMAL;
1885 1886 (void) strlcat(s, "|RCTL_LOCAL_MAXIMAL",
1886 1887 sizeof (pri->code_buf));
1887 1888 }
1888 1889
1889 1890 if ((pval & RCTL_LOCAL_ACTION_MASK) != 0)
1890 1891 return (NULL);
1891 1892 else if (*s != '\0')
1892 1893 return (s+1);
1893 1894 else
1894 1895 return (NULL);
1895 1896 }
1896 1897
1897 1898
1898 1899 const char *
1899 1900 sconfname(int code)
1900 1901 {
1901 1902 const char *str = NULL;
1902 1903
1903 1904 if (code >= SCONFMIN && code <= SCONFMAX)
1904 1905 str = SCONFname[code-SCONFMIN];
1905 1906 return (str);
1906 1907 }
1907 1908
1908 1909 const char *
1909 1910 pathconfname(int code)
1910 1911 {
↓ open down ↓ |
1874 lines elided |
↑ open up ↑ |
1911 1912 const char *str = NULL;
1912 1913
1913 1914 if (code >= PATHCONFMIN && code <= PATHCONFMAX)
1914 1915 str = PATHCONFname[code-PATHCONFMIN];
1915 1916 return (str);
1916 1917 }
1917 1918
1918 1919 #define ALL_O_FLAGS \
1919 1920 (O_NDELAY|O_APPEND|O_SYNC|O_DSYNC|O_NONBLOCK|O_CREAT|O_TRUNC\
1920 1921 |O_EXCL|O_NOCTTY|O_LARGEFILE|O_RSYNC|O_XATTR|O_NOFOLLOW|O_NOLINKS\
1921 - |FXATTRDIROPEN)
1922 + |O_CLOEXEC|FXATTRDIROPEN)
1922 1923
1923 1924 const char *
1924 1925 openarg(private_t *pri, int arg)
1925 1926 {
1926 1927 char *str = pri->code_buf;
1927 1928
1928 1929 if ((arg & ~(O_ACCMODE | ALL_O_FLAGS)) != 0)
1929 1930 return (NULL);
1930 1931
1931 1932 switch (arg & O_ACCMODE) {
1932 1933 default:
1933 1934 return (NULL);
1934 1935 case O_RDONLY:
1935 1936 (void) strcpy(str, "O_RDONLY");
1936 1937 break;
1937 1938 case O_WRONLY:
1938 1939 (void) strcpy(str, "O_WRONLY");
1939 1940 break;
1940 1941 case O_RDWR:
1941 1942 (void) strcpy(str, "O_RDWR");
1942 1943 break;
1943 1944 case O_SEARCH:
1944 1945 (void) strcpy(str, "O_SEARCH");
1945 1946 break;
1946 1947 case O_EXEC:
1947 1948 (void) strcpy(str, "O_EXEC");
1948 1949 break;
1949 1950 }
1950 1951
1951 1952 if (arg & O_NDELAY)
1952 1953 (void) strlcat(str, "|O_NDELAY", sizeof (pri->code_buf));
1953 1954 if (arg & O_APPEND)
1954 1955 (void) strlcat(str, "|O_APPEND", sizeof (pri->code_buf));
1955 1956 if (arg & O_SYNC)
1956 1957 (void) strlcat(str, "|O_SYNC", sizeof (pri->code_buf));
1957 1958 if (arg & O_DSYNC)
1958 1959 (void) strlcat(str, "|O_DSYNC", sizeof (pri->code_buf));
1959 1960 if (arg & O_NONBLOCK)
1960 1961 (void) strlcat(str, "|O_NONBLOCK", sizeof (pri->code_buf));
1961 1962 if (arg & O_CREAT)
1962 1963 (void) strlcat(str, "|O_CREAT", sizeof (pri->code_buf));
1963 1964 if (arg & O_TRUNC)
1964 1965 (void) strlcat(str, "|O_TRUNC", sizeof (pri->code_buf));
1965 1966 if (arg & O_EXCL)
1966 1967 (void) strlcat(str, "|O_EXCL", sizeof (pri->code_buf));
1967 1968 if (arg & O_NOCTTY)
1968 1969 (void) strlcat(str, "|O_NOCTTY", sizeof (pri->code_buf));
↓ open down ↓ |
37 lines elided |
↑ open up ↑ |
1969 1970 if (arg & O_LARGEFILE)
1970 1971 (void) strlcat(str, "|O_LARGEFILE", sizeof (pri->code_buf));
1971 1972 if (arg & O_RSYNC)
1972 1973 (void) strlcat(str, "|O_RSYNC", sizeof (pri->code_buf));
1973 1974 if (arg & O_XATTR)
1974 1975 (void) strlcat(str, "|O_XATTR", sizeof (pri->code_buf));
1975 1976 if (arg & O_NOFOLLOW)
1976 1977 (void) strlcat(str, "|O_NOFOLLOW", sizeof (pri->code_buf));
1977 1978 if (arg & O_NOLINKS)
1978 1979 (void) strlcat(str, "|O_NOLINKS", sizeof (pri->code_buf));
1980 + if (arg & O_CLOEXEC)
1981 + (void) strlcat(str, "|O_CLOEXEC", sizeof (pri->code_buf));
1979 1982 if (arg & FXATTRDIROPEN)
1980 1983 (void) strlcat(str, "|FXATTRDIROPEN", sizeof (pri->code_buf));
1981 1984
1982 1985 return ((const char *)str);
1983 1986 }
1984 1987
1985 1988 const char *
1986 1989 whencearg(int arg)
1987 1990 {
1988 1991 const char *str = NULL;
1989 1992
1990 1993 switch (arg) {
1991 1994 case SEEK_SET: str = "SEEK_SET"; break;
1992 1995 case SEEK_CUR: str = "SEEK_CUR"; break;
1993 1996 case SEEK_END: str = "SEEK_END"; break;
1994 1997 case SEEK_DATA: str = "SEEK_DATA"; break;
1995 1998 case SEEK_HOLE: str = "SEEK_HOLE"; break;
1996 1999 }
1997 2000
1998 2001 return (str);
1999 2002 }
2000 2003
2001 2004 #define IPC_FLAGS (IPC_ALLOC|IPC_CREAT|IPC_EXCL|IPC_NOWAIT)
2002 2005
2003 2006 char *
2004 2007 ipcflags(private_t *pri, int arg)
2005 2008 {
2006 2009 char *str = pri->code_buf;
2007 2010
2008 2011 if (arg & 0777)
2009 2012 (void) sprintf(str, "0%.3o", arg&0777);
2010 2013 else
2011 2014 *str = '\0';
2012 2015
2013 2016 if (arg & IPC_ALLOC)
2014 2017 (void) strcat(str, "|IPC_ALLOC");
2015 2018 if (arg & IPC_CREAT)
2016 2019 (void) strcat(str, "|IPC_CREAT");
2017 2020 if (arg & IPC_EXCL)
2018 2021 (void) strcat(str, "|IPC_EXCL");
2019 2022 if (arg & IPC_NOWAIT)
2020 2023 (void) strcat(str, "|IPC_NOWAIT");
2021 2024
2022 2025 return (str);
2023 2026 }
2024 2027
2025 2028 const char *
2026 2029 msgflags(private_t *pri, int arg)
2027 2030 {
2028 2031 char *str;
2029 2032
2030 2033 if (arg == 0 || (arg & ~(IPC_FLAGS|MSG_NOERROR|0777)) != 0)
2031 2034 return ((char *)NULL);
2032 2035
2033 2036 str = ipcflags(pri, arg);
2034 2037
2035 2038 if (arg & MSG_NOERROR)
2036 2039 (void) strcat(str, "|MSG_NOERROR");
2037 2040
2038 2041 if (*str == '|')
2039 2042 str++;
2040 2043 return ((const char *)str);
2041 2044 }
2042 2045
2043 2046 const char *
2044 2047 semflags(private_t *pri, int arg)
2045 2048 {
2046 2049 char *str;
2047 2050
2048 2051 if (arg == 0 || (arg & ~(IPC_FLAGS|SEM_UNDO|0777)) != 0)
2049 2052 return ((char *)NULL);
2050 2053
2051 2054 str = ipcflags(pri, arg);
2052 2055
2053 2056 if (arg & SEM_UNDO)
2054 2057 (void) strcat(str, "|SEM_UNDO");
2055 2058
2056 2059 if (*str == '|')
2057 2060 str++;
2058 2061 return ((const char *)str);
2059 2062 }
2060 2063
2061 2064 const char *
2062 2065 shmflags(private_t *pri, int arg)
2063 2066 {
2064 2067 char *str;
2065 2068
2066 2069 if (arg == 0 || (arg & ~(IPC_FLAGS|SHM_RDONLY|SHM_RND|0777)) != 0)
2067 2070 return ((char *)NULL);
2068 2071
2069 2072 str = ipcflags(pri, arg);
2070 2073
2071 2074 if (arg & SHM_RDONLY)
2072 2075 (void) strcat(str, "|SHM_RDONLY");
2073 2076 if (arg & SHM_RND)
2074 2077 (void) strcat(str, "|SHM_RND");
2075 2078
2076 2079 if (*str == '|')
2077 2080 str++;
2078 2081 return ((const char *)str);
2079 2082 }
2080 2083
2081 2084 #define MSGCMDMIN 0
2082 2085 #define MSGCMDMAX IPC_STAT64
2083 2086 const char *const MSGCMDname[MSGCMDMAX+1] = {
2084 2087 NULL, NULL, NULL, NULL, NULL,
2085 2088 NULL, NULL, NULL, NULL, NULL,
2086 2089 "IPC_RMID", /* 10 */
2087 2090 "IPC_SET", /* 11 */
2088 2091 "IPC_STAT", /* 12 */
2089 2092 "IPC_SET64", /* 13 */
2090 2093 "IPC_STAT64", /* 14 */
2091 2094 };
2092 2095
2093 2096 #define SEMCMDMIN 0
2094 2097 #define SEMCMDMAX IPC_STAT64
2095 2098 const char *const SEMCMDname[SEMCMDMAX+1] = {
2096 2099 NULL, /* 0 */
2097 2100 NULL, /* 1 */
2098 2101 NULL, /* 2 */
2099 2102 "GETNCNT", /* 3 */
2100 2103 "GETPID", /* 4 */
2101 2104 "GETVAL", /* 5 */
2102 2105 "GETALL", /* 6 */
2103 2106 "GETZCNT", /* 7 */
2104 2107 "SETVAL", /* 8 */
2105 2108 "SETALL", /* 9 */
2106 2109 "IPC_RMID", /* 10 */
2107 2110 "IPC_SET", /* 11 */
2108 2111 "IPC_STAT", /* 12 */
2109 2112 "IPC_SET64", /* 13 */
2110 2113 "IPC_STAT64", /* 14 */
2111 2114 };
2112 2115
2113 2116 #define SHMCMDMIN 0
2114 2117 #define SHMCMDMAX IPC_STAT64
2115 2118 const char *const SHMCMDname[SHMCMDMAX+1] = {
2116 2119 NULL, /* 0 */
2117 2120 NULL, /* 1 */
2118 2121 NULL, /* 2 */
2119 2122 "SHM_LOCK", /* 3 */
2120 2123 "SHM_UNLOCK", /* 4 */
2121 2124 NULL, NULL, NULL, NULL, NULL, /* 5 NULLs */
2122 2125 "IPC_RMID", /* 10 */
2123 2126 "IPC_SET", /* 11 */
2124 2127 "IPC_STAT", /* 12 */
2125 2128 "IPC_SET64", /* 13 */
2126 2129 "IPC_STAT64", /* 14 */
2127 2130 };
2128 2131
2129 2132 const char *
2130 2133 msgcmd(int arg)
2131 2134 {
2132 2135 const char *str = NULL;
2133 2136
2134 2137 if (arg >= MSGCMDMIN && arg <= MSGCMDMAX)
2135 2138 str = MSGCMDname[arg-MSGCMDMIN];
2136 2139 return (str);
2137 2140 }
2138 2141
2139 2142 const char *
2140 2143 semcmd(int arg)
2141 2144 {
2142 2145 const char *str = NULL;
2143 2146
2144 2147 if (arg >= SEMCMDMIN && arg <= SEMCMDMAX)
2145 2148 str = SEMCMDname[arg-SEMCMDMIN];
2146 2149 return (str);
2147 2150 }
2148 2151
2149 2152 const char *
2150 2153 shmcmd(int arg)
2151 2154 {
2152 2155 const char *str = NULL;
2153 2156
2154 2157 if (arg >= SHMCMDMIN && arg <= SHMCMDMAX)
2155 2158 str = SHMCMDname[arg-SHMCMDMIN];
2156 2159 return (str);
2157 2160 }
2158 2161
2159 2162 const char *
2160 2163 strrdopt(int arg) /* streams read option (I_SRDOPT I_GRDOPT) */
2161 2164 {
2162 2165 const char *str = NULL;
2163 2166
2164 2167 switch (arg) {
2165 2168 case RNORM: str = "RNORM"; break;
2166 2169 case RMSGD: str = "RMSGD"; break;
2167 2170 case RMSGN: str = "RMSGN"; break;
2168 2171 }
2169 2172
2170 2173 return (str);
2171 2174 }
2172 2175
2173 2176 /* bit map of streams events (I_SETSIG & I_GETSIG) */
2174 2177 const char *
2175 2178 strevents(private_t *pri, int arg)
2176 2179 {
2177 2180 char *str = pri->code_buf;
2178 2181
2179 2182 if (arg & ~(S_INPUT|S_HIPRI|S_OUTPUT|S_MSG|S_ERROR|S_HANGUP))
2180 2183 return ((char *)NULL);
2181 2184
2182 2185 *str = '\0';
2183 2186 if (arg & S_INPUT)
2184 2187 (void) strcat(str, "|S_INPUT");
2185 2188 if (arg & S_HIPRI)
2186 2189 (void) strcat(str, "|S_HIPRI");
2187 2190 if (arg & S_OUTPUT)
2188 2191 (void) strcat(str, "|S_OUTPUT");
2189 2192 if (arg & S_MSG)
2190 2193 (void) strcat(str, "|S_MSG");
2191 2194 if (arg & S_ERROR)
2192 2195 (void) strcat(str, "|S_ERROR");
2193 2196 if (arg & S_HANGUP)
2194 2197 (void) strcat(str, "|S_HANGUP");
2195 2198
2196 2199 return ((const char *)(str+1));
2197 2200 }
2198 2201
2199 2202 const char *
2200 2203 tiocflush(private_t *pri, int arg) /* bit map passsed by TIOCFLUSH */
2201 2204 {
2202 2205 char *str = pri->code_buf;
2203 2206
2204 2207 if (arg & ~(FREAD|FWRITE))
2205 2208 return ((char *)NULL);
2206 2209
2207 2210 *str = '\0';
2208 2211 if (arg & FREAD)
2209 2212 (void) strcat(str, "|FREAD");
2210 2213 if (arg & FWRITE)
2211 2214 (void) strcat(str, "|FWRITE");
2212 2215
2213 2216 return ((const char *)(str+1));
2214 2217 }
2215 2218
2216 2219 const char *
2217 2220 strflush(int arg) /* streams flush option (I_FLUSH) */
2218 2221 {
2219 2222 const char *str = NULL;
2220 2223
2221 2224 switch (arg) {
2222 2225 case FLUSHR: str = "FLUSHR"; break;
2223 2226 case FLUSHW: str = "FLUSHW"; break;
2224 2227 case FLUSHRW: str = "FLUSHRW"; break;
2225 2228 }
2226 2229
2227 2230 return (str);
2228 2231 }
2229 2232
2230 2233 #define ALL_MOUNT_FLAGS (MS_RDONLY|MS_FSS|MS_DATA|MS_NOSUID|MS_REMOUNT| \
2231 2234 MS_NOTRUNC|MS_OVERLAY|MS_OPTIONSTR|MS_GLOBAL|MS_FORCE|MS_NOMNTTAB)
2232 2235
2233 2236 const char *
2234 2237 mountflags(private_t *pri, int arg) /* bit map of mount syscall flags */
2235 2238 {
2236 2239 char *str = pri->code_buf;
2237 2240 size_t used = 0;
2238 2241
2239 2242 if (arg & ~ALL_MOUNT_FLAGS)
2240 2243 return ((char *)NULL);
2241 2244
2242 2245 *str = '\0';
2243 2246 if (arg & MS_RDONLY)
2244 2247 used = strlcat(str, "|MS_RDONLY", sizeof (pri->code_buf));
2245 2248 if (arg & MS_FSS)
2246 2249 used = strlcat(str, "|MS_FSS", sizeof (pri->code_buf));
2247 2250 if (arg & MS_DATA)
2248 2251 used = strlcat(str, "|MS_DATA", sizeof (pri->code_buf));
2249 2252 if (arg & MS_NOSUID)
2250 2253 used = strlcat(str, "|MS_NOSUID", sizeof (pri->code_buf));
2251 2254 if (arg & MS_REMOUNT)
2252 2255 used = strlcat(str, "|MS_REMOUNT", sizeof (pri->code_buf));
2253 2256 if (arg & MS_NOTRUNC)
2254 2257 used = strlcat(str, "|MS_NOTRUNC", sizeof (pri->code_buf));
2255 2258 if (arg & MS_OVERLAY)
2256 2259 used = strlcat(str, "|MS_OVERLAY", sizeof (pri->code_buf));
2257 2260 if (arg & MS_OPTIONSTR)
2258 2261 used = strlcat(str, "|MS_OPTIONSTR", sizeof (pri->code_buf));
2259 2262 if (arg & MS_GLOBAL)
2260 2263 used = strlcat(str, "|MS_GLOBAL", sizeof (pri->code_buf));
2261 2264 if (arg & MS_FORCE)
2262 2265 used = strlcat(str, "|MS_FORCE", sizeof (pri->code_buf));
2263 2266 if (arg & MS_NOMNTTAB)
2264 2267 used = strlcat(str, "|MS_NOMNTTAB", sizeof (pri->code_buf));
2265 2268
2266 2269 if (used == 0 || used >= sizeof (pri->code_buf))
2267 2270 return ((char *)NULL); /* use prt_hex() */
2268 2271
2269 2272 return ((const char *)(str+1));
2270 2273 }
2271 2274
2272 2275 const char *
2273 2276 svfsflags(private_t *pri, ulong_t arg) /* bit map of statvfs syscall flags */
2274 2277 {
2275 2278 char *str = pri->code_buf;
2276 2279
2277 2280 if (arg & ~(ST_RDONLY|ST_NOSUID|ST_NOTRUNC)) {
2278 2281 (void) sprintf(str, "0x%lx", arg);
2279 2282 return (str);
2280 2283 }
2281 2284 *str = '\0';
2282 2285 if (arg & ST_RDONLY)
2283 2286 (void) strcat(str, "|ST_RDONLY");
2284 2287 if (arg & ST_NOSUID)
2285 2288 (void) strcat(str, "|ST_NOSUID");
2286 2289 if (arg & ST_NOTRUNC)
2287 2290 (void) strcat(str, "|ST_NOTRUNC");
2288 2291 if (*str == '\0')
2289 2292 (void) strcat(str, "|0");
2290 2293 return ((const char *)(str+1));
2291 2294 }
2292 2295
2293 2296 const char *
2294 2297 fuiname(int arg) /* fusers() input argument */
2295 2298 {
2296 2299 const char *str = NULL;
2297 2300
2298 2301 switch (arg) {
2299 2302 case F_FILE_ONLY: str = "F_FILE_ONLY"; break;
2300 2303 case F_CONTAINED: str = "F_CONTAINED"; break;
2301 2304 }
2302 2305
2303 2306 return (str);
2304 2307 }
2305 2308
2306 2309 const char *
2307 2310 fuflags(private_t *pri, int arg) /* fusers() output flags */
2308 2311 {
2309 2312 char *str = pri->code_buf;
2310 2313
2311 2314 if (arg & ~(F_CDIR|F_RDIR|F_TEXT|F_MAP|F_OPEN|F_TRACE|F_TTY)) {
2312 2315 (void) sprintf(str, "0x%x", arg);
2313 2316 return (str);
2314 2317 }
2315 2318 *str = '\0';
2316 2319 if (arg & F_CDIR)
2317 2320 (void) strcat(str, "|F_CDIR");
2318 2321 if (arg & F_RDIR)
2319 2322 (void) strcat(str, "|F_RDIR");
2320 2323 if (arg & F_TEXT)
2321 2324 (void) strcat(str, "|F_TEXT");
2322 2325 if (arg & F_MAP)
2323 2326 (void) strcat(str, "|F_MAP");
2324 2327 if (arg & F_OPEN)
2325 2328 (void) strcat(str, "|F_OPEN");
2326 2329 if (arg & F_TRACE)
2327 2330 (void) strcat(str, "|F_TRACE");
2328 2331 if (arg & F_TTY)
2329 2332 (void) strcat(str, "|F_TTY");
2330 2333 if (*str == '\0')
2331 2334 (void) strcat(str, "|0");
2332 2335 return ((const char *)(str+1));
2333 2336 }
2334 2337
2335 2338
2336 2339 const char *
2337 2340 ipprotos(int arg) /* IP protocols cf. netinet/in.h */
2338 2341 {
2339 2342 switch (arg) {
2340 2343 case IPPROTO_IP: return ("IPPROTO_IP");
2341 2344 case IPPROTO_ICMP: return ("IPPROTO_ICMP");
2342 2345 case IPPROTO_IGMP: return ("IPPROTO_IGMP");
2343 2346 case IPPROTO_GGP: return ("IPPROTO_GGP");
2344 2347 case IPPROTO_ENCAP: return ("IPPROTO_ENCAP");
2345 2348 case IPPROTO_TCP: return ("IPPROTO_TCP");
2346 2349 case IPPROTO_EGP: return ("IPPROTO_EGP");
2347 2350 case IPPROTO_PUP: return ("IPPROTO_PUP");
2348 2351 case IPPROTO_UDP: return ("IPPROTO_UDP");
2349 2352 case IPPROTO_IDP: return ("IPPROTO_IDP");
2350 2353 case IPPROTO_IPV6: return ("IPPROTO_IPV6");
2351 2354 case IPPROTO_ROUTING: return ("IPPROTO_ROUTING");
2352 2355 case IPPROTO_FRAGMENT: return ("IPPROTO_FRAGMENT");
2353 2356 case IPPROTO_RSVP: return ("IPPROTO_RSVP");
2354 2357 case IPPROTO_ESP: return ("IPPROTO_ESP");
2355 2358 case IPPROTO_AH: return ("IPPROTO_AH");
2356 2359 case IPPROTO_ICMPV6: return ("IPPROTO_ICMPV6");
2357 2360 case IPPROTO_NONE: return ("IPPROTO_NONE");
2358 2361 case IPPROTO_DSTOPTS: return ("IPPROTO_DSTOPTS");
2359 2362 case IPPROTO_HELLO: return ("IPPROTO_HELLO");
2360 2363 case IPPROTO_ND: return ("IPPROTO_ND");
2361 2364 case IPPROTO_EON: return ("IPPROTO_EON");
2362 2365 case IPPROTO_PIM: return ("IPPROTO_PIM");
2363 2366 case IPPROTO_SCTP: return ("IPPROTO_SCTP");
2364 2367 case IPPROTO_RAW: return ("IPPROTO_RAW");
2365 2368 default: return (NULL);
2366 2369 }
2367 2370 }
↓ open down ↓ |
379 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX