diff options
| author | Val Packett <val@packett.cool> | 2023-04-15 17:59:30 +0000 |
|---|---|---|
| committer | Konstantin Belousov <kib@FreeBSD.org> | 2023-04-16 10:48:20 +0000 |
| commit | 77f0e198d9134b6ca2650d3a84d7db2d786ec0c0 (patch) | |
| tree | 69bd6ea3164adca96a16fa8ec356b2fdda25e974 /lib/libc/sys | |
| parent | 82a036d86acaac75b1ff6d4f8b767bbb117694f1 (diff) | |
procctl: add state flags to PROC_REAP_GETPIDS reports
For a process supervisor using the reaper API to track process subtrees,
it is very useful to know the state of the processes on the list.
Sponsored by: https://www.patreon.com/valpackett
Reviewed by: kib
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D39585
Diffstat (limited to 'lib/libc/sys')
| -rw-r--r-- | lib/libc/sys/procctl.2 | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/libc/sys/procctl.2 b/lib/libc/sys/procctl.2 index 97509d0fbf06..052fcb37fb9d 100644 --- a/lib/libc/sys/procctl.2 +++ b/lib/libc/sys/procctl.2 @@ -29,7 +29,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 2, 2021 +.Dd April 15, 2023 .Dt PROCCTL 2 .Os .Sh NAME @@ -302,7 +302,7 @@ of the process. The .Fa pi_flags field returns the following flags, further describing the descendant: -.Bl -tag -width REAPER_PIDINFO_REAPER +.Bl -tag -width REAPER_PIDINFO_EXITING .It Dv REAPER_PIDINFO_VALID Set to indicate that the .Vt procctl_reaper_pidinfo @@ -320,6 +320,12 @@ field identifies the direct child of the reaper. .It Dv REAPER_PIDINFO_REAPER The reported process is itself a reaper. The descendants of the subordinate reaper are not reported. +.It Dv REAPER_PIDINFO_ZOMBIE +The reported process is in the zombie state, ready to be reaped. +.It Dv REAPER_PIDINFO_STOPPED +The reported process is stopped by a SIGSTOP/SIGTSTP signal. +.It Dv REAPER_PIDINFO_EXITING +The reported process is in the process of exiting (but not yet a zombie). .El .It Dv PROC_REAP_KILL Request to deliver a signal to some subset of the descendants of the reaper. |
