1*0Sstevel@tonic-gate /* 2*0Sstevel@tonic-gate * CDDL HEADER START 3*0Sstevel@tonic-gate * 4*0Sstevel@tonic-gate * The contents of this file are subject to the terms of the 5*0Sstevel@tonic-gate * Common Development and Distribution License, Version 1.0 only 6*0Sstevel@tonic-gate * (the "License"). You may not use this file except in compliance 7*0Sstevel@tonic-gate * with the License. 8*0Sstevel@tonic-gate * 9*0Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 10*0Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 11*0Sstevel@tonic-gate * See the License for the specific language governing permissions 12*0Sstevel@tonic-gate * and limitations under the License. 13*0Sstevel@tonic-gate * 14*0Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 15*0Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16*0Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 17*0Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 18*0Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 19*0Sstevel@tonic-gate * 20*0Sstevel@tonic-gate * CDDL HEADER END 21*0Sstevel@tonic-gate */ 22*0Sstevel@tonic-gate /* 23*0Sstevel@tonic-gate * Copyright 1992-2003 Sun Microsystems, Inc. All rights reserved. 24*0Sstevel@tonic-gate * Use is subject to license terms. 25*0Sstevel@tonic-gate */ 26*0Sstevel@tonic-gate 27*0Sstevel@tonic-gate /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */ 28*0Sstevel@tonic-gate /* All Rights Reserved */ 29*0Sstevel@tonic-gate 30*0Sstevel@tonic-gate 31*0Sstevel@tonic-gate #ifndef _SYS_OLD_PROCFS_H 32*0Sstevel@tonic-gate #define _SYS_OLD_PROCFS_H 33*0Sstevel@tonic-gate 34*0Sstevel@tonic-gate #pragma ident "%Z%%M% %I% %E% SMI" 35*0Sstevel@tonic-gate 36*0Sstevel@tonic-gate /* 37*0Sstevel@tonic-gate * This file contains the definitions for the old ioctl()-based 38*0Sstevel@tonic-gate * version of the process file system. It is obsolete but will 39*0Sstevel@tonic-gate * continue to be supported in SunOS until the next major release. 40*0Sstevel@tonic-gate * Note that <sys/procfs.h> and <sys/old_procfs.h> contain conflicting 41*0Sstevel@tonic-gate * definitions and cannot be included together in the same source file. 42*0Sstevel@tonic-gate */ 43*0Sstevel@tonic-gate 44*0Sstevel@tonic-gate #include <sys/types.h> 45*0Sstevel@tonic-gate #include <sys/time_impl.h> 46*0Sstevel@tonic-gate #include <sys/signal.h> 47*0Sstevel@tonic-gate #include <sys/siginfo.h> 48*0Sstevel@tonic-gate #include <sys/fault.h> 49*0Sstevel@tonic-gate #include <sys/syscall.h> 50*0Sstevel@tonic-gate #include <sys/procfs_isa.h> 51*0Sstevel@tonic-gate 52*0Sstevel@tonic-gate #ifdef __cplusplus 53*0Sstevel@tonic-gate extern "C" { 54*0Sstevel@tonic-gate #endif 55*0Sstevel@tonic-gate 56*0Sstevel@tonic-gate #if !defined(_LP64) && _FILE_OFFSET_BITS == 64 57*0Sstevel@tonic-gate #error "Cannot use procfs in the large file compilation environment" 58*0Sstevel@tonic-gate #endif 59*0Sstevel@tonic-gate 60*0Sstevel@tonic-gate #if _STRUCTURED_PROC == 0 61*0Sstevel@tonic-gate 62*0Sstevel@tonic-gate /* 63*0Sstevel@tonic-gate * ioctl codes and system call interfaces for /proc. 64*0Sstevel@tonic-gate */ 65*0Sstevel@tonic-gate 66*0Sstevel@tonic-gate #define PIOC ('q'<<8) 67*0Sstevel@tonic-gate #define PIOCSTATUS (PIOC|1) /* get process status */ 68*0Sstevel@tonic-gate #define PIOCSTOP (PIOC|2) /* post STOP request and... */ 69*0Sstevel@tonic-gate #define PIOCWSTOP (PIOC|3) /* wait for process to STOP */ 70*0Sstevel@tonic-gate #define PIOCRUN (PIOC|4) /* make process runnable */ 71*0Sstevel@tonic-gate #define PIOCGTRACE (PIOC|5) /* get traced signal set */ 72*0Sstevel@tonic-gate #define PIOCSTRACE (PIOC|6) /* set traced signal set */ 73*0Sstevel@tonic-gate #define PIOCSSIG (PIOC|7) /* set current signal */ 74*0Sstevel@tonic-gate #define PIOCKILL (PIOC|8) /* send signal */ 75*0Sstevel@tonic-gate #define PIOCUNKILL (PIOC|9) /* delete a signal */ 76*0Sstevel@tonic-gate #define PIOCGHOLD (PIOC|10) /* get held signal set */ 77*0Sstevel@tonic-gate #define PIOCSHOLD (PIOC|11) /* set held signal set */ 78*0Sstevel@tonic-gate #define PIOCMAXSIG (PIOC|12) /* get max signal number */ 79*0Sstevel@tonic-gate #define PIOCACTION (PIOC|13) /* get signal action structs */ 80*0Sstevel@tonic-gate #define PIOCGFAULT (PIOC|14) /* get traced fault set */ 81*0Sstevel@tonic-gate #define PIOCSFAULT (PIOC|15) /* set traced fault set */ 82*0Sstevel@tonic-gate #define PIOCCFAULT (PIOC|16) /* clear current fault */ 83*0Sstevel@tonic-gate #define PIOCGENTRY (PIOC|17) /* get syscall entry set */ 84*0Sstevel@tonic-gate #define PIOCSENTRY (PIOC|18) /* set syscall entry set */ 85*0Sstevel@tonic-gate #define PIOCGEXIT (PIOC|19) /* get syscall exit set */ 86*0Sstevel@tonic-gate #define PIOCSEXIT (PIOC|20) /* set syscall exit set */ 87*0Sstevel@tonic-gate 88*0Sstevel@tonic-gate /* 89*0Sstevel@tonic-gate * These four are obsolete (replaced by PIOCSET/PIOCRESET). 90*0Sstevel@tonic-gate */ 91*0Sstevel@tonic-gate #define PIOCSFORK (PIOC|21) /* set inherit-on-fork flag */ 92*0Sstevel@tonic-gate #define PIOCRFORK (PIOC|22) /* reset inherit-on-fork flag */ 93*0Sstevel@tonic-gate #define PIOCSRLC (PIOC|23) /* set run-on-last-close flag */ 94*0Sstevel@tonic-gate #define PIOCRRLC (PIOC|24) /* reset run-on-last-close flag */ 95*0Sstevel@tonic-gate 96*0Sstevel@tonic-gate #define PIOCGREG (PIOC|25) /* get general registers */ 97*0Sstevel@tonic-gate #define PIOCSREG (PIOC|26) /* set general registers */ 98*0Sstevel@tonic-gate #define PIOCGFPREG (PIOC|27) /* get floating-point registers */ 99*0Sstevel@tonic-gate #define PIOCSFPREG (PIOC|28) /* set floating-point registers */ 100*0Sstevel@tonic-gate #define PIOCNICE (PIOC|29) /* set nice priority */ 101*0Sstevel@tonic-gate #define PIOCPSINFO (PIOC|30) /* get ps(1) information */ 102*0Sstevel@tonic-gate #define PIOCNMAP (PIOC|31) /* get number of memory mappings */ 103*0Sstevel@tonic-gate #define PIOCMAP (PIOC|32) /* get memory map information */ 104*0Sstevel@tonic-gate #define PIOCOPENM (PIOC|33) /* open mapped object for reading */ 105*0Sstevel@tonic-gate #define PIOCCRED (PIOC|34) /* get process credentials */ 106*0Sstevel@tonic-gate #define PIOCGROUPS (PIOC|35) /* get supplementary groups */ 107*0Sstevel@tonic-gate #define PIOCGETPR (PIOC|36) /* read struct proc */ 108*0Sstevel@tonic-gate #define PIOCGETU (PIOC|37) /* read user area */ 109*0Sstevel@tonic-gate 110*0Sstevel@tonic-gate /* 111*0Sstevel@tonic-gate * These are new with SunOS5.0. 112*0Sstevel@tonic-gate */ 113*0Sstevel@tonic-gate #define PIOCSET (PIOC|38) /* set process flags */ 114*0Sstevel@tonic-gate #define PIOCRESET (PIOC|39) /* reset process flags */ 115*0Sstevel@tonic-gate #define PIOCUSAGE (PIOC|43) /* get resource usage */ 116*0Sstevel@tonic-gate #define PIOCOPENPD (PIOC|44) /* get page data file descriptor */ 117*0Sstevel@tonic-gate 118*0Sstevel@tonic-gate /* 119*0Sstevel@tonic-gate * Lightweight process interfaces. 120*0Sstevel@tonic-gate */ 121*0Sstevel@tonic-gate #define PIOCLWPIDS (PIOC|45) /* get lwp identifiers */ 122*0Sstevel@tonic-gate #define PIOCOPENLWP (PIOC|46) /* get lwp file descriptor */ 123*0Sstevel@tonic-gate #define PIOCLSTATUS (PIOC|47) /* get status of all lwps */ 124*0Sstevel@tonic-gate #define PIOCLUSAGE (PIOC|48) /* get resource usage of all lwps */ 125*0Sstevel@tonic-gate 126*0Sstevel@tonic-gate /* 127*0Sstevel@tonic-gate * SVR4 run-time loader interfaces. 128*0Sstevel@tonic-gate */ 129*0Sstevel@tonic-gate #define PIOCNAUXV (PIOC|49) /* get number of aux vector entries */ 130*0Sstevel@tonic-gate #define PIOCAUXV (PIOC|50) /* get aux vector (see sys/auxv.h) */ 131*0Sstevel@tonic-gate 132*0Sstevel@tonic-gate /* 133*0Sstevel@tonic-gate * extra register state interfaces 134*0Sstevel@tonic-gate */ 135*0Sstevel@tonic-gate #define PIOCGXREGSIZE (PIOC|51) /* get extra register state size */ 136*0Sstevel@tonic-gate #define PIOCGXREG (PIOC|52) /* get extra register state */ 137*0Sstevel@tonic-gate #define PIOCSXREG (PIOC|53) /* set extra register state */ 138*0Sstevel@tonic-gate 139*0Sstevel@tonic-gate /* 140*0Sstevel@tonic-gate * Intel-specific interfaces. 141*0Sstevel@tonic-gate */ 142*0Sstevel@tonic-gate #define PIOCNLDT (PIOC|103) /* get number of LDT entries */ 143*0Sstevel@tonic-gate #define PIOCLDT (PIOC|104) /* get LDT (see sys/sysi86.h) */ 144*0Sstevel@tonic-gate 145*0Sstevel@tonic-gate /* Process/lwp status structure */ 146*0Sstevel@tonic-gate 147*0Sstevel@tonic-gate #define PRCLSZ 8 /* maximum size of scheduling class name */ 148*0Sstevel@tonic-gate #define PRSYSARGS 8 /* maximum number of syscall arguments */ 149*0Sstevel@tonic-gate 150*0Sstevel@tonic-gate #endif /* _STRUCTURED_PROC == 0 */ 151*0Sstevel@tonic-gate 152*0Sstevel@tonic-gate typedef struct prstatus { 153*0Sstevel@tonic-gate int pr_flags; /* Flags (see below) */ 154*0Sstevel@tonic-gate short pr_why; /* Reason for process stop (if stopped) */ 155*0Sstevel@tonic-gate short pr_what; /* More detailed reason */ 156*0Sstevel@tonic-gate siginfo_t pr_info; /* Info associated with signal or fault */ 157*0Sstevel@tonic-gate short pr_cursig; /* Current signal */ 158*0Sstevel@tonic-gate ushort_t pr_nlwp; /* Number of lwps in the process */ 159*0Sstevel@tonic-gate sigset_t pr_sigpend; /* Set of signals pending to the process */ 160*0Sstevel@tonic-gate sigset_t pr_sighold; /* Set of signals held (blocked) by the lwp */ 161*0Sstevel@tonic-gate struct sigaltstack pr_altstack; /* Alternate signal stack info */ 162*0Sstevel@tonic-gate struct sigaction pr_action; /* Signal action for current signal */ 163*0Sstevel@tonic-gate pid_t pr_pid; /* Process id */ 164*0Sstevel@tonic-gate pid_t pr_ppid; /* Parent process id */ 165*0Sstevel@tonic-gate pid_t pr_pgrp; /* Process group id */ 166*0Sstevel@tonic-gate pid_t pr_sid; /* Session id */ 167*0Sstevel@tonic-gate timestruc_t pr_utime; /* Process user cpu time */ 168*0Sstevel@tonic-gate timestruc_t pr_stime; /* Process system cpu time */ 169*0Sstevel@tonic-gate timestruc_t pr_cutime; /* Sum of children's user times */ 170*0Sstevel@tonic-gate timestruc_t pr_cstime; /* Sum of children's system times */ 171*0Sstevel@tonic-gate char pr_clname[PRCLSZ]; /* Scheduling class name */ 172*0Sstevel@tonic-gate short pr_syscall; /* System call number (if in syscall) */ 173*0Sstevel@tonic-gate short pr_nsysarg; /* Number of arguments to this syscall */ 174*0Sstevel@tonic-gate long pr_sysarg[PRSYSARGS]; /* Arguments to this syscall */ 175*0Sstevel@tonic-gate id_t pr_who; /* Specific lwp identifier */ 176*0Sstevel@tonic-gate sigset_t pr_lwppend; /* Set of signals pending to the lwp */ 177*0Sstevel@tonic-gate struct ucontext *pr_oldcontext; /* Address of previous ucontext */ 178*0Sstevel@tonic-gate caddr_t pr_brkbase; /* Address of the process heap */ 179*0Sstevel@tonic-gate size_t pr_brksize; /* Size of the process heap, in bytes */ 180*0Sstevel@tonic-gate caddr_t pr_stkbase; /* Address of the process stack */ 181*0Sstevel@tonic-gate size_t pr_stksize; /* Size of the process stack, in bytes */ 182*0Sstevel@tonic-gate short pr_processor; /* processor which last ran this LWP */ 183*0Sstevel@tonic-gate short pr_bind; /* processor LWP bound to or PBIND_NONE */ 184*0Sstevel@tonic-gate long pr_instr; /* Current instruction */ 185*0Sstevel@tonic-gate prgregset_t pr_reg; /* General registers */ 186*0Sstevel@tonic-gate } prstatus_t; 187*0Sstevel@tonic-gate 188*0Sstevel@tonic-gate #if _STRUCTURED_PROC == 0 189*0Sstevel@tonic-gate 190*0Sstevel@tonic-gate /* pr_flags */ 191*0Sstevel@tonic-gate 192*0Sstevel@tonic-gate #define PR_STOPPED 0x0001 /* lwp is stopped */ 193*0Sstevel@tonic-gate #define PR_ISTOP 0x0002 /* lwp is stopped on an event of interest */ 194*0Sstevel@tonic-gate #define PR_DSTOP 0x0004 /* lwp has a stop directive in effect */ 195*0Sstevel@tonic-gate #define PR_ASLEEP 0x0008 /* lwp is sleeping in a system call */ 196*0Sstevel@tonic-gate #define PR_FORK 0x0010 /* inherit-on-fork is in effect */ 197*0Sstevel@tonic-gate #define PR_RLC 0x0020 /* run-on-last-close is in effect */ 198*0Sstevel@tonic-gate #define PR_PTRACE 0x0040 /* obsolete, never set in SunOS5.0 */ 199*0Sstevel@tonic-gate #define PR_PCINVAL 0x0080 /* contents of pr_instr undefined */ 200*0Sstevel@tonic-gate #define PR_ISSYS 0x0100 /* system process */ 201*0Sstevel@tonic-gate #define PR_STEP 0x0200 /* lwp has a single-step directive in effect */ 202*0Sstevel@tonic-gate #define PR_KLC 0x0400 /* kill-on-last-close is in effect */ 203*0Sstevel@tonic-gate #define PR_ASYNC 0x0800 /* asynchronous-stop is in effect */ 204*0Sstevel@tonic-gate #define PR_PCOMPAT 0x1000 /* ptrace-compatibility mode is in effect */ 205*0Sstevel@tonic-gate #define PR_MSACCT 0x2000 /* micro-state usage accounting is in effect */ 206*0Sstevel@tonic-gate #define PR_BPTADJ 0x4000 /* breakpoint trap pc adjustment is in effect */ 207*0Sstevel@tonic-gate #define PR_ASLWP 0x8000 /* obsolete flag; never set */ 208*0Sstevel@tonic-gate 209*0Sstevel@tonic-gate /* Reasons for stopping */ 210*0Sstevel@tonic-gate 211*0Sstevel@tonic-gate #define PR_REQUESTED 1 212*0Sstevel@tonic-gate #define PR_SIGNALLED 2 213*0Sstevel@tonic-gate #define PR_SYSENTRY 3 214*0Sstevel@tonic-gate #define PR_SYSEXIT 4 215*0Sstevel@tonic-gate #define PR_JOBCONTROL 5 216*0Sstevel@tonic-gate #define PR_FAULTED 6 217*0Sstevel@tonic-gate #define PR_SUSPENDED 7 218*0Sstevel@tonic-gate #define PR_CHECKPOINT 8 219*0Sstevel@tonic-gate 220*0Sstevel@tonic-gate /* Information for the ps(1) command */ 221*0Sstevel@tonic-gate 222*0Sstevel@tonic-gate #define PRFNSZ 16 /* max size of execed filename */ 223*0Sstevel@tonic-gate #define PRARGSZ 80 /* Number of chars of arguments */ 224*0Sstevel@tonic-gate 225*0Sstevel@tonic-gate #endif /* _STRUCTURED_PROC == 0 */ 226*0Sstevel@tonic-gate 227*0Sstevel@tonic-gate typedef struct prpsinfo { 228*0Sstevel@tonic-gate char pr_state; /* numeric process state (see pr_sname) */ 229*0Sstevel@tonic-gate char pr_sname; /* printable character representing pr_state */ 230*0Sstevel@tonic-gate char pr_zomb; /* !=0: process terminated but not waited for */ 231*0Sstevel@tonic-gate char pr_nice; /* nice for cpu usage */ 232*0Sstevel@tonic-gate uint_t pr_flag; /* process flags */ 233*0Sstevel@tonic-gate uid_t pr_uid; /* real user id */ 234*0Sstevel@tonic-gate gid_t pr_gid; /* real group id */ 235*0Sstevel@tonic-gate pid_t pr_pid; /* unique process id */ 236*0Sstevel@tonic-gate pid_t pr_ppid; /* process id of parent */ 237*0Sstevel@tonic-gate pid_t pr_pgrp; /* pid of process group leader */ 238*0Sstevel@tonic-gate pid_t pr_sid; /* session id */ 239*0Sstevel@tonic-gate caddr_t pr_addr; /* physical address of process */ 240*0Sstevel@tonic-gate size_t pr_size; /* size of process image in pages */ 241*0Sstevel@tonic-gate size_t pr_rssize; /* resident set size in pages */ 242*0Sstevel@tonic-gate caddr_t pr_wchan; /* wait addr for sleeping process */ 243*0Sstevel@tonic-gate timestruc_t pr_start; /* process start time, sec+nsec since epoch */ 244*0Sstevel@tonic-gate timestruc_t pr_time; /* usr+sys cpu time for this process */ 245*0Sstevel@tonic-gate int pr_pri; /* priority, high value is high priority */ 246*0Sstevel@tonic-gate char pr_oldpri; /* pre-SVR4, low value is high priority */ 247*0Sstevel@tonic-gate char pr_cpu; /* pre-SVR4, cpu usage for scheduling */ 248*0Sstevel@tonic-gate o_dev_t pr_ottydev; /* short tty device number */ 249*0Sstevel@tonic-gate dev_t pr_lttydev; /* controlling tty device (PRNODEV if none) */ 250*0Sstevel@tonic-gate char pr_clname[PRCLSZ]; /* scheduling class name */ 251*0Sstevel@tonic-gate char pr_fname[PRFNSZ]; /* last component of execed pathname */ 252*0Sstevel@tonic-gate char pr_psargs[PRARGSZ]; /* initial characters of arg list */ 253*0Sstevel@tonic-gate short pr_syscall; /* system call number (if in syscall) */ 254*0Sstevel@tonic-gate short pr_fill; 255*0Sstevel@tonic-gate timestruc_t pr_ctime; /* usr+sys cpu time for reaped children */ 256*0Sstevel@tonic-gate size_t pr_bysize; /* size of process image in bytes */ 257*0Sstevel@tonic-gate size_t pr_byrssize; /* resident set size in bytes */ 258*0Sstevel@tonic-gate int pr_argc; /* initial argument count */ 259*0Sstevel@tonic-gate char **pr_argv; /* initial argument vector */ 260*0Sstevel@tonic-gate char **pr_envp; /* initial environment vector */ 261*0Sstevel@tonic-gate int pr_wstat; /* if zombie, the wait() status */ 262*0Sstevel@tonic-gate /* The following percent numbers are 16-bit binary */ 263*0Sstevel@tonic-gate /* fractions [0 .. 1] with the binary point to the */ 264*0Sstevel@tonic-gate /* right of the high-order bit (one == 0x8000) */ 265*0Sstevel@tonic-gate ushort_t pr_pctcpu; /* % of recent cpu time, one or all lwps */ 266*0Sstevel@tonic-gate ushort_t pr_pctmem; /* % of of system memory used by the process */ 267*0Sstevel@tonic-gate uid_t pr_euid; /* effective user id */ 268*0Sstevel@tonic-gate gid_t pr_egid; /* effective group id */ 269*0Sstevel@tonic-gate id_t pr_aslwpid; /* historical; now always zero */ 270*0Sstevel@tonic-gate char pr_dmodel; /* data model of the process */ 271*0Sstevel@tonic-gate char pr_pad[3]; 272*0Sstevel@tonic-gate int pr_filler[6]; /* for future expansion */ 273*0Sstevel@tonic-gate } prpsinfo_t; 274*0Sstevel@tonic-gate 275*0Sstevel@tonic-gate #if _STRUCTURED_PROC == 0 276*0Sstevel@tonic-gate 277*0Sstevel@tonic-gate #if !defined(_STYPES) 278*0Sstevel@tonic-gate #define pr_ttydev pr_lttydev 279*0Sstevel@tonic-gate #else 280*0Sstevel@tonic-gate #define pr_ttydev pr_ottydev 281*0Sstevel@tonic-gate #endif 282*0Sstevel@tonic-gate 283*0Sstevel@tonic-gate #define PRNODEV (dev_t)(-1l) /* non-existent device */ 284*0Sstevel@tonic-gate 285*0Sstevel@tonic-gate /* 286*0Sstevel@tonic-gate * See <sys/procfs_isa.h> for possible values of pr_dmodel. 287*0Sstevel@tonic-gate */ 288*0Sstevel@tonic-gate 289*0Sstevel@tonic-gate /* Optional actions to take when process continues */ 290*0Sstevel@tonic-gate 291*0Sstevel@tonic-gate typedef struct prrun { 292*0Sstevel@tonic-gate int pr_flags; /* Flags */ 293*0Sstevel@tonic-gate sigset_t pr_trace; /* Set of signals to be traced */ 294*0Sstevel@tonic-gate sigset_t pr_sighold; /* Set of signals to be held */ 295*0Sstevel@tonic-gate fltset_t pr_fault; /* Set of faults to be traced */ 296*0Sstevel@tonic-gate caddr_t pr_vaddr; /* Virtual address at which to resume */ 297*0Sstevel@tonic-gate int pr_filler[8]; /* Filler area for future expansion */ 298*0Sstevel@tonic-gate } prrun_t; 299*0Sstevel@tonic-gate 300*0Sstevel@tonic-gate #define PRCSIG 0x001 /* Clear current signal */ 301*0Sstevel@tonic-gate #define PRCFAULT 0x002 /* Clear current fault */ 302*0Sstevel@tonic-gate #define PRSTRACE 0x004 /* Use traced-signal set in pr_trace */ 303*0Sstevel@tonic-gate #define PRSHOLD 0x008 /* Use held-signal set in pr_sighold */ 304*0Sstevel@tonic-gate #define PRSFAULT 0x010 /* Use traced-fault set in pr_fault */ 305*0Sstevel@tonic-gate #define PRSVADDR 0x020 /* Resume at virtual address in pr_vaddr */ 306*0Sstevel@tonic-gate #define PRSTEP 0x040 /* Direct the lwp to single-step */ 307*0Sstevel@tonic-gate #define PRSABORT 0x080 /* Abort syscall */ 308*0Sstevel@tonic-gate #define PRSTOP 0x100 /* Set directed stop request */ 309*0Sstevel@tonic-gate 310*0Sstevel@tonic-gate /* Memory-management interface */ 311*0Sstevel@tonic-gate 312*0Sstevel@tonic-gate typedef struct prmap { 313*0Sstevel@tonic-gate caddr_t pr_vaddr; /* Virtual address */ 314*0Sstevel@tonic-gate size_t pr_size; /* Size of mapping in bytes */ 315*0Sstevel@tonic-gate off_t pr_off; /* Offset into mapped object, if any */ 316*0Sstevel@tonic-gate uint_t pr_mflags; /* Protection and attribute flags */ 317*0Sstevel@tonic-gate uint_t pr_pagesize; /* pagesize (bytes) for this mapping */ 318*0Sstevel@tonic-gate long pr_filler[3]; /* Filler for future expansion */ 319*0Sstevel@tonic-gate } prmap_t; 320*0Sstevel@tonic-gate 321*0Sstevel@tonic-gate /* Protection and attribute flags */ 322*0Sstevel@tonic-gate 323*0Sstevel@tonic-gate #define MA_READ 0x04 /* Readable by the traced process */ 324*0Sstevel@tonic-gate #define MA_WRITE 0x02 /* Writable by the traced process */ 325*0Sstevel@tonic-gate #define MA_EXEC 0x01 /* Executable by the traced process */ 326*0Sstevel@tonic-gate #define MA_SHARED 0x08 /* Changes are shared by mapped object */ 327*0Sstevel@tonic-gate /* 328*0Sstevel@tonic-gate * These are obsolete and unreliable. 329*0Sstevel@tonic-gate * They are included here only for historical compatibility. 330*0Sstevel@tonic-gate */ 331*0Sstevel@tonic-gate #define MA_BREAK 0x10 /* Grown by brk(2) */ 332*0Sstevel@tonic-gate #define MA_STACK 0x20 /* Grown automatically on stack faults */ 333*0Sstevel@tonic-gate 334*0Sstevel@tonic-gate /* Process credentials */ 335*0Sstevel@tonic-gate 336*0Sstevel@tonic-gate typedef struct prcred { 337*0Sstevel@tonic-gate uid_t pr_euid; /* Effective user id */ 338*0Sstevel@tonic-gate uid_t pr_ruid; /* Real user id */ 339*0Sstevel@tonic-gate uid_t pr_suid; /* Saved user id (from exec) */ 340*0Sstevel@tonic-gate gid_t pr_egid; /* Effective group id */ 341*0Sstevel@tonic-gate gid_t pr_rgid; /* Real group id */ 342*0Sstevel@tonic-gate gid_t pr_sgid; /* Saved group id (from exec) */ 343*0Sstevel@tonic-gate uint_t pr_ngroups; /* Number of supplementary groups */ 344*0Sstevel@tonic-gate } prcred_t; 345*0Sstevel@tonic-gate 346*0Sstevel@tonic-gate /* Resource usage */ 347*0Sstevel@tonic-gate 348*0Sstevel@tonic-gate typedef struct prusage { 349*0Sstevel@tonic-gate id_t pr_lwpid; /* lwp id. 0: process or defunct */ 350*0Sstevel@tonic-gate int pr_count; /* number of contributing lwps */ 351*0Sstevel@tonic-gate timestruc_t pr_tstamp; /* current time stamp */ 352*0Sstevel@tonic-gate timestruc_t pr_create; /* process/lwp creation time stamp */ 353*0Sstevel@tonic-gate timestruc_t pr_term; /* process/lwp termination time stamp */ 354*0Sstevel@tonic-gate timestruc_t pr_rtime; /* total lwp real (elapsed) time */ 355*0Sstevel@tonic-gate timestruc_t pr_utime; /* user level CPU time */ 356*0Sstevel@tonic-gate timestruc_t pr_stime; /* system call CPU time */ 357*0Sstevel@tonic-gate timestruc_t pr_ttime; /* other system trap CPU time */ 358*0Sstevel@tonic-gate timestruc_t pr_tftime; /* text page fault sleep time */ 359*0Sstevel@tonic-gate timestruc_t pr_dftime; /* data page fault sleep time */ 360*0Sstevel@tonic-gate timestruc_t pr_kftime; /* kernel page fault sleep time */ 361*0Sstevel@tonic-gate timestruc_t pr_ltime; /* user lock wait sleep time */ 362*0Sstevel@tonic-gate timestruc_t pr_slptime; /* all other sleep time */ 363*0Sstevel@tonic-gate timestruc_t pr_wtime; /* wait-cpu (latency) time */ 364*0Sstevel@tonic-gate timestruc_t pr_stoptime; /* stopped time */ 365*0Sstevel@tonic-gate timestruc_t filltime[6]; /* filler for future expansion */ 366*0Sstevel@tonic-gate ulong_t pr_minf; /* minor page faults */ 367*0Sstevel@tonic-gate ulong_t pr_majf; /* major page faults */ 368*0Sstevel@tonic-gate ulong_t pr_nswap; /* swaps */ 369*0Sstevel@tonic-gate ulong_t pr_inblk; /* input blocks */ 370*0Sstevel@tonic-gate ulong_t pr_oublk; /* output blocks */ 371*0Sstevel@tonic-gate ulong_t pr_msnd; /* messages sent */ 372*0Sstevel@tonic-gate ulong_t pr_mrcv; /* messages received */ 373*0Sstevel@tonic-gate ulong_t pr_sigs; /* signals received */ 374*0Sstevel@tonic-gate ulong_t pr_vctx; /* voluntary context switches */ 375*0Sstevel@tonic-gate ulong_t pr_ictx; /* involuntary context switches */ 376*0Sstevel@tonic-gate ulong_t pr_sysc; /* system calls */ 377*0Sstevel@tonic-gate ulong_t pr_ioch; /* chars read and written */ 378*0Sstevel@tonic-gate ulong_t filler[10]; /* filler for future expansion */ 379*0Sstevel@tonic-gate } prusage_t; 380*0Sstevel@tonic-gate 381*0Sstevel@tonic-gate /* Page data */ 382*0Sstevel@tonic-gate 383*0Sstevel@tonic-gate /* page data file header */ 384*0Sstevel@tonic-gate typedef struct prpageheader { 385*0Sstevel@tonic-gate timestruc_t pr_tstamp; /* real time stamp */ 386*0Sstevel@tonic-gate ulong_t pr_nmap; /* number of address space mappings */ 387*0Sstevel@tonic-gate ulong_t pr_npage; /* total number of pages */ 388*0Sstevel@tonic-gate } prpageheader_t; 389*0Sstevel@tonic-gate 390*0Sstevel@tonic-gate /* page data mapping header */ 391*0Sstevel@tonic-gate typedef struct prasmap { 392*0Sstevel@tonic-gate caddr_t pr_vaddr; /* virtual address */ 393*0Sstevel@tonic-gate size_t pr_npage; /* number of pages in mapping */ 394*0Sstevel@tonic-gate off_t pr_off; /* offset into mapped object, if any */ 395*0Sstevel@tonic-gate uint_t pr_mflags; /* protection and attribute flags */ 396*0Sstevel@tonic-gate uint_t pr_pagesize; /* pagesize (bytes) for this mapping */ 397*0Sstevel@tonic-gate long pr_filler[3]; /* filler for future expansion */ 398*0Sstevel@tonic-gate } prasmap_t; 399*0Sstevel@tonic-gate 400*0Sstevel@tonic-gate /* 401*0Sstevel@tonic-gate * npage bytes (rounded up to a sizeof (long)-byte boundary) follow 402*0Sstevel@tonic-gate * each mapping header, containing zero or more of these flags. 403*0Sstevel@tonic-gate */ 404*0Sstevel@tonic-gate #define PG_REFERENCED 0x02 /* page referenced since last read */ 405*0Sstevel@tonic-gate #define PG_MODIFIED 0x01 /* page modified since last read */ 406*0Sstevel@tonic-gate #define PG_HWMAPPED 0x04 /* page is present and mapped */ 407*0Sstevel@tonic-gate 408*0Sstevel@tonic-gate /* 409*0Sstevel@tonic-gate * Macros for manipulating sets of flags. 410*0Sstevel@tonic-gate * sp must be a pointer to one of sigset_t, fltset_t, or sysset_t. 411*0Sstevel@tonic-gate * flag must be a member of the enumeration corresponding to *sp. 412*0Sstevel@tonic-gate */ 413*0Sstevel@tonic-gate 414*0Sstevel@tonic-gate /* turn on all flags in set */ 415*0Sstevel@tonic-gate #define prfillset(sp) \ 416*0Sstevel@tonic-gate { register int _i_ = sizeof (*(sp))/sizeof (uint32_t); \ 417*0Sstevel@tonic-gate while (_i_) ((uint32_t *)(sp))[--_i_] = (uint32_t)0xFFFFFFFF; } 418*0Sstevel@tonic-gate 419*0Sstevel@tonic-gate /* turn off all flags in set */ 420*0Sstevel@tonic-gate #define premptyset(sp) \ 421*0Sstevel@tonic-gate { register int _i_ = sizeof (*(sp))/sizeof (uint32_t); \ 422*0Sstevel@tonic-gate while (_i_) ((uint32_t *)(sp))[--_i_] = (uint32_t)0; } 423*0Sstevel@tonic-gate 424*0Sstevel@tonic-gate /* turn on specified flag in set */ 425*0Sstevel@tonic-gate #define praddset(sp, flag) \ 426*0Sstevel@tonic-gate ((void)(((unsigned)((flag)-1) < 32*sizeof (*(sp))/sizeof (uint32_t)) ? \ 427*0Sstevel@tonic-gate (((uint32_t *)(sp))[((flag)-1)/32] |= (1UL<<(((flag)-1)%32))) : 0)) 428*0Sstevel@tonic-gate 429*0Sstevel@tonic-gate /* turn off specified flag in set */ 430*0Sstevel@tonic-gate #define prdelset(sp, flag) \ 431*0Sstevel@tonic-gate ((void)(((unsigned)((flag)-1) < 32*sizeof (*(sp))/sizeof (uint32_t)) ? \ 432*0Sstevel@tonic-gate (((uint32_t *)(sp))[((flag)-1)/32] &= ~(1UL<<(((flag)-1)%32))) : 0)) 433*0Sstevel@tonic-gate 434*0Sstevel@tonic-gate /* query: != 0 iff flag is turned on in set */ 435*0Sstevel@tonic-gate #define prismember(sp, flag) \ 436*0Sstevel@tonic-gate (((unsigned)((flag)-1) < 32*sizeof (*(sp))/sizeof (uint32_t)) && \ 437*0Sstevel@tonic-gate (((uint32_t *)(sp))[((flag)-1)/32] & (1UL<<(((flag)-1)%32)))) 438*0Sstevel@tonic-gate 439*0Sstevel@tonic-gate #endif /* _STRUCTURED_PROC == 0 */ 440*0Sstevel@tonic-gate 441*0Sstevel@tonic-gate #ifdef _SYSCALL32 442*0Sstevel@tonic-gate 443*0Sstevel@tonic-gate #if _STRUCTURED_PROC == 0 444*0Sstevel@tonic-gate 445*0Sstevel@tonic-gate /* 446*0Sstevel@tonic-gate * dev32_t version of PRNODEV 447*0Sstevel@tonic-gate */ 448*0Sstevel@tonic-gate #define PRNODEV32 (dev32_t)(-1) 449*0Sstevel@tonic-gate 450*0Sstevel@tonic-gate /* 451*0Sstevel@tonic-gate * Kernel view of structures used by _ILP32 programs. 452*0Sstevel@tonic-gate */ 453*0Sstevel@tonic-gate 454*0Sstevel@tonic-gate #endif /* _STRUCTURED_PROC == 0 */ 455*0Sstevel@tonic-gate 456*0Sstevel@tonic-gate typedef struct prstatus32 { 457*0Sstevel@tonic-gate int32_t pr_flags; /* Flags */ 458*0Sstevel@tonic-gate short pr_why; /* Reason for process stop (if stopped) */ 459*0Sstevel@tonic-gate short pr_what; /* More detailed reason */ 460*0Sstevel@tonic-gate siginfo32_t pr_info; /* Info associated with signal or fault */ 461*0Sstevel@tonic-gate short pr_cursig; /* Current signal */ 462*0Sstevel@tonic-gate ushort_t pr_nlwp; /* Number of lwps in the process */ 463*0Sstevel@tonic-gate sigset_t pr_sigpend; /* Set of signals pending to the process */ 464*0Sstevel@tonic-gate sigset_t pr_sighold; /* Set of signals held (blocked) by the lwp */ 465*0Sstevel@tonic-gate struct sigaltstack32 pr_altstack; /* Alternate signal stack info */ 466*0Sstevel@tonic-gate struct sigaction32 pr_action; /* Signal action for current signal */ 467*0Sstevel@tonic-gate pid32_t pr_pid; /* Process id */ 468*0Sstevel@tonic-gate pid32_t pr_ppid; /* Parent process id */ 469*0Sstevel@tonic-gate pid32_t pr_pgrp; /* Process group id */ 470*0Sstevel@tonic-gate pid32_t pr_sid; /* Session id */ 471*0Sstevel@tonic-gate timestruc32_t pr_utime; /* Process user cpu time */ 472*0Sstevel@tonic-gate timestruc32_t pr_stime; /* Process system cpu time */ 473*0Sstevel@tonic-gate timestruc32_t pr_cutime; /* Sum of children's user times */ 474*0Sstevel@tonic-gate timestruc32_t pr_cstime; /* Sum of children's system times */ 475*0Sstevel@tonic-gate char pr_clname[PRCLSZ]; /* Scheduling class name */ 476*0Sstevel@tonic-gate short pr_syscall; /* System call number (if in syscall) */ 477*0Sstevel@tonic-gate short pr_nsysarg; /* Number of arguments to this syscall */ 478*0Sstevel@tonic-gate int32_t pr_sysarg[PRSYSARGS]; /* Arguments to this syscall */ 479*0Sstevel@tonic-gate id32_t pr_who; /* Specific lwp identifier */ 480*0Sstevel@tonic-gate sigset_t pr_lwppend; /* Set of signals pending to the lwp */ 481*0Sstevel@tonic-gate caddr32_t pr_oldcontext; /* Address of previous ucontext */ 482*0Sstevel@tonic-gate caddr32_t pr_brkbase; /* Address of the process heap */ 483*0Sstevel@tonic-gate size32_t pr_brksize; /* Size of the process heap, in bytes */ 484*0Sstevel@tonic-gate caddr32_t pr_stkbase; /* Address of the process stack */ 485*0Sstevel@tonic-gate size32_t pr_stksize; /* Size of the process stack, in bytes */ 486*0Sstevel@tonic-gate short pr_processor; /* processor which last ran this LWP */ 487*0Sstevel@tonic-gate short pr_bind; /* processor LWP bound to or PBIND_NONE */ 488*0Sstevel@tonic-gate int32_t pr_instr; /* Current instruction */ 489*0Sstevel@tonic-gate prgregset32_t pr_reg; /* General registers */ 490*0Sstevel@tonic-gate } prstatus32_t; 491*0Sstevel@tonic-gate 492*0Sstevel@tonic-gate typedef struct prpsinfo32 { 493*0Sstevel@tonic-gate char pr_state; /* numeric process state (see pr_sname) */ 494*0Sstevel@tonic-gate char pr_sname; /* printable character representing pr_state */ 495*0Sstevel@tonic-gate char pr_zomb; /* !=0: process terminated but not waited for */ 496*0Sstevel@tonic-gate char pr_nice; /* nice for cpu usage */ 497*0Sstevel@tonic-gate uint32_t pr_flag; /* process flags */ 498*0Sstevel@tonic-gate uid32_t pr_uid; /* real user id */ 499*0Sstevel@tonic-gate gid32_t pr_gid; /* real group id */ 500*0Sstevel@tonic-gate pid32_t pr_pid; /* unique process id */ 501*0Sstevel@tonic-gate pid32_t pr_ppid; /* process id of parent */ 502*0Sstevel@tonic-gate pid32_t pr_pgrp; /* pid of process group leader */ 503*0Sstevel@tonic-gate pid32_t pr_sid; /* session id */ 504*0Sstevel@tonic-gate caddr32_t pr_addr; /* physical address of process */ 505*0Sstevel@tonic-gate size32_t pr_size; /* size of process image in pages */ 506*0Sstevel@tonic-gate size32_t pr_rssize; /* resident set size in pages */ 507*0Sstevel@tonic-gate caddr32_t pr_wchan; /* wait addr for sleeping process */ 508*0Sstevel@tonic-gate timestruc32_t pr_start; /* process start time, sec+nsec since epoch */ 509*0Sstevel@tonic-gate timestruc32_t pr_time; /* usr+sys cpu time for this process */ 510*0Sstevel@tonic-gate int32_t pr_pri; /* priority, high value is high priority */ 511*0Sstevel@tonic-gate char pr_oldpri; /* pre-SVR4, low value is high priority */ 512*0Sstevel@tonic-gate char pr_cpu; /* pre-SVR4, cpu usage for scheduling */ 513*0Sstevel@tonic-gate o_dev_t pr_ottydev; /* short tty device number */ 514*0Sstevel@tonic-gate dev32_t pr_lttydev; /* controlling tty device (PRNODEV if none) */ 515*0Sstevel@tonic-gate char pr_clname[PRCLSZ]; /* scheduling class name */ 516*0Sstevel@tonic-gate char pr_fname[PRFNSZ]; /* last component of execed pathname */ 517*0Sstevel@tonic-gate char pr_psargs[PRARGSZ]; /* initial characters of arg list */ 518*0Sstevel@tonic-gate short pr_syscall; /* system call number (if in syscall) */ 519*0Sstevel@tonic-gate short pr_fill; 520*0Sstevel@tonic-gate timestruc32_t pr_ctime; /* usr+sys cpu time for reaped children */ 521*0Sstevel@tonic-gate size32_t pr_bysize; /* size of process image in bytes */ 522*0Sstevel@tonic-gate size32_t pr_byrssize; /* resident set size in bytes */ 523*0Sstevel@tonic-gate int pr_argc; /* initial argument count */ 524*0Sstevel@tonic-gate caddr32_t pr_argv; /* initial argument vector */ 525*0Sstevel@tonic-gate caddr32_t pr_envp; /* initial environment vector */ 526*0Sstevel@tonic-gate int pr_wstat; /* if zombie, the wait() status */ 527*0Sstevel@tonic-gate ushort_t pr_pctcpu; /* % of recent cpu time, one or all lwps */ 528*0Sstevel@tonic-gate ushort_t pr_pctmem; /* % of of system memory used by the process */ 529*0Sstevel@tonic-gate uid32_t pr_euid; /* effective user id */ 530*0Sstevel@tonic-gate gid32_t pr_egid; /* effective group id */ 531*0Sstevel@tonic-gate id32_t pr_aslwpid; /* historical; now always zero */ 532*0Sstevel@tonic-gate char pr_dmodel; /* data model of the process */ 533*0Sstevel@tonic-gate char pr_pad[3]; 534*0Sstevel@tonic-gate int32_t pr_filler[6]; /* for future expansion */ 535*0Sstevel@tonic-gate } prpsinfo32_t; 536*0Sstevel@tonic-gate 537*0Sstevel@tonic-gate #if _STRUCTURED_PROC == 0 538*0Sstevel@tonic-gate 539*0Sstevel@tonic-gate typedef struct prrun32 { 540*0Sstevel@tonic-gate int32_t pr_flags; /* Flags */ 541*0Sstevel@tonic-gate sigset_t pr_trace; /* Set of signals to be traced */ 542*0Sstevel@tonic-gate sigset_t pr_sighold; /* Set of signals to be held */ 543*0Sstevel@tonic-gate fltset_t pr_fault; /* Set of faults to be traced */ 544*0Sstevel@tonic-gate caddr32_t pr_vaddr; /* Virtual address at which to resume */ 545*0Sstevel@tonic-gate int32_t pr_filler[8]; /* Filler area for future expansion */ 546*0Sstevel@tonic-gate } prrun32_t; 547*0Sstevel@tonic-gate 548*0Sstevel@tonic-gate typedef struct ioc_prmap32 { 549*0Sstevel@tonic-gate caddr32_t pr_vaddr; /* Virtual address */ 550*0Sstevel@tonic-gate size32_t pr_size; /* Size of mapping in bytes */ 551*0Sstevel@tonic-gate off32_t pr_off; /* Offset into mapped object, if any */ 552*0Sstevel@tonic-gate uint32_t pr_mflags; /* Protection and attribute flags */ 553*0Sstevel@tonic-gate uint32_t pr_pagesize; /* pagesize (bytes) for this mapping */ 554*0Sstevel@tonic-gate int32_t pr_filler[3]; /* Filler for future expansion */ 555*0Sstevel@tonic-gate } ioc_prmap32_t; 556*0Sstevel@tonic-gate 557*0Sstevel@tonic-gate typedef struct prusage32 { 558*0Sstevel@tonic-gate id32_t pr_lwpid; /* lwp id. 0: process or defunct */ 559*0Sstevel@tonic-gate int32_t pr_count; /* number of contributing lwps */ 560*0Sstevel@tonic-gate timestruc32_t pr_tstamp; /* current time stamp */ 561*0Sstevel@tonic-gate timestruc32_t pr_create; /* process/lwp creation time stamp */ 562*0Sstevel@tonic-gate timestruc32_t pr_term; /* process/lwp termination time stamp */ 563*0Sstevel@tonic-gate timestruc32_t pr_rtime; /* total lwp real (elapsed) time */ 564*0Sstevel@tonic-gate timestruc32_t pr_utime; /* user level cpu time */ 565*0Sstevel@tonic-gate timestruc32_t pr_stime; /* system call cpu time */ 566*0Sstevel@tonic-gate timestruc32_t pr_ttime; /* other system trap cpu time */ 567*0Sstevel@tonic-gate timestruc32_t pr_tftime; /* text page fault sleep time */ 568*0Sstevel@tonic-gate timestruc32_t pr_dftime; /* data page fault sleep time */ 569*0Sstevel@tonic-gate timestruc32_t pr_kftime; /* kernel page fault sleep time */ 570*0Sstevel@tonic-gate timestruc32_t pr_ltime; /* user lock wait sleep time */ 571*0Sstevel@tonic-gate timestruc32_t pr_slptime; /* all other sleep time */ 572*0Sstevel@tonic-gate timestruc32_t pr_wtime; /* wait-cpu (latency) time */ 573*0Sstevel@tonic-gate timestruc32_t pr_stoptime; /* stopped time */ 574*0Sstevel@tonic-gate timestruc32_t filltime[6]; /* filler for future expansion */ 575*0Sstevel@tonic-gate uint32_t pr_minf; /* minor page faults */ 576*0Sstevel@tonic-gate uint32_t pr_majf; /* major page faults */ 577*0Sstevel@tonic-gate uint32_t pr_nswap; /* swaps */ 578*0Sstevel@tonic-gate uint32_t pr_inblk; /* input blocks */ 579*0Sstevel@tonic-gate uint32_t pr_oublk; /* output blocks */ 580*0Sstevel@tonic-gate uint32_t pr_msnd; /* messages sent */ 581*0Sstevel@tonic-gate uint32_t pr_mrcv; /* messages received */ 582*0Sstevel@tonic-gate uint32_t pr_sigs; /* signals received */ 583*0Sstevel@tonic-gate uint32_t pr_vctx; /* voluntary context switches */ 584*0Sstevel@tonic-gate uint32_t pr_ictx; /* involuntary context switches */ 585*0Sstevel@tonic-gate uint32_t pr_sysc; /* system calls */ 586*0Sstevel@tonic-gate uint32_t pr_ioch; /* chars read and written */ 587*0Sstevel@tonic-gate uint32_t filler[10]; /* filler for future expansion */ 588*0Sstevel@tonic-gate } prusage32_t; 589*0Sstevel@tonic-gate 590*0Sstevel@tonic-gate typedef struct ioc_prpageheader32 { 591*0Sstevel@tonic-gate timestruc32_t pr_tstamp; /* real time stamp */ 592*0Sstevel@tonic-gate uint32_t pr_nmap; /* number of address space mappings */ 593*0Sstevel@tonic-gate uint32_t pr_npage; /* total number of pages */ 594*0Sstevel@tonic-gate } ioc_prpageheader32_t; 595*0Sstevel@tonic-gate 596*0Sstevel@tonic-gate typedef struct ioc_prasmap32 { 597*0Sstevel@tonic-gate caddr32_t pr_vaddr; /* virtual address */ 598*0Sstevel@tonic-gate size32_t pr_npage; /* number of pages in mapping */ 599*0Sstevel@tonic-gate off32_t pr_off; /* offset into mapped object, if any */ 600*0Sstevel@tonic-gate uint32_t pr_mflags; /* protection and attribute flags */ 601*0Sstevel@tonic-gate uint32_t pr_pagesize; /* pagesize (bytes) for this mapping */ 602*0Sstevel@tonic-gate int32_t pr_filler[3]; /* filler for future expansion */ 603*0Sstevel@tonic-gate } ioc_prasmap32_t; 604*0Sstevel@tonic-gate 605*0Sstevel@tonic-gate #endif /* _STRUCTURED_PROC == 0 */ 606*0Sstevel@tonic-gate 607*0Sstevel@tonic-gate #endif /* _SYSCALL32 */ 608*0Sstevel@tonic-gate 609*0Sstevel@tonic-gate #ifdef __cplusplus 610*0Sstevel@tonic-gate } 611*0Sstevel@tonic-gate #endif 612*0Sstevel@tonic-gate 613*0Sstevel@tonic-gate #endif /* _SYS_OLD_PROCFS_H */ 614