-#define SESS_LEADER(p) ((p)->p_session->s_leader == (p))
-#define SESSHOLD(s) ((s)->s_count++)
-#define SESSRELE(s) { \
- if (--(s)->s_count == 0) \
- FREE(s, M_SESSION); \
- }
-#endif
-
-/* stat codes */
-#define SSLEEP 1 /* awaiting an event */
-#define SWAIT 2 /* (abandoned state) */
-#define SRUN 3 /* running */
-#define SIDL 4 /* intermediate state in process creation */
-#define SZOMB 5 /* intermediate state in process termination */
-#define SSTOP 6 /* process being traced */
-
-/* flag codes */
-/* NEED TO CHECK which of these are still used */
-#define SLOAD 0x0000001 /* in core */
-#define SSYS 0x0000002 /* swapper or pager process */
-#define SLOCK 0x0000004 /* process being swapped out */
-#define SSWAP 0x0000008 /* save area flag */
-#define STRC 0x0000010 /* process is being traced */
-#define SWTED 0x0000020 /* another tracing flag */
-#define SSINTR 0x0000040 /* sleep is interruptible */
-#define SPAGE 0x0000080 /* process in page wait state */
-#define SKEEP 0x0000100 /* another flag to prevent swap out */
-/*#define SOMASK 0x0000200 /* restore old mask after taking signal */
-#define SWEXIT 0x0000400 /* working on exiting */
-#define SPHYSIO 0x0000800 /* doing physical i/o */
-#define SPPWAIT 0x0001000 /* parent is waiting for child to exec/exit */
-#define SVFORK SPARSYNC /* process resulted from vfork() XXX */
-/*#define SVFDONE 0x0002000 /* another vfork flag XXX */
-/*#define SNOVM 0x0004000 /* no vm, parent in a vfork() XXX */
-#define SPAGV 0x0008000 /* init data space on demand, from vnode */
-#define SSEQL 0x0010000 /* user warned of sequential vm behavior */
-#define SUANOM 0x0020000 /* user warned of random vm behavior */
-#define STIMO 0x0040000 /* timing out during sleep */
-#define SNOCLDSTOP 0x0080000 /* no SIGCHLD when children stop */
-#define SCTTY 0x0100000 /* has a controlling terminal */
-#define SOWEUPC 0x0200000 /* owe process an addupc() call at next ast */
-#define SSEL 0x0400000 /* selecting; wakeup/waiting danger */
-#define SEXEC 0x0800000 /* process called exec */
-#define SHPUX 0x1000000 /* HP-UX process (HPUXCOMPAT) */
-#define SULOCK 0x2000000 /* locked in core after swap error XXX */
-#define SPTECHG 0x4000000 /* pte's for process have changed XXX */