1
0
Files
irix-657m-src/eoe/man/manD/delay.d3
2022-09-29 17:59:04 +03:00

61 lines
1.7 KiB
Plaintext

.if n .pH ddi.rm/d3/gen/delay @(#)delay 43.10 of 11/27/92
.\" Copyright 1992, 1991 UNIX System Laboratories, Inc.
.TH delay D3
.IX "\f4delay\fP(D3)"
.SH "NAME"
\f4delay\f1 \- delay process execution for a specified number of clock ticks
.SH "SYNOPSIS"
.nf
.na
.ft 4
void delay(long \f2ticks\fP);
.ft 1
.ad
.fi
.SS Arguments
.RS 0
.IP "\f2ticks\f1" 10n
The number of clock ticks to delay.
.RE
.SH "DESCRIPTION"
\f4delay\f1 causes the caller to sleep for the amount of time specified
by \f2ticks\f1, which is in units of clock ticks.
The exact length of the delay is not guaranteed but it will not be less
than \f2ticks -1\f1 clock ticks.
.SS "Return Values"
None
.SH USAGE
The length of a clock tick can vary across different implementations and
therefore drivers should not include any hard-coded assumptions about
the length of a tick.
The \f4drv_usectohz\f1(D3) and \f4drv_hztousec\f1(D3) functions
can be used, as necessary, to convert between clock ticks and microseconds
(implementation independent units).
.P
The \f4delay\f1 function calls \f4itimeout\f1(D3)
to schedule a wakeup after the specified amount of time has elapsed.
\f4delay\f1 then goes to sleep until \f4itimeout\f1
wakes up the sleeping process.
.SS Level
Base only.
.SS "Synchronization Constraints"
Can sleep.
.P
Driver-defined basic locks and read/write locks
may not be held across calls to this function.
.P
Driver-defined sleep locks may be held across calls to this function,
but this is discouraged because it can adversely affect performance
by forcing any other processes contending for the lock to
sleep for the duration of the delay.
.SH REFERENCES
.na
\f4drv_hztousec\fP(D3),
\f4drv_usectohz\fP(D3),
\f4drv_usecwait\fP(D3),
\f4itimeout\fP(D3),
\f4sleep\fP(D3),
\f4untimeout\fP(D3),
\f4wakeup\fP(D3)
.ad