Module Name: src
Committed By: jruoho
Date: Sun Jul 25 21:05:20 UTC 2010
Modified Files:
src/distrib/sets/lists/comp: mi
src/share/man/man9: Makefile
Added Files:
src/share/man/man9: nullop.9
Log Message:
Document the fine nullop() family of dummy functions.
To generate a diff of this commit:
cvs rdiff -u -r1.1483 -r1.1484 src/distrib/sets/lists/comp/mi
cvs rdiff -u -r1.335 -r1.336 src/share/man/man9/Makefile
cvs rdiff -u -r0 -r1.1 src/share/man/man9/nullop.9
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/distrib/sets/lists/comp/mi
diff -u src/distrib/sets/lists/comp/mi:1.1483 src/distrib/sets/lists/comp/mi:1.1484
--- src/distrib/sets/lists/comp/mi:1.1483 Mon Jul 19 15:28:18 2010
+++ src/distrib/sets/lists/comp/mi Sun Jul 25 21:05:14 2010
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.1483 2010/07/19 15:28:18 pooka Exp $
+# $NetBSD: mi,v 1.1484 2010/07/25 21:05:14 jruoho Exp $
#
# Note: don't delete entries from here - mark them as "obsolete" instead.
#
@@ -9032,6 +9032,11 @@
./usr/share/man/cat9/dumpsys.0 comp-sys-catman .cat
./usr/share/man/cat9/dupfdopen.0 comp-sys-catman .cat
./usr/share/man/cat9/edid.0 comp-sys-catman .cat
+./usr/share/man/cat9/enodev.0 comp-sys-catman .cat
+./usr/share/man/cat9/enoioctl.0 comp-sys-catman .cat
+./usr/share/man/cat9/enosys.0 comp-sys-catman .cat
+./usr/share/man/cat9/enxio.0 comp-sys-catman .cat
+./usr/share/man/cat9/eopnotsupp.0 comp-sys-catman .cat
./usr/share/man/cat9/errno.0 comp-sys-catman .cat
./usr/share/man/cat9/ether_addmulti.0 comp-sys-catman .cat
./usr/share/man/cat9/ether_delmulti.0 comp-sys-catman .cat
@@ -9356,6 +9361,7 @@
./usr/share/man/cat9/nanouptime.0 comp-sys-catman .cat
./usr/share/man/cat9/need_resched.0 comp-obsolete obsolete
./usr/share/man/cat9/nextrunqueue.0 comp-obsolete obsolete
+./usr/share/man/cat9/nullop.0 comp-sys-catman .cat
./usr/share/man/cat9/old_sysctl.0 comp-sys-catman .cat
./usr/share/man/cat9/opencrypto.0 comp-sys-catman .cat
./usr/share/man/cat9/optstr.0 comp-sys-catman .cat
@@ -9913,7 +9919,7 @@
./usr/share/man/cat9/vnode.0 comp-sys-catman .cat
./usr/share/man/cat9/vnodeops.0 comp-sys-catman .cat
./usr/share/man/cat9/vnsubr.0 comp-sys-catman .cat
-./usr/share/man/cat9/vprint.0 comp-sys-catman .cat
+./usr/share/man/cat9/voidop.0 comp-sys-catman .cat
./usr/share/man/cat9/vprintf.0 comp-sys-catman .cat
./usr/share/man/cat9/vput.0 comp-sys-catman .cat
./usr/share/man/cat9/vrecycle.0 comp-sys-catman .cat
@@ -14796,6 +14802,11 @@
./usr/share/man/html9/dumpsys.html comp-sys-htmlman html
./usr/share/man/html9/dupfdopen.html comp-sys-htmlman html
./usr/share/man/html9/edid.html comp-sys-htmlman html
+./usr/share/man/html9/enodev.html comp-sys-htmlman html
+./usr/share/man/html9/enoioctl.html comp-sys-htmlman html
+./usr/share/man/html9/enosys.html comp-sys-htmlman html
+./usr/share/man/html9/enxio.html comp-sys-htmlman html
+./usr/share/man/html9/eopnotsupp.html comp-sys-htmlman html
./usr/share/man/html9/errno.html comp-sys-htmlman html
./usr/share/man/html9/ether_addmulti.html comp-sys-htmlman html
./usr/share/man/html9/ether_delmulti.html comp-sys-htmlman html
@@ -15112,6 +15123,7 @@
./usr/share/man/html9/namei.html comp-sys-htmlman html
./usr/share/man/html9/nanotime.html comp-sys-htmlman html
./usr/share/man/html9/nanouptime.html comp-sys-htmlman html
+./usr/share/man/html9/nullop.html comp-sys-htmlman html
./usr/share/man/html9/old_sysctl.html comp-sys-htmlman html
./usr/share/man/html9/opencrypto.html comp-sys-htmlman html
./usr/share/man/html9/optstr.html comp-sys-htmlman html
@@ -15625,6 +15637,7 @@
./usr/share/man/html9/vnode.html comp-sys-htmlman html
./usr/share/man/html9/vnodeops.html comp-sys-htmlman html
./usr/share/man/html9/vnsubr.html comp-sys-htmlman html
+./usr/share/man/html9/voidop.html comp-sys-htmlman html
./usr/share/man/html9/vprint.html comp-sys-htmlman html
./usr/share/man/html9/vprintf.html comp-sys-htmlman html
./usr/share/man/html9/vput.html comp-sys-htmlman html
@@ -20711,6 +20724,11 @@
./usr/share/man/man9/dumpsys.9 comp-sys-man .man
./usr/share/man/man9/dupfdopen.9 comp-sys-man .man
./usr/share/man/man9/edid.9 comp-sys-man .man
+./usr/share/man/man9/enodev.9 comp-sys-man .man
+./usr/share/man/man9/enoioctl.9 comp-sys-man .man
+./usr/share/man/man9/enosys.9 comp-sys-man .man
+./usr/share/man/man9/enxio.9 comp-sys-man .man
+./usr/share/man/man9/eopnotsupp.9 comp-sys-man .man
./usr/share/man/man9/errno.9 comp-sys-man .man
./usr/share/man/man9/ether_addmulti.9 comp-sys-man .man
./usr/share/man/man9/ether_delmulti.9 comp-sys-man .man
@@ -21035,6 +21053,7 @@
./usr/share/man/man9/nanouptime.9 comp-sys-man .man
./usr/share/man/man9/need_resched.9 comp-obsolete obsolete
./usr/share/man/man9/nextrunqueue.9 comp-obsolete obsolete
+./usr/share/man/man9/nullop.9 comp-sys-man .man
./usr/share/man/man9/old_sysctl.9 comp-sys-man .man
./usr/share/man/man9/opencrypto.9 comp-sys-man .man
./usr/share/man/man9/optstr.9 comp-sys-man .man
@@ -21592,6 +21611,7 @@
./usr/share/man/man9/vnode.9 comp-sys-man .man
./usr/share/man/man9/vnodeops.9 comp-sys-man .man
./usr/share/man/man9/vnsubr.9 comp-sys-man .man
+./usr/share/man/man9/voidop.9 comp-sys-man .man
./usr/share/man/man9/vprint.9 comp-sys-man .man
./usr/share/man/man9/vprintf.9 comp-sys-man .man
./usr/share/man/man9/vput.9 comp-sys-man .man
Index: src/share/man/man9/Makefile
diff -u src/share/man/man9/Makefile:1.335 src/share/man/man9/Makefile:1.336
--- src/share/man/man9/Makefile:1.335 Thu Jul 1 14:54:44 2010
+++ src/share/man/man9/Makefile Sun Jul 25 21:05:14 2010
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.335 2010/07/01 14:54:44 jruoho Exp $
+# $NetBSD: Makefile,v 1.336 2010/07/25 21:05:14 jruoho Exp $
# Makefile for section 9 (kernel function and variable) manual pages.
@@ -36,7 +36,7 @@
memmove.9 memset.9 \
microtime.9 microuptime.9 mi_switch.9 \
mstohz.9 mutex.9 m_tag.9 namecache.9 \
- namei.9 opencrypto.9 optstr.9 \
+ namei.9 nullop.9 opencrypto.9 optstr.9 \
panic.9 pci.9 pci_configure_bus.9 pci_intr.9 pckbport.9 \
pcmcia.9 pcq.9 percpu.9 pfil.9 physio.9 pmap.9 pmatch.9 \
pmc.9 pmf.9 pool.9 pool_cache.9 powerhook_establish.9 ppsratecheck.9 \
@@ -460,6 +460,12 @@
MLINKS+=namei.9 lookup.9 \
namei.9 relookup.9 \
namei.9 NDINIT.9
+MLINKS+=nullop.9 voidop.9 \
+ nullop.9 enodev.9 \
+ nullop.9 enxio.9 \
+ nullop.9 enoioctl.9 \
+ nullop.9 enosys.9 \
+ nullop.9 eopnotsupp.9
MLINKS+=opencrypto.9 crypto_get_driverid.9 \
opencrypto.9 crypto_register.9 \
opencrypto.9 crypto_kregister.9 \
Added files:
Index: src/share/man/man9/nullop.9
diff -u /dev/null src/share/man/man9/nullop.9:1.1
--- /dev/null Sun Jul 25 21:05:20 2010
+++ src/share/man/man9/nullop.9 Sun Jul 25 21:05:13 2010
@@ -0,0 +1,88 @@
+.\" $NetBSD: nullop.9,v 1.1 2010/07/25 21:05:13 jruoho Exp $
+.\"
+.\" Copyright (c) 2010 The NetBSD Foundation, Inc.
+.\" All rights reserved.
+.\"
+.\" This code is derived from software contributed to The NetBSD Foundation
+.\" by Jukka Ruohonen.
+.\"
+.\" 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 NETBSD FOUNDATION, INC. 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 FOUNDATION 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.
+.\"
+.Dd July 25, 2010
+.Dt NULLOP 9
+.Os
+.Sh NAME
+.Nm nullop
+.Nd dummy functions
+.Sh SYNOPSIS
+.In sys/systm.h
+.Ft int
+.Fn nullop "void *v"
+.Ft void
+.Fn voidop "void"
+.Ft int
+.Fn enodev "void"
+.Ft int
+.Fn enxio "void"
+.Ft int
+.Fn enoioctl "void"
+.Ft int
+.Fn enosys "void"
+.Ft int
+.Fn eopnotsupp "void"
+.Sh DESCRIPTION
+The
+.Fn nullop
+function provides a generic
+.Dq null operation .
+It always returns the value 0.
+The
+.Fn voidop
+function takes no arguments and does nothing.
+.Pp
+The
+.Fn enodev ,
+.Fn enxio ,
+.Fn enoioctl ,
+.Fn enosys ,
+and
+.Fn eopnotsupp
+functions always fail, returning
+.Er ENODEV ,
+.Er ENXIO ,
+.Er ENOTTY ,
+.Er ENOSYS ,
+and
+.Er EOPNOTSUPP ,
+respectively.
+.Sh EXAMPLES
+The following example demonstrates a case where
+.Fn nullop
+may be useful:
+.Bd -literal -offset indent
+uint64_t xc;
+
+\&...
+
+xc = xc_broadcast(0, (xcfunc_t)nullop, NULL, NULL);
+xc_wait(xc);
+.Ed