diff options
author | Artur Grabowski <art@cvs.openbsd.org> | 2002-02-15 02:01:02 +0000 |
---|---|---|
committer | Artur Grabowski <art@cvs.openbsd.org> | 2002-02-15 02:01:02 +0000 |
commit | 605a6928df611a898e4cd4423efbdd5541879587 (patch) | |
tree | 8b3e2f864c4cf4258ab334d699a6a9bdfce53341 /share/man | |
parent | 18b52be11c9f47bb9190bb894a0f42e14d368257 (diff) |
Document tvtohz.
Diffstat (limited to 'share/man')
-rw-r--r-- | share/man/man9/Makefile | 4 | ||||
-rw-r--r-- | share/man/man9/tvtohz.9 | 58 |
2 files changed, 60 insertions, 2 deletions
diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile index b70248e2642..cf55472dd97 100644 --- a/share/man/man9/Makefile +++ b/share/man/man9/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.45 2001/12/06 10:48:59 mickey Exp $ +# $OpenBSD: Makefile,v 1.46 2002/02/15 02:01:01 art Exp $ # $NetBSD: Makefile,v 1.4 1996/01/09 03:23:01 thorpej Exp $ # Makefile for section 9 (kernel function and variable) manual pages. @@ -14,7 +14,7 @@ MAN= altq.9 audio.9 boot.9 bus_dma.9 bus_space.9 copy.9 crypto.9 ctxsw.9 \ ratecheck.9 resettodr.9 radio.9 random.9 \ shutdownhook_establish.9 sleep.9 spl.9 startuphook_establish.9 \ store.9 style.9 \ - time.9 timeout.9 uvm.9 \ + time.9 timeout.9 tvtohz.9 uvm.9 \ vm_allocate.9 vm_map_copy.9 vm_deallocate.9 \ vm_map_inherit.9 vm_map_protect.9 vnode.9 vn_lock.9 \ vwaitforio.9 vwaitforio.9 diff --git a/share/man/man9/tvtohz.9 b/share/man/man9/tvtohz.9 new file mode 100644 index 00000000000..fd166f06474 --- /dev/null +++ b/share/man/man9/tvtohz.9 @@ -0,0 +1,58 @@ +.\" $OpenBSD: tvtohz.9,v 1.1 2002/02/15 02:01:01 art Exp $ +.\" +.\" Copyright (c) 1999 Marc Espie +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" 3. All advertising materials mentioning features or use of this software +.\" must display the following acknowledgement: +.\" This product includes software developed by Marc Espie +.\" for the OpenBSD Project. +.\" 3. The name of the author may not be used to endorse or promote products +.\" derived from this software without specific prior written permission +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.Dd February 15, 2002 +.Dt TVTOHZ 9 +.Os +.Sh NAME +.Nm tvtohz +.Nd translate time period to timeout delay. +.Sh SYNOPSIS +.Fd #include <sys/types.h> +.Fd #include <sys/time.h> +.Fd #include <sys/systm.h> +.Ft int +.Fn tvtohz "struct timeval *tv" +.Sh DESCRIPTION +The +.Fn tvtohz +function computes the number of +.Va hz +in the specified amount of time. +This is mainly used to translate a timeval into a suitable argument for +.Xr timeout 9 . +.Sh CODE REFERENCES +This function is implemented in the file +.Pa sys/kern/kern_clock.c . +.Sh SEE ALSO +.Xr hz 9 , +.Xr hzto 9 , +.Xr timeout 9 |