Small select manpage update.
manpages for sync and getpriority/setpriority system calls. manpage for nice utility.
This commit is contained in:
parent
7f2e7461e6
commit
bfc8f08ae7
4 changed files with 70 additions and 2 deletions
26
man/man1/nice.1
Normal file
26
man/man1/nice.1
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
.TH NICE 1
|
||||||
|
.SH NAME
|
||||||
|
nice \- invoke command with higher or lower scheduling priority
|
||||||
|
.SH SYNOPSIS
|
||||||
|
\fBnice\fP [\fB\-n\fP increment] \fIutility\fP [\fIargument\fP...]
|
||||||
|
.SH DESCRIPTION
|
||||||
|
The
|
||||||
|
.B nice
|
||||||
|
utility runs \fIutility\fP at a different scheduling priority than
|
||||||
|
the default. The nicer the process is to others (the higher the
|
||||||
|
increment), the less favourable the scheduling is. Super-users
|
||||||
|
can give a negative increment, meaning scheduling is more favourable
|
||||||
|
than the default.
|
||||||
|
.SH OPTIONS
|
||||||
|
.TP
|
||||||
|
.B \-n \fIincrement
|
||||||
|
the increment value sets how nice the invoked command will be. 0 is
|
||||||
|
the same priority as regular processes. 10 is the default.
|
||||||
|
The range is -20 to 20.
|
||||||
|
.SH SEE ALSO
|
||||||
|
getpriority(2), setpriority(2)
|
||||||
|
.SH AUTHOR
|
||||||
|
This
|
||||||
|
.B nice
|
||||||
|
utility was imported from FreeBSD. This manual page was written
|
||||||
|
Ben Gras <beng@few.vu.nl>.
|
37
man/man2/getpriority.2
Normal file
37
man/man2/getpriority.2
Normal file
|
@ -0,0 +1,37 @@
|
||||||
|
.TH GETPRIORITY 2 "Jul 1, 2005"
|
||||||
|
.UC 4
|
||||||
|
.SH NAME
|
||||||
|
getpriority, setpriority \- get and set scheduling priority
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
.ft B
|
||||||
|
#include <sys/resource.h>
|
||||||
|
|
||||||
|
int getpriority(int \fIwhich\fP, int \fIwho\fP)
|
||||||
|
int setpriority(int \fIwhich\fP, int \fIwho\fP, int \fIprio\fP)
|
||||||
|
.SH DESCRIPTION
|
||||||
|
.B Getpriority
|
||||||
|
returns the scheduling priority of the process, process group, or user
|
||||||
|
referred to in \fIwho\fP. Which of the three is indicated in
|
||||||
|
\fIwhich\fP, by PRIO_PROCESS, PRIO_PGRP and PRIO_USER, respectively.
|
||||||
|
In Minix, currently only PRIO_PROCESS is implemented.
|
||||||
|
|
||||||
|
The range of the returned value is between PRIO_MIN and PRIO_MAX,
|
||||||
|
currently between -20 and 20, and is the so-called nice value of
|
||||||
|
a process. The higher the nice value, the less favourable the scheduling
|
||||||
|
priority.
|
||||||
|
|
||||||
|
.B Setpriority
|
||||||
|
sets the priority indicated by \fIwho\fP and \fIwhich\fP to \fIprio\fP.
|
||||||
|
\fIprio\fP, which is the nice value, may only be lowered by the super-user.
|
||||||
|
.SH RETURN VALUES
|
||||||
|
These functions both return -1 on failure, and set errno in this case.
|
||||||
|
Because
|
||||||
|
.B getpriority
|
||||||
|
can return -1 as the real nice value, the caller has to reset errno
|
||||||
|
and check errno afterwards to distinguish between an error condition
|
||||||
|
and a negative nice value.
|
||||||
|
.SH SEE ALSO
|
||||||
|
nice(1)
|
||||||
|
.SH AUTHOR
|
||||||
|
Ben Gras <beng@few.vu.nl>
|
|
@ -27,7 +27,7 @@ up to and including file descriptor
|
||||||
, for reading, writing, or exceptional conditions, respectively.
|
, for reading, writing, or exceptional conditions, respectively.
|
||||||
.B Select
|
.B Select
|
||||||
currently supports regular files, pipes, named pipes,
|
currently supports regular files, pipes, named pipes,
|
||||||
and tty file descriptors. Inet and pty fd's still to be done.
|
inet, and tty file descriptors. Pty fd's still to be done.
|
||||||
|
|
||||||
If the
|
If the
|
||||||
.I readfds
|
.I readfds
|
||||||
|
|
|
@ -7,13 +7,14 @@
|
||||||
.TH SYNC 2 "June 30, 1985"
|
.TH SYNC 2 "June 30, 1985"
|
||||||
.UC 4
|
.UC 4
|
||||||
.SH NAME
|
.SH NAME
|
||||||
sync \- update super-block
|
sync, fsync \- update dirty buffers and super-block
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
.nf
|
.nf
|
||||||
.ft B
|
.ft B
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
int sync(void)
|
int sync(void)
|
||||||
|
int fsync(fd)
|
||||||
.ft R
|
.ft R
|
||||||
.fi
|
.fi
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
@ -22,6 +23,10 @@ causes all information in the file system
|
||||||
buffers that should be on disk to be written out.
|
buffers that should be on disk to be written out.
|
||||||
This includes modified super blocks,
|
This includes modified super blocks,
|
||||||
modified i-nodes, and delayed block I/O.
|
modified i-nodes, and delayed block I/O.
|
||||||
|
.B
|
||||||
|
Fsync
|
||||||
|
does the same thing, but only for the blocks associated with a specific
|
||||||
|
file descriptor. Under minix, currently the two calls do the same thing.
|
||||||
.SH "SEE ALSO"
|
.SH "SEE ALSO"
|
||||||
.BR reboot (2),
|
.BR reboot (2),
|
||||||
.BR sync (8).
|
.BR sync (8).
|
||||||
|
|
Loading…
Reference in a new issue