branch for updated copyright for network release
[unix-history] / usr / src / lib / libc / sys / syscall.2
index 4295f24..d461336 100644 (file)
@@ -2,15 +2,17 @@
 .\" All rights reserved.  The Berkeley software License Agreement
 .\" specifies the terms and conditions for redistribution.
 .\"
 .\" All rights reserved.  The Berkeley software License Agreement
 .\" specifies the terms and conditions for redistribution.
 .\"
-.\"    @(#)syscall.2   4.1 (Berkeley) %G%
+.\"    @(#)syscall.2   6.2 (Berkeley) %G%
 .\"
 .\"
-.TH SYSCALL 2 
+.TH SYSCALL 2 ""
 .UC 4
 .SH NAME
 syscall \- indirect system call
 .SH SYNOPSIS
 .nf
 .UC 4
 .SH NAME
 syscall \- indirect system call
 .SH SYNOPSIS
 .nf
-.BR "syscall(number, r0, r1, arg ...)" \  \  (PDP-11)
+.ft B
+#include <syscall.h>
+.PP
 .BR "syscall(number, arg, ...)" \  \  (VAX-11)
 .fi
 .SH DESCRIPTION
 .BR "syscall(number, arg, ...)" \  \  (VAX-11)
 .fi
 .SH DESCRIPTION
@@ -22,9 +24,10 @@ register arguments
 .I r0
 and
 .I r1
 .I r0
 and
 .I r1
-(on the PDP-11, regardless of whether the entry point really
-uses them) and further arguments
+and further arguments
 .IR arg .
 .IR arg .
+Symbolic constants for system calls can be found in the header file
+.I <syscall.h>.
 .PP
 The r0 value of the system call is returned.
 .SH DIAGNOSTICS
 .PP
 The r0 value of the system call is returned.
 .SH DIAGNOSTICS
@@ -40,32 +43,3 @@ There is no way to simulate system calls
 such as
 .IR pipe (2),
 which return values in register r1.
 such as
 .IR pipe (2),
 which return values in register r1.
-.SH "ASSEMBLER (PDP-11)"
-(indir = 0.)
-.br
-.B sys indir; call
-.PP
-The system call at the location
-.I call
-is executed.
-Execution resumes after the
-.I indir
-call.
-.PP
-On the PDP-11, the main purpose of
-.I indir
-is to allow a program to
-store arguments in system calls and execute them
-out of line in the data segment.
-This preserves the purity of the text segment.
-.PP
-If
-.I indir
-is executed indirectly,
-it is a no-op.
-If the instruction at the indirect
-location is not a system call,
-.I indir
-returns error code EINVAL;
-see
-.IR intro (2).