summaryrefslogtreecommitdiffstats
path: root/lib/libc
diff options
context:
space:
mode:
authorguenther <guenther@openbsd.org>2014-05-30 04:42:07 +0000
committerguenther <guenther@openbsd.org>2014-05-30 04:42:07 +0000
commit117148834a222cab54433d175d47d366779724be (patch)
tree3985285864b4516fb2fa9dc97c5f968078e9e011 /lib/libc
parentA program is the thing you run; a process is an instance of something (diff)
downloadwireguard-openbsd-117148834a222cab54433d175d47d366779724be.tar.xz
wireguard-openbsd-117148834a222cab54433d175d47d366779724be.zip
Add definitions for Process and (finally!) Thread
Tweak some error descriptions based on that Completely reword ETXTBSY description based on a suggestion from millert@ tweaks and oks jmc@ millert@ sobrado@
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/sys/intro.237
1 files changed, 28 insertions, 9 deletions
diff --git a/lib/libc/sys/intro.2 b/lib/libc/sys/intro.2
index 80456dc09ff..460a75aff28 100644
--- a/lib/libc/sys/intro.2
+++ b/lib/libc/sys/intro.2
@@ -1,4 +1,4 @@
-.\" $OpenBSD: intro.2,v 1.50 2014/05/02 20:20:12 guenther Exp $
+.\" $OpenBSD: intro.2,v 1.51 2014/05/30 04:42:07 guenther Exp $
.\" $NetBSD: intro.2,v 1.6 1995/02/27 12:33:41 cgd Exp $
.\"
.\" Copyright (c) 1980, 1983, 1986, 1991, 1993
@@ -30,7 +30,7 @@
.\"
.\" @(#)intro.2 8.3 (Berkeley) 12/11/93
.\"
-.Dd $Mdocdate: May 2 2014 $
+.Dd $Mdocdate: May 30 2014 $
.Dt INTRO 2
.Os
.Sh NAME
@@ -92,7 +92,7 @@ An asynchronous signal (such as
.Dv SIGINT
or
.Dv SIGQUIT )
-was caught by the process during the execution of an interruptible
+was caught by the thread during the execution of an interruptible
function.
If the signal handler performs a normal return, the
interrupted function call will seem to have returned the error condition.
@@ -187,11 +187,10 @@ A control function (see
was attempted for a file or
special device for which the operation was inappropriate.
.It Er 26 ETXTBSY Em "Text file busy" .
-The new process was a pure procedure (shared text) file
-which was open for writing by another process, or
-while the pure procedure file was being executed an
-.Xr open 2
-call requested write access.
+An attempt was made either to execute a pure procedure (shared text)
+file which was open for writing by another process,
+or to open with write access a pure procedure file that is currently
+being executed.
.It Er 27 EFBIG Em "File too large" .
The size of a file exceeded the maximum.
(The system-wide maximum file size is 2**63 bytes.
@@ -427,7 +426,7 @@ caller provided space.
.It Er 88 ECANCELED Em "Operation canceled" .
The requested operation was canceled.
.It Er 89 EIDRM Em "Identifier removed" .
-An IPC identifier was removed while the current process was waiting on it.
+An IPC identifier was removed while the current thread was waiting on it.
.It Er 90 ENOMSG Em "\&No message of desired type".
An IPC message queue does not contain a message of the desired type,
or a message catalog does not contain the requested message.
@@ -436,6 +435,12 @@ The operation has requested an unsupported value.
.El
.Sh DEFINITIONS
.Bl -tag -width Ds
+.It Process
+A process is a collection of one or more threads,
+plus the resources shared by those threads such as process ID,
+address space,
+user IDs and group IDs,
+and root directory and current working directory.
.It Process ID
Each active process in the system is uniquely identified by a non-negative
integer called a process ID.
@@ -498,6 +503,20 @@ which is in a separate session.
Not all members of an orphaned process group are necessarily orphaned
processes (those whose creating process has exited).
The process group of a session leader is orphaned by definition.
+.It Thread
+A thread is a preemptively scheduled flow of control within a process,
+with its own set of register values,
+floating point environment,
+thread ID,
+signal mask,
+pending signal set,
+alternate signal stack,
+thread control block address,
+resource utilization,
+errno variable location,
+and values for thread-specific keys.
+A process initially has just one thread,
+a duplicate of the thread in the parent process that created this process.
.It Real User ID and Real Group ID
Each user on the system is identified by a positive integer
termed the real user ID.