From e27e32c9d459d8a2c77d1d5315ded1f9f4b0e9d0 Mon Sep 17 00:00:00 2001 From: tsutsui Date: Mon, 24 Nov 2008 14:08:12 +0000 Subject: [PATCH] Add tvtohz(9) man page, which is Xref'ed from microtime(9) and microuptime(9), from FreeBSD. --- distrib/sets/lists/comp/mi | 5 ++- share/man/man9/Makefile | 4 +-- share/man/man9/tvtohz.9 | 65 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 71 insertions(+), 3 deletions(-) create mode 100644 share/man/man9/tvtohz.9 diff --git a/distrib/sets/lists/comp/mi b/distrib/sets/lists/comp/mi index b24e9c715ee8..fde984f534df 100644 --- a/distrib/sets/lists/comp/mi +++ b/distrib/sets/lists/comp/mi @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.1212 2008/11/24 13:50:07 tsutsui Exp $ +# $NetBSD: mi,v 1.1213 2008/11/24 14:08:12 tsutsui Exp $ # # Note: don't delete entries from here - mark them as "obsolete" instead. # @@ -8878,6 +8878,7 @@ ./usr/share/man/cat9/ttyldisc_lookup.0 comp-sys-catman .cat ./usr/share/man/cat9/ttyldisc_remove.0 comp-sys-catman .cat ./usr/share/man/cat9/ttyprintf.0 comp-sys-catman .cat +./usr/share/man/cat9/tvtohz.0 comp-sys-catman .cat ./usr/share/man/cat9/uao_create.0 comp-sys-catman .cat ./usr/share/man/cat9/uao_detach.0 comp-sys-catman .cat ./usr/share/man/cat9/uao_reference.0 comp-sys-catman .cat @@ -14039,6 +14040,7 @@ ./usr/share/man/html9/ttyldisc_lookup.html comp-sys-htmlman html ./usr/share/man/html9/ttyldisc_remove.html comp-sys-htmlman html ./usr/share/man/html9/ttyprintf.html comp-sys-htmlman html +./usr/share/man/html9/tvtohz.html comp-sys-htmlman html ./usr/share/man/html9/uao_create.html comp-sys-htmlman html ./usr/share/man/html9/uao_detach.html comp-sys-htmlman html ./usr/share/man/html9/uao_reference.html comp-sys-htmlman html @@ -19416,6 +19418,7 @@ ./usr/share/man/man9/ttyldisc_lookup.9 comp-sys-man .man ./usr/share/man/man9/ttyldisc_remove.9 comp-sys-man .man ./usr/share/man/man9/ttyprintf.9 comp-sys-man .man +./usr/share/man/man9/tvtohz.9 comp-sys-man .man ./usr/share/man/man9/uao_create.9 comp-sys-man .man ./usr/share/man/man9/uao_detach.9 comp-sys-man .man ./usr/share/man/man9/uao_reference.9 comp-sys-man .man diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile index 7e9b61663f50..3848acced1da 100644 --- a/share/man/man9/Makefile +++ b/share/man/man9/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.272 2008/11/24 13:50:07 tsutsui Exp $ +# $NetBSD: Makefile,v 1.273 2008/11/24 14:08:12 tsutsui Exp $ # Makefile for section 9 (kernel function and variable) manual pages. @@ -50,7 +50,7 @@ MAN= accept_filter.9 accf_data.9 accf_http.9 \ signal.9 sockopt.9 softintr.9 spl.9 splraiseipl.9 \ store.9 suspendsched.9 \ sysctl.9 sysmon_envsys.9 tc.9 tcp_congctl.9 timecounter.9 \ - time_second.9 todr.9 uiomove.9 ucom.9 userret.9 \ + time_second.9 todr.9 tvtohz.9 uiomove.9 ucom.9 userret.9 \ vattr.9 veriexec.9 vcons.9 vfs.9 vfs_hooks.9 vfsops.9 vfssubr.9 \ video.9 vme.9 \ vnfileops.9 vnode.9 vnodeops.9 vnsubr.9 \ diff --git a/share/man/man9/tvtohz.9 b/share/man/man9/tvtohz.9 new file mode 100644 index 000000000000..0dec426bd6bb --- /dev/null +++ b/share/man/man9/tvtohz.9 @@ -0,0 +1,65 @@ +.\" $NetBSD: tvtohz.9,v 1.1 2008/11/24 14:08:13 tsutsui Exp $ +.\" +.\" Copyright (c) 2000 Kelly Yancey +.\" 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. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``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 OR CONTRIBUTORS 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. +.\" +.\" $FreeBSD: src/share/man/man9/tvtohz.9,v 1.4 2005/02/09 18:07:17 ru Exp $ +.\" +.Dd November 24, 2008 +.Dt TVTOHZ 9 +.Os +.Sh NAME +.Nm tvtohz +.Nd convert time interval to tick count +.Sh SYNOPSIS +.In sys/time.h +.Ft int +.Fn tvtohz "struct timeval *tv" +.Sh DESCRIPTION +The +.Fn tvtohz +function accepts a single argument +.Fa tv +which specifies the time interval over which to calculate the number +of system ticks that would elapse. +.Sh RETURN VALUES +Returns the integral number of system ticks expected to elapse in the given +interval, including the current tick. +.Sh SEE ALSO +.Xr microtime 9 , +.Xr microuptime 9 , +.Xr timeout 9 +.Sh HISTORY +The +.Nm +function first appeared in +.Fx 3.0 +and was ported to +.Nx 4.0 +as a part of +.Xr timecounter 9 +framework. +.Sh AUTHORS +This manual page was written by +.An Kelly Yancey Aq kbyanc@posi.net .