Index: src/share/Makefile diff -u src/share/Makefile:1.33.2.1 src/share/Makefile:1.37 --- src/share/Makefile:1.33.2.1 Sun Aug 26 23:57:06 2007 +++ src/share/Makefile Wed Jun 27 03:40:03 2007 @@ -1,47 +1,74 @@ # @(#)Makefile 8.1 (Berkeley) 6/5/93 # $FreeBSD$ +.include + # Do not include `info' in the SUBDIR list, it is handled separately. -SUBDIR= colldef \ +SUBDIR= ${_colldef} \ ${_dict} \ ${_doc} \ - examples \ + ${_examples} \ ${_isdn} \ - man \ - me \ + ${_man} \ + ${_me} \ misc \ mk \ - mklocale \ - monetdef \ - msgdef \ - numericdef \ + ${_mklocale} \ + ${_monetdef} \ + ${_msgdef} \ + ${_numericdef} \ ${_sendmail} \ skel \ snmp \ - syscons \ + ${_syscons} \ tabset \ termcap \ - timedef \ + ${_timedef} \ ${_zoneinfo} -.if !defined(NO_I4B) +.if ${MK_LOCALES} != "no" +_colldef = colldef +_mklocale = mklocale +_monetdef = monetdef +_msgdef = msgdef +_numericdef = numericdef +_timedef = timedef +.endif + +.if ${MK_SYSCONS} != "no" +_syscons= syscons +.endif + +.if ${MK_MAN} != "no" +_man= man +.endif + +.if ${MK_GROFF} != "no" +_me= me +.endif + +.if ${MK_EXAMPLES} != "no" +_examples= examples +.endif + +.if ${MK_I4B} != "no" _isdn= isdn .endif -.if !defined(NO_DICT) +.if ${MK_DICT} != "no" _dict= dict .endif -.if !defined(NO_SENDMAIL) +.if ${MK_SENDMAIL} != "no" _sendmail= sendmail .endif -.if !defined(NO_SHAREDOCS) +.if ${MK_SHAREDOCS} != "no" _doc= doc .endif -.if !defined(NO_ZONEINFO) +.if ${MK_ZONEINFO} != "no" _zoneinfo= zoneinfo .endif Index: src/share/colldef/Makefile diff -u src/share/colldef/Makefile:1.69 src/share/colldef/Makefile:1.72 --- src/share/colldef/Makefile:1.69 Fri Mar 4 22:24:29 2005 +++ src/share/colldef/Makefile Mon Dec 24 18:30:08 2007 @@ -34,6 +34,7 @@ sr_YU.ISO8859-5 \ sv_SE.ISO8859-1 \ sv_SE.ISO8859-15 \ + tr_TR.ISO8859-9 \ uk_UA.CP1251 \ uk_UA.ISO8859-5 \ uk_UA.KOI8-U @@ -58,14 +59,14 @@ CLEANFILES= ${FILES} ENCODINGS= Big5 Big5HKSCS CP949 eucCN eucJP eucKR GB18030 GB2312 GBK \ - ISO8859-1 ISO8859-2 ISO8859-9 ISO8859-15 SJIS US-ASCII UTF-8 + ISO8859-1 ISO8859-2 ISO8859-15 SJIS US-ASCII UTF-8 ISO8859-1_Big5= is_IS:zh_TW ISO8859-1_ISO8859-1= ${ISO8859-15_ISO8859-15} pt_PT:pt_BR LATIN1LINKS= af_ZA da_DK en_AU en_CA en_GB en_NZ en_US eu_ES fi_FI \ - fr_BE fr_CA fr_CH fr_FR it_CH it_IT nl_BE nl_NL no_NO \ - pt_PT + fr_BE fr_CA fr_CH fr_FR it_CH it_IT nb_NO nl_BE nl_NL \ + nn_NO no_NO pt_PT ISO8859-15_ISO8859-15= de_DE:de_AT de_DE:de_CH ${LATIN1LINKS:C/^/la_LN:/} LATIN2LINKS= hr_HR hu_HU ro_RO sr_YU @@ -79,7 +80,6 @@ US-ASCII_GB18030= la_LN:zh_CN US-ASCII_GB2312= la_LN:zh_CN US-ASCII_GBK= la_LN:zh_CN -US-ASCII_ISO8859-9= la_LN:tr_TR US-ASCII_SJIS= la_LN:ja_JP ASCIILINKS= en_AU en_CA en_GB en_NZ en_US @@ -89,7 +89,8 @@ de_DE el_GR en_AU en_CA en_GB en_IE en_NZ en_US es_ES \ et_EE eu_ES fi_FI fr_BE \ fr_CA fr_CH fr_FR he_IL hr_HR hu_HU hy_AM is_IS it_CH it_IT \ - ja_JP kk_KZ ko_KR lt_LT nl_BE nl_NL no_NO pl_PL pt_BR pt_PT \ + ja_JP kk_KZ ko_KR lt_LT mn_MN \ + nb_NO nl_BE nl_NL nn_NO no_NO pl_PL pt_BR pt_PT \ ro_RO ru_RU sk_SK sl_SI sr_YU sv_SE tr_TR uk_UA zh_CN zh_HK \ zh_TW US-ASCII_UTF-8= ${UTF8LINKS:C/^/la_LN:/} Index: src/share/colldef/README diff -u src/share/colldef/README:1.2 src/share/colldef/README:1.3 --- src/share/colldef/README:1.2 Mon Apr 8 17:28:22 2002 +++ src/share/colldef/README Wed Dec 26 05:21:26 2007 @@ -3,3 +3,4 @@ WARNING: For the compatibility sake try to keep collating table backward compatible with ASCII, i.e. add other symbols to the existent ASCII order. +For mnemonic names see ftp://std.dkuug.dk/i18n/charmaps/ Index: src/share/colldef/map.ISO8859-9 diff -u /dev/null src/share/colldef/map.ISO8859-9:1.1 --- /dev/null Thu Jan 17 11:57:33 2008 +++ src/share/colldef/map.ISO8859-9 Mon Dec 24 18:30:09 2007 @@ -0,0 +1,175 @@ +# $FreeBSD$ +NU \x00 +SH \x01 +SX \x02 +EX \x03 +ET \x04 +EQ \x05 +AK \x06 +BL \x07 +BS \x08 +HT \x09 +LF \x0a +VT \x0b +FF \x0c +CR \x0d +SO \x0e +SI \x0f +DL \x10 +D1 \x11 +D2 \x12 +D3 \x13 +D4 \x14 +NK \x15 +SY \x16 +EB \x17 +CN \x18 +EM \x19 +SB \x1a +EC \x1b +FS \x1c +GS \x1d +RS \x1e +US \x1f +SP \x20 +Nb \x23 +DO \x24 +At \x40 +<( \x5b +// \x5c +)> \x5d +'> \x5e +'! \x60 +(! \x7b +!! \x7c +!) \x7d +'? \x7e +DT \x7f +PA \x80 +HO \x81 +BH \x82 +NH \x83 +IN \x84 +NL \x85 +SA \x86 +ES \x87 +HS \x88 +HJ \x89 +VS \x8a +PD \x8b +PU \x8c +RI \x8d +S2 \x8e +S3 \x8f +DC \x90 +P1 \x91 +P2 \x92 +TS \x93 +CC \x94 +MW \x95 +SG \x96 +EG \x97 +SS \x98 +GC \x99 +SC \x9a +CI \x9b +ST \x9c +OC \x9d +PM \x9e +AC \x9f +NS \xa0 +!I \xa1 +Ct \xa2 +Pd \xa3 +Cu \xa4 +Ye \xa5 +BB \xa6 +SE \xa7 +': \xa8 +Co \xa9 +-a \xaa +<< \xab +NO \xac +-- \xad +Rg \xae +'m \xaf +DG \xb0 ++- \xb1 +2S \xb2 +3S \xb3 +'' \xb4 +My \xb5 +PI \xb6 +.M \xb7 +', \xb8 +1S \xb9 +-o \xba +>> \xbb +14 \xbc +12 \xbd +34 \xbe +?I \xbf +A! \xc0 +A' \xc1 +A> \xc2 +A? \xc3 +A: \xc4 +AA \xc5 +AE \xc6 +C, \xc7 +E! \xc8 +E' \xc9 +E> \xca +E: \xcb +I! \xcc +I' \xcd +I> \xce +I: \xcf +G( \xd0 +N? \xd1 +O! \xd2 +O' \xd3 +O> \xd4 +O? \xd5 +O: \xd6 +*X \xd7 +O/ \xd8 +U! \xd9 +U' \xda +U> \xdb +U: \xdc +I. \xdd +S, \xde +ss \xdf +a! \xe0 +a' \xe1 +a> \xe2 +a? \xe3 +a: \xe4 +aa \xe5 +ae \xe6 +c, \xe7 +e! \xe8 +e' \xe9 +e; \xea +e: \xeb +e. \xec +i' \xed +i> \xee +i- \xef +g( \xf0 +n? \xf1 +o! \xf2 +o' \xf3 +o> \xf4 +o? \xf5 +o: \xf6 +-: \xf7 +o/ \xf8 +u! \xf9 +u' \xfa +u> \xfb +u: \xfc +i. \xfd +s, \xfe +y: \xff Index: src/share/colldef/sv_SE.ISO8859-1.src diff -u src/share/colldef/sv_SE.ISO8859-1.src:1.2 src/share/colldef/sv_SE.ISO8859-1.src:1.3 --- src/share/colldef/sv_SE.ISO8859-1.src:1.2 Sun Jun 10 21:43:47 2001 +++ src/share/colldef/sv_SE.ISO8859-1.src Mon Nov 19 20:39:02 2007 @@ -22,7 +22,7 @@ F;G;H;(I,,,>,);\ J;...;M;(N,);(O,,,,>);\ P;...;T;(U,,,>,);\ - (V,W);X;(Y,);Z;;(,);(,);\ + V;W;X;(Y,);Z;;(,);(,);\ ;\ # [;\\;];^;<':>;_;<'m>;<''>;`;\ @@ -32,7 +32,7 @@ f;g;h;(i,,,>,);\ j;...;m;(n,);(o,,,,>);\ p;...;t;(u,,,>,);\ - (v,w);x;(y,,);z;;(,);(,);\ + v;w;x;(y,,);z;;(,);(,);\ ;\ # \{;;|;;\};~;<.M>;;;
;\ Index: src/share/colldef/sv_SE.ISO8859-15.src diff -u src/share/colldef/sv_SE.ISO8859-15.src:1.3 src/share/colldef/sv_SE.ISO8859-15.src:1.4 --- src/share/colldef/sv_SE.ISO8859-15.src:1.3 Sun Jun 10 21:43:47 2001 +++ src/share/colldef/sv_SE.ISO8859-15.src Mon Nov 19 20:39:02 2007 @@ -22,7 +22,7 @@ F;G;H;(I,,,>,);\ J;...;M;(N,);(O,,,,>,);\ P;Q;R;(S,);T;(U,,,>,);\ - (V,W);X;(Y,,);(Z,);;(,);(,);\ + V;W;X;(Y,,);(Z,);;(,);(,);\ ;\ # [;\\;];^;_;<'m>;`;\ @@ -32,7 +32,7 @@ f;g;h;(i,,,>,);\ j;...;m;(n,);(o,,,,>,);\ p;q;r;(s,,);t;(u,,,>,);\ - (v,w);x;(y,,);(z,);;(,);(,);\ + v;w;x;(y,,);(z,);;(,);(,);\ ;\ # \{;;|;\};~;<.M>;;;
;\ Index: src/share/colldef/tr_TR.ISO8859-9.src diff -u /dev/null src/share/colldef/tr_TR.ISO8859-9.src:1.1 --- /dev/null Thu Jan 17 11:57:33 2008 +++ src/share/colldef/tr_TR.ISO8859-9.src Mon Dec 24 18:30:09 2007 @@ -0,0 +1,36 @@ +# latin5 (backward compatible with ASCII) +# +# $FreeBSD$ +# +charmap map.ISO8859-9 +order \ +# controls + ;...;;;...;;\ +# + ;;!;;\";<<<>;/>>;;\ + ;;;;;\ + %;&;<',>;';\(;\);*;+;<+->;<-:>;<*X>;\,;<-->;-;.;/;\ +# digits + (0,<14>,<12>,<34>);(1,<1S>);(2,<2S>);(3,<3S>);4;...;9;\ +# + :;\;;\<;=;>;?;;;;;;;\ +# capital + (A,,,>,,,,);\ + B;(C,);D;(E,,,>,);\ + F;G;;H;(I,,,>,);;\ + J;...;M;(N,);(O,,,>,,,);\ + P;...;S;;T;(U,,,>,);\ + V;W;X;Y;Z;\ +# + [;\\;];^;<':>;_;<'m>;<''>;`;\ +# small + (a,,,>,,,,);\ + b;(c,);d;(e,,,,);\ + f;g;;h;;(i,,,>,);\ + j;...;m;(n,);(o,,,>,,,);\ + p;...;s;;;t;(u,,,>,);\ + v;w;x;(y,);z;\ +# + \{;;|;;\};~;<.M>;;;
;\ +# remains + <-a>;<-o> Index: src/share/dict/web2a diff -u src/share/dict/web2a:1.1.1.1 src/share/dict/web2a:1.2 --- src/share/dict/web2a:1.1.1.1 Tue May 31 03:07:47 1994 +++ src/share/dict/web2a Mon Feb 19 03:48:59 2007 @@ -59704,7 +59704,7 @@ stock buckle stock card stock cattle -stock cerificate +stock certificate stock change stock company stock dividend Index: src/share/doc/Makefile diff -u src/share/doc/Makefile:1.19 src/share/doc/Makefile:1.21 --- src/share/doc/Makefile:1.19 Sat Sep 25 17:11:39 2004 +++ src/share/doc/Makefile Fri Mar 2 19:42:53 2007 @@ -1,9 +1,11 @@ # From: @(#)Makefile 8.1 (Berkeley) 6/5/93 # $FreeBSD$ -SUBDIR= ${_bind9} IPv6 papers psd smm usd +.include -.if !defined(NO_BIND) +SUBDIR= ${_bind9} IPv6 legal papers psd smm usd + +.if ${MK_BIND} != "no" _bind9= bind9 .endif Index: src/share/doc/IPv6/IMPLEMENTATION diff -u src/share/doc/IPv6/IMPLEMENTATION:1.7.10.2 src/share/doc/IPv6/IMPLEMENTATION:1.10 --- src/share/doc/IPv6/IMPLEMENTATION:1.7.10.2 Sun Dec 25 22:03:37 2005 +++ src/share/doc/IPv6/IMPLEMENTATION Mon Nov 13 02:38:07 2006 @@ -6,10 +6,10 @@ $FreeBSD$ NOTE: The document tries to describe behaviors/implementation choices -of the latest KAME/*BSD stack (like KAME/NetBSD 1.5.1). The description -here may not be applicable to KAME-integrated *BSD releases (like stock -NetBSD 1.5.1), as we have certain amount of changes between them. Still, -some of the content can be useful for KAME-integrated *BSD releases. +of the latest KAME/*BSD stack. The description here may not be +applicable to KAME-integrated *BSD releases, as we have certain amount +of changes between them. Still, some of the content can be useful for +KAME-integrated *BSD releases. Table of Contents @@ -83,11 +83,8 @@ 6.1 KAME node as correspondent node 6.2 KAME node as home agent/mobile node 6.3 Old Mobile IPv6 code - 7. Routing table extensions - 7.1 ART routing table lookup algorithm - 7.2 Multipath routing support - 8. Coding style - 9. Policy on technology with intellectual property right restriction + 7. Coding style + 8. Policy on technology with intellectual property right restriction 1. IPv6 @@ -2365,7 +2362,7 @@ especially when you have a policy about the style. -9. Policy on technology with intellectual property right restriction +8. Policy on technology with intellectual property right restriction There are quite a few IETF documents/whatever which has intellectual property right (IPR) restriction. KAME's stance is stated below. Index: src/share/doc/bind9/Makefile diff -u src/share/doc/bind9/Makefile:1.4 src/share/doc/bind9/Makefile:1.5 --- src/share/doc/bind9/Makefile:1.4 Thu Mar 17 18:15:29 2005 +++ src/share/doc/bind9/Makefile Sun Jun 3 07:19:56 2007 @@ -8,12 +8,16 @@ NO_OBJ= FILESGROUPS= TOP ARM MISC -TOP= CHANGES COPYRIGHT FAQ README +TOP= CHANGES COPYRIGHT FAQ README README.idnkit TOPDIR= ${DOCDIR}/bind9 ARM= Bv9ARM.ch01.html Bv9ARM.ch02.html Bv9ARM.ch03.html \ Bv9ARM.ch04.html Bv9ARM.ch05.html Bv9ARM.ch06.html \ Bv9ARM.ch07.html Bv9ARM.ch08.html Bv9ARM.ch09.html \ - Bv9ARM.html + Bv9ARM.ch10.html Bv9ARM.html man.dig.html \ + man.dnssec-keygen.html man.dnssec-signzone.html man.host.html \ + man.named-checkconf.html man.named-checkzone.html \ + man.named.html man.rndc-confgen.html man.rndc.conf.html \ + man.rndc.html ARMDIR= ${TOPDIR}/arm MISC= dnssec format-options.pl ipv6 migration migration-4to9 \ options rfc-compliance roadmap sdb Index: src/share/doc/legal/Makefile diff -u /dev/null src/share/doc/legal/Makefile:1.2 --- /dev/null Thu Jan 17 11:57:34 2008 +++ src/share/doc/legal/Makefile Fri Nov 9 06:09:35 2007 @@ -0,0 +1,7 @@ +# $FreeBSD$ + +SUBDIR= intel_ipw \ + intel_iwi \ + intel_wpi + +.include Index: src/share/doc/legal/intel_ipw/Makefile diff -u /dev/null src/share/doc/legal/intel_ipw/Makefile:1.2 --- /dev/null Thu Jan 17 11:57:34 2008 +++ src/share/doc/legal/intel_ipw/Makefile Sat Mar 3 02:10:55 2007 @@ -0,0 +1,7 @@ +# $FreeBSD$ + +NO_OBJ= +FILES= ${.CURDIR}/../../../../sys/contrib/dev/ipw/LICENSE +FILESDIR= ${SHAREDIR}/doc/legal/intel_ipw + +.include Index: src/share/doc/legal/intel_iwi/Makefile diff -u /dev/null src/share/doc/legal/intel_iwi/Makefile:1.2 --- /dev/null Thu Jan 17 11:57:34 2008 +++ src/share/doc/legal/intel_iwi/Makefile Sat Mar 3 02:10:55 2007 @@ -0,0 +1,7 @@ +# $FreeBSD$ + +NO_OBJ= +FILES= ${.CURDIR}/../../../../sys/contrib/dev/iwi/LICENSE +FILESDIR= ${SHAREDIR}/doc/legal/intel_iwi + +.include Index: src/share/doc/legal/intel_wpi/Makefile diff -u /dev/null src/share/doc/legal/intel_wpi/Makefile:1.1 --- /dev/null Thu Jan 17 11:57:34 2008 +++ src/share/doc/legal/intel_wpi/Makefile Mon Nov 5 19:47:18 2007 @@ -0,0 +1,8 @@ +# $FreeBSD$ + +NO_OBJ= +FILES= ${.CURDIR}/../../../../sys/contrib/dev/wpi/LICENSE +FILESDIR= ${SHAREDIR}/doc/legal/intel_wpi + +.include + Index: src/share/doc/papers/Makefile diff -u src/share/doc/papers/Makefile:1.15.2.1 src/share/doc/papers/Makefile:1.17 --- src/share/doc/papers/Makefile:1.15.2.1 Wed Aug 17 06:39:27 2005 +++ src/share/doc/papers/Makefile Thu Oct 5 21:42:30 2006 @@ -5,8 +5,8 @@ contents \ devfs \ diskperf \ - hwpmc \ fsinterface \ + hwpmc \ jail \ kernmalloc \ kerntune \ Index: src/share/doc/smm/Makefile diff -u src/share/doc/smm/Makefile:1.19 src/share/doc/smm/Makefile:1.20 --- src/share/doc/smm/Makefile:1.19 Tue Jan 20 21:08:33 2004 +++ src/share/doc/smm/Makefile Sat Mar 18 02:54:33 2006 @@ -1,6 +1,8 @@ # From: @(#)Makefile 8.1 (Berkeley) 6/10/93 # $FreeBSD$ +.include + # The following modules do not describe FreeBSD: # 14.uucpimpl, 15.uucpnet @@ -24,7 +26,7 @@ 12.timed \ 18.net -.if !defined(NO_SENDMAIL) +.if ${MK_SENDMAIL} != "no" _08.sendmailop= 08.sendmailop .endif Index: src/share/examples/Makefile diff -u src/share/examples/Makefile:1.48.2.1 src/share/examples/Makefile:1.51 --- src/share/examples/Makefile:1.48.2.1 Wed May 2 00:50:03 2007 +++ src/share/examples/Makefile Sun Jul 15 05:49:22 2007 @@ -2,10 +2,11 @@ # # Doing a make install builds /usr/share/examples +.include + LDIRS= BSD_daemon \ FreeBSD_version \ IPv6 \ - atm \ bootforth \ cvsup \ diskless \ @@ -33,6 +34,9 @@ startslip \ sunrpc +# Disabled in 7.0 as netatm is not MPSAFE. +#LDIRS+= atm + XFILES= BSD_daemon/FreeBSD.pfa \ BSD_daemon/README \ BSD_daemon/beastie.eps \ @@ -43,15 +47,6 @@ FreeBSD_version/Makefile \ FreeBSD_version/README \ IPv6/USAGE \ - atm/NOTES \ - atm/README \ - atm/Startup \ - atm/atm-config.sh \ - atm/atm-sockets.txt \ - atm/cpcs-design.txt \ - atm/fore-microcode.txt \ - atm/sscf-design.txt \ - atm/sscop-design.txt \ bootforth/README \ bootforth/boot.4th \ bootforth/frames.4th \ @@ -244,6 +239,17 @@ sunrpc/sort/sort.x \ sunrpc/sort/sort_proc.c +# Disabled in 7.0 as netatm is not MPSAFE. +#XFILES+= atm/NOTES \ +# atm/README \ +# atm/Startup \ +# atm/atm-config.sh \ +# atm/atm-sockets.txt \ +# atm/cpcs-design.txt \ +# atm/fore-microcode.txt \ +# atm/sscf-design.txt \ +# atm/sscop-design.txt + BINDIR= ${SHAREDIR}/examples NO_OBJ= @@ -282,10 +288,10 @@ .if ${SHARED} != "symlinks" SUBDIR= smbfs -.if !defined(NO_IPFILTER) +.if ${MK_IPFILTER} != "no" SUBDIR+=ipfilter .endif -.if !defined(NO_PF) +.if ${MK_PF} != "no" SUBDIR+=pf .endif .endif Index: src/share/examples/cvsup/stable-supfile diff -u src/share/examples/cvsup/stable-supfile:1.29.2.3 src/share/examples/cvsup/stable-supfile:1.33 --- src/share/examples/cvsup/stable-supfile:1.29.2.3 Tue Sep 11 01:30:02 2007 +++ src/share/examples/cvsup/stable-supfile Thu Oct 11 12:28:08 2007 @@ -66,10 +66,10 @@ *default host=CHANGE_THIS.FreeBSD.org *default base=/var/db *default prefix=/usr -# The following line is for 6-stable. If you want 5-stable, 4-stable, -# 3-stable, or 2.2-stable, change to "RELENG_5", "RELENG_4", "RELENG_3", -# or "RELENG_2_2" respectively. -*default release=cvs tag=RELENG_6 +# The following line is for 7-stable. If you want 6-stable, 5-stable, +# 4-stable, 3-stable, or 2.2-stable, change to "RELENG_6", "RELENG_5", +# "RELENG_4", "RELENG_3", or "RELENG_2_2" respectively. +*default release=cvs tag=RELENG_7 *default delete use-rel-suffix # If you seem to be limited by CPU rather than network or disk bandwidth, try Index: src/share/examples/cvsup/standard-supfile diff -u src/share/examples/cvsup/standard-supfile:1.23.4.4 src/share/examples/cvsup/standard-supfile:1.25 --- src/share/examples/cvsup/standard-supfile:1.23.4.4 Tue Sep 11 01:30:26 2007 +++ src/share/examples/cvsup/standard-supfile Sat Sep 8 06:01:19 2007 @@ -1,7 +1,7 @@ # $FreeBSD$ # # This file contains all of the "CVSup collections" that make up the -# FreeBSD 6.x-STABLE source tree. +# FreeBSD-current source tree. # # CVSup (CVS Update Protocol) allows you to download the latest CVS # tree (or any branch of development therefrom) to your system easily @@ -49,7 +49,7 @@ *default host=CHANGE_THIS.FreeBSD.org *default base=/var/db *default prefix=/usr -*default release=cvs tag=RELENG_6 +*default release=cvs tag=. *default delete use-rel-suffix # If you seem to be limited by CPU rather than network or disk bandwidth, try Index: src/share/examples/diskless/clone_root diff -u src/share/examples/diskless/clone_root:1.3 src/share/examples/diskless/clone_root:1.4 --- src/share/examples/diskless/clone_root:1.3 Fri Sep 24 05:17:31 2004 +++ src/share/examples/diskless/clone_root Fri Jun 2 23:01:11 2006 @@ -36,7 +36,7 @@ # local startup files will not be used. # # create a kernel config file in /sys/i386/conf/DISKLESS with -# options MFS +# options MD_ROOT # options BOOTP # options BOOTP_NFSROOT # options BOOTP_COMPAT Index: src/share/examples/etc/README.examples diff -u src/share/examples/etc/README.examples:1.14.8.1 src/share/examples/etc/README.examples:1.17 --- src/share/examples/etc/README.examples:1.14.8.1 Mon May 29 23:25:49 2006 +++ src/share/examples/etc/README.examples Thu Oct 19 13:19:00 2006 @@ -44,7 +44,6 @@ newsyslog.conf - configuration for system log file rotator newsyslog(8) nsmb.conf - smbfs lookups configuration file opieaccess - OPIE database of trusted networks -pccard_ether - configuration script for Ethernet pccards (see pccardd(8)) pf.conf - pf(4) example configuration file pf.os - SYN fingerprint database phones - phone number database for tip(1) @@ -72,6 +71,5 @@ ttys - defines port configuration for init(8) defaults/bluetooth.device.conf - defaults/devfs.rules - default configuration rules for devfs(8) -defaults/pccard.conf - default configuration file for pccard(8) defaults/periodic.conf - default configuration file for periodic(8) defaults/rc.conf - default system configuration info (see rc.conf(5)) Index: src/share/examples/etc/make.conf diff -u src/share/examples/etc/make.conf:1.265.2.9 src/share/examples/etc/make.conf:1.279 --- src/share/examples/etc/make.conf:1.265.2.9 Fri May 25 00:03:44 2007 +++ src/share/examples/etc/make.conf Wed Jan 17 20:43:06 2007 @@ -49,10 +49,14 @@ # CFLAGS controls the compiler settings used when compiling C code. # Note that optimization settings other than -O and -O2 are not recommended # or supported for compiling the world or the kernel - please revert any -# nonstandard optimization settings to "-O" or -O2 before submitting bug -# reports without patches to the developers. +# nonstandard optimization settings to "-O" or "-O2 -fno-strict-aliasing" +# before submitting bug reports without patches to the developers. # -#CFLAGS= -O -pipe +# Compiling with -fstrict-aliasing optimization breaks some [notable] ports. +# GCC turns on -fstrict-aliasing optimization at all levels above -O[1], so +# explicitly turn it off when using compiling with the -O2 optimization level. +# +#CFLAGS= -O2 -fno-strict-aliasing -pipe # # CXXFLAGS controls the compiler settings used when compiling C++ code. # Note that CXXFLAGS is initially set to the value of CFLAGS. If you wish @@ -99,50 +103,9 @@ #ENABLE_SUID_NEWGRP= # # To avoid building various parts of the base system: -#NO_ACPI= # do not build acpiconf(8) and related programs -#NO_ATM= # do not build ATM related programs and libraries -#NO_AUTHPF= # do not build and install authpf (setuid/gid) -#NO_BLUETOOTH= # do not build Bluetooth related stuff -#NO_BOOT= # do not build boot blocks and loader -#NO_CRYPT= # do not build any crypto code -#NO_CVS= # do not build CVS -#NO_CXX= # do not build C++ and friends -#NO_DICT= # do not build the Webster dictionary files -#NO_DYNAMICROOT= # do not link /bin and /sbin dynamically -#NO_FORTRAN= # do not build g77 and related libraries -#NO_GAMES= # do not build games (games/ subdir) -#NO_GDB= # do not build GDB -#NO_GPIB= # do not build GPIB support -#NO_I4B= # do not build isdn4bsd package -#NO_INET6= # do not build IPv6 related programs and libraries -#NO_INFO= # do not make or install info files -#NO_IPFILTER= # do not build IP Filter package -#NO_KERBEROS= # do not build and install Kerberos 5 (KTH Heimdal) -#NO_LIBC_R= # do not build libc_r (re-entrant version of libc) -#NO_LIBPTHREAD= # do not build libpthread (M:N threading library) -#NO_LIBTHR= # do not build libthr (1:1 threading library) -#NO_LPR= # do not build lpr and related programs -#NO_MAILWRAPPER= # do not build the mailwrapper(8) MTA selector -#NO_MAN= # do not build manual pages #NO_MODULES= # do not build modules with the kernel -#NO_NETCAT= # do not build netcat -#NO_NIS= # do not build NIS support and related programs. -# # If NO_NIS is set, you might need to adopt your -# # nsswitch.conf(5) and remove `nis' entries. -#NO_NLS_CATALOGS= # do not build NLS catalog support for csh(1) -#NO_OBJC= # do not build Objective C support -#NO_OPENSSH= # do not build OpenSSH -#NO_OPENSSL= # do not build OpenSSL (implies NO_KERBEROS/NO_OPENSSH) -#NO_PF= # do not build PF firewall package -#NO_PROFILE= # Avoid compiling profiled libraries -#NO_RCMDS= # do not build or install BSD r* commands (rsh, etc). -#NO_SENDMAIL= # do not build sendmail and related programs #NO_SHARE= # do not go into the share subdir #NO_SHARED= # build /bin and /sbin statically linked (bad idea) -#NO_SHAREDOCS= # do not build the 4.4BSD legacy docs -#NO_TCSH= # do not build and install /bin/csh (which is tcsh) -#NO_TOOLCHAIN= # do not build programs for program development -#NO_USB= # do not build usbd(8) and related programs # # Variables that control how ppp(8) is built. #PPP_NO_NAT= # do not build with NAT support (see make.conf(5)) @@ -152,18 +115,6 @@ # #TRACEROUTE_NO_IPSEC= # do not build traceroute(8) with IPSEC support # -# Variables to control whether parts of the base BIND are built. -# Defining NO_BIND makes all of the following BIND variables obsolete. -# Please see the more detailed descriptions in make.conf(5). -#NO_BIND= # Do not build any part of BIND -#NO_BIND_DNSSEC= # Do not build dnssec-keygen, dnssec-signzone -#NO_BIND_ETC= # Do not install files to /etc/namedb -#NO_BIND_LIBS_LWRES= # Do not install the lwres library -#NO_BIND_MTREE= # Do not run mtree to create chroot directories -#NO_BIND_NAMED= # Do not build named, rndc, lwresd, etc. -#NO_BIND_UTILS= # Do not build dig, host, nslookup, nsupdate -#WITH_BIND_LIBS= # Install the BIND libs and include files -# # To build sys/modules when building the world (our old way of doing things) #MODULES_WITH_WORLD= # do not build modules when building kernel # @@ -173,17 +124,6 @@ # The list of modules to never build, applied *after* MODULES_OVERRIDE. #WITHOUT_MODULES= bktr plip # -# The following controls building optional IDEA code in libcrypto and -# certain ports. Patents are involved - you must not use this unless -# you either have a license or fall within patent 'fair use' -# provisions. -# -# *** It is YOUR RESPONSIBILITY to determine if you can use this! *** -# -# IDEA is patented in the USA and many European countries - thought to -# be OK to use for any non-commercial use. This is optional. -#MAKE_IDEA= # IDEA (128 bit symmetric encryption) -# # If you do not want unformatted manual pages to be compressed # when they are installed: # @@ -330,9 +270,3 @@ # /etc/mail/Makefile. Defaults to 0640. # #SENDMAIL_MAP_PERMS= -# -# wpa_supplicant -# -# Set this to disable building 802.1X and EAP support in wpa_supplicant. -# -#NO_WPA_SUPPLICANT_EAPOL=true Index: src/share/examples/ipfilter/Makefile diff -u src/share/examples/ipfilter/Makefile:1.5 src/share/examples/ipfilter/Makefile:1.8 --- src/share/examples/ipfilter/Makefile:1.5 Tue Dec 21 16:46:53 2004 +++ src/share/examples/ipfilter/Makefile Thu Mar 2 06:59:00 2006 @@ -1,11 +1,11 @@ # $FreeBSD$ -NO_OBJ= - FILES= README # dist sample files -.PATH: ${.CURDIR}/../../../contrib/ipfilter/rules +.PATH: ${.CURDIR}/../../../contrib/ipfilter/rules \ + ${.CURDIR}/../../../contrib/ipfilter \ + ${.CURDIR}/../../../contrib/ipfilter/man FILES+= BASIC.NAT BASIC_1.FW BASIC_2.FW \ example.1 example.2 example.3 example.4 example.5 \ example.6 example.7 example.8 example.9 example.10 \ @@ -23,6 +23,11 @@ # http://coombs.anu.edu.au/~avalon/ sample files FILES+= examples.txt rules.txt +BINMODE=0755 +SCRIPTS= mkfilters +MAN= mkfilters.1 + +SCRIPTSDIR= ${SHAREDIR}/examples/ipfilter FILESDIR= ${SHAREDIR}/examples/ipfilter .include Index: src/share/examples/ipfilter/ipf-howto.txt diff -u src/share/examples/ipfilter/ipf-howto.txt:1.2 src/share/examples/ipfilter/ipf-howto.txt:1.3 --- src/share/examples/ipfilter/ipf-howto.txt:1.2 Thu Jan 2 02:48:48 2003 +++ src/share/examples/ipfilter/ipf-howto.txt Thu Oct 27 01:39:35 2005 @@ -2564,7 +2564,7 @@ your firewall, thereby subverting its ruleset? This is a common problem administrators must face, particularly when they're using firewall solutions on top of their Unix/NT -machines. Some use it as an arguement for blackbox hardware +machines. Some use it as an argument for blackbox hardware solutions, under the flawed notion that inherent obscurity Index: src/share/examples/isdn/FAQ diff -u src/share/examples/isdn/FAQ:1.14 src/share/examples/isdn/FAQ:1.15 --- src/share/examples/isdn/FAQ:1.14 Thu Jan 2 02:48:48 2003 +++ src/share/examples/isdn/FAQ Fri Jul 6 15:21:55 2007 @@ -450,7 +450,7 @@ 8) add the flag value and function prototypes to layer1/i4b_l1.h 9) add support for NetBSD to layer1/isa_isic.c 10) add support for attach/probe to layer1/i4b_isic.c -11) add card type to machine/i4b_ioctl.h and update CARD_TYPEP_MAX +11) add card type to i4b/i4b_ioctl.h and update CARD_TYPEP_MAX 12) add an entry to the man page man/isic.4 Produce diffs (please use context diffs, flag "-c" for diff) and send them in. Index: src/share/examples/isdn/Overview diff -u src/share/examples/isdn/Overview:1.4 src/share/examples/isdn/Overview:1.5 --- src/share/examples/isdn/Overview:1.4 Thu Jan 2 02:48:48 2003 +++ src/share/examples/isdn/Overview Fri Jul 6 15:21:55 2007 @@ -252,7 +252,7 @@ (6) the device driver for /dev/i4bctl in conjunction with the userland program isdndebug(8) is used to set the debug level for each of the layers and several other parts of the system, information how to use - this is contained in machine/i4b_debug.h and all parts of the kernel + this is contained in i4b/i4b_debug.h and all parts of the kernel sources. It is only usable for passive cards. @@ -271,7 +271,7 @@ consisting of "messages" sent to userland and which are read(2) by the isdnd. The isdnd in turn sends "messages" to the kernel by using the ioctl(2) call. This protocol and the required messages for both - directions are documented in the machine/i4b_ioctl.h file and are + directions are documented in the i4b/i4b_ioctl.h file and are implemented in files i4b_i4bdrv.c and i4b_l4.c, the latter also containing much of the Layer 4 interface to the lower layers. Index: src/share/examples/isdn/contrib/hplay.c diff -u src/share/examples/isdn/contrib/hplay.c:1.1 src/share/examples/isdn/contrib/hplay.c:1.2 --- src/share/examples/isdn/contrib/hplay.c:1.1 Fri May 25 21:25:59 2001 +++ src/share/examples/isdn/contrib/hplay.c Fri Jul 6 15:21:56 2007 @@ -29,7 +29,7 @@ #include #include -#include +#include #include "proto.h" #include "getargs.h" Index: src/share/examples/isdn/contrib/isdntelmux.c diff -u src/share/examples/isdn/contrib/isdntelmux.c:1.1 src/share/examples/isdn/contrib/isdntelmux.c:1.2 --- src/share/examples/isdn/contrib/isdntelmux.c:1.1 Fri May 25 21:25:59 2001 +++ src/share/examples/isdn/contrib/isdntelmux.c Fri Jul 6 15:21:56 2007 @@ -47,7 +47,7 @@ #include #include #include -#include +#include // DECL DEFS #define BUFLEN 2048 Index: src/share/examples/isdn/i4brunppp/i4brunppp.c diff -u src/share/examples/isdn/i4brunppp/i4brunppp.c:1.3 src/share/examples/isdn/i4brunppp/i4brunppp.c:1.4 --- src/share/examples/isdn/i4brunppp/i4brunppp.c:1.3 Thu Jan 2 02:48:48 2003 +++ src/share/examples/isdn/i4brunppp/i4brunppp.c Fri Jul 6 15:21:56 2007 @@ -59,8 +59,8 @@ #include #include -#include -#include +#include +#include #define I4BDEVICE "/dev/i4b" Index: src/share/examples/isdn/v21/v21modem.c diff -u src/share/examples/isdn/v21/v21modem.c:1.2 src/share/examples/isdn/v21/v21modem.c:1.3 --- src/share/examples/isdn/v21/v21modem.c:1.2 Mon Jul 9 17:23:44 2001 +++ src/share/examples/isdn/v21/v21modem.c Fri Jul 6 15:21:56 2007 @@ -25,7 +25,7 @@ #include #include -#include +#include static void create_session(void); static void input_byte(int byte, int stopbit); Index: src/share/examples/kld/firmware/fwimage/firmware.img Index: src/share/examples/kld/syscall/module/syscall.c diff -u src/share/examples/kld/syscall/module/syscall.c:1.4 src/share/examples/kld/syscall/module/syscall.c:1.5 --- src/share/examples/kld/syscall/module/syscall.c:1.4 Mon Aug 30 17:49:59 2004 +++ src/share/examples/kld/syscall/module/syscall.c Sun Jul 22 14:48:34 2007 @@ -30,6 +30,7 @@ #include #include #include +#include #include #include #include Index: src/share/examples/kld/syscall/test/Makefile diff -u src/share/examples/kld/syscall/test/Makefile:1.3 src/share/examples/kld/syscall/test/Makefile:1.4 --- src/share/examples/kld/syscall/test/Makefile:1.3 Tue Dec 21 16:47:10 2004 +++ src/share/examples/kld/syscall/test/Makefile Wed Mar 15 18:40:01 2006 @@ -1,7 +1,7 @@ # Makefile for simple caller of syscall # $FreeBSD$ -PROG = call -NO_MAN = +PROG= call +NO_MAN= .include Index: src/share/examples/mdoc/example.4 diff -u src/share/examples/mdoc/example.4:1.21.2.2 src/share/examples/mdoc/example.4:1.27 --- src/share/examples/mdoc/example.4:1.21.2.2 Tue Jun 6 03:31:57 2006 +++ src/share/examples/mdoc/example.4 Thu Sep 28 05:28:44 2006 @@ -33,15 +33,19 @@ .Nm example .Nd "example device driver manual page" .Sh SYNOPSIS -To compile this driver into the kernel, -place the following lines in your +To compile the +.Ns Nm +driver into the kernel, +place the following lines in the kernel configuration file: .Bd -ragged -offset indent .Cd "device example" .Cd "options EXAMPLE_DEBUG" .Ed .Pp -Alternatively, to load the driver as a +Alternatively, to load the +.Ns Nm +driver as a module at boot time, place the following line in .Xr loader.conf 5 : .Bd -literal -offset indent Index: src/share/examples/mdoc/example.9 diff -u src/share/examples/mdoc/example.9:1.3 src/share/examples/mdoc/example.9:1.4 --- src/share/examples/mdoc/example.9:1.3 Sun Jan 16 00:01:19 2005 +++ src/share/examples/mdoc/example.9 Wed Sep 27 16:39:00 2006 @@ -26,7 +26,7 @@ .\" .\" Note: The date here should be updated whenever a non-trivial .\" change is made to the manual page. -.Dd January 12, 2005 +.Dd September 27, 2006 .Dt EXAMPLE 9 .Os .Sh NAME @@ -96,14 +96,14 @@ section is returned, to indicate the error. .Sh EXAMPLES .Bd -literal - int val; + int error; - mutex_lock(&example_lock); - if ((val = example(NULL, EXAMPLE_ONE)) != 0) { - mutex_unlock(&example_lock); - return (val); + mtx_lock(&example_lock); + if ((error = example(NULL, EXAMPLE_ONE)) != 0) { + mtx_unlock(&example_lock); + return (error); } - mutex_unlock(&example_lock); + mtx_unlock(&example_lock); .Ed .Sh COMPATIBILITY The @@ -298,7 +298,8 @@ .Xr example 1 , .Xr example 3 , .Xr example 4 , -.Xr mdoc 7 +.Xr mdoc 7 , +.Xr mutex 9 .Rs .%A "A. B. Author" .%T "Example RFC Title" Index: src/share/examples/netgraph/ether.bridge diff -u src/share/examples/netgraph/ether.bridge:1.4 src/share/examples/netgraph/ether.bridge:1.5 --- src/share/examples/netgraph/ether.bridge:1.4 Mon Apr 22 21:44:33 2002 +++ src/share/examples/netgraph/ether.bridge Sun Mar 5 23:53:07 2006 @@ -6,7 +6,7 @@ # # To use this script: # -# 0. Make your own copy of this example script +# 0. Make your own copy of this example script. # # 1. Give your bridging network a name by editing the definition of # ${BRIDGE_NAME} below. It must be a valid netgraph node name. @@ -27,11 +27,11 @@ # # To make a "brouted" network, with IP being routed and other protocols being # bridged, add all the interface in the BRIDGE_IFACES to the LOCAL_IFACES. -# I you just want a normal bridge, just one will surfice. -# in some cases you may want some mixture. -# +# If you just want a normal bridge, just one will be enough. +# In some cases you may want some combination. +# -# Give each bridging network a unique name here +# Give each bridging network a unique name here. BRIDGE_NAME="bnet0" @@ -40,16 +40,16 @@ # machine as well then set ${LOCAL_IFACES} as well (they may also be # listed in ${BRIDGE_IFACES}). Of course, any ${LOCAL_IFACE} must # be ifconfig(8)ured separately. If you don't want a ${LOCAL_IFACE} -# then leave it defined as the emtpy string. +# then assign it the emtpy string. BRIDGE_IFACES="de0 fxp0 fxp1" LOCAL_IFACES="fxp0 fxp1" -#################################################################### -#### Everything below this point should not need to be modified #### -#################################################################### +##################################################################### +#### Everything below this point should not need to be modified. #### +##################################################################### -# Routine to verify node's existence +# Routine to verify node's existence. bridge_verify() { ngctl info ${BRIDGE_NAME}: >/dev/null 2>&1 if [ $? -ne 0 ]; then @@ -58,7 +58,7 @@ fi } -# Routine to get and display link stats +# Routine to get and display link stats. bridge_linkstats() { STATS=`ngctl msg ${BRIDGE_NAME}: getstats $1` if [ $? -ne 0 ]; then @@ -68,38 +68,36 @@ printf "%20s = %s\n", substr($0, 0, fl - 1), substr($0, fl + 1); }' } -# Start/restart routine +# Start/restart routine. bridge_start() { - # Load netgraph KLD's as necessary + # Load netgraph KLD's as necessary. for KLD in ng_ether ng_bridge; do - if kldstat -v | grep -qw ${KLD}; then - else + if ! kldstat -v | grep -qw ${KLD}; then echo -n "Loading ${KLD}.ko... " kldload ${KLD} || exit 1 echo "done" fi done - # Reset all interfaces + # Reset all interfaces. bridge_stop - # Verify all interfaces exist + # Verify all interfaces exist. for ETHER in ${BRIDGE_IFACES} ${LOCAL_IFACES}; do - if ngctl info ${ETHER}: >/dev/null 2>&1; then - else + if ! ngctl info ${ETHER}: >/dev/null 2>&1; then echo "Error: interface ${ETHER} does not exist" exit 1 fi ifconfig ${ETHER} up || exit 1 done - # Create new ng_bridge(4) node, attached to the first interface + # Create new ng_bridge(4) node, attached to the first interface. FIRSTIF=`echo ${BRIDGE_IFACES} | awk '{ print $1 }'` ngctl mkpeer ${FIRSTIF}: bridge lower link0 || exit 1 ngctl name ${FIRSTIF}:lower ${BRIDGE_NAME} || exit 1 - # Attach other interfaces as well + # Attach other interfaces as well. LINKNUM=0 for ETHER in ${BRIDGE_IFACES}; do if [ ${LINKNUM} != 0 ]; then @@ -109,21 +107,21 @@ LINKNUM=`expr ${LINKNUM} + 1` done - # Hook up local interface, if any + # Hook up local interface, if any. for LOCAL_IFACE in ${LOCAL_IFACES}; do ngctl connect ${LOCAL_IFACE}: ${BRIDGE_NAME}: \ upper link${LINKNUM} || exit 1 LINKNUM=`expr ${LINKNUM} + 1` done - # Set all interfaces in promiscuous mode and don't overwrite src addr + # Set all interfaces in promiscuous mode and don't overwrite src addr. for ETHER in ${BRIDGE_IFACES}; do ngctl msg ${ETHER}: setpromisc 1 || exit 1 ngctl msg ${ETHER}: setautosrc 0 || exit 1 done } -# Stop routine +# Stop routine. bridge_stop() { ngctl kill ${BRIDGE_NAME}: >/dev/null 2>&1 for ETHER in ${BRIDGE_IFACES} ${LOCAL_IFACES}; do @@ -131,10 +129,10 @@ done } -# Stats routine +# Stats routine. bridge_stats() { - # Make sure node exists + # Make sure node exists. bridge_verify echo "" @@ -153,7 +151,7 @@ done } -# Main entry point +# Main entry point. case $1 in start) bridge_start @@ -167,7 +165,6 @@ bridge_stop ;; *) - echo "usage: ether.bridge [ start | stop | stats ]" + echo "usage: $0 [ start | stop | stats ]" exit 1 esac - Index: src/share/examples/pf/Makefile diff -u src/share/examples/pf/Makefile:1.3 src/share/examples/pf/Makefile:1.4 --- src/share/examples/pf/Makefile:1.3 Tue Dec 21 16:46:53 2004 +++ src/share/examples/pf/Makefile Sun Nov 11 09:16:51 2007 @@ -4,6 +4,7 @@ FILES= faq-example1 faq-example2 faq-example3 \ ackpri queue1 queue2 queue3 queue4 \ + pf.conf \ spamd FILESDIR= ${SHAREDIR}/examples/pf Index: src/share/examples/pf/ackpri diff -u src/share/examples/pf/ackpri:1.1 src/share/examples/pf/ackpri:1.2 --- src/share/examples/pf/ackpri:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/ackpri Sun Nov 11 09:16:51 2007 @@ -1,5 +1,5 @@ # $FreeBSD$ -# $OpenBSD: ackpri,v 1.2 2003/03/10 14:24:33 henning Exp $ +# $OpenBSD: ackpri,v 1.3 2006/10/07 04:48:01 mcbride Exp $ # Use a simple priority queue to prioritize empty (no payload) TCP ACKs, # which dramatically improves throughput on (asymmetric) links when the @@ -25,9 +25,7 @@ queue q_pri priority 7 queue q_def priority 1 priq(default) -pass out on $ext_if proto tcp from $ext_if to any flags S/SA \ - keep state queue (q_def, q_pri) +pass out on $ext_if proto tcp from $ext_if to any queue (q_def, q_pri) -pass in on $ext_if proto tcp from any to $ext_if flags S/SA \ - keep state queue (q_def, q_pri) +pass in on $ext_if proto tcp from any to $ext_if queue (q_def, q_pri) Index: src/share/examples/pf/faq-example1 diff -u src/share/examples/pf/faq-example1:1.1 src/share/examples/pf/faq-example1:1.2 --- src/share/examples/pf/faq-example1:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/faq-example1 Sun Nov 11 09:16:51 2007 @@ -1,5 +1,5 @@ # $FreeBSD$ -# $OpenBSD: faq-example1,v 1.2 2003/08/06 16:04:45 henning Exp $ +# $OpenBSD: faq-example1,v 1.5 2006/10/07 04:48:01 mcbride Exp $ # # Firewall for Home or Small Office @@ -8,41 +8,44 @@ # macros -int_if = "fxp0" -ext_if = "ep0" +ext_if="fxp0" +int_if="xl0" -tcp_services = "{ 22, 113 }" -icmp_types = "echoreq" +tcp_services="{ 22, 113 }" +icmp_types="echoreq" + +comp3="192.168.0.3" -priv_nets = "{ 127.0.0.0/8, 192.168.0.0/16, 172.16.0.0/12, 10.0.0.0/8 }" - # options set block-policy return set loginterface $ext_if +set skip on lo + # scrub -scrub in all +scrub in # nat/rdr -nat on $ext_if from $int_if:network to any -> ($ext_if) -rdr on $int_if proto tcp from any to any port 21 -> 127.0.0.1 \ - port 8021 +nat on $ext_if from !($ext_if) -> ($ext_if:0) +nat-anchor "ftp-proxy/*" +rdr-anchor "ftp-proxy/*" + +rdr pass on $int_if proto tcp to port ftp -> 127.0.0.1 port 8021 +rdr on $ext_if proto tcp from any to any port 80 -> $comp3 # filter rules -block all +block in -pass quick on lo0 all +pass out -block drop in quick on $ext_if from $priv_nets to any -block drop out quick on $ext_if from any to $priv_nets +anchor "ftp-proxy/*" +antispoof quick for { lo $int_if } -pass in on $ext_if inet proto tcp from any to ($ext_if) \ - port $tcp_services flags S/SA keep state +pass in on $ext_if inet proto tcp from any to ($ext_if) port $tcp_services -pass in inet proto icmp all icmp-type $icmp_types keep state +pass in on $ext_if inet proto tcp from any to $comp3 port 80 \ + synproxy state -pass in on $int_if from $int_if:network to any keep state -pass out on $int_if from any to $int_if:network keep state +pass in inet proto icmp all icmp-type $icmp_types -pass out on $ext_if proto tcp all modulate state flags S/SA -pass out on $ext_if proto { udp, icmp } all keep state +pass quick on $int_if no state Index: src/share/examples/pf/faq-example2 diff -u src/share/examples/pf/faq-example2:1.1 src/share/examples/pf/faq-example2:1.2 --- src/share/examples/pf/faq-example2:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/faq-example2 Sun Nov 11 09:16:51 2007 @@ -1,5 +1,5 @@ # $FreeBSD$ -# $OpenBSD: faq-example2,v 1.2 2003/08/06 16:04:45 henning Exp $ +# $OpenBSD: faq-example2,v 1.4 2006/10/07 04:48:01 mcbride Exp $ # # Small, Home Network @@ -43,9 +43,9 @@ # bob_in - bandwidth reserved for Bob's workstation. allow him to # borrow. -queue std_in cbq(default) -queue ssh_im_in priority 4 -queue dns_in priority 5 +queue std_in bandwidth 1.6Mb cbq(default) +queue ssh_im_in bandwidth 200Kb priority 4 +queue dns_in bandwidth 120Kb priority 5 queue bob_in bandwidth 80Kb cbq(borrow) @@ -63,15 +63,15 @@ # filter rules for fxp0 outbound block out on fxp0 all -pass out on fxp0 inet proto tcp from (fxp0) to any flags S/SA \ - keep state queue(std_out, tcp_ack_out) -pass out on fxp0 inet proto { udp icmp } from (fxp0) to any keep state +pass out on fxp0 inet proto tcp from (fxp0) to any \ + queue(std_out, tcp_ack_out) +pass out on fxp0 inet proto { udp icmp } from (fxp0) to any pass out on fxp0 inet proto { tcp udp } from (fxp0) to any port domain \ - keep state queue dns_out + queue dns_out pass out on fxp0 inet proto tcp from (fxp0) to any port $ssh_ports \ - flags S/SA keep state queue(std_out, ssh_im_out) + queue(std_out, ssh_im_out) pass out on fxp0 inet proto tcp from (fxp0) to any port $im_ports \ - flags S/SA keep state queue(ssh_im_out, tcp_ack_out) + queue(ssh_im_out, tcp_ack_out) # filter rules for dc0 inbound block in on dc0 all Index: src/share/examples/pf/faq-example3 diff -u src/share/examples/pf/faq-example3:1.1 src/share/examples/pf/faq-example3:1.2 --- src/share/examples/pf/faq-example3:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/faq-example3 Sun Nov 11 09:16:51 2007 @@ -1,12 +1,12 @@ # $FreeBSD$ -# $OpenBSD: faq-example3,v 1.2 2003/08/06 16:04:45 henning Exp $ +# $OpenBSD: faq-example3,v 1.4 2006/10/07 04:48:01 mcbride Exp $ # # Company Network # http://www.openbsd.org/faq/pf/queueing.html#example2 # - + # enable queueing on the external interface to queue packets going out # to the Internet. use the cbq scheduler so that the bandwidth use of # each queue can be controlled. the max outgoing bandwidth is 1.5Mbps. @@ -18,15 +18,15 @@ # outgoing traffic on fxp0. # www_ext - container queue for WWW server queues. limit to # 500Kbps. -# www_ext_http - http traffic from the WWW server -# www_ext_misc - all non-http traffic from the WWW server -# boss_ext - traffic coming from the boss's computer +# www_ext_http - http traffic from the WWW server; higher priority. +# www_ext_misc - all non-http traffic from the WWW server. +# boss_ext - traffic coming from the boss's computer. -queue std_ext cbq(default) +queue std_ext bandwidth 500Kb cbq(default borrow) queue www_ext bandwidth 500Kb { www_ext_http, www_ext_misc } - queue www_ext_http priority 3 cbq(red) - queue www_ext_misc priority 1 -queue boss_ext priority 3 + queue www_ext_http bandwidth 50% priority 3 cbq(red borrow) + queue www_ext_misc bandwidth 50% priority 1 cbq(borrow) +queue boss_ext bandwidth 500Kb priority 3 cbq(borrow) # enable queueing on the internal interface to control traffic coming # from the Internet or the DMZ. use the cbq scheduler to control the @@ -42,15 +42,15 @@ # is 1.0Mbps. # std_int - the standard queue. also the default queue for outgoing # traffic on dc0. -# it_int - traffic to the IT Dept network. -# boss_int - traffic to the boss's PC. -# www_int - traffic from the WWW server in the DMZ. +# it_int - traffic to the IT Dept network; reserve them 500Kbps. +# boss_int - traffic to the boss's PC; assign a higher priority. +# www_int - traffic from the WWW server in the DMZ; full speed. queue net_int bandwidth 1.0Mb { std_int, it_int, boss_int } - queue std_int cbq(default) + queue std_int bandwidth 250Kb cbq(default borrow) queue it_int bandwidth 500Kb cbq(borrow) - queue boss_int priority 3 -queue www_int cbq(red) + queue boss_int bandwidth 250Kb priority 3 cbq(borrow) +queue www_int bandwidth 99Mb cbq(red borrow) # enable queueing on the DMZ interface to control traffic destined for # the WWW server. cbq will be used on this interface since detailed @@ -64,13 +64,13 @@ # define the parameters for the child queues. # internal_dmz - traffic from the internal network. # net_dmz - container queue for traffic from the Internet. -# net_dmz_http - http traffic. +# net_dmz_http - http traffic; higher priority. # net_dmz_misc - all non-http traffic. this is also the default queue. -queue internal_dmz # no special settings needed +queue internal_dmz bandwidth 99Mb cbq(borrow) queue net_dmz bandwidth 500Kb { net_dmz_http, net_dmz_misc } - queue net_dmz_http priority 3 cbq(red) - queue net_dmz_misc priority 1 cbq(default) + queue net_dmz_http bandwidth 50% priority 3 cbq(red borrow) + queue net_dmz_misc bandwidth 50% priority 1 cbq(default borrow) # ... in the filtering section of pf.conf ... @@ -88,32 +88,30 @@ # filter rules for fxp0 inbound pass in on fxp0 proto tcp from any to $wwwserv port { 21, \ - > 49151 } flags S/SA keep state queue www_ext_misc + > 49151 } queue www_ext_misc pass in on fxp0 proto tcp from any to $wwwserv port 80 \ - flags S/SA keep state queue www_ext_http + queue www_ext_http # filter rules for fxp0 outbound -pass out on fxp0 from $int_nets to any keep state -pass out on fxp0 from $boss to any keep state queue boss_ext +pass out on fxp0 from $int_nets to any +pass out on fxp0 from $boss to any queue boss_ext # filter rules for dc0 inbound -pass in on dc0 from $int_nets to any keep state +pass in on dc0 from $int_nets to any pass in on dc0 from $it_net to any queue it_int pass in on dc0 from $boss to any queue boss_int pass in on dc0 proto tcp from $int_nets to $wwwserv port { 21, 80, \ - > 49151 } flags S/SA keep state queue www_int + > 49151 } queue www_int # filter rules for dc0 outbound pass out on dc0 from dc0 to $int_nets # filter rules for fxp1 inbound -pass in on fxp1 proto { tcp, udp } from $wwwserv to any port 53 \ - keep state +pass in on fxp1 proto { tcp, udp } from $wwwserv to any port 53 # filter rules for fxp1 outbound pass out on fxp1 proto tcp from any to $wwwserv port { 21, \ - > 49151 } flags S/SA keep state queue net_dmz_misc -pass out on fxp1 proto tcp from any to $wwwserv port 80 \ - flags S/SA keep state queue net_dmz_http + > 49151 } queue net_dmz_misc +pass out on fxp1 proto tcp from any to $wwwserv port 80 queue net_dmz_http pass out on fxp1 proto tcp from $int_nets to $wwwserv port { 80, \ - 21, > 49151 } flags S/SA keep state queue internal_dmz + 21, > 49151 } queue internal_dmz Index: src/share/examples/pf/pf.conf diff -u /dev/null src/share/examples/pf/pf.conf:1.1 --- /dev/null Thu Jan 17 11:57:37 2008 +++ src/share/examples/pf/pf.conf Sun Nov 11 09:16:51 2007 @@ -0,0 +1,34 @@ +# $FreeBSD$ +# $OpenBSD: pf.conf,v 1.34 2007/02/24 19:30:59 millert Exp $ +# +# See pf.conf(5) and /usr/share/examples/pf for syntax and examples. +# Remember to set net.inet.ip.forwarding=1 and/or net.inet6.ip6.forwarding=1 +# in /etc/sysctl.conf if packets are to be forwarded between interfaces. + +#ext_if="ext0" +#int_if="int0" + +#table persist + +#set skip on lo + +#scrub in + +#nat-anchor "ftp-proxy/*" +#rdr-anchor "ftp-proxy/*" +#nat on $ext_if from !($ext_if) -> ($ext_if:0) +#rdr pass on $int_if proto tcp to port ftp -> 127.0.0.1 port 8021 +#no rdr on $ext_if proto tcp from to any port smtp +#rdr pass on $ext_if proto tcp from any to any port smtp \ +# -> 127.0.0.1 port spamd + +#anchor "ftp-proxy/*" +#block in +#pass out + +#pass quick on $int_if no state +#antispoof quick for { lo $int_if } + +#pass in on $ext_if proto tcp to ($ext_if) port ssh +#pass in log on $ext_if proto tcp to ($ext_if) port smtp +#pass out log on $ext_if proto tcp from ($ext_if) to port smtp Index: src/share/examples/pf/queue1 diff -u src/share/examples/pf/queue1:1.1 src/share/examples/pf/queue1:1.2 --- src/share/examples/pf/queue1:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/queue1 Sun Nov 11 09:16:51 2007 @@ -1,5 +1,5 @@ # $FreeBSD$ -# $OpenBSD: queue1,v 1.3 2003/01/20 16:14:23 henning Exp $ +# $OpenBSD: queue1,v 1.4 2006/10/07 04:48:01 mcbride Exp $ ext_if = "dc0" @@ -14,10 +14,8 @@ queue rsets bandwidth 7500b priority 0 cbq(red) block return in on $ext_if inet all queue rsets -pass in on $ext_if inet proto tcp from any to any port 80 keep state queue http -pass out on $ext_if inet proto tcp from any to any port 22 keep state queue ssh -pass in on $ext_if inet proto tcp from any to any port 22 keep state queue ssh -pass out on $ext_if inet proto tcp from any to any port 25 keep state queue mail -pass out on $ext_if inet all keep state - - +pass in on $ext_if inet proto tcp from any to any port 80 queue http +pass out on $ext_if inet proto tcp from any to any port 22 queue ssh +pass in on $ext_if inet proto tcp from any to any port 22 queue ssh +pass out on $ext_if inet proto tcp from any to any port 25 queue mail +pass out on $ext_if inet all Index: src/share/examples/pf/queue2 diff -u src/share/examples/pf/queue2:1.1 src/share/examples/pf/queue2:1.2 --- src/share/examples/pf/queue2:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/queue2 Sun Nov 11 09:16:51 2007 @@ -1,5 +1,5 @@ # $FreeBSD$ -# $OpenBSD: queue2,v 1.2 2003/01/20 16:14:23 henning Exp $ +# $OpenBSD: queue2,v 1.4 2006/10/07 04:48:01 mcbride Exp $ # advanced queue example. # give interactive ssh traffic priority over ssh bulk transfers (scp, sftp) @@ -15,15 +15,15 @@ queue employees bandwidth 15% queue mail bandwidth 10% priority 0 cbq(borrow ecn) queue ssh bandwidth 20% cbq(borrow) { ssh_interactive, ssh_bulk } -queue ssh_interactive priority 7 -queue ssh_bulk priority 0 +queue ssh_interactive bandwidth 25% priority 7 +queue ssh_bulk bandwidth 75% priority 0 block return out on $ext_if inet all queue std pass out on $ext_if inet proto tcp from $developerhosts to any port 80 \ - keep state queue developers + queue developers pass out on $ext_if inet proto tcp from $employeehosts to any port 80 \ - keep state queue employees + queue employees pass out on $ext_if inet proto tcp from any to any port 22 \ - keep state queue(ssh_bulk, ssh_interactive) + queue(ssh_bulk, ssh_interactive) pass out on $ext_if inet proto tcp from any to any port 25 \ - keep state queue mail + queue mail Index: src/share/examples/pf/queue3 diff -u src/share/examples/pf/queue3:1.1 src/share/examples/pf/queue3:1.2 --- src/share/examples/pf/queue3:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/queue3 Sun Nov 11 09:16:51 2007 @@ -1,5 +1,5 @@ # $FreeBSD$ -# $OpenBSD: queue3,v 1.2 2003/01/20 16:14:23 henning Exp $ +# $OpenBSD: queue3,v 1.3 2006/10/07 04:48:01 mcbride Exp $ # simple PRIQ example ext_if="lo0" @@ -9,8 +9,8 @@ queue pri-med priority 1 priq(default) queue pri-high priority 2 -pass out on $ext_if proto tcp from any to any port 22 keep state \ +pass out on $ext_if proto tcp from any to any port 22 \ queue(pri-med, pri-high) -pass out on $ext_if proto tcp from any to any port 80 keep state queue pri-med -pass in on $ext_if proto tcp from any to any port 80 keep state queue pri-low +pass out on $ext_if proto tcp from any to any port 80 queue pri-med +pass in on $ext_if proto tcp from any to any port 80 queue pri-low Index: src/share/examples/pf/spamd diff -u src/share/examples/pf/spamd:1.1 src/share/examples/pf/spamd:1.2 --- src/share/examples/pf/spamd:1.1 Tue Sep 14 09:07:18 2004 +++ src/share/examples/pf/spamd Sun Nov 11 09:16:51 2007 @@ -1,8 +1,8 @@ # $FreeBSD$ -# $OpenBSD: spamd,v 1.1 2003/08/22 15:25:01 henning Exp $ +# $OpenBSD: spamd,v 1.2 2005/08/06 19:52:37 jmc Exp $ # spamd-setup puts addresses to be redirected into table . table persist no rdr on { lo0, lo1 } from any to any -rdr inet proto tcp from to any port smtp -> 127.0.0.1 port 8025 +rdr inet proto tcp from to any port smtp -> 127.0.0.1 port spamd Index: src/share/examples/scsi_target/scsi_cmds.c diff -u src/share/examples/scsi_target/scsi_cmds.c:1.6.8.1 src/share/examples/scsi_target/scsi_cmds.c:1.10 --- src/share/examples/scsi_target/scsi_cmds.c:1.6.8.1 Sun Nov 5 03:02:18 2006 +++ src/share/examples/scsi_target/scsi_cmds.c Wed Sep 27 23:38:13 2006 @@ -35,6 +35,7 @@ #include #include #include +#include #include #include #include @@ -48,6 +49,9 @@ typedef int targ_start_func(struct ccb_accept_tio *, struct ccb_scsiio *); typedef void targ_done_func(struct ccb_accept_tio *, struct ccb_scsiio *, io_ops); +#ifndef REPORT_LUNS +#define REPORT_LUNS 0xa0 +#endif struct targ_cdb_handlers { u_int8_t cmd; @@ -87,7 +91,7 @@ { SYNCHRONIZE_CACHE, tcmd_null_ok, NULL }, { MODE_SENSE_6, tcmd_illegal_req, NULL }, { MODE_SELECT_6, tcmd_illegal_req, NULL }, - /* XXX REPORT_LUNS should be handled here. */ + { REPORT_LUNS, tcmd_illegal_req, NULL }, #ifdef READ_16 { READ_16, tcmd_rdwr, tcmd_rdwr_done }, { WRITE_16, tcmd_rdwr, tcmd_rdwr_done }, @@ -152,6 +156,16 @@ } last_cmd = h; } + + /* call completion and exit */ + if (event != ATIO_WORK) { + if (last_cmd->done != NULL) + last_cmd->done(atio, ctio, event); + else + free_ccb((union ccb *)ctio); + return (1); + } + if (last_cmd->cmd == ILLEGAL_CDB) { if (event != ATIO_WORK) { warnx("no done func for %#x???", a_descr->cdb[0]); @@ -164,15 +178,6 @@ return (0); } - /* call completion and exit */ - if (event != ATIO_WORK) { - if (last_cmd->done != NULL) - last_cmd->done(atio, ctio, event); - else - free_ccb((union ccb *)ctio); - return (1); - } - istate = tcmd_get_istate(ctio->init_id); if (istate == NULL) { tcmd_illegal_req(atio, ctio); @@ -492,21 +497,13 @@ if ((a_descr->flags & CAM_DIR_IN) != 0) { ret = start_io(atio, ctio, CAM_DIR_IN); if (debug) -#if __FreeBSD_version >= 500000 - warnx("Starting DIR_IN @%jd:%u", -#else - warnx("Starting DIR_IN @%lld:%u", -#endif - c_descr->offset, a_descr->targ_req); + warnx("Starting %p DIR_IN @" OFF_FMT ":%u", + a_descr, c_descr->offset, a_descr->targ_req); } else { ret = start_io(atio, ctio, CAM_DIR_OUT); if (debug) -#if __FreeBSD_version >= 500000 - warnx("Starting DIR_OUT @%jd:%u", -#else - warnx("Starting DIR_OUT @%lld:%u", -#endif - c_descr->offset, a_descr->init_req); + warnx("Starting %p DIR_OUT @" OFF_FMT ":%u", + a_descr, c_descr->offset, a_descr->init_req); } return (ret); @@ -568,29 +565,17 @@ a_descr->total_len = count * sector_size; if (a_descr->total_len == 0) { if (debug) -#if __FreeBSD_version >= 500000 - warnx("r/w 0 blocks @ blkno %ju", blkno); -#else - warnx("r/w 0 blocks @ blkno %llu", blkno); -#endif + warnx("r/w 0 blocks @ blkno " OFF_FMT, blkno); tcmd_null_ok(atio, ctio); return (0); } else if (cdb[0] == WRITE_6 || cdb[0] == WRITE_10) { a_descr->flags |= CAM_DIR_OUT; if (debug) -#if __FreeBSD_version >= 500000 - warnx("write %u blocks @ blkno %ju", count, blkno); -#else - warnx("write %u blocks @ blkno %llu", count, blkno); -#endif + warnx("write %u blocks @ blkno " OFF_FMT, count, blkno); } else { a_descr->flags |= CAM_DIR_IN; if (debug) -#if __FreeBSD_version >= 500000 - warnx("read %u blocks @ blkno %ju", count, blkno); -#else - warnx("read %u blocks @ blkno %llu", count, blkno); -#endif + warnx("read %u blocks @ blkno " OFF_FMT, count, blkno); } return (1); } @@ -622,14 +607,41 @@ /* If DIR_IN, start read from target, otherwise begin CTIO xfer. */ ret = 1; if (dir == CAM_DIR_IN) { - if (aio_read(&c_descr->aiocb) < 0) - err(1, "aio_read"); /* XXX */ + if (notaio) { + if (debug) + warnx("read sync %lud @ block " OFF_FMT, + (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (lseek(c_descr->aiocb.aio_fildes, + c_descr->aiocb.aio_offset, SEEK_SET) < 0) { + perror("lseek"); + err(1, "lseek"); + } + if (read(c_descr->aiocb.aio_fildes, + (void *)c_descr->aiocb.aio_buf, + ctio->dxfer_len) != ctio->dxfer_len) { + err(1, "read"); + } + } else { + if (debug) + warnx("read async %lud @ block " OFF_FMT, + (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (aio_read(&c_descr->aiocb) < 0) { + err(1, "aio_read"); /* XXX */ + } + } a_descr->targ_req += ctio->dxfer_len; + /* if we're done, we can mark the CCB as to send status */ if (a_descr->targ_req == a_descr->total_len) { ctio->ccb_h.flags |= CAM_SEND_STATUS; ctio->scsi_status = SCSI_STATUS_OK; ret = 0; } + if (notaio) + tcmd_rdwr_done(atio, ctio, AIO_DONE); } else { if (a_descr->targ_ack == a_descr->total_len) tcmd_null_ok(atio, ctio); @@ -661,7 +673,7 @@ switch (event) { case AIO_DONE: - if (aio_return(&c_descr->aiocb) < 0) { + if (!notaio && aio_return(&c_descr->aiocb) < 0) { warn("aio_return error"); /* XXX */ tcmd_sense(ctio->init_id, ctio, @@ -671,8 +683,12 @@ } a_descr->targ_ack += ctio->dxfer_len; if ((a_descr->flags & CAM_DIR_IN) != 0) { - if (debug) - warnx("sending CTIO for AIO read"); + if (debug) { + if (notaio) + warnx("sending CTIO for AIO read"); + else + warnx("sending CTIO for sync read"); + } a_descr->init_req += ctio->dxfer_len; send_ccb((union ccb *)ctio, /*priority*/1); } else { @@ -685,18 +701,55 @@ } break; case CTIO_DONE: - if (ctio->ccb_h.status != CAM_REQ_CMP) { - /* XXX */ + switch (ctio->ccb_h.status & CAM_STATUS_MASK) { + case CAM_REQ_CMP: + break; + case CAM_REQUEUE_REQ: + warnx("requeueing request"); + if ((a_descr->flags & CAM_DIR_MASK) == CAM_DIR_OUT) { + if (aio_write(&c_descr->aiocb) < 0) { + err(1, "aio_write"); /* XXX */ + } + } else { + if (aio_read(&c_descr->aiocb) < 0) { + err(1, "aio_read"); /* XXX */ + } + } + return; + default: errx(1, "CTIO failed, status %#x", ctio->ccb_h.status); } a_descr->init_ack += ctio->dxfer_len; if ((a_descr->flags & CAM_DIR_MASK) == CAM_DIR_OUT && ctio->dxfer_len > 0) { - if (debug) - warnx("sending AIO for CTIO write"); a_descr->targ_req += ctio->dxfer_len; - if (aio_write(&c_descr->aiocb) < 0) - err(1, "aio_write"); /* XXX */ + if (notaio) { + if (debug) + warnx("write sync %lud @ block " + OFF_FMT, (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (lseek(c_descr->aiocb.aio_fildes, + c_descr->aiocb.aio_offset, SEEK_SET) < 0) { + perror("lseek"); + err(1, "lseek"); + } + if (write(c_descr->aiocb.aio_fildes, + (void *) c_descr->aiocb.aio_buf, + ctio->dxfer_len) != ctio->dxfer_len) { + err(1, "write"); + } + tcmd_rdwr_done(atio, ctio, AIO_DONE); + } else { + if (debug) + warnx("write async %lud @ block " + OFF_FMT, (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (aio_write(&c_descr->aiocb) < 0) { + err(1, "aio_write"); /* XXX */ + } + } } else { if (debug) warnx("CTIO done freeing CTIO"); Index: src/share/examples/scsi_target/scsi_target.c diff -u src/share/examples/scsi_target/scsi_target.c:1.16 src/share/examples/scsi_target/scsi_target.c:1.18 --- src/share/examples/scsi_target/scsi_target.c:1.16 Sat Oct 18 12:54:08 2003 +++ src/share/examples/scsi_target/scsi_target.c Wed Sep 27 23:38:13 2006 @@ -56,12 +56,13 @@ /* Maximum amount to transfer per CTIO */ #define MAX_XFER MAXPHYS /* Maximum number of allocated CTIOs */ -#define MAX_CTIOS 32 +#define MAX_CTIOS 64 /* Maximum sector size for emulated volume */ #define MAX_SECTOR 32768 /* Global variables */ int debug; +int notaio = 0; off_t volume_size; u_int sector_size; size_t buf_size; @@ -86,7 +87,7 @@ static void handle_read(void); /* static int work_atio(struct ccb_accept_tio *); */ static void queue_io(struct ccb_scsiio *); -static void run_queue(struct ccb_accept_tio *); +static int run_queue(struct ccb_accept_tio *); static int work_inot(struct ccb_immed_notify *); static struct ccb_scsiio * get_ctio(void); @@ -117,7 +118,7 @@ TAILQ_INIT(&pending_queue); TAILQ_INIT(&work_queue); - while ((ch = getopt(argc, argv, "AdSTb:c:s:W:")) != -1) { + while ((ch = getopt(argc, argv, "AdSTYb:c:s:W:")) != -1) { switch(ch) { case 'A': req_flags |= SID_Addr16; @@ -193,6 +194,9 @@ /* NOTREACHED */ } break; + case 'Y': + notaio = 1; + break; default: usage(); /* NOTREACHED */ @@ -246,20 +250,16 @@ volume_size = user_size / sector_size; } if (debug) -#if __FreeBSD_version >= 500000 - warnx("volume_size: %d bytes x %jd sectors", -#else - warnx("volume_size: %d bytes x %lld sectors", -#endif + warnx("volume_size: %d bytes x " OFF_FMT " sectors", sector_size, volume_size); if (volume_size <= 0) errx(1, "volume must be larger than %d", sector_size); - { + if (notaio == 0) { struct aiocb aio, *aiop; - /* Make sure we have working AIO support */ + /* See if we have we have working AIO support */ memset(&aio, 0, sizeof(aio)); aio.aio_buf = malloc(sector_size); if (aio.aio_buf == NULL) @@ -269,16 +269,17 @@ aio.aio_nbytes = sector_size; signal(SIGSYS, SIG_IGN); if (aio_read(&aio) != 0) { - printf("You must enable VFS_AIO in your kernel " - "or load the aio(4) module.\n"); - err(1, "aio_read"); - } - if (aio_waitcomplete(&aiop, NULL) != sector_size) - err(1, "aio_waitcomplete"); - assert(aiop == &aio); - signal(SIGSYS, SIG_DFL); + printf("AIO support is not available- switchin to" + " single-threaded mode.\n"); + notaio = 1; + } else { + if (aio_waitcomplete(&aiop, NULL) != sector_size) + err(1, "aio_waitcomplete"); + assert(aiop == &aio); + signal(SIGSYS, SIG_DFL); + } free((void *)aio.aio_buf); - if (debug) + if (debug && notaio == 0) warnx("aio support tested ok"); } @@ -311,7 +312,7 @@ /* Enable debugging if requested */ if (debug) { if (ioctl(targ_fd, TARGIOCDEBUG, &debug) != 0) - err(1, "TARGIOCDEBUG"); + warnx("TARGIOCDEBUG"); } /* Set up inquiry data according to what SIM supports */ @@ -421,7 +422,7 @@ /* Loop until user signal */ while (quit == 0) { - int retval, i; + int retval, i, oo; struct ccb_hdr *ccb_h; /* Check for the next signal, read ready, or AIO completion */ @@ -440,7 +441,7 @@ } /* Process all received events. */ - for (i = 0; i < retval; i++) { + for (oo = i = 0; i < retval; i++) { if ((events[i].flags & EV_ERROR) != 0) errx(1, "kevent registration failed"); @@ -464,7 +465,7 @@ /* Queue on the appropriate ATIO */ queue_io(ctio); /* Process any queued completions. */ - run_queue(c_descr->atio); + oo += run_queue(c_descr->atio); break; } case EVFILT_SIGNAL: @@ -473,12 +474,17 @@ quit = 1; break; default: - warnx("unknown event %#x", events[i].filter); + warnx("unknown event %d", events[i].filter); break; } if (debug) - warnx("event done"); + warnx("event %d done", events[i].filter); + } + + if (oo) { + tptr = &ts; + continue; } /* Grab the first CCB and perform one work unit. */ @@ -534,7 +540,7 @@ handle_read() { union ccb *ccb_array[MAX_INITIATORS], *ccb; - int ccb_count, i; + int ccb_count, i, oo; ccb_count = read(targ_fd, ccb_array, sizeof(ccb_array)); if (ccb_count <= 0) { @@ -586,7 +592,7 @@ /* Queue on the appropriate ATIO */ queue_io(ctio); /* Process any queued completions. */ - run_queue(c_descr->atio); + oo += run_queue(c_descr->atio); break; } case XPT_IMMED_NOTIFY: @@ -619,8 +625,9 @@ /* Get a CTIO and initialize it according to our known parameters */ ctio = get_ctio(); - if (ctio == NULL) + if (ctio == NULL) { return (1); + } ret = 0; ctio->ccb_h.flags = a_descr->flags; ctio->tag_id = atio->tag_id; @@ -659,6 +666,7 @@ ret = tcmd_handle(atio, ctio, ATIO_WORK); break; case CAM_REQ_ABORTED: + warn("ATIO %p aborted", a_descr); /* Requeue on HBA */ TAILQ_REMOVE(&work_queue, &atio->ccb_h, periph_links.tqe); send_ccb((union ccb *)atio, /*priority*/1); @@ -679,35 +687,29 @@ { struct ccb_hdr *ccb_h; struct io_queue *ioq; - struct ctio_descr *c_descr, *curr_descr; + struct ctio_descr *c_descr; c_descr = (struct ctio_descr *)ctio->ccb_h.targ_descr; - /* If the completion is for a specific ATIO, queue in order */ - if (c_descr->atio != NULL) { - struct atio_descr *a_descr; - - a_descr = (struct atio_descr *)c_descr->atio->ccb_h.targ_descr; - ioq = &a_descr->cmplt_io; - } else { + if (c_descr->atio == NULL) { errx(1, "CTIO %p has NULL ATIO", ctio); } + ioq = &((struct atio_descr *)c_descr->atio->ccb_h.targ_descr)->cmplt_io; - /* Insert in order, sorted by offset */ - if (!TAILQ_EMPTY(ioq)) { - TAILQ_FOREACH_REVERSE(ccb_h, ioq, io_queue, periph_links.tqe) { - curr_descr = (struct ctio_descr *)ccb_h->targ_descr; - if (curr_descr->offset <= c_descr->offset) { - TAILQ_INSERT_AFTER(ioq, ccb_h, &ctio->ccb_h, - periph_links.tqe); - break; - } - if (TAILQ_PREV(ccb_h, io_queue, periph_links.tqe) - == NULL) { - TAILQ_INSERT_BEFORE(ccb_h, &ctio->ccb_h, - periph_links.tqe); - break; - } + if (TAILQ_EMPTY(ioq)) { + TAILQ_INSERT_HEAD(ioq, &ctio->ccb_h, periph_links.tqe); + return; + } + + TAILQ_FOREACH_REVERSE(ccb_h, ioq, io_queue, periph_links.tqe) { + struct ctio_descr *curr_descr = + (struct ctio_descr *)ccb_h->targ_descr; + if (curr_descr->offset <= c_descr->offset) { + break; } + } + + if (ccb_h) { + TAILQ_INSERT_AFTER(ioq, ccb_h, &ctio->ccb_h, periph_links.tqe); } else { TAILQ_INSERT_HEAD(ioq, &ctio->ccb_h, periph_links.tqe); } @@ -717,7 +719,7 @@ * Go through all completed AIO/CTIOs for a given ATIO and advance data * counts, start continuation IO, etc. */ -static void +static int run_queue(struct ccb_accept_tio *atio) { struct atio_descr *a_descr; @@ -725,7 +727,7 @@ int sent_status, event; if (atio == NULL) - return; + return (0); a_descr = (struct atio_descr *)atio->ccb_h.targ_descr; @@ -761,11 +763,14 @@ send_ccb((union ccb *)atio, /*priority*/1); } else { /* Gap in offsets so wait until later callback */ - if (debug) - warnx("IO %p out of order", ccb_h); - break; + if (/* debug */ 1) + warnx("IO %p:%p out of order %s", ccb_h, + a_descr, c_descr->event == AIO_DONE? + "aio" : "ctio"); + return (1); } } + return (0); } static int @@ -856,8 +861,10 @@ struct ctio_descr *c_descr; struct sigevent *se; - if (num_ctios == MAX_CTIOS) + if (num_ctios == MAX_CTIOS) { + warnx("at CTIO max"); return (NULL); + } ctio = (struct ccb_scsiio *)malloc(sizeof(*ctio)); if (ctio == NULL) { @@ -890,7 +897,7 @@ se = &c_descr->aiocb.aio_sigevent; se->sigev_notify = SIGEV_KEVENT; se->sigev_notify_kqueue = kq_fd; - se->sigev_value.sigval_ptr = ctio; + se->sigev_value.sival_ptr = ctio; return (ctio); } @@ -987,7 +994,7 @@ usage() { fprintf(stderr, - "Usage: scsi_target [-AdST] [-b bufsize] [-c sectorsize]\n" + "Usage: scsi_target [-AdSTY] [-b bufsize] [-c sectorsize]\n" "\t\t[-r numbufs] [-s volsize] [-W 8,16,32]\n" "\t\tbus:target:lun filename\n"); exit(1); Index: src/share/examples/scsi_target/scsi_target.h diff -u src/share/examples/scsi_target/scsi_target.h:1.3 src/share/examples/scsi_target/scsi_target.h:1.4 --- src/share/examples/scsi_target/scsi_target.h:1.3 Sat Jan 10 03:26:30 2004 +++ src/share/examples/scsi_target/scsi_target.h Wed Sep 27 23:38:13 2006 @@ -33,9 +33,9 @@ /* * Maximum number of parallel commands to accept, - * 256 for Fibre Channel (SPI is 16). + * 1024 for Fibre Channel (SPI is 16). */ -#define MAX_INITIATORS 256 +#define MAX_INITIATORS 1024 #define SECTOR_SIZE 512 #define MAX_EVENTS (MAX_INITIATORS + 5) /* kqueue for AIO, signals */ @@ -114,4 +114,16 @@ extern void free_ccb(union ccb *ccb); static __inline u_int min(u_int a, u_int b) { return (a < b ? a : b); } +/* Global Data */ +extern int notaio; + +/* + * Compat Defines + */ +#if __FreeBSD_version >= 500000 +#define OFF_FMT "%ju" +#else +#define OFF_FMT "%llu" +#endif + #endif /* _SCSI_TARGET_H */ Index: src/share/examples/ses/Makefile.inc diff -u src/share/examples/ses/Makefile.inc:1.2 src/share/examples/ses/Makefile.inc:1.3 --- src/share/examples/ses/Makefile.inc:1.2 Fri Aug 13 22:19:12 2004 +++ src/share/examples/ses/Makefile.inc Sat Dec 10 20:09:54 2005 @@ -1,5 +1,3 @@ -# $NetBSD: $ -# $OpenBSD: $ # $FreeBSD$ # # Copyright (c) 2000 by Matthew Jacob @@ -34,15 +32,11 @@ # mjacob@feral.com # -SYS != uname -s +CFLAGS+= -I/usr/include/cam/scsi -DSESINC="" +BINDIR?= /usr/sbin -.if ${SYS} == OpenBSD -COPTS += -I/usr/include/scsi -DSESINC="" -.elif ${SYS} == NetBSD -COPTS += -I/usr/include/dev/scsipi -DSESINC="" -.else -CFLAGS += -I/usr/include/cam/scsi -DSESINC="" -.endif -BINDIR ?= /usr/sbin +CLEANFILES+= ${MAN} -.PATH: ../srcs +.SUFFIXES: .0 .8 +.0.8: + cat ${.IMPSRC} > ${.TARGET} Index: src/share/examples/ses/getencstat/Makefile diff -u src/share/examples/ses/getencstat/Makefile:1.2 src/share/examples/ses/getencstat/Makefile:1.3 --- src/share/examples/ses/getencstat/Makefile:1.2 Mon Jul 29 12:43:09 2002 +++ src/share/examples/ses/getencstat/Makefile Sat Dec 10 20:09:54 2005 @@ -32,9 +32,10 @@ # mjacob@feral.com # -MAN8 = getencstat.0 -SRCS = getencstat.c eltsub.c -PROG = getencstat -VPATH = ${.CURDIR}/../srcs +.PATH: ${.CURDIR}/../srcs + +PROG= getencstat +SRCS= getencstat.c eltsub.c +MAN= getencstat.8 .include Index: src/share/examples/ses/sesd/Makefile diff -u src/share/examples/ses/sesd/Makefile:1.2 src/share/examples/ses/sesd/Makefile:1.3 --- src/share/examples/ses/sesd/Makefile:1.2 Mon Jul 29 12:43:09 2002 +++ src/share/examples/ses/sesd/Makefile Sat Dec 10 20:09:54 2005 @@ -32,9 +32,10 @@ # mjacob@feral.com # -MAN8 = sesd.0 -SRCS = sesd.c eltsub.c -PROG = sesd -VPATH = ${.CURDIR}/../srcs +.PATH: ${.CURDIR}/../srcs + +PROG= sesd +SRCS= sesd.c eltsub.c +MAN= sesd.8 .include Index: src/share/examples/ses/setencstat/Makefile diff -u src/share/examples/ses/setencstat/Makefile:1.2 src/share/examples/ses/setencstat/Makefile:1.3 --- src/share/examples/ses/setencstat/Makefile:1.2 Mon Jul 29 12:43:09 2002 +++ src/share/examples/ses/setencstat/Makefile Sat Dec 10 20:09:54 2005 @@ -32,9 +32,10 @@ # mjacob@feral.com # -MAN8 = setencstat.0 -SRCS = setencstat.c eltsub.c -PROG = setencstat -VPATH = ${.CURDIR}/../srcs +.PATH: ${.CURDIR}/../srcs + +PROG= setencstat +SRCS= setencstat.c eltsub.c +MAN= setencstat.8 .include Index: src/share/examples/ses/setobjstat/Makefile diff -u src/share/examples/ses/setobjstat/Makefile:1.2 src/share/examples/ses/setobjstat/Makefile:1.3 --- src/share/examples/ses/setobjstat/Makefile:1.2 Mon Jul 29 12:43:10 2002 +++ src/share/examples/ses/setobjstat/Makefile Sat Dec 10 20:09:54 2005 @@ -32,9 +32,10 @@ # mjacob@feral.com # -MAN8 = setobjstat.0 -SRCS = setobjstat.c eltsub.c -PROG = setobjstat -VPATH = ${.CURDIR}/../srcs +.PATH: ${.CURDIR}/../srcs + +PROG= setobjstat +SRCS= setobjstat.c eltsub.c +MAN= setobjstat.8 .include Index: src/share/man/Makefile diff -u src/share/man/Makefile:1.18 src/share/man/Makefile:1.19 --- src/share/man/Makefile:1.18 Tue Dec 21 18:16:01 2004 +++ src/share/man/Makefile Sat Mar 18 02:54:33 2006 @@ -1,6 +1,8 @@ # @(#)Makefile 8.2 (Berkeley) 4/16/94 # $FreeBSD$ +.include + # XXX MISSING: man3f SUBDIR= man1 man3 man4 man5 man6 man7 man8 man9 @@ -8,7 +10,7 @@ makedb: ${MAKEWHATIS} ${DESTDIR}${BINDIR}/man -.if !defined(NO_CRYPT) && !defined(NO_OPENSSL) +.if ${MK_OPENSSL} != "no" ${MAKEWHATIS} ${DESTDIR}${BINDIR}/openssl/man .endif Index: src/share/man/man1/Makefile diff -u src/share/man/man1/Makefile:1.17 src/share/man/man1/Makefile:1.19 --- src/share/man/man1/Makefile:1.17 Tue Jan 20 18:27:22 2004 +++ src/share/man/man1/Makefile Thu Oct 5 20:40:44 2006 @@ -75,6 +75,7 @@ builtin.1 switch.1 \ builtin.1 telltc.1 \ builtin.1 then.1 \ + builtin.1 times.1 \ builtin.1 trap.1 \ builtin.1 type.1 \ builtin.1 ulimit.1 \ Index: src/share/man/man1/builtin.1 diff -u src/share/man/man1/builtin.1:1.24.2.2 src/share/man/man1/builtin.1:1.28 --- src/share/man/man1/builtin.1:1.24.2.2 Mon Oct 16 20:31:45 2006 +++ src/share/man/man1/builtin.1 Wed Dec 27 06:25:58 2006 @@ -32,12 +32,12 @@ .Sh NAME .Nm builtin , .Nm \&! , -.Nm \&% , +.Nm % , .Nm \&. , .Nm \&: , -.Nm \&@ , -.Nm \&{ , -.Nm \&} , +.Nm @ , +.Nm { , +.Nm } , .Nm alias , .Nm alloc , .Nm bg , @@ -120,6 +120,7 @@ .Nm test , .Nm then , .Nm time , +.Nm times , .Nm trap , .Nm true , .Nm type , @@ -148,18 +149,18 @@ any component of a pipeline except the last. .Pp If a command specified to the shell contains a slash -.Dq \&/ , +.Ql / , the shell will not execute a builtin command, even if the last component of the specified command matches the name of a builtin command. Thus, while specifying -.Dq Ic echo +.Dq Li echo causes a builtin command to be executed under shells that support the .Nm echo builtin command, specifying -.Dq Ic /bin/echo +.Dq Li /bin/echo or -.Dq Ic ./echo +.Dq Li ./echo does not. .Pp While some builtin commands may exist in more than one shell, their @@ -194,28 +195,28 @@ .It Xo .Em "Command External" Ta Xr csh 1 Ta Xr sh 1 .Xc -.It Ic ! Ta \&No Ta \&No Ta \&Yes +.It Ic ! Ta \&No Ta \&No Ta Yes .It Ic % Ta \&No Ta Yes Ta \&No .It Ic . Ta \&No Ta \&No Ta Yes .It Ic : Ta \&No Ta Yes Ta Yes .It Ic @ Ta \&No Ta Yes Ta Yes -.It Ic { Ta \&No Ta \&No Ta \&Yes -.It Ic } Ta \&No Ta \&No Ta \&Yes -.It Ic alias Ta \&No** Ta Yes Ta Yes +.It Ic { Ta \&No Ta \&No Ta Yes +.It Ic } Ta \&No Ta \&No Ta Yes +.It Ic alias Ta No** Ta Yes Ta Yes .It Ic alloc Ta \&No Ta Yes Ta \&No .It Ic bg Ta No** Ta Yes Ta Yes .It Ic bind Ta \&No Ta \&No Ta Yes .It Ic bindkey Ta \&No Ta Yes Ta \&No -.It Ic break Ta \&No Ta Yes Ta \&Yes +.It Ic break Ta \&No Ta Yes Ta Yes .It Ic breaksw Ta \&No Ta Yes Ta \&No .It Ic builtin Ta \&No Ta \&No Ta Yes .It Ic builtins Ta \&No Ta Yes Ta \&No .It Ic case Ta \&No Ta Yes Ta Yes -.It Ic cd Ta \&No** Ta Yes Ta Yes -.It Ic chdir Ta \&No Ta Yes Ta \&Yes -.It Ic command Ta \&No** Ta \&No Ta Yes +.It Ic cd Ta No** Ta Yes Ta Yes +.It Ic chdir Ta \&No Ta Yes Ta Yes +.It Ic command Ta No** Ta \&No Ta Yes .It Ic complete Ta \&No Ta Yes Ta \&No -.It Ic continue Ta \&No Ta Yes Ta \&Yes +.It Ic continue Ta \&No Ta Yes Ta Yes .It Ic default Ta \&No Ta Yes Ta \&No .It Ic dirs Ta \&No Ta Yes Ta \&No .It Ic do Ta \&No Ta \&No Ta Yes @@ -223,7 +224,7 @@ .It Ic echo Ta Yes Ta Yes Ta Yes .It Ic echotc Ta \&No Ta Yes Ta \&No .It Ic elif Ta \&No Ta \&No Ta Yes -.It Ic else Ta \&No Ta Yes Ta \&Yes +.It Ic else Ta \&No Ta Yes Ta Yes .It Ic end Ta \&No Ta Yes Ta \&No .It Ic endif Ta \&No Ta Yes Ta \&No .It Ic endsw Ta \&No Ta Yes Ta \&No @@ -233,22 +234,22 @@ .It Ic exit Ta \&No Ta Yes Ta Yes .It Ic export Ta \&No Ta \&No Ta Yes .It Ic false Ta Yes Ta \&No Ta Yes -.It Ic fc Ta \&No** Ta \&No Ta Yes -.It Ic fg Ta \&No** Ta Yes Ta Yes +.It Ic fc Ta No** Ta \&No Ta Yes +.It Ic fg Ta No** Ta Yes Ta Yes .It Ic filetest Ta \&No Ta Yes Ta \&No .It Ic fi Ta \&No Ta \&No Ta Yes .It Ic for Ta \&No Ta \&No Ta Yes .It Ic foreach Ta \&No Ta Yes Ta \&No -.It Ic getopts Ta \&No** Ta \&No Ta Yes +.It Ic getopts Ta No** Ta \&No Ta Yes .It Ic glob Ta \&No Ta Yes Ta \&No .It Ic goto Ta \&No Ta Yes Ta \&No .It Ic hash Ta \&No Ta \&No Ta Yes .It Ic hashstat Ta \&No Ta Yes Ta \&No .It Ic history Ta \&No Ta Yes Ta \&No .It Ic hup Ta \&No Ta Yes Ta \&No -.It Ic if Ta \&No Ta Yes Ta \&Yes +.It Ic if Ta \&No Ta Yes Ta Yes .It Ic jobid Ta \&No Ta \&No Ta Yes -.It Ic jobs Ta \&No** Ta Yes Ta Yes +.It Ic jobs Ta No** Ta Yes Ta Yes .It Ic kill Ta Yes Ta Yes Ta \&No .It Ic limit Ta \&No Ta Yes Ta \&No .It Ic local Ta \&No Ta \&No Ta Yes @@ -264,13 +265,13 @@ .It Ic printenv Ta Yes Ta Yes Ta \&No .It Ic pushd Ta \&No Ta Yes Ta \&No .It Ic pwd Ta Yes Ta \&No Ta Yes -.It Ic read Ta \&No** Ta \&No Ta Yes +.It Ic read Ta No** Ta \&No Ta Yes .It Ic readonly Ta \&No Ta \&No Ta Yes .It Ic rehash Ta \&No Ta Yes Ta \&No .It Ic repeat Ta \&No Ta Yes Ta \&No .It Ic return Ta \&No Ta \&No Ta Yes .It Ic sched Ta \&No Ta Yes Ta \&No -.It Ic set Ta \&No Ta Yes Ta \&Yes +.It Ic set Ta \&No Ta Yes Ta Yes .It Ic setenv Ta \&No Ta Yes Ta \&No .It Ic settc Ta \&No Ta Yes Ta \&No .It Ic setty Ta \&No Ta Yes Ta \&No @@ -284,22 +285,23 @@ .It Ic test Ta Yes Ta \&No Ta Yes .It Ic then Ta \&No Ta \&No Ta Yes .It Ic time Ta Yes Ta Yes Ta \&No +.It Ic times Ta \&No Ta \&No Ta Yes .It Ic trap Ta \&No Ta \&No Ta Yes .It Ic true Ta Yes Ta \&No Ta Yes .It Ic type Ta \&No Ta \&No Ta Yes .It Ic ulimit Ta \&No Ta \&No Ta Yes -.It Ic umask Ta \&No** Ta Yes Ta Yes -.It Ic unalias Ta \&No** Ta Yes Ta Yes +.It Ic umask Ta No** Ta Yes Ta Yes +.It Ic unalias Ta No** Ta Yes Ta Yes .It Ic uncomplete Ta \&No Ta Yes Ta \&No .It Ic unhash Ta \&No Ta Yes Ta \&No .It Ic unlimit Ta \&No Ta Yes Ta \&No .It Ic unset Ta \&No Ta Yes Ta Yes .It Ic unsetenv Ta \&No Ta Yes Ta \&No .It Ic until Ta \&No Ta \&No Ta Yes -.It Ic wait Ta \&No** Ta Yes Ta Yes +.It Ic wait Ta No** Ta Yes Ta Yes .It Ic where Ta \&No Ta Yes Ta \&No .It Ic which Ta Yes Ta Yes Ta \&No -.It Ic while Ta \&No Ta Yes Ta \&Yes +.It Ic while Ta \&No Ta Yes Ta Yes .El .Sh SEE ALSO .Xr csh 1 , Index: src/share/man/man1/intro.1 diff -u src/share/man/man1/intro.1:1.16 src/share/man/man1/intro.1:1.17 --- src/share/man/man1/intro.1:1.16 Tue Oct 23 08:46:13 2001 +++ src/share/man/man1/intro.1 Sun Dec 24 18:25:23 2006 @@ -58,7 +58,7 @@ Traditionally, the value 0 signifies successful completion of the command, while a value >0 indicates an error. Some commands attempt to describe the nature of the failure by using -errors codes as defined in +exit codes as defined in .Xr sysexits 3 , while others simply set the status to an arbitrary value >0 (typically 1). .Sh SEE ALSO Index: src/share/man/man3/Makefile diff -u src/share/man/man3/Makefile:1.36.2.1 src/share/man/man3/Makefile:1.45 --- src/share/man/man3/Makefile:1.36.2.1 Sun Oct 8 01:34:25 2006 +++ src/share/man/man3/Makefile Wed Oct 10 07:31:10 2007 @@ -1,6 +1,8 @@ # @(#)Makefile 8.2 (Berkeley) 12/13/93 # $FreeBSD$ +.include + MAN= assert.3 \ bitstring.3 \ end.3 \ @@ -8,6 +10,7 @@ intro.3 \ ${PTHREAD_MAN} \ queue.3 \ + siginfo.3 \ stdarg.3 \ sysexits.3 \ tgmath.3 \ @@ -109,6 +112,7 @@ tree.3 RB_FIND.3 \ tree.3 RB_FOREACH.3 \ tree.3 RB_GENERATE.3 \ + tree.3 RB_GENERATE_STATIC.3 \ tree.3 RB_HEAD.3 \ tree.3 RB_INIT.3 \ tree.3 RB_INITIALIZER.3 \ @@ -117,8 +121,10 @@ tree.3 RB_MAX.3 \ tree.3 RB_MIN.3 \ tree.3 RB_NEXT.3 \ + tree.3 RB_NFIND.3 \ tree.3 RB_PARENT.3 \ tree.3 RB_PROTOTYPE.3 \ + tree.3 RB_PROTOTYPE_STATIC.3 \ tree.3 RB_REMOVE.3 \ tree.3 RB_RIGHT.3 \ tree.3 RB_ROOT.3 \ @@ -140,7 +146,7 @@ tree.3 SPLAY_RIGHT.3 \ tree.3 SPLAY_ROOT.3 -.if !defined(NO_LIBC_R) || !defined(NO_LIBPTHREAD) || !defined(NO_LIBTHR) +.if ${MK_LIBTHR} != "no" || ${MK_LIBKSE} != "no" PTHREAD_MAN= pthread.3 \ pthread_atfork.3 \ pthread_attr.3 \ Index: src/share/man/man3/pthread.3 diff -u src/share/man/man3/pthread.3:1.28 src/share/man/man3/pthread.3:1.31 --- src/share/man/man3/pthread.3:1.28 Thu May 19 00:23:11 2005 +++ src/share/man/man3/pthread.3 Mon Oct 22 18:07:59 2007 @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 15, 2004 +.Dd October 19, 2007 .Dt PTHREAD 3 .Os .Sh NAME @@ -38,8 +38,6 @@ .Nd POSIX thread functions .Sh LIBRARY .Lb libpthread -.Lb libthr -.Lb libc_r .Sh SYNOPSIS .In pthread.h .Sh DESCRIPTION @@ -468,20 +466,20 @@ Push the specified cancellation cleanup handler onto the calling thread's cancellation stack. .El -.Sh INSTALLATION +.Sh IMPLEMENTATION NOTES The current .Fx -POSIX thread implementation is built in three libraries, -.Lb libc_r , -.Lb libpthread , +POSIX thread implementation is built in two libraries, +.Lb libthr , and -.Lb libthr . +.Lb libkse . They contain both thread-safe versions of .Lb libc functions and the thread functions. Threaded applications are linked with one of these libraries. .Sh SEE ALSO .Xr pthread_atfork 3 , +.Xr pthread_cancel 3 , .Xr pthread_cleanup_pop 3 , .Xr pthread_cleanup_push 3 , .Xr pthread_condattr_destroy 3 , Index: src/share/man/man3/pthread_attr.3 diff -u src/share/man/man3/pthread_attr.3:1.16 src/share/man/man3/pthread_attr.3:1.18 --- src/share/man/man3/pthread_attr.3:1.16 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_attr.3 Mon Oct 22 18:08:00 2007 @@ -52,9 +52,7 @@ .Nm pthread_attr_getscope .Nd thread attribute operations .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_attr_get_np.3 diff -u src/share/man/man3/pthread_attr_get_np.3:1.12 src/share/man/man3/pthread_attr_get_np.3:1.14 --- src/share/man/man3/pthread_attr_get_np.3:1.12 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_attr_get_np.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_attr_get_np .Nd get attributes of existent thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft int Index: src/share/man/man3/pthread_attr_setcreatesuspend_np.3 diff -u src/share/man/man3/pthread_attr_setcreatesuspend_np.3:1.5 src/share/man/man3/pthread_attr_setcreatesuspend_np.3:1.7 --- src/share/man/man3/pthread_attr_setcreatesuspend_np.3:1.5 Mon Jun 21 22:54:43 2004 +++ src/share/man/man3/pthread_attr_setcreatesuspend_np.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_attr_setcreatesuspend_np .Nd prepare attribute for creation of suspended thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft int Index: src/share/man/man3/pthread_barrier_destroy.3 diff -u src/share/man/man3/pthread_barrier_destroy.3:1.4 src/share/man/man3/pthread_barrier_destroy.3:1.6 --- src/share/man/man3/pthread_barrier_destroy.3:1.4 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_barrier_destroy.3 Mon Oct 22 18:08:00 2007 @@ -32,13 +32,12 @@ .Nd "destroy, initialize or wait on a barrier object" .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int .Fn pthread_barrier_destroy "pthread_barrier_t *barrier" .Ft int -.Fn pthread_barrier_init "pthread_barrier_t *barrier" "const pthread_barrierattr_t *attr" "int count" +.Fn pthread_barrier_init "pthread_barrier_t *barrier" "const pthread_barrierattr_t *attr" "unsigned count" .Ft int .Fn pthread_barrier_wait "pthread_barrier_t *barrier" .Sh DESCRIPTION @@ -77,7 +76,7 @@ Once the threads have been released the barrier will be reset. .Sh IMPLEMENTATION NOTES In both -.Lb libpthread +.Lb libkse and .Lb libthr the @@ -150,7 +149,7 @@ and .Fn pthread_barrier_wait functions first appeared in -.Lb libpthread +.Lb libkse in .Fx 5.2 , and in Index: src/share/man/man3/pthread_barrierattr.3 diff -u src/share/man/man3/pthread_barrierattr.3:1.2 src/share/man/man3/pthread_barrierattr.3:1.3 --- src/share/man/man3/pthread_barrierattr.3:1.2 Fri Jun 18 01:51:17 2004 +++ src/share/man/man3/pthread_barrierattr.3 Mon Oct 22 18:08:00 2007 @@ -33,7 +33,6 @@ .Nd "manipulate a barrier attribute object" .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -125,7 +124,7 @@ The .Fn pthread_barrierattr_* functions first appeared in -.Lb libpthread +.Lb libkse in .Fx 5.2 , and in @@ -140,7 +139,7 @@ because the process-shared attribute is ignored in .Lb libthr , and in -.Lb libpthread ; +.Lb libkse ; if any value other than .Dv PTHREAD_PROCESSES_PRIVATE is specified in a call to Index: src/share/man/man3/pthread_cancel.3 diff -u src/share/man/man3/pthread_cancel.3:1.11 src/share/man/man3/pthread_cancel.3:1.13 --- src/share/man/man3/pthread_cancel.3:1.11 Thu Jun 30 21:13:49 2005 +++ src/share/man/man3/pthread_cancel.3 Mon Oct 22 18:08:00 2007 @@ -6,9 +6,7 @@ .Nm pthread_cancel .Nd cancel execution of a thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_cleanup_pop.3 diff -u src/share/man/man3/pthread_cleanup_pop.3:1.12 src/share/man/man3/pthread_cleanup_pop.3:1.14 --- src/share/man/man3/pthread_cleanup_pop.3:1.12 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cleanup_pop.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_cleanup_pop .Nd call the first cleanup routine .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft void Index: src/share/man/man3/pthread_cleanup_push.3 diff -u src/share/man/man3/pthread_cleanup_push.3:1.13 src/share/man/man3/pthread_cleanup_push.3:1.15 --- src/share/man/man3/pthread_cleanup_push.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cleanup_push.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_cleanup_push .Nd add a cleanup function for thread exit .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft void Index: src/share/man/man3/pthread_cond_broadcast.3 diff -u src/share/man/man3/pthread_cond_broadcast.3:1.13 src/share/man/man3/pthread_cond_broadcast.3:1.15 --- src/share/man/man3/pthread_cond_broadcast.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cond_broadcast.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_cond_broadcast .Nd unblock all threads waiting for a condition variable .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_cond_destroy.3 diff -u src/share/man/man3/pthread_cond_destroy.3:1.14 src/share/man/man3/pthread_cond_destroy.3:1.16 --- src/share/man/man3/pthread_cond_destroy.3:1.14 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cond_destroy.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_cond_destroy .Nd destroy a condition variable .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_cond_init.3 diff -u src/share/man/man3/pthread_cond_init.3:1.15 src/share/man/man3/pthread_cond_init.3:1.18 --- src/share/man/man3/pthread_cond_init.3:1.15 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cond_init.3 Mon Oct 22 18:08:00 2007 @@ -27,16 +27,14 @@ .\" .\" $FreeBSD$ .\" -.Dd July 28, 1998 +.Dd November 4, 2006 .Dt PTHREAD_COND_INIT 3 .Os .Sh NAME .Nm pthread_cond_init .Nd create a condition variable .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -72,6 +70,7 @@ variable. .El .Sh SEE ALSO +.Xr pthread_condattr 3 , .Xr pthread_cond_broadcast 3 , .Xr pthread_cond_destroy 3 , .Xr pthread_cond_signal 3 , Index: src/share/man/man3/pthread_cond_signal.3 diff -u src/share/man/man3/pthread_cond_signal.3:1.13 src/share/man/man3/pthread_cond_signal.3:1.15 --- src/share/man/man3/pthread_cond_signal.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cond_signal.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_cond_signal .Nd unblock a thread waiting for a condition variable .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_cond_timedwait.3 diff -u src/share/man/man3/pthread_cond_timedwait.3:1.18 src/share/man/man3/pthread_cond_timedwait.3:1.21 --- src/share/man/man3/pthread_cond_timedwait.3:1.18 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cond_timedwait.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_cond_timedwait .Nd "wait on a condition variable for a specific amount of time" .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -47,7 +45,7 @@ function atomically blocks the current thread waiting on the condition variable specified by .Fa cond , -and unblocks the mutex specified by +and releases the mutex specified by .Fa mutex . The waiting thread unblocks only after another thread calls .Xr pthread_cond_signal 3 , @@ -79,6 +77,10 @@ .It Bq Er ETIMEDOUT The system time has reached or exceeded the time specified in .Fa abstime . +.It Bq Er EPERM +The specified +.Fa mutex +was not locked by the calling thread. .El .Sh SEE ALSO .Xr pthread_cond_broadcast 3 , Index: src/share/man/man3/pthread_cond_wait.3 diff -u src/share/man/man3/pthread_cond_wait.3:1.18 src/share/man/man3/pthread_cond_wait.3:1.22 --- src/share/man/man3/pthread_cond_wait.3:1.18 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_cond_wait.3 Mon Oct 22 18:08:00 2007 @@ -27,16 +27,14 @@ .\" .\" $FreeBSD$ .\" -.Dd July 28, 1998 +.Dd February 16, 2006 .Dt PTHREAD_COND_WAIT 3 .Os .Sh NAME .Nm pthread_cond_wait .Nd wait on a condition variable .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -47,7 +45,7 @@ function atomically blocks the current thread waiting on the condition variable specified by .Fa cond , -and unblocks the mutex specified by +and releases the mutex specified by .Fa mutex . The waiting thread unblocks only after another thread calls .Xr pthread_cond_signal 3 , @@ -73,6 +71,10 @@ or the value specified by .Fa mutex is invalid. +.It Bq Er EPERM +The specified +.Fa mutex +was not locked by the calling thread. .El .Sh SEE ALSO .Xr pthread_cond_broadcast 3 , Index: src/share/man/man3/pthread_condattr.3 diff -u src/share/man/man3/pthread_condattr.3:1.13 src/share/man/man3/pthread_condattr.3:1.15 --- src/share/man/man3/pthread_condattr.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_condattr.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_condattr_destroy .Nd condition attribute operations .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_create.3 diff -u src/share/man/man3/pthread_create.3:1.19 src/share/man/man3/pthread_create.3:1.24 --- src/share/man/man3/pthread_create.3:1.19 Sun Jul 4 02:29:20 2004 +++ src/share/man/man3/pthread_create.3 Mon Oct 22 18:08:00 2007 @@ -30,16 +30,14 @@ .\" .\" $FreeBSD$ .\" -.Dd April 4, 1996 +.Dd November 4, 2006 .Dt PTHREAD_CREATE 3 .Os .Sh NAME .Nm pthread_create .Nd create a new thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -109,6 +107,9 @@ The system lacked the necessary resources to create another thread, or the system-imposed limit on the total number of threads in a process [PTHREAD_THREADS_MAX] would be exceeded. +.It Bq Er EPERM +The caller does not have appropriate permission to set the required scheduling +parameters or scheduling policy. .It Bq Er EINVAL The value specified by .Fa attr @@ -116,6 +117,7 @@ .El .Sh SEE ALSO .Xr fork 2 , +.Xr pthread_attr 3 , .Xr pthread_cleanup_pop 3 , .Xr pthread_cleanup_push 3 , .Xr pthread_exit 3 , Index: src/share/man/man3/pthread_detach.3 diff -u src/share/man/man3/pthread_detach.3:1.16 src/share/man/man3/pthread_detach.3:1.18 --- src/share/man/man3/pthread_detach.3:1.16 Sun Jul 4 02:29:20 2004 +++ src/share/man/man3/pthread_detach.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_detach .Nd detach a thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_equal.3 diff -u src/share/man/man3/pthread_equal.3:1.13 src/share/man/man3/pthread_equal.3:1.15 --- src/share/man/man3/pthread_equal.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_equal.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_equal .Nd compare thread IDs .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_exit.3 diff -u src/share/man/man3/pthread_exit.3:1.19 src/share/man/man3/pthread_exit.3:1.21 --- src/share/man/man3/pthread_exit.3:1.19 Sun Jul 4 02:29:20 2004 +++ src/share/man/man3/pthread_exit.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_exit .Nd terminate the calling thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft void Index: src/share/man/man3/pthread_getconcurrency.3 diff -u src/share/man/man3/pthread_getconcurrency.3:1.4 src/share/man/man3/pthread_getconcurrency.3:1.6 --- src/share/man/man3/pthread_getconcurrency.3:1.4 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_getconcurrency.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_setconcurrency .Nd get or set level of concurrency .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_getspecific.3 diff -u src/share/man/man3/pthread_getspecific.3:1.13 src/share/man/man3/pthread_getspecific.3:1.15 --- src/share/man/man3/pthread_getspecific.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_getspecific.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_getspecific .Nd get a thread-specific data value .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft void * Index: src/share/man/man3/pthread_join.3 diff -u src/share/man/man3/pthread_join.3:1.16 src/share/man/man3/pthread_join.3:1.18 --- src/share/man/man3/pthread_join.3:1.16 Sun Jul 4 02:29:20 2004 +++ src/share/man/man3/pthread_join.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_join .Nd wait for thread termination .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_key_create.3 diff -u src/share/man/man3/pthread_key_create.3:1.14 src/share/man/man3/pthread_key_create.3:1.16 --- src/share/man/man3/pthread_key_create.3:1.14 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_key_create.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_key_create .Nd thread-specific data key creation .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_key_delete.3 diff -u src/share/man/man3/pthread_key_delete.3:1.14 src/share/man/man3/pthread_key_delete.3:1.16 --- src/share/man/man3/pthread_key_delete.3:1.14 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_key_delete.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_key_delete .Nd delete a thread-specific data key .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_kill.3 diff -u src/share/man/man3/pthread_kill.3:1.11 src/share/man/man3/pthread_kill.3:1.13 --- src/share/man/man3/pthread_kill.3:1.11 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_kill.3 Mon Oct 22 18:08:00 2007 @@ -33,9 +33,7 @@ .Nm pthread_kill .Nd send a signal to a specified thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .In signal.h Index: src/share/man/man3/pthread_main_np.3 diff -u src/share/man/man3/pthread_main_np.3:1.4 src/share/man/man3/pthread_main_np.3:1.6 --- src/share/man/man3/pthread_main_np.3:1.4 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_main_np.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_main_np .Nd identify the initial thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft int Index: src/share/man/man3/pthread_multi_np.3 diff -u src/share/man/man3/pthread_multi_np.3:1.4 src/share/man/man3/pthread_multi_np.3:1.7 --- src/share/man/man3/pthread_multi_np.3:1.4 Fri Jan 16 00:12:11 2004 +++ src/share/man/man3/pthread_multi_np.3 Mon Oct 22 18:08:00 2007 @@ -32,9 +32,7 @@ .Nm pthread_single_np .Nd "switch between multi- and single-threaded scheduling modes" .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft int @@ -54,15 +52,6 @@ function switches the process to a multi-threaded mode. The semantics of this function is similar to .Xr pthread_resume_all_np 3 . -.Sh IMPLEMENTATION NOTES -The -.Fn pthread_single_np -function is only available in -.Lb libc_r -and -.Lb libpthread . -This function is not implemented in -.Lb libthr . .Sh RETURN VALUES The .Fn pthread_multi_np Index: src/share/man/man3/pthread_mutex_destroy.3 diff -u src/share/man/man3/pthread_mutex_destroy.3:1.13 src/share/man/man3/pthread_mutex_destroy.3:1.15 --- src/share/man/man3/pthread_mutex_destroy.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_mutex_destroy.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_mutex_destroy .Nd free resources allocated for a mutex .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_mutex_init.3 diff -u src/share/man/man3/pthread_mutex_init.3:1.15 src/share/man/man3/pthread_mutex_init.3:1.18 --- src/share/man/man3/pthread_mutex_init.3:1.15 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_mutex_init.3 Mon Oct 22 18:08:00 2007 @@ -27,16 +27,14 @@ .\" .\" $FreeBSD$ .\" -.Dd July 29, 1998 +.Dd November 4, 2006 .Dt PTHREAD_MUTEX_INIT 3 .Os .Sh NAME .Nm pthread_mutex_init .Nd create a mutex .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -68,6 +66,7 @@ The process cannot allocate enough memory to create another mutex. .El .Sh SEE ALSO +.Xr pthread_mutexattr 3 , .Xr pthread_mutex_destroy 3 , .Xr pthread_mutex_lock 3 , .Xr pthread_mutex_trylock 3 , Index: src/share/man/man3/pthread_mutex_lock.3 diff -u src/share/man/man3/pthread_mutex_lock.3:1.14.2.1 src/share/man/man3/pthread_mutex_lock.3:1.18 --- src/share/man/man3/pthread_mutex_lock.3:1.14.2.1 Thu Mar 23 15:48:09 2006 +++ src/share/man/man3/pthread_mutex_lock.3 Mon Oct 22 18:08:00 2007 @@ -27,16 +27,14 @@ .\" .\" $FreeBSD$ .\" -.Dd February 8, 2005 +.Dd January 31, 2006 .Dt PTHREAD_MUTEX_LOCK 3 .Os .Sh NAME .Nm pthread_mutex_lock .Nd lock a mutex .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_mutex_timedlock.3 diff -u src/share/man/man3/pthread_mutex_timedlock.3:1.5 src/share/man/man3/pthread_mutex_timedlock.3:1.6 --- src/share/man/man3/pthread_mutex_timedlock.3:1.5 Fri Jan 16 00:13:49 2004 +++ src/share/man/man3/pthread_mutex_timedlock.3 Mon Oct 22 18:08:00 2007 @@ -32,7 +32,6 @@ .Nd lock a mutex without blocking indefinitely .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .In time.h Index: src/share/man/man3/pthread_mutex_trylock.3 diff -u src/share/man/man3/pthread_mutex_trylock.3:1.13 src/share/man/man3/pthread_mutex_trylock.3:1.15 --- src/share/man/man3/pthread_mutex_trylock.3:1.13 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_mutex_trylock.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_mutex_trylock .Nd attempt to lock a mutex without blocking .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_mutex_unlock.3 diff -u src/share/man/man3/pthread_mutex_unlock.3:1.14 src/share/man/man3/pthread_mutex_unlock.3:1.16 --- src/share/man/man3/pthread_mutex_unlock.3:1.14 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_mutex_unlock.3 Mon Oct 22 18:08:00 2007 @@ -34,9 +34,7 @@ .Nm pthread_mutex_unlock .Nd unlock a mutex .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_mutexattr.3 diff -u src/share/man/man3/pthread_mutexattr.3:1.11 src/share/man/man3/pthread_mutexattr.3:1.13 --- src/share/man/man3/pthread_mutexattr.3:1.11 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_mutexattr.3 Mon Oct 22 18:08:00 2007 @@ -40,9 +40,7 @@ .Nm pthread_mutexattr_gettype .Nd mutex attribute operations .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_mutexattr_getkind_np.3 diff -u src/share/man/man3/pthread_mutexattr_getkind_np.3:1.5 src/share/man/man3/pthread_mutexattr_getkind_np.3:1.7 --- src/share/man/man3/pthread_mutexattr_getkind_np.3:1.5 Fri Jan 21 18:33:02 2005 +++ src/share/man/man3/pthread_mutexattr_getkind_np.3 Mon Oct 22 18:08:00 2007 @@ -32,9 +32,7 @@ .Nm pthread_mutexattr_setkind_np .Nd mutex attribute operations (legacy) .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft int Index: src/share/man/man3/pthread_once.3 diff -u src/share/man/man3/pthread_once.3:1.19 src/share/man/man3/pthread_once.3:1.21 --- src/share/man/man3/pthread_once.3:1.19 Wed Dec 29 08:11:34 2004 +++ src/share/man/man3/pthread_once.3 Mon Oct 22 18:08:00 2007 @@ -37,9 +37,7 @@ .Nm pthread_once .Nd dynamic package initialization .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Pp Index: src/share/man/man3/pthread_resume_all_np.3 diff -u src/share/man/man3/pthread_resume_all_np.3:1.4 src/share/man/man3/pthread_resume_all_np.3:1.6 --- src/share/man/man3/pthread_resume_all_np.3:1.4 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_resume_all_np.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_resume_all_np .Nd resume all suspended threads .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft void Index: src/share/man/man3/pthread_resume_np.3 diff -u src/share/man/man3/pthread_resume_np.3:1.4 src/share/man/man3/pthread_resume_np.3:1.6 --- src/share/man/man3/pthread_resume_np.3:1.4 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_resume_np.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_resume_np .Nd resume suspended thread .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft int Index: src/share/man/man3/pthread_rwlock_destroy.3 diff -u src/share/man/man3/pthread_rwlock_destroy.3:1.10 src/share/man/man3/pthread_rwlock_destroy.3:1.12 --- src/share/man/man3/pthread_rwlock_destroy.3:1.10 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlock_destroy.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_rwlock_destroy .Nd destroy a read/write lock .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlock_init.3 diff -u src/share/man/man3/pthread_rwlock_init.3:1.9 src/share/man/man3/pthread_rwlock_init.3:1.11 --- src/share/man/man3/pthread_rwlock_init.3:1.9 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlock_init.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_rwlock_init .Nd initialize a read/write lock .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlock_rdlock.3 diff -u src/share/man/man3/pthread_rwlock_rdlock.3:1.8 src/share/man/man3/pthread_rwlock_rdlock.3:1.10 --- src/share/man/man3/pthread_rwlock_rdlock.3:1.8 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlock_rdlock.3 Mon Oct 22 18:08:00 2007 @@ -32,9 +32,7 @@ .Nm pthread_rwlock_tryrdlock .Nd acquire a read/write lock for reading .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlock_timedrdlock.3 diff -u src/share/man/man3/pthread_rwlock_timedrdlock.3:1.2 src/share/man/man3/pthread_rwlock_timedrdlock.3:1.3 --- src/share/man/man3/pthread_rwlock_timedrdlock.3:1.2 Fri Jun 18 01:49:30 2004 +++ src/share/man/man3/pthread_rwlock_timedrdlock.3 Mon Oct 22 18:08:00 2007 @@ -32,7 +32,6 @@ .Nd "acquire a read-write lock for reading or give up after a specified period" .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlock_timedwrlock.3 diff -u src/share/man/man3/pthread_rwlock_timedwrlock.3:1.2 src/share/man/man3/pthread_rwlock_timedwrlock.3:1.3 --- src/share/man/man3/pthread_rwlock_timedwrlock.3:1.2 Fri Jun 18 01:49:30 2004 +++ src/share/man/man3/pthread_rwlock_timedwrlock.3 Mon Oct 22 18:08:00 2007 @@ -32,7 +32,6 @@ .Nd "acquire a read-write lock for writing or give up after a specified period" .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlock_unlock.3 diff -u src/share/man/man3/pthread_rwlock_unlock.3:1.8 src/share/man/man3/pthread_rwlock_unlock.3:1.10 --- src/share/man/man3/pthread_rwlock_unlock.3:1.8 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlock_unlock.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_rwlock_unlock .Nd release a read/write lock .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlock_wrlock.3 diff -u src/share/man/man3/pthread_rwlock_wrlock.3:1.9 src/share/man/man3/pthread_rwlock_wrlock.3:1.11 --- src/share/man/man3/pthread_rwlock_wrlock.3:1.9 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlock_wrlock.3 Mon Oct 22 18:08:00 2007 @@ -32,9 +32,7 @@ .Nm pthread_rwlock_trywrlock .Nd acquire a read/write lock for writing .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlockattr_destroy.3 diff -u src/share/man/man3/pthread_rwlockattr_destroy.3:1.11 src/share/man/man3/pthread_rwlockattr_destroy.3:1.13 --- src/share/man/man3/pthread_rwlockattr_destroy.3:1.11 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlockattr_destroy.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_rwlockattr_destroy .Nd destroy a read/write lock .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlockattr_getpshared.3 diff -u src/share/man/man3/pthread_rwlockattr_getpshared.3:1.13 src/share/man/man3/pthread_rwlockattr_getpshared.3:1.15 --- src/share/man/man3/pthread_rwlockattr_getpshared.3:1.13 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlockattr_getpshared.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_rwlockattr_getpshared .Nd get the process shared attribute .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlockattr_init.3 diff -u src/share/man/man3/pthread_rwlockattr_init.3:1.11 src/share/man/man3/pthread_rwlockattr_init.3:1.13 --- src/share/man/man3/pthread_rwlockattr_init.3:1.11 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlockattr_init.3 Mon Oct 22 18:08:00 2007 @@ -31,9 +31,7 @@ .Nm pthread_rwlockattr_init .Nd initialize a read/write lock .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_rwlockattr_setpshared.3 diff -u src/share/man/man3/pthread_rwlockattr_setpshared.3:1.13 src/share/man/man3/pthread_rwlockattr_setpshared.3:1.15 --- src/share/man/man3/pthread_rwlockattr_setpshared.3:1.13 Fri Jan 21 16:36:36 2005 +++ src/share/man/man3/pthread_rwlockattr_setpshared.3 Mon Oct 22 18:08:01 2007 @@ -31,9 +31,7 @@ .Nm pthread_rwlockattr_setpshared .Nd set the process shared attribute .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_schedparam.3 diff -u src/share/man/man3/pthread_schedparam.3:1.9.8.1 src/share/man/man3/pthread_schedparam.3:1.12 --- src/share/man/man3/pthread_schedparam.3:1.9.8.1 Sat Oct 21 02:59:44 2006 +++ src/share/man/man3/pthread_schedparam.3 Mon Oct 22 18:08:01 2007 @@ -35,9 +35,7 @@ .Nm pthread_getschedparam .Nd thread scheduling parameter manipulation .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_self.3 diff -u src/share/man/man3/pthread_self.3:1.12 src/share/man/man3/pthread_self.3:1.14 --- src/share/man/man3/pthread_self.3:1.12 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_self.3 Mon Oct 22 18:08:01 2007 @@ -37,9 +37,7 @@ .Nm pthread_self .Nd get the calling thread's ID .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft pthread_t Index: src/share/man/man3/pthread_set_name_np.3 diff -u src/share/man/man3/pthread_set_name_np.3:1.4 src/share/man/man3/pthread_set_name_np.3:1.6 --- src/share/man/man3/pthread_set_name_np.3:1.4 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_set_name_np.3 Mon Oct 22 18:08:01 2007 @@ -31,9 +31,7 @@ .Nm pthread_set_name_np .Nd set the thread name .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread_np.h .Ft void Index: src/share/man/man3/pthread_setspecific.3 diff -u src/share/man/man3/pthread_setspecific.3:1.15 src/share/man/man3/pthread_setspecific.3:1.17 --- src/share/man/man3/pthread_setspecific.3:1.15 Wed Dec 29 08:11:34 2004 +++ src/share/man/man3/pthread_setspecific.3 Mon Oct 22 18:08:01 2007 @@ -37,9 +37,7 @@ .Nm pthread_setspecific .Nd set a thread-specific data value .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_sigmask.3 diff -u src/share/man/man3/pthread_sigmask.3:1.12 src/share/man/man3/pthread_sigmask.3:1.14 --- src/share/man/man3/pthread_sigmask.3:1.12 Thu Jan 15 23:59:00 2004 +++ src/share/man/man3/pthread_sigmask.3 Mon Oct 22 18:08:01 2007 @@ -33,9 +33,7 @@ .Nm pthread_sigmask .Nd examine and/or change a thread's signal mask .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .In signal.h Index: src/share/man/man3/pthread_spin_init.3 diff -u src/share/man/man3/pthread_spin_init.3:1.2 src/share/man/man3/pthread_spin_init.3:1.3 --- src/share/man/man3/pthread_spin_init.3:1.2 Fri Jun 18 01:51:17 2004 +++ src/share/man/man3/pthread_spin_init.3 Mon Oct 22 18:08:01 2007 @@ -32,7 +32,6 @@ .Nd "initialize or destroy a spin lock" .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -115,7 +114,7 @@ and .Fn pthread_spin_destroy functions first appeared in -.Lb libpthread +.Lb libkse in .Fx 5.2 , and in @@ -132,7 +131,7 @@ argument is ignored in .Lb libthr , and in -.Lb libpthread +.Lb libkse if any value other than .Dv PTHREAD_PROCESSES_PRIVATE is specified, it returns Index: src/share/man/man3/pthread_spin_lock.3 diff -u src/share/man/man3/pthread_spin_lock.3:1.3 src/share/man/man3/pthread_spin_lock.3:1.4 --- src/share/man/man3/pthread_spin_lock.3:1.3 Thu Jul 8 01:36:31 2004 +++ src/share/man/man3/pthread_spin_lock.3 Mon Oct 22 18:08:01 2007 @@ -32,7 +32,6 @@ .Nd "lock or unlock a spin lock" .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int @@ -122,7 +121,7 @@ and .Fn pthread_spin_unlock functions first appeared in -.Lb libpthread +.Lb libkse in .Fx 5.2 , and in Index: src/share/man/man3/pthread_suspend_all_np.3 diff -u src/share/man/man3/pthread_suspend_all_np.3:1.5 src/share/man/man3/pthread_suspend_all_np.3:1.6 --- src/share/man/man3/pthread_suspend_all_np.3:1.5 Fri Jan 16 00:07:52 2004 +++ src/share/man/man3/pthread_suspend_all_np.3 Sat Sep 30 19:22:26 2006 @@ -31,7 +31,6 @@ .Nm pthread_suspend_all_np .Nd suspend all active threads .Sh LIBRARY -.Lb libc_r .Lb libpthread .Sh SYNOPSIS .In pthread_np.h Index: src/share/man/man3/pthread_suspend_np.3 diff -u src/share/man/man3/pthread_suspend_np.3:1.5 src/share/man/man3/pthread_suspend_np.3:1.6 --- src/share/man/man3/pthread_suspend_np.3:1.5 Fri Jan 16 00:07:52 2004 +++ src/share/man/man3/pthread_suspend_np.3 Sat Sep 30 19:22:26 2006 @@ -31,7 +31,6 @@ .Nm pthread_suspend_np .Nd suspend a thread .Sh LIBRARY -.Lb libc_r .Lb libpthread .Sh SYNOPSIS .In pthread_np.h Index: src/share/man/man3/pthread_switch_add_np.3 diff -u src/share/man/man3/pthread_switch_add_np.3:1.3 src/share/man/man3/pthread_switch_add_np.3:1.5 --- src/share/man/man3/pthread_switch_add_np.3:1.3 Sat Jul 3 03:07:32 2004 +++ src/share/man/man3/pthread_switch_add_np.3 Mon Oct 22 18:08:01 2007 @@ -32,7 +32,7 @@ .Nm pthread_switch_delete_np .Nd thread context switches debugging primitives .Sh LIBRARY -.Lb libc_r +.Lb libpthread .Sh SYNOPSIS .In pthread_np.h .Ft int Index: src/share/man/man3/pthread_testcancel.3 diff -u src/share/man/man3/pthread_testcancel.3:1.13 src/share/man/man3/pthread_testcancel.3:1.15 --- src/share/man/man3/pthread_testcancel.3:1.13 Thu Jun 30 21:13:49 2005 +++ src/share/man/man3/pthread_testcancel.3 Mon Oct 22 18:08:01 2007 @@ -8,9 +8,7 @@ .Nm pthread_testcancel .Nd set cancelability state .Sh LIBRARY -.Lb libc_r .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft int Index: src/share/man/man3/pthread_yield.3 diff -u src/share/man/man3/pthread_yield.3:1.1.2.1 src/share/man/man3/pthread_yield.3:1.2 --- src/share/man/man3/pthread_yield.3:1.1.2.1 Sun Oct 8 01:34:25 2006 +++ src/share/man/man3/pthread_yield.3 Mon Oct 22 18:08:01 2007 @@ -12,7 +12,6 @@ .Nd yield control of the current thread .Sh LIBRARY .Lb libpthread -.Lb libthr .Sh SYNOPSIS .In pthread.h .Ft void Index: src/share/man/man3/queue.3 diff -u src/share/man/man3/queue.3:1.35.2.2 src/share/man/man3/queue.3:1.41 --- src/share/man/man3/queue.3:1.35.2.2 Tue May 2 12:02:39 2006 +++ src/share/man/man3/queue.3 Fri Nov 2 08:34:44 2007 @@ -32,7 +32,7 @@ .\" @(#)queue.3 8.2 (Berkeley) 1/24/94 .\" $FreeBSD$ .\" -.Dd January 24, 1994 +.Dd March 24, 2006 .Dt QUEUE 3 .Os .Sh NAME @@ -179,22 +179,28 @@ .It O(1) removal of an entry from the head of the list. .It -O(n) removal of any entry in the list. -.It Forward traversal through the list. .El .Pp +O(n) removal of any entry in the list. Singly-linked lists are the simplest of the four data structures and support only the above functionality. Singly-linked lists are ideal for applications with large datasets and few or no removals, or for implementing a LIFO queue. +Singly-linked lists add the following functionality: +.Bl -enum -compact -offset indent +.It +O(n) removal of any entry in the list. +.El .Pp Singly-linked tail queues add the following functionality: .Bl -enum -compact -offset indent .It Entries can be added at the end of a list. .It +O(n) removal of any entry in the list. +.It They may be concatenated. .El However: @@ -538,7 +544,8 @@ The macro .Nm STAILQ_LAST returns the last item on the tail queue. -If the tail queue is empty the return value is undefined. +If the tail queue is empty the return value is +.Dv NULL . .Pp The macro .Nm STAILQ_NEXT @@ -899,7 +906,8 @@ The macro .Nm TAILQ_LAST returns the last item on the tail queue. -If the tail queue is empty the return value is undefined. +If the tail queue is empty the return value is +.Dv NULL . .Pp The macro .Nm TAILQ_NEXT Index: src/share/man/man3/siginfo.3 diff -u /dev/null src/share/man/man3/siginfo.3:1.3 --- /dev/null Thu Jan 17 11:57:39 2008 +++ src/share/man/man3/siginfo.3 Sat Sep 30 19:48:12 2006 @@ -0,0 +1,309 @@ +.\" Copyright (c) 2005 David Xu +.\" 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(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), 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 COPYRIGHT HOLDER(S) ``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 COPYRIGHT HOLDER(S) 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$ +.\" +.Dd December 8, 2005 +.Dt SIGINFO 3 +.Os +.Sh NAME +.Nm siginfo +.Nd "signal generation information" +.Sh SYNOPSIS +.In signal.h +.Sh DESCRIPTION +A process may request signal information when it is catching a signal. +The information specifies why the system generated that signal. +To request signal information in a signal handler, the user can set +.Dv SA_SIGINFO +in +.Va sa_flags +before +.Xr sigaction 2 +is called, +otherwise the user can use +.Xr sigwaitinfo 2 +and +.Xr sigtimedwait 2 +to get signal information. +In either case, the system returns the information in a structure of type +.Vt siginfo_t , +which includes the following information: +.Bl -column ".Vt union signal" ".Va si_overrun" +.It Sy "Type Member Description" +.It Vt int Ta Va si_signo Ta +signal number +.It Vt int Ta Va si_errno Ta +error number +.It Vt int Ta Va si_code Ta +signal code +.It Vt union sigval Ta Va si_value Ta +signal value +.It Vt pid_t Ta Va si_pid Ta +sending process ID +.It Vt uid_t Ta Va si_uid Ta +sending process's real user ID +.It Vt void Ta Va *si_addr Ta +address of faulting instruction +.It Vt int Ta Va si_status Ta +exit value or signal +.It Vt long Ta Va si_band Ta +band event for +.Dv SIGPOLL +.It Vt int Ta Va si_trapno Ta +machine trap code +.It Vt int Ta Va si_timerid Ta +.Tn POSIX +timer ID +.It Vt int Ta Va si_overrun Ta +.Tn POSIX +timer overrun count +.It Vt int Ta Va si_mqd Ta +.Tn POSIX +message queue ID +.El +.Pp +The +.Va si_signo +member contains the signal number. +.Pp +The +.Va si_errno +member contains an error number defined in the file +.In errno.h . +.Pp +The +.Va si_code +member contains a code which describes the cause of the signal. +The macros specified in the +.Sy Code +column of the following table are defined +for use as values of +.Va si_code +that are signal-specific or non-signal-specific reasons why the signal was +generated: +.Bl -column ".Dv SIGPOLL" ".Dv CLD_CONTINUED" +.It Sy "Signal Code Reason" +.It Dv SIGILL Ta Dv ILL_ILLOPC Ta +illegal opcode +.It Ta Dv ILL_ILLOPN Ta +illegal operand +.It Ta Dv ILL_ILLADR Ta +illegal addressing mode +.It Ta Dv ILL_ILLTRP Ta +illegal trap +.It Ta Dv ILL_PRVOPC Ta +illegal privileged opcode +.It Ta Dv ILL_PRVREG Ta +illegal privileged register +.It Ta Dv ILL_COPROC Ta +coprocessor error +.It Ta Dv ILL_BADSTK Ta +internal stack error +.It Dv SIGFPE Ta Dv FPE_INTDIV Ta +integer divide by zero +.It Ta Dv FPE_INTOVF Ta +integer overflow +.It Ta Dv FPE_FLTDIV Ta +floating-point divide by zero +.It Ta Dv FPE_FLTOVF Ta +floating-point overflow +.It Ta Dv FPE_FLTUND Ta +floating-point underflow +.It Ta Dv FPE_FLTRES Ta +floating-point inexact result +.It Ta Dv FPE_FLTINV Ta +invalid floating-point operation +.It Ta Dv FPE_FLTSUB Ta +subscript out of range +.It Dv SIGSEGV Ta Dv SEGV_MAPERR Ta +address not mapped to object +.It Ta Dv SEGV_ACCERR Ta +invalid permissions for mapped object +.It Dv SIGBUS Ta Dv BUS_ADRALN Ta +invalid address alignment +.It Ta Dv BUS_ADRERR Ta +nonexistent physical address +.It Ta Dv BUS_OBJERR Ta +object-specific hardware error +.It Dv SIGTRAP Ta Dv TRAP_BRKPT Ta +process breakpoint +.It Ta Dv TRAP_TRACE Ta +process trace trap +.It Dv SIGCHLD Ta Dv CLD_EXITED Ta +child has exited +.It Ta Dv CLD_KILLED Ta +child has terminated abnormally and did not create a core file +.It Ta Dv CLD_DUMPED Ta +child has terminated abnormally and created a core file +.It Ta Dv CLD_TRAPPED Ta +traced child has trapped +.It Ta Dv CLD_STOPPED Ta +child has stopped +.It Ta Dv CLD_CONTINUED Ta +stopped child has continued +.It Dv SIGPOLL Ta Dv POLL_IN Ta +data input available +.It Ta Dv POLL_OUT Ta +output buffers available +.It Ta Dv POLL_MSG Ta +input message available +.It Ta Dv POLL_ERR Ta +I/O error +.It Ta Dv POLL_PRI Ta +high priority input available +.It Ta Dv POLL_HUP Ta +device disconnected +.It Any Ta Dv SI_NOINFO Ta +Only the +.Va si_signo +member is meaningful; the value of all other members is unspecified. +.It Ta Dv SI_USER Ta +signal sent by +.Xr kill 2 +.It Ta Dv SI_QUEUE Ta +signal sent by +.Xr sigqueue 2 +.It Ta Dv SI_TIMER Ta +signal generated by expiration of a timer set by +.Xr timer_settime 2 +.It Ta Dv SI_ASYNCIO Ta +signal generated by completion of an asynchronous I/O request +.It Ta Dv SI_MESGQ Ta +signal generated by arrival of a message on an empty message queue +.El +.Pp +In addition, the following signal-specific information is available: +.Bl -column ".Dv SIGPOLL" ".Dv CLD_CONTINUED" +.It Sy "Signal Member Value" +.It Dv SIGILL Ta Va si_addr Ta +address of faulting instruction +.It Ta Va si_trapno Ta +machine dependent of trap code +.It Dv SIGFPE Ta Va si_addr Ta +address of faulting instruction +.It Ta Va si_trapno Ta +machine dependent of trap code +.It Dv SIGSEGV Ta Va si_addr Ta +address of faulting memory reference +.It Ta Va si_trapno Ta +machine dependent of trap code +.It Dv SIGBUS Ta Va si_addr Ta +address of faulting instruction +.It Ta Va si_trapno Ta +machine dependent of trap code +.It Dv SIGCHLD Ta Vt Va si_pid Ta +child process ID +.It Ta Va si_status Ta +exit value or signal; if +.Va si_code +is equal to +.Dv CLD_EXITED , +then it is equal to the exit value of the child process, otherwise, +it is equal to a signal that caused the child process to change state. +.It Ta Va si_uid Ta "real user ID of the process that sent the signal" +.It Dv SIGPOLL Ta Va si_band Ta "band event for" +.Dv POLL_IN , POLL_OUT , +or +.Dv POLL_MSG +.El +.Pp +Finally, the following code-specific information is available: +.Bl -column ".Dv SI_QUEUE" ".Va si_overrun" +.It Sy "Code Member Value" +.It Dv SI_QUEUE Ta Va si_value Ta +the value passed to +.Xr sigqueue 2 +system call +.It Ta Va si_pid Ta +the process ID that sent the signal +.It Ta Va si_uid Ta +real user ID of the process that sent the signal +.It Dv SI_TIMER Ta Va si_value Ta +the value passed to +.Xr timer_create 2 +system call +.It Ta Va si_timerid Ta +the timer ID returned by +.Xr timer_create 2 +system call +.It Ta Va si_overrun Ta +timer overrun count corresponding to the signal +.It Ta Va si_errno Ta +If timer overrun will be +.Brq Dv DELAYTIMER_MAX , +an error code defined in +.In errno.h +is set +.It Dv SI_ASYNCIO Ta Va si_value Ta +the value passed to aio system calls +.It Dv SI_MESGQ Ta Va si_value Ta +the value passed to +.Xr mq_notify 2 +system call +.It Ta Va si_mqd Ta +the ID of the message queue which generated the signal +.El +.Sh NOTES +Currently, the kernel never generates the +.Dv SIGPOLL +signal. +Also, the +.Xr kill 2 +system call does not queue signals, so you will not get code +.Dv SI_USER . +.Dv SIGCHLD +signal is queued when a process changed its status or exited. +.Tn POSIX +Realtime Extensions like aio, timer, and message queue also queue +signals. +For some hardware architectures, the exact value of +.Va si_addr +might not be available. +.Sh SEE ALSO +.Xr aio_read 2 , +.Xr kill 2 , +.Xr mq_notify 2 , +.Xr sigaction 2 , +.Xr sigqueue 2 , +.Xr sigwaitinfo 2 , +.Xr timer_create 2 , +.Xr timer_settime 2 , +.Xr waitpid 2 +.Sh STANDARDS +The +.Vt siginfo_t +type conforms to +.St -p1003.1-2004 . +.Sh HISTORY +Full support for +.Tn POSIX +signal information first appeared in +.Fx 7.0 . +.Sh AUTHORS +This manual page was written by +.An "David Xu" Aq davidxu@FreeBSD.org . Index: src/share/man/man3/tgmath.3 diff -u src/share/man/man3/tgmath.3:1.2 src/share/man/man3/tgmath.3:1.3 --- src/share/man/man3/tgmath.3:1.2 Thu Jan 13 19:22:29 2005 +++ src/share/man/man3/tgmath.3 Sat Dec 15 10:40:10 2007 @@ -101,6 +101,7 @@ .It Fn exp Ta Fn exp Ta Fn cexp .It Fn log Ta Fn log Ta Fn clog .It Fn pow Ta Fn pow Ta Fn cpow +.It Fn sqrt Ta Fn sqrt Ta Fn csqrt .It Fn fabs Ta Fn fabs Ta Fn cabs .El .Pp Index: src/share/man/man3/tree.3 diff -u src/share/man/man3/tree.3:1.4 src/share/man/man3/tree.3:1.7 --- src/share/man/man3/tree.3:1.4 Mon Jun 21 22:54:43 2004 +++ src/share/man/man3/tree.3 Fri Dec 28 15:03:26 2007 @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd February 24, 2002 +.Dd December 27, 2007 .Dt TREE 3 .Os .Sh NAME @@ -52,20 +52,25 @@ .Nm SPLAY_INSERT , .Nm SPLAY_REMOVE , .Nm RB_PROTOTYPE , +.Nm RB_PROTOTYPE_STATIC , .Nm RB_GENERATE , +.Nm RB_GENERATE_STATIC , .Nm RB_ENTRY , .Nm RB_HEAD , .Nm RB_INITIALIZER , .Nm RB_ROOT , .Nm RB_EMPTY , .Nm RB_NEXT , +.Nm RB_PREV , .Nm RB_MIN , .Nm RB_MAX , .Nm RB_FIND , +.Nm RB_NFIND , .Nm RB_LEFT , .Nm RB_RIGHT , .Nm RB_PARENT , .Nm RB_FOREACH , +.Nm RB_FOREACH_REVERSE , .Nm RB_INIT , .Nm RB_INSERT , .Nm RB_REMOVE @@ -101,7 +106,9 @@ .Ft "struct TYPE *" .Fn SPLAY_REMOVE NAME "SPLAY_HEAD *head" "struct TYPE *elm" .Fn RB_PROTOTYPE NAME TYPE FIELD CMP +.Fn RB_PROTOTYPE_STATIC NAME TYPE FIELD CMP .Fn RB_GENERATE NAME TYPE FIELD CMP +.Fn RB_GENERATE_STATIC NAME TYPE FIELD CMP .Fn RB_ENTRY TYPE .Fn RB_HEAD HEADNAME TYPE .Fn RB_INITIALIZER "RB_HEAD *head" @@ -112,18 +119,23 @@ .Ft "struct TYPE *" .Fn RB_NEXT NAME "RB_HEAD *head" "struct TYPE *elm" .Ft "struct TYPE *" +.Fn RB_PREV NAME "RB_HEAD *head" "struct TYPE *elm" +.Ft "struct TYPE *" .Fn RB_MIN NAME "RB_HEAD *head" .Ft "struct TYPE *" .Fn RB_MAX NAME "RB_HEAD *head" .Ft "struct TYPE *" .Fn RB_FIND NAME "RB_HEAD *head" "struct TYPE *elm" .Ft "struct TYPE *" +.Fn RB_NFIND NAME "RB_HEAD *head" "struct TYPE *elm" +.Ft "struct TYPE *" .Fn RB_LEFT "struct TYPE *elm" "RB_ENTRY NAME" .Ft "struct TYPE *" .Fn RB_RIGHT "struct TYPE *elm" "RB_ENTRY NAME" .Ft "struct TYPE *" .Fn RB_PARENT "struct TYPE *elm" "RB_ENTRY NAME" .Fn RB_FOREACH VARNAME NAME "RB_HEAD *head" +.Fn RB_FOREACH_REVERSE VARNAME NAME "RB_HEAD *head" .Ft void .Fn RB_INIT "RB_HEAD *head" .Ft "struct TYPE *" @@ -153,14 +165,16 @@ .Fa NAME has to be a unique name prefix for every tree that is defined. .Pp -The function prototypes are declared with either +The function prototypes are declared with .Fn SPLAY_PROTOTYPE , +.Fn RB_PROTOTYPE , or -.Fn RB_PROTOTYPE . -The function bodies are generated with either +.Fn RB_PROTOTYPE_STATIC . +The function bodies are generated with .Fn SPLAY_GENERATE , +.Fn RB_GENERATE , or -.Fn RB_GENERATE . +.Fn RB_GENERATE_STATIC . See the examples below for further explanation of how these macros are used. .Sh SPLAY TREES A splay tree is a self-organizing data structure. @@ -341,6 +355,8 @@ In order to use the functions that manipulate the tree structure, their prototypes need to be declared with the .Fn RB_PROTOTYPE +or +.Fn RB_PROTOTYPE_STATIC macro, where .Fa NAME @@ -356,10 +372,14 @@ .Pp The function bodies are generated with the .Fn RB_GENERATE +or +.Fn RB_GENERATE_STATIC macro. -It takes the same arguments as the +These macros take the same arguments as the .Fn RB_PROTOTYPE -macro, but should be used only once. +and +.Fn RB_PROTOTYPE_STATIC +macros, but should be used only once. .Pp Finally, the @@ -405,7 +425,9 @@ .Pp The .Fn RB_FIND -macro can be used to find a particular element in the tree. +and +.Fn RB_NFIND +macros can be used to find a particular element in the tree. .Bd -literal -offset indent struct TYPE find, *res; find.key = 30; @@ -416,14 +438,17 @@ .Fn RB_ROOT , .Fn RB_MIN , .Fn RB_MAX , +.Fn RB_NEXT , and -.Fn RB_NEXT +.Fn RB_PREV macros can be used to traverse the tree: .Pp .Dl "for (np = RB_MIN(NAME, &head); np != NULL; np = RB_NEXT(NAME, &head, np))" .Pp Or, for simplicity, one can use the .Fn RB_FOREACH +or +.Fn RB_FOREACH_REVERSE macro: .Bd -ragged -offset indent .Fn RB_FOREACH np NAME head Index: src/share/man/man4/Makefile diff -u src/share/man/man4/Makefile:1.320.2.32 src/share/man/man4/Makefile:1.402 --- src/share/man/man4/Makefile:1.320.2.32 Sat Dec 15 14:03:43 2007 +++ src/share/man/man4/Makefile Fri Jan 4 16:26:22 2008 @@ -3,6 +3,7 @@ MAN= aac.4 \ acpi.4 \ + ${_acpi_dock.4} \ acpi_thermal.4 \ acpi_video.4 \ adv.4 \ @@ -17,8 +18,9 @@ amd.4 \ ${_amdsmb.4} \ amr.4 \ - arcmsr.4 \ an.4 \ + arcmsr.4 \ + ${_asmc.4} \ asr.4 \ ata.4 \ atapicam.4 \ @@ -38,7 +40,6 @@ bktr.4 \ blackhole.4 \ bpf.4 \ - bridge.4 \ bt.4 \ cardbus.4 \ carp.4 \ @@ -49,6 +50,7 @@ ciss.4 \ cm.4 \ cnw.4 \ + ${_coretemp.4} \ cpufreq.4 \ crypto.4 \ cue.4 \ @@ -76,7 +78,6 @@ esp.4 \ exca.4 \ faith.4 \ - fast_ipsec.4 \ fatm.4 \ fd.4 \ fdc.4 \ @@ -100,17 +101,19 @@ hfa.4 \ hifn.4 \ hme.4 \ - hptmv.4 \ - hptrr.4 \ + ${_hptiop.4} \ + ${_hptmv.4} \ + ${_hptrr.4} \ hwpmc.4 \ ichsmb.4 \ + ${_ichwd.4} \ icmp.4 \ icmp6.4 \ ida.4 \ idt.4 \ ieee80211.4 \ - ifmib.4 \ if_bridge.4 \ + ifmib.4 \ iic.4 \ iicbb.4 \ iicbus.4 \ @@ -127,6 +130,7 @@ ips.4 \ ipsec.4 \ ipw.4 \ + iscsi_initiator.4 \ isp.4 \ ispfw.4 \ iwi.4 \ @@ -141,6 +145,7 @@ le.4 \ led.4 \ lge.4 \ + lmc.4 \ lo.4 \ lp.4 \ lpbb.4 \ @@ -164,6 +169,8 @@ miibus.4 \ mlx.4 \ mly.4 \ + mmc.4 \ + mmcsd.4 \ mn.4 \ mouse.4 \ mpt.4 \ @@ -178,6 +185,7 @@ ncv.4 \ netgraph.4 \ netintro.4 \ + ${_nfe.4} \ ${_nfsmb.4} \ ng_async.4 \ ng_atm.4 \ @@ -189,6 +197,7 @@ ng_bridge.4 \ ng_bt3c.4 \ ng_btsocket.4 \ + ng_car.4 \ ng_ccatm.4 \ ng_cisco.4 \ ng_deflate.4 \ @@ -207,8 +216,8 @@ ng_hole.4 \ ng_hub.4 \ ng_iface.4 \ - ng_ip_input.4 \ ng_ipfw.4 \ + ng_ip_input.4 \ ng_ksocket.4 \ ng_l2cap.4 \ ng_l2tp.4 \ @@ -241,6 +250,7 @@ nsp.4 \ null.4 \ ${_nve.4} \ + ${_nxge.4} \ ohci.4 \ oldcard.4 \ orm.4 \ @@ -249,10 +259,10 @@ pccard.4 \ pccbb.4 \ pci.4 \ + pcib.4 \ pcic.4 \ pcm.4 \ pcn.4 \ - pcvt.4 \ pim.4 \ polling.4 \ ppbus.4 \ @@ -274,16 +284,18 @@ rp.4 \ ${_rr232x.4} \ rue.4 \ + rum.4 \ sa.4 \ - sab.4 \ safe.4 \ sbp.4 \ sbp_targ.4 \ sbsh.4 \ + scc.4 \ sched_4bsd.4 \ sched_ule.4 \ screen.4 \ scsi.4 \ + sctp.4 \ sem.4 \ ses.4 \ sf.4 \ @@ -304,6 +316,7 @@ snd_csa.4 \ snd_ds1.4 \ snd_emu10k1.4 \ + snd_emu10kx.4 \ snd_envy24.4 \ snd_envy24ht.4 \ snd_es137x.4 \ @@ -312,8 +325,8 @@ snd_gusc.4 \ snd_hda.4 \ snd_ich.4 \ - snd_maestro.4 \ snd_maestro3.4 \ + snd_maestro.4 \ snd_mss.4 \ snd_neomagic.4 \ snd_sbc.4 \ @@ -343,6 +356,7 @@ tcp.4 \ tdfx.4 \ termios.4 \ + textdump.4 \ ti.4 \ tl.4 \ trm.4 \ @@ -364,6 +378,7 @@ udbp.4 \ udp.4 \ ufm.4 \ + ufoma.4 \ uftdi.4 \ ugen.4 \ uhci.4 \ @@ -396,15 +411,17 @@ witness.4 \ wlan.4 \ wlan_acl.4 \ + wlan_amrr.4 \ wlan_ccmp.4 \ wlan_tkip.4 \ wlan_wep.4 \ wlan_xauth.4 \ - worm.4 \ + ${_wpi.4} \ xe.4 \ xl.4 \ xpt.4 \ - zero.4 + zero.4 \ + zyd.4 MLINKS= agp.4 agpgart.4 MLINKS+=altq.4 ALTQ.4 @@ -448,12 +465,14 @@ MLINKS+=hatm.4 if_hatm.4 MLINKS+=hme.4 if_hme.4 MLINKS+=idt.4 if_idt.4 +MLINKS+=if_bridge.4 bridge.4 MLINKS+=ip.4 rawip.4 MLINKS+=ipfirewall.4 ipaccounting.4 \ ipfirewall.4 ipacct.4 \ ipfirewall.4 ipfw.4 MLINKS+=ipw.4 if_ipw.4 MLINKS+=iwi.4 if_iwi.4 +MLINKS+=ixgb.4 if_ixgb.4 MLINKS+=kue.4 if_kue.4 MLINKS+=lagg.4 trunk.4 MLINKS+=le.4 if_le.4 @@ -467,20 +486,22 @@ MLINKS+=my.4 if_my.4 MLINKS+=netintro.4 net.4 \ netintro.4 networking.4 +MLINKS+=${_nfe.4} ${_if_nfe.4} MLINKS+=nge.4 if_nge.4 MLINKS+=${_nve.4} ${_if_nve.4} +MLINKS+=${_nxge.4} ${_if_nxge.4} MLINKS+=oldcard.4 card.4 MLINKS+=patm.4 if_patm.4 MLINKS+=pccbb.4 cbb.4 MLINKS+=pcm.4 snd.4 \ pcm.4 sound.4 MLINKS+=pcn.4 if_pcn.4 -MLINKS+=pcvt.4 vt.4 MLINKS+=ppp.4 if_ppp.4 MLINKS+=ral.4 if_ral.4 MLINKS+=re.4 if_re.4 MLINKS+=rl.4 if_rl.4 MLINKS+=rue.4 if_rue.4 +MLINKS+=rum.4 if_rum.4 MLINKS+=sbsh.4 if_sbsh.4 MLINKS+=scsi.4 CAM.4 \ scsi.4 cam.4 \ @@ -492,6 +513,9 @@ MLINKS+=sl.4 if_sl.4 MLINKS+=smp.4 SMP.4 MLINKS+=sn.4 if_sn.4 +MLINKS+=snd_envy24.4 snd_ak452x.4 +MLINKS+=snd_sbc.4 snd_sb16.4 \ + snd_sbc.4 snd_sb8.4 MLINKS+=${_spkr.4} ${_speaker.4} MLINKS+=splash.4 screensaver.4 MLINKS+=ste.4 if_ste.4 @@ -500,6 +524,7 @@ MLINKS+=syncache.4 syncookies.4 MLINKS+=syscons.4 sc.4 MLINKS+=tap.4 if_tap.4 +MLINKS+=tdfx.4 tdfx_linux.4 MLINKS+=ti.4 if_ti.4 MLINKS+=tl.4 if_tl.4 MLINKS+=tun.4 if_tun.4 @@ -511,21 +536,35 @@ MLINKS+=vlan.4 if_vlan.4 MLINKS+=vpo.4 imm.4 MLINKS+=vr.4 if_vr.4 +MLINKS+=watchdog.4 SW_WATCHDOG.4 MLINKS+=wb.4 if_wb.4 MLINKS+=wi.4 if_wi.4 +MLINKS+=${_wpi.4} ${_if_wpi.4} MLINKS+=xe.4 if_xe.4 MLINKS+=xl.4 if_xl.4 -MLINKS+=watchdog.4 SW_WATCHDOG.4 .if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" +_acpi_dock.4= acpi_dock.4 _amdsmb.4= amdsmb.4 +_asmc.4= asmc.4 +_coretemp.4= coretemp.4 +_hptiop.4= hptiop.4 +_hptmv.4= hptmv.4 +_hptrr.4= hptrr.4 +_ichwd.4= ichwd.4 +_if_nfe.4= if_nfe.4 _if_nve.4= if_nve.4 +_if_nxge.4= if_nxge.4 +_if_wpi.4= if_wpi.4 _ipmi.4= ipmi.4 +_nfe.4= nfe.4 _nfsmb.4= nfsmb.4 _nve.4= nve.4 +_nxge.4= nxge.4 _rr232x.4= rr232x.4 -_spkr.4= spkr.4 _speaker.4= speaker.4 +_spkr.4= spkr.4 +_wpi.4= wpi.4 .endif .if exists(${.CURDIR}/man4.${MACHINE_ARCH}) Index: src/share/man/man4/aac.4 diff -u src/share/man/man4/aac.4:1.31.2.4 src/share/man/man4/aac.4:1.39 --- src/share/man/man4/aac.4:1.31.2.4 Tue Dec 11 03:33:36 2007 +++ src/share/man/man4/aac.4 Fri Dec 7 02:31:57 2007 @@ -73,7 +73,7 @@ .Pa /dev/afa? and .Pa /dev/hpn? -exist for compatibilty with the Dell and HP versions of management tools, +exist for compatibility with the Dell and HP versions of management tools, respectively. If the kernel is compiled with the .Dv COMPAT_LINUX Index: src/share/man/man4/acpi_dock.4 diff -u /dev/null src/share/man/man4/acpi_dock.4:1.2 --- /dev/null Thu Jan 17 11:57:39 2008 +++ src/share/man/man4/acpi_dock.4 Sat Sep 30 23:14:48 2006 @@ -0,0 +1,62 @@ +.\" Copyright (c) 2006 Christian Brueffer +.\" 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$ +.\" +.Dd May 20, 2006 +.Dt ACPI_DOCK 4 +.Os +.Sh NAME +.Nm acpi_dock +.Nd "Laptop Docking Station device driver" +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device acpi_dock" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +acpi_dock_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for laptop docking stations. +.Sh SEE ALSO +.Xr acpi 4 +.Sh HISTORY +The +.Nm +device driver first appeared in +.Fx 7.0 . +.Sh AUTHORS +The +.Nm +device driver was written by +.An Mitsuru IWASAKI Aq iwasaki@FreeBSD.org . Index: src/share/man/man4/adw.4 diff -u src/share/man/man4/adw.4:1.18.2.1 src/share/man/man4/adw.4:1.20 --- src/share/man/man4/adw.4:1.18.2.1 Wed Jun 21 12:24:09 2006 +++ src/share/man/man4/adw.4 Mon Sep 18 23:24:18 2006 @@ -37,6 +37,7 @@ .Cd "device pci" .Cd "device scbus" .Cd "device adw" +.Ed .Sh DESCRIPTION This driver provides access to the 16bit .Tn SCSI Index: src/share/man/man4/agp.4 diff -u src/share/man/man4/agp.4:1.6.10.2 src/share/man/man4/agp.4:1.11 --- src/share/man/man4/agp.4:1.6.10.2 Sat Dec 31 21:55:08 2005 +++ src/share/man/man4/agp.4 Wed Nov 28 20:04:25 2007 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 20, 2005 +.Dd November 28, 2007 .Dt AGP 4 .Os .Sh NAME @@ -39,18 +39,18 @@ the following devices: .Pp .Bl -tag -width "NVIDIA:" -compact -.It ALI: +.It Ali: M1541, M1621 and M1671 host to AGP bridges .It AMD: 751, 761 and 762 host to AGP bridges .It ATI: RS100, RS200, RS250 and RS300 AGP bridges .It Intel: -i820, i840, i845, i850, and i860 host to AGP bridge +i820, i840, i845, i850, and i860 host to AGP bridges .It Intel: -i810, i810-DC100, i810E, i815, 830M, 845G, 852GM, 852GME, 855GM, 855GME, 865G, 915G and 915GM SVGA controllers +i810, i810-DC100, i810E, i815, 830M, 845G, 845M, 852GM, 852GME, 855GM, 855GME, 865G, 915G and 915GM SVGA controllers .It Intel: -82443BX, 82443GX, 82443LX, 82815, 82820, 82830, 82840, 82845, 82845G, 82850, 82855, 82855GM, 82860, 82865, 82875P and E7205 host to AGP bridges +82443BX, 82443GX, 82443LX, 82815, 82820, 82830, 82840, 82845, 82845G, 82850, 82855, 82855GM, 82860, 82865, 82875P, E7205 and E7505 host to AGP bridges .It NVIDIA: nForce and nForce2 AGP controllers .It SiS: Index: src/share/man/man4/altq.4 diff -u src/share/man/man4/altq.4:1.13.2.11 src/share/man/man4/altq.4:1.32 --- src/share/man/man4/altq.4:1.13.2.11 Tue May 22 02:16:30 2007 +++ src/share/man/man4/altq.4 Tue Jun 12 10:19:11 2007 @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 12, 2007 +.Dd June 12, 2007 .Dt ALTQ 4 .Os .Sh NAME @@ -94,7 +94,7 @@ .Dq "Priority Queuing" discipline. .It Dv ALTQ_NOPCC -Required for SMP builds. +Required if the TSC is unusable. .It Dv ALTQ_DEBUG Enable additional debugging facilities. .El @@ -119,7 +119,7 @@ .Xr ath 4 , .Xr aue 4 , .Xr awi 4 , -.Xr axe 4 , +.Xt axe 4 , .Xr bce 4 , .Xr bfe 4 , .Xr bge 4 , @@ -129,17 +129,21 @@ .Xr em 4 , .Xr ep 4 , .Xr fxp 4 , +.Xr gem 4 , .Xr hme 4 , .Xr ipw 4 , .Xr iwi 4 , .Xr le 4 , -.Xr lnc 4 , .Xr msk 4 , +.Xr mxge 4 , .Xr my 4 , +.Xr nfe 4 , +.Xr npe 4 , .Xr nve 4 , .Xr ral 4 , .Xr re 4 , .Xr rl 4 , +.Xr rum 4 , .Xr sf 4 , .Xr sis 4 , .Xr sk 4 , Index: src/share/man/man4/amdsmb.4 diff -u src/share/man/man4/amdsmb.4:1.2.2.1 src/share/man/man4/amdsmb.4:1.3 --- src/share/man/man4/amdsmb.4:1.2.2.1 Thu Aug 17 19:01:26 2006 +++ src/share/man/man4/amdsmb.4 Sat Sep 30 23:14:48 2006 @@ -38,14 +38,14 @@ The .Nm driver provides access to the AMD-8111 SMBus 2.0 controller. +.Sh SEE ALSO +.Xr smb 4 , +.Xr smbus 4 .Sh HISTORY The .Nm driver first appeared in .Fx 6.2 . -.Sh SEE ALSO -.Xr smb 4 , -.Xr smbus 4 .Sh AUTHORS .An -nosplit The Index: src/share/man/man4/asmc.4 diff -u /dev/null src/share/man/man4/asmc.4:1.3 --- /dev/null Thu Jan 17 11:57:39 2008 +++ src/share/man/man4/asmc.4 Tue Nov 13 19:31:53 2007 @@ -0,0 +1,156 @@ +.\"- +.\" Copyright (c) 2007 Rui Paulo +.\" 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 ``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. +.\" +.\" $FreeBSD$ +.\" +.Dd November 10, 2007 +.Dt ASMC 4 +.Os +.Sh NAME +.Nm asmc +.Nd device driver for the Apple System Management Console (SMC) +.Sh SYNOPSIS +To compile this driver into the kernel, place the following line in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device asmc" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +asmc_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver controls the Apple System Management Console (SMC for short) +found on Intel Apple systems. +.Pp +The SMC is known to be found on the following systems: +.Pp +.Bl -bullet -offset indent -compact +.It +MacBook (any generation) +.It +MacBook Pro (any generation) +.It +Intel MacMini +.El +.Pp +With this driver, you can configure your keyboard backlight +brightness, check temperatures of several sensors, check the speed of +the internal fans and check the status of the Sudden Motion Sensor. +.Pp +Variables related to the SMC control and inspection are exported via +.Xr sysctl 3 +under the device tree +.Va dev.asmc . +.Sh KEYBOARD BACKLIGHT +On +.Tn MacBook Pro +systems, you can control the keyboard brightness by writing values to +the +.Va dev.asmc.%d.light.left +or +.Va dev.asmc.%d.light.right +sysctl MIBs. +.Pp +Each of these sysctl MIBs contains the raw value returned by the left +and right light sensors. +.Sh TEMPERATURES +The number of temperature sensors and their description varies among +systems. +You can inspect the temperature sensors on your system by traversing +the +.Va dev.asmc.temp +sysctl MIB. +.Pp +All values are in degrees celsius. +.Sh SYSTEM FANS +The +.Va dev.asmc.fan.%d +sysctl tree contains the leaf nodes +.Va speed , +.Va safespeed , +.Va minspeed , +.Va maxspeed +and +.Va targetspeed . +Each of these leaf nodes represent the current fan speed, the safest +minimum fan speed, the mininum speed and the maximum speed +respectively. +.Pp +All values are in RPM. +.Sh SUDDEN MOTION SENSOR +The Sudden Motion Sensor (SMS for short) is a device that detects +laptop movement and notifies the operating system via an interrupt. +The sysctl MIBs present under +.Va dev.asmc.sms +all relate to the SMS. +.Pp +The most interesting usage of this device is to park the disk heads +when the laptop is moved harshly. +First, you need to install +.Xr ataidle 8 Pq Pa ports/sysutils/ataidle +and then configure +.Xr devd 8 +the following way: +.Bd -literal -offset indent +notify 0 { + match "system" "ISA"; + match "subsystem" "asmc"; + action "/usr/local/sbin/ataidle -s X Y"; +}; +.Ed +.Pp +Do not forget to change the +.Ar X +and +.Ar Y +values in the command above. +.Pp +Also, please note that parking the disk heads too many times can +dramatically reduce your hard drive's life span. +Do not rely solely on +the SMS to protect your hard drive: good care and common sense can +increase your hard drive's life. +.Sh SEE ALSO +.Xr ataidle 8 Pq Pa ports/sysutils/ataidle , +.Xr devd 8 , +.Xr sysctl 8 +.Sh HISTORY +The +.Nm +driver first appeared in +.Fx 8.0 . +.Sh AUTHORS +.An -nosplit +.An Rui Paulo Aq rpaulo@FreeBSD.org +(Google Summer of Code project). +.Sh BUGS +Support for the latest models was never tested and is most likely not +fully working. Index: src/share/man/man4/ata.4 diff -u src/share/man/man4/ata.4:1.52.2.10 src/share/man/man4/ata.4:1.74 --- src/share/man/man4/ata.4:1.52.2.10 Mon Feb 12 13:37:55 2007 +++ src/share/man/man4/ata.4 Fri Oct 5 15:06:51 2007 @@ -27,7 +27,7 @@ .\" .\" $FreeBSD$ .\" -.Dd February 8, 2007 +.Dd October 5, 2007 .Dt ATA 4 .Os .Sh NAME @@ -107,7 +107,7 @@ .It ALI: M5229, M5281, M5287, M5288, M5289. .It AMD: -AMD756, AMD766, AMD768, AMD8111. +AMD756, AMD766, AMD768, AMD8111, CS5536. .It ATI: IXP200, IXP300, IXP400. .It CMD: @@ -119,13 +119,13 @@ .It HighPoint: HPT302, HPT366, HPT368, HPT370, HPT371, HPT372, HPT372N, HPT374. .It Intel: -6300ESB, 31244, PIIX, PIIX3, PIIX4, ESB2, ICH, ICH0, ICH2, ICH3, ICH4, ICH5, ICH6, ICH7, ICH8. +6300ESB, 31244, PIIX, PIIX3, PIIX4, ESB2, ICH, ICH0, ICH2, ICH3, ICH4, ICH5, ICH6, ICH7, ICH8, ICH9. .It ITE: IT8211F, IT8212F. .It JMicron: -JMB360, JMB361, JMB363, JMB365, JMB366. +JMB360, JMB361, JMB363, JMB365, JMB366, JMB368. .It Marvell -88SX5040, 88SX5041, 88SX5080, 88SX5081, 88SX6041, 88SX6081. +88SX5040, 88SX5041, 88SX5080, 88SX5081, 88SX6041, 88SX6081, 88SX6101, 88SX6141. .It National: SC1100. .It NetCell: @@ -137,11 +137,11 @@ .It ServerWorks: HT1000, ROSB4, CSB5, CSB6, K2, Frodo4, Frodo8. .It Silicon Image: -SiI0680, SiI3112, SiI3114, SiI3512. +SiI0680, SiI3112, SiI3114, SiI3124, SiI3132, SiI3512. .It SiS: SIS180, SIS181, SIS182, SIS5513, SIS530, SIS540, SIS550, SIS620, SIS630, SIS630S, SIS633, SIS635, SIS730, SIS733, SIS735, SIS745, SIS961, SIS962, SIS963, SIS964, SIS965. .It VIA: -VT6410, VT6420, VT6421, VT82C586, VT82C586B, VT82C596, VT82C596B, VT82C686, VT82C686A, VT82C686B, VT8231, VT8233, VT8233A, VT8233C, VT8235, VT8237, VT8237A, VT8251. +VT6410, VT6420, VT6421, VT82C586, VT82C586B, VT82C596, VT82C596B, VT82C686, VT82C686A, VT82C686B, VT8231, VT8233, VT8233A, VT8233C, VT8235, VT8237, VT8237A, VT8237S, VT8251. .El .Pp Unknown ATA chipsets are supported in PIO modes, and if the standard Index: src/share/man/man4/ataraid.4 diff -u src/share/man/man4/ataraid.4:1.3.2.3 src/share/man/man4/ataraid.4:1.10 --- src/share/man/man4/ataraid.4:1.3.2.3 Mon Feb 20 02:33:07 2006 +++ src/share/man/man4/ataraid.4 Mon Sep 18 23:24:18 2006 @@ -137,7 +137,7 @@ .Xr atacontrol 8 .Sh CAVEATS RAID5 is not supported at this time. -Code exists, but it neither uses nor maintains parity information. +Code exists, but it neither uses nor maintains parity information. .Sh AUTHORS .An -nosplit The Index: src/share/man/man4/ath.4 diff -u src/share/man/man4/ath.4:1.31.2.5 src/share/man/man4/ath.4:1.43 --- src/share/man/man4/ath.4:1.31.2.5 Sat Mar 3 04:47:06 2007 +++ src/share/man/man4/ath.4 Sun Jul 1 18:25:06 2007 @@ -262,7 +262,6 @@ .Xr wi 4 , .Xr wlan 4 , .Xr ifconfig 8 , -.Xr wicontrol 8 .Sh HISTORY The .Nm @@ -274,9 +273,6 @@ See .Xr ifconfig 8 for information on how to change the channel. -See -.Xr wicontrol 8 -for information on different regulatory domains. Different regulatory domains may not be able to communicate with each other with 802.11a as different regulatory domains do not necessarily have overlapping channels. Index: src/share/man/man4/atkbd.4 diff -u src/share/man/man4/atkbd.4:1.25 src/share/man/man4/atkbd.4:1.28 --- src/share/man/man4/atkbd.4:1.25 Thu Dec 16 07:01:45 2004 +++ src/share/man/man4/atkbd.4 Mon Sep 18 23:24:18 2006 @@ -50,10 +50,8 @@ driver, provides access to the AT 84 keyboard or the AT enhanced keyboard which is connected to the AT keyboard controller. .Pp -This driver is required for the console drivers -.Xr syscons 4 -and -.Xr pcvt 4 . +This driver is required for the console driver +.Xr syscons 4 . .Pp There can be only one .Nm @@ -199,14 +197,12 @@ .Dl hint.atkbdc.0.port="0x060" .Dl hint.atkbd.0.at="atkbdc" .Dl hint.atkbd.0.irq="1" -.Pp .\".Sh DIAGNOSTICS .\".Sh CAVEATS .\".Sh BUGS .Sh SEE ALSO .Xr kbdcontrol 1 , .Xr atkbdc 4 , -.Xr pcvt 4 , .Xr psm 4 , .Xr syscons 4 , .Xr loader 8 Index: src/share/man/man4/audit.4 diff -u src/share/man/man4/audit.4:1.8.2.1 src/share/man/man4/audit.4:1.10 --- src/share/man/man4/audit.4:1.8.2.1 Sat Sep 2 19:59:31 2006 +++ src/share/man/man4/audit.4 Fri Dec 15 00:40:57 2006 @@ -39,7 +39,8 @@ evaluation. The .Fx -audit facility implements the de facto industry standard BSM API, file +.Nm +facility implements the de facto industry standard BSM API, file formats, and command line interface, first found in the Solaris operating system. Information on the user space implementation can be found in @@ -50,22 +51,28 @@ flag. The audit daemon, .Xr auditd 8 , -is responsible for configuring the kernel to perform audit, pushing +is responsible for configuring the kernel to perform +.Nm , +pushing configuration data from the various audit configuration files into the kernel. .Ss Audit Special Device -The kernel audit facility provides a special device, +The kernel +.Nm +facility provides a special device, .Pa /dev/audit , which is used by .Xr auditd 8 -to monitor for audit events, such as requests to cycle the log, low disk +to monitor for +.Nm +events, such as requests to cycle the log, low disk space conditions, and requests to terminate auditing. This device is not intended for use by applications. .Ss Audit Pipe Special Devices Audit pipe special devices, discussed in .Xr auditpipe 4 , provide a configurable live tracking mechanism to allow applications to -tee the audit trail, as well as to configure custom preselection paramaters +tee the audit trail, as well as to configure custom preselection parameters to track users and events in a fine-grained manner. .Sh SEE ALSO .Xr auditreduce 1 , @@ -81,35 +88,45 @@ .Xr setauid 2 , .Xr libbsm 3 , .Xr auditpipe 4 , -.Xr audit.log 5 , .Xr audit_class 5 , .Xr audit_control 5 , .Xr audit_event 5 , +.Xr audit.log 5 , .Xr audit_user 5 , .Xr audit_warn 5 , .Xr rc.conf 5 , .Xr audit 8 , .Xr auditd 8 +.Sh HISTORY +The +.Tn OpenBSM +implementation was created by McAfee Research, the security +division of McAfee Inc., under contract to Apple Computer Inc.\& in 2004. +It was subsequently adopted by the TrustedBSD Project as the foundation for +the OpenBSM distribution. +.Pp +Support for kernel +.Nm +first appeared in +.Fx 6.2 . .Sh AUTHORS +.An -nosplit This software was created by McAfee Research, the security research division of McAfee, Inc., under contract to Apple Computer Inc. -Additional authors include Wayne Salamon, Robert Watson, and SPARTA Inc. +Additional authors include +.An Wayne Salamon , +.An Robert Watson , +and SPARTA Inc. .Pp The Basic Security Module (BSM) interface to audit records and audit event stream format were defined by Sun Microsystems. .Pp This manual page was written by .An Robert Watson Aq rwatson@FreeBSD.org . -.Sh HISTORY -The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 2004. -It was subsequently adopted by the TrustedBSD Project as the foundation for -the OpenBSM distribution. -.Pp -Support for kernel audit first appeared in -.Fx 6.2 . .Sh BUGS -The audit facility in +The +.Nm +facility in .Fx is considered experimental, and production deployment should occur only after careful consideration of the risks of deploying experimental software. Index: src/share/man/man4/auditpipe.4 diff -u src/share/man/man4/auditpipe.4:1.3.2.1 src/share/man/man4/auditpipe.4:1.5 --- src/share/man/man4/auditpipe.4:1.3.2.1 Sat Sep 2 19:59:31 2006 +++ src/share/man/man4/auditpipe.4 Fri Dec 15 00:40:57 2006 @@ -29,7 +29,7 @@ .Dt AUDITPIPE 4 .Sh NAME .Nm auditpipe -.Nd Pseudo-device for live audit event tracking +.Nd "pseudo-device for live audit event tracking" .Sh SYNOPSIS .Cd "options AUDIT" .Sh DESCRIPTION @@ -50,7 +50,7 @@ monitoring. Audit pipes are available via a clonable special device, .Pa /dev/auditpipe , -subject to the permissions on the device node, and provide a +subject to the permissions on the device node, and provide a .Qq tee of the audit event stream. As the device is clonable, more than one instance of the device may be opened @@ -64,7 +64,9 @@ delivery is not guaranteed. In particular, when an audit pipe queue fills, records will be dropped. Audit pipe devices are blocking by default, but support non-blocking I/O, -asynchronous I/O using SIGIO, and polled operation via +asynchronous I/O using +.Dv SIGIO , +and polled operation via .Xr select 2 and .Xr poll 2 . @@ -74,28 +76,28 @@ .Ss Audit Pipe Queue Ioctls The following ioctls retrieve and set various audit pipe record queue properties: -.Bl -tag -width AUDITPIPE_GET_MAXAUDITDATA -.It AUDITPIPE_GET_QLEN +.Bl -tag -width ".Dv AUDITPIPE_GET_MAXAUDITDATA" +.It Dv AUDITPIPE_GET_QLEN Query the current number of records available for reading on the pipe. -.It AUDITPIPE_GET_QLIMIT +.It Dv AUDITPIPE_GET_QLIMIT Retrieve the current maximum number of records that may be queued for reading on the pipe. -.It AUDITPIPE_SET_QLIMIT +.It Dv AUDITPIPE_SET_QLIMIT Set the current maximum number of records that may be queued for reading on the pipe. The new limit must fall between the queue limit minimum and queue limit maximum queryable using the following two ioctls. -.It AUDITPIPE_GET_QLIMIT_MIN +.It Dv AUDITPIPE_GET_QLIMIT_MIN Query the lowest possible maximum number of records that may be queued for reading on the pipe. -.It AUDITPIPE_GET_QLIMIT_MAX +.It Dv AUDITPIPE_GET_QLIMIT_MAX Query the highest possible maximum number of records that may be queued for reading on the pipe. -.It AUDITPIPE_FLUSH +.It Dv AUDITPIPE_FLUSH Flush all outstanding records on the audit pipe; useful after setting initial preselection properties to delete records queued during the configuration process which may not match the interests of the user process. -.It AUDITPIPE_GET_MAXAUDITDATA +.It Dv AUDITPIPE_GET_MAXAUDITDATA Query the maximum size of an audit record, which is a useful minimum size for a user space buffer intended to hold audit records read from the audit pipe. .El @@ -111,23 +113,23 @@ the application. .Pp The following ioctls configure the preselection mode on an audit pipe: -.Bl -tag -width AUDITPIPE_GET_PRESELECT_MODE -.It AUDITPIPE_GET_PRESELECT_MODE +.Bl -tag -width ".Dv AUDITPIPE_GET_PRESELECT_MODE" +.It Dv AUDITPIPE_GET_PRESELECT_MODE Return the current preselect mode on the audit pipe. The ioctl argument should be of type .Vt int . -.It AUDITPIPE_SET_PRESELECT_MODE +.It Dv AUDITPIPE_SET_PRESELECT_MODE Set the current preselection mode on the audit pipe. The ioctl argument should be of type .Vt int . .El .Pp Possible preselection mode values are: -.Bl -tag -width AUDITPIPE_PRESELECT_MODE_TRAIL -.It AUDITPIPE_PRESELECT_MODE_TRAIL +.Bl -tag -width ".Dv AUDITPIPE_PRESELECT_MODE_TRAIL" +.It Dv AUDITPIPE_PRESELECT_MODE_TRAIL Use the global audit trail preselection parameters to select records for the audit pipe. -.It AUDITPIPE_PRESELECT_MODE_LOCAL +.It Dv AUDITPIPE_PRESELECT_MODE_LOCAL Use local audit pipe preselection; this model is similar to the global audit trail configuration model, consisting of global flags and naflags parameters, as well as a set of per-auid masks. @@ -143,47 +145,47 @@ pipe is configured for the .Dv AUDITPIPE_PRESELECT_MODE_LOCAL preselection mode. -.Bl -tag -width AUDITPIPE_GET_PRESELECT_NAFLAGS -.It AUDITPIPE_GET_PRESELECT_FLAGS +.Bl -tag -width ".Dv AUDITPIPE_GET_PRESELECT_NAFLAGS" +.It Dv AUDITPIPE_GET_PRESELECT_FLAGS Retrieve the current default preselection flags for attributable events on the pipe. These flags correspond to the -.Dv flags +.Va flags field in .Xr audit_control 5 . The ioctl argument should be of type .Vt u_int . -.It AUDITPIPE_SET_PRESELECT_FLAGS +.It Dv AUDITPIPE_SET_PRESELECT_FLAGS Set the current default preselection flags for attributable events on the pipe. These flags correspond to the -.Dv flags +.Va flags field in .Xr audit_control 5 . The ioctl argument should be of type .Vt u_int . -.It AUDITPIPE_GET_PRESELECT_NAFLAGS +.It Dv AUDITPIPE_GET_PRESELECT_NAFLAGS Retrieve the current default preselection flags for non-attributable events on the pipe. These flags correspond to the -.Dv naflags +.Va naflags field in .Xr audit_control 5 . The ioctl argument should be of type .Vt u_int . -.It AUDITPIPE_SET_PRESELECT_NAFLAGS +.It Dv AUDITPIPE_SET_PRESELECT_NAFLAGS Set the current default preselection flags for non-attributable events on the pipe. These flags correspond to the -.Dv naflags +.Va naflags field in .Xr audit_control 5 . The ioctl argument should be of type .Vt u_int . -.It AUDITPIPE_GET_PRESELECT_AUID +.It Dv AUDITPIPE_GET_PRESELECT_AUID Query the current preselection masks for a specific auid on the pipe. The ioctl argument should be of type -.Vt struct auditpipe_preselect . +.Vt "struct auditpipe_preselect" . The auid to query is specified via the .Va ap_auid field of type @@ -192,24 +194,26 @@ .Va ap_mask of type .Vt au_mask_t . -.It AUDITPIPE_SET_PRESELECT_AUID +.It Dv AUDITPIPE_SET_PRESELECT_AUID Set the current preselection masks for a specific auid on the pipe. Arguments are identical to -.Dv AUDITPIPE_GET_PRESELECT_AUID, +.Dv AUDITPIPE_GET_PRESELECT_AUID , except that the caller should properly initialize the .Va ap_mask field to hold the desired preselection mask. -.It AUDITPIPE_DELETE_PRESELECT_AUID +.It Dv AUDITPIPE_DELETE_PRESELECT_AUID Delete the current preselection mask for a specific auid on the pipe. Once called, events associated with the specified auid will use the default flags mask. The ioctl argument should be of type .Vt au_id_t . -.It AUDITPIPE_FLUSH_PRESELECT_AUID +.It Dv AUDITPIPE_FLUSH_PRESELECT_AUID Delete all auid specific preselection specifications. .El .Sh EXAMPLES +The .Xr praudit 1 +utility may be directly executed on .Pa /dev/auditpipe to review the default audit trail. @@ -220,20 +224,20 @@ .Xr audit_control 5 , .Xr audit 8 , .Xr auditd 8 -.Sh AUTHORS -The audit pipe facility was designed and implemented by -.An Robert Watson Aq rwatson@FreeBSD.org . -.Pp -The Basic Security Module (BSM) interface to audit records and audit event -stream format were defined by Sun Microsystems. .Sh HISTORY The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 2004. +division of McAfee Inc., under contract to Apple Computer Inc.\& in 2004. It was subsequently adopted by the TrustedBSD Project as the foundation for the OpenBSM distribution. .Pp Support for kernel audit first appeared in .Fx 6.2 . +.Sh AUTHORS +The audit pipe facility was designed and implemented by +.An Robert Watson Aq rwatson@FreeBSD.org . +.Pp +The Basic Security Module (BSM) interface to audit records and audit event +stream format were defined by Sun Microsystems. .Sh BUGS See the .Xr audit 4 @@ -243,7 +247,7 @@ for the global audit trail. It might be desirable to provided a more flexible selection model. .Pp -The per-pipe audit event queue is fifo, with drops occuring if either the +The per-pipe audit event queue is fifo, with drops occurring if either the user thread provides in sufficient for the record on the queue head, or on enqueue if there is insufficient room. It might be desirable to support partial reads of records, which would be Index: src/share/man/man4/aue.4 diff -u src/share/man/man4/aue.4:1.21.2.4 src/share/man/man4/aue.4:1.26 --- src/share/man/man4/aue.4:1.21.2.4 Fri Feb 16 21:55:23 2007 +++ src/share/man/man4/aue.4 Sun Feb 4 03:29:31 2007 @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 14, 2006 +.Dd October 7, 2006 .Dt AUE 4 .Os .Sh NAME Index: src/share/man/man4/bce.4 diff -u src/share/man/man4/bce.4:1.2.2.4 src/share/man/man4/bce.4:1.8 --- src/share/man/man4/bce.4:1.2.2.4 Tue Feb 27 05:11:38 2007 +++ src/share/man/man4/bce.4 Mon Jun 25 02:36:07 2007 @@ -1,34 +1,34 @@ -.\"Copyright (c) 2006 Broadcom Corporation -.\" David Christensen . All rights reserved. +.\" Copyright (c) 2006 Broadcom Corporation +.\" David Christensen . All rights reserved. .\" -.\"Redistribution and use in source and binary forms, with or without -.\"modification, are permitted provided that the following conditions -.\"are met: +.\" 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. Neither the name of Broadcom Corporation nor the name of its contributors -.\" may be used to endorse or promote products derived from this software -.\" without specific prior written consent. +.\" 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. Neither the name of Broadcom Corporation nor the name of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written consent. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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. .\" -.\"THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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$ .\" -.Dd February 9, 2007 +.Dd June 24, 2007 .Dt BCE 4 .Os .Sh NAME @@ -52,24 +52,32 @@ .Sh DESCRIPTION The .Nm -driver supports Broadcom's NetXtreme II product family, including the +driver supports Broadcom's NetXtreme II product family, including the BCM5706 and BCM5708 Ethernet controllers. .Pp -The NetXtreme II product family is composed of various Converged NIC (or CNIC) -Ethernet controllers which support a TCP Offload Engine (TOE), Remote DMA (RDMA), -and iSCSI acceleration, in addition to standard L2 Ethernet traffic, all on the +The NetXtreme II product family is composed of various Converged NIC (or CNIC) +Ethernet controllers which support a TCP Offload Engine (TOE), Remote DMA (RDMA), +and iSCSI acceleration, in addition to standard L2 Ethernet traffic, all on the same controller. -The following features are supported in the +The following features are supported in the .Nm -driver under FreeBSD: -.Bd -literal -offset indent +driver under +.Fx : +.Pp +.Bl -item -offset indent -compact +.It IP/TCP/UDP checksum offload +.It Jumbo frames (up to 9022 bytes) +.It VLAN tag stripping +.It Interrupt coalescing +.It 10/100/1000Mbps operation in full-duplex mode +.It 10/100Mbps operation in half-duplex mode -.Ed +.El .Pp The .Nm @@ -84,7 +92,7 @@ Set 10Mbps operation. The .Xr ifconfig 8 -.Ic mediaopt +.Cm mediaopt option can also be used to select either .Cm full-duplex or @@ -94,7 +102,7 @@ Set 100Mbps (Fast Ethernet) operation. The .Xr ifconfig 8 -.Ic mediaopt +.Cm mediaopt option can also be used to select either .Cm full-duplex or @@ -132,6 +140,17 @@ .It HP NC370i Multifunction Gigabit Server Adapter .El +.Sh SYSCTL VARIABLES +The following variables are available as both +.Xr sysctl 8 +variables and +.Xr loader 8 +tunables: +.Bl -tag -width indent +.It Va hw.bce.msi_enable +Whether or not MSI support is enabled in the driver. +The default value is 1. +.El .Sh DIAGNOSTICS .Bl -diag .It "bce%d: PCI memory allocation failed!" @@ -226,7 +245,7 @@ controller. The firmware may be stopped or hung. .It "bce%d: Invalid Ethernet address!" -The driver was not able to read a vaild Ethernet MAC address from NVRAM. +The driver was not able to read a valid Ethernet MAC address from NVRAM. .It "bce%d: Reset failed!" The driver has encountered a fatal initialization error. .It "bce%d: Byte swap is incorrect!" Index: src/share/man/man4/bge.4 diff -u src/share/man/man4/bge.4:1.18.2.7 src/share/man/man4/bge.4:1.33 --- src/share/man/man4/bge.4:1.18.2.7 Fri Feb 16 21:55:23 2007 +++ src/share/man/man4/bge.4 Wed Dec 26 03:53:26 2007 @@ -31,12 +31,12 @@ .\" .\" $FreeBSD$ .\" -.Dd January 30, 2007 +.Dd December 25, 2007 .Dt BGE 4 .Os .Sh NAME .Nm bge -.Nd "Broadcom BCM570x/5714/5721/5750/5751/5752/5789 PCI Gigabit Ethernet adapter driver" +.Nd "Broadcom BCM570x/5714/5721/5722/5750/5751/5752/5789 PCI Gigabit Ethernet adapter driver" .Sh SYNOPSIS To compile this driver into the kernel, place the following lines in your @@ -56,7 +56,7 @@ The .Nm driver provides support for various NICs based on the Broadcom BCM570x, -5714, 5721, 5750, 5751, 5752 and 5789 families of Gigabit Ethernet +5714, 5721, 5722, 5750, 5751, 5752 and 5789 families of Gigabit Ethernet controller chips. .Pp All of these NICs are capable of 10, 100 and 1000Mbps speeds over CAT5 @@ -194,6 +194,8 @@ .It HP ProLiant NC7770 PCI-X Gigabit NIC (10/100/1000baseTX) .It +HP ProLiant NC7771 PCI-X Gigabit NIC (10/100/1000baseTX) +.It HP ProLiant NC7781 embedded PCI-X Gigabit NIC (10/100/1000baseTX) .It Netgear GA302T (10/100/1000baseTX) @@ -202,6 +204,17 @@ .It SysKonnect SK-9D41 (1000baseSX) .El +.Sh LOADER TUNABLES +The following tunable can be set at the +.Xr loader 8 +prompt before booting the kernel, or stored in +.Xr loader.conf 5 . +.Bl -tag -width indent +.It Va hw.bge.allow_asf +Allow the ASF feature for cooperating with IPMI. +Can cause system lockup problems on a small number of systems. +Enabled by default. +.El .Sh DIAGNOSTICS .Bl -diag .It "bge%d: couldn't map memory" Index: src/share/man/man4/bktr.4 diff -u src/share/man/man4/bktr.4:1.29.2.1 src/share/man/man4/bktr.4:1.31 --- src/share/man/man4/bktr.4:1.29.2.1 Sat Jan 21 23:00:14 2006 +++ src/share/man/man4/bktr.4 Sat Jan 21 22:58:25 2006 @@ -1,7 +1,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 21, 2006 +.Dd January 18, 2006 .Dt BKTR 4 .Os .Sh NAME Index: src/share/man/man4/blackhole.4 diff -u src/share/man/man4/blackhole.4:1.12 src/share/man/man4/blackhole.4:1.14 --- src/share/man/man4/blackhole.4:1.12 Fri Jan 21 16:36:37 2005 +++ src/share/man/man4/blackhole.4 Tue Jan 2 05:22:32 2007 @@ -12,7 +12,7 @@ .\" .\" .\" $FreeBSD$ -.Dd August 17, 1999 +.Dd January 1, 2007 .Dt BLACKHOLE 4 .Os .Sh NAME @@ -58,12 +58,11 @@ of service attack. .Sh WARNING The TCP and UDP blackhole features should not be regarded as a replacement -for -.Xr ipfw 8 -as a tool for firewalling a system. -In order to create a highly secure system, -.Xr ipfw 8 -should be used for protection, not the blackhole feature. +for firewall solutions. +Better security would consist of the +.Nm +.Xr sysctl 8 +MIB used in conjuction with one of the available firewall packages. .Pp This mechanism is not a substitute for securing a system. It should be used together with other security mechanisms. @@ -71,7 +70,9 @@ .Xr ip 4 , .Xr tcp 4 , .Xr udp 4 , +.Xr ipf 8 , .Xr ipfw 8 , +.Xr pfctl 8 , .Xr sysctl 8 .Sh HISTORY The TCP and UDP Index: src/share/man/man4/bpf.4 diff -u src/share/man/man4/bpf.4:1.45 src/share/man/man4/bpf.4:1.48 --- src/share/man/man4/bpf.4:1.45 Mon Feb 14 06:25:17 2005 +++ src/share/man/man4/bpf.4 Tue Feb 27 06:24:14 2007 @@ -22,7 +22,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 16, 1996 +.Dd February 26, 2007 .Dt BPF 4 .Os .Sh NAME @@ -231,7 +231,7 @@ The default for a new file is off. .It Dv BIOCSETF .Pq Li "struct bpf_program" -Sets the filter program used by the kernel to discard uninteresting +Sets the read filter program used by the kernel to discard uninteresting packets. An array of instructions and its length is passed in using the following structure: @@ -255,6 +255,16 @@ See section .Sx "FILTER MACHINE" for an explanation of the filter language. +.It Dv BIOCSETWF +.Pq Li "struct bpf_program" +Sets the write filter program used by the kernel to control what type of +packets can be written to the interface. +See the +.Dv BIOCSETF +command for more +information on the +.Nm +filter program. .It Dv BIOCVERSION .Pq Li "struct bpf_version" Returns the major and minor version numbers of the filter language currently @@ -295,12 +305,50 @@ .It Dv BIOCSSEESENT .It Dv BIOCGSEESENT .Pq Li u_int +These commands are obsolete but left for compatibility. +Use +.Dv BIOCSDIRECTION +and +.Dv BIOCGDIRECTION +instead. Set or get the flag determining whether locally generated packets on the interface should be returned by BPF. Set to zero to see only incoming packets on the interface. Set to one to see packets originating locally and remotely on the interface. -This flag is initialized to one by -default. +This flag is initialized to one by default. +.It Dv BIOCSDIRECTION +.It Dv BIOCGDIRECTION +.Pq Li u_int +Set or get the setting determining whether incoming, outgoing, or all packets +on the interface should be returned by BPF. +Set to +.Dv BPF_D_IN +to see only incoming packets on the interface. +Set to +.Dv BPF_D_INOUT +to see packets originating locally and remotely on the interface. +Set to +.Dv BPF_D_OUT +to see only outgoing packets on the interface. +This setting is initialized to +.Dv BPF_D_INOUT +by default. +.It Dv BIOCFEEDBACK +.Pq Li u_int +Set packet feedback mode. +This allows injected packets to be fed back as input to the interface when +output via the interface is successful. +When +.Dv BPF_D_INOUT +direction is set, injected outgoing packet is not returned by BPF to avoid +duplication. This flag is initialized to zero by default. +.It Dv BIOCLOCK +Set the locked flag on the +.Nm +descriptor. +This prevents the execution of +ioctl commands which could change the underlying operating parameters of +the device. .El .Sh BPF HEADER The following structure is prepended to each packet returned by @@ -718,9 +766,12 @@ Data link protocols with variable length headers are not currently supported. .Pp The -.Dv SEESENT -flag has been observed to work incorrectly on some interface +.Dv SEESENT , +.Dv DIRECTION , +and +.Dv FEEDBACK +settings have been observed to work incorrectly on some interface types, including those with hardware loopback rather than software loopback, and point-to-point interfaces. -It appears to function correctly on a +They appear to function correctly on a broad range of Ethernet-style interfaces. Index: src/share/man/man4/bridge.4 diff -u src/share/man/man4/bridge.4:1.24.2.1 src/share/man/man4/bridge.4:removed --- src/share/man/man4/bridge.4:1.24.2.1 Wed Sep 28 02:51:02 2005 +++ src/share/man/man4/bridge.4 Thu Jan 17 11:57:39 2008 @@ -1,260 +0,0 @@ -.\" -.\" $FreeBSD$ -.\" -.Dd September 27, 2005 -.Dt BRIDGE 4 -.Os -.Sh NAME -.Nm bridge -.Nd bridging support -.Sh SYNOPSIS -.Cd "options BRIDGE" -.Sh DESCRIPTION -.Bf -symbolic -This bridge implementation is made obsolete by: -.Ef -.Xr if_bridge 4 -.Bf -symbolic -and will be removed from future releases. -.Ef -.Pp -.Fx -supports bridging on Ethernet-type interfaces, including VLANs. -Bridging support can be either compiled into the kernel, or loaded -at runtime as a kernel module. -.Pp -A single -.Fx -host can do bridging on independent sets of interfaces, -which are called -.Dq clusters . -Each cluster connects a set of interfaces, and is -identified by a -.Dq cluster-ID -which is a number in the range 1..65535. -A cluster in fact is very similar to what commercial switches call -a -.Dq VLAN . -Note however that there is no relation whatsoever -between the cluster-ID and the IEEE 802.1q VLAN-ID which appears -in the header of packets transmitted on the wire. -In fact, in most cases there is no relation between the -so-called -.Dq "VLAN identifier" -used in most commercial switches, and -the IEEE 802.1q VLAN-ID. -.Pp -By putting both physical and logical -.Pq Xr vlan 4 -interfaces in the same cluster, a -.Fx -box can also implement what in commercial terms is called a -.Dq trunk -interface. -This means that packets -coming from one of the interfaces in a cluster -will appear on the wire of the -.Dq parent -interface of any VLAN interface in a cluster, -with the proper VLAN tag. -Similarly, packets -coming from a parent interface of any VLAN interface in a cluster -will have the VLAN tag stripped, -and will be forwarded to other interfaces in a cluster. -See the -.Sx EXAMPLES -section for more details. -.Pp -Runtime operation of the -.Nm -is controlled by several -.Xr sysctl 8 -variables, as follows. -.Bl -tag -width indent -.It Va net.link.ether.bridge.enable -Set to -.Li 1 -to enable bridging, set to -.Li 0 -to disable it. -.It Va net.link.ether.bridge.ipfw -Set to -.Li 1 -to enable -.Xr ipfw 8 -processing of bridged packets. -Note that -.Xr ipfw 8 -rules only apply -to IP packets. -Non-IP packets are accepted by default. -See the -.Sx BUGS -section and the -.Xr ipfw 8 -manpage for more details on the interaction of bridging -and the firewall. -.It Va net.link.ether.bridge.ipf -Set to -.Li 1 -to enable -.Xr ipf 8 -processing of bridged packets. -Note that -.Xr ipf 8 -rules only apply -to IP packets. -Non-IP packets are accepted by default. -.It Va net.link.ether.bridge.config -Set to the list of interfaces to bridge. -Interfaces are separated by spaces, commas or tabs. -Each interface -can be optionally followed by a colon and an integer indicating the -cluster it belongs to (defaults to 1 if the cluster-ID is missing), e.g.\& -.Dq Li "dc0:1,dc1,vlan0:3 dc2:3" -will put -.Li dc0 -and -.Li dc1 -in cluster number 1, and -.Li vlan0 -and -.Li dc2 -in cluster -number 3. -See the -.Sx EXAMPLES -section for more examples. -.Pp -The list of interfaces is rescanned every time the list is -modified, bridging is enabled, or new interfaces are created or -destroyed. -An explicit request to refresh the -.Nm -configuration can also -be done by writing any value to -.Va net.link.ether.bridge.refresh . -Interfaces that are in the list but cannot be used -for bridging (because they are non-existing, or not Ethernet or VLAN) -are not used and a warning message is generated. -.El -.Pp -Bridging requires interfaces to be put in promiscuous mode, -and transmit packets with Ethernet source addresses different -than their own. -Some interfaces (e.g.\& -.Xr wi 4 ) -do not support this functionality. -Also, bridging is not compatible with interfaces which -use hardware loopback, because there is no way to tell locally -generated packets from externally generated ones. -.Sh FILES -.Bl -tag -width ".Pa /boot/kernel/bridge.ko" -compact -.It Pa /boot/kernel/bridge.ko -.Nm -loadable module. -.El -.Sh EXAMPLES -A simple -.Nm -configuration with three interfaces in the same -cluster can be set as follows. -No cluster-ID is specified here, which -will cause the interfaces to appear as part of cluster #1. -.Pp -.Dl "sysctl net.link.ether.bridge.config=dc0,dc1,fxp1" -.Pp -If you do not know what actual interfaces will be present on -your system, you can just put all existing interfaces in the -configuration, as follows: -.Pp -.Dl sysctl net.link.ether.bridge.config="`ifconfig -l`" -.Pp -This will result in a space-separated list of interfaces. -Out of the list, only Ethernet and VLAN interfaces will be -used for bridging, whereas for others the kernel will produce -a warning message. -.Pp -More complex configurations can be used to create multiple -clusters, e.g.\& -.Pp -.Dl "sysctl net.link.ether.bridge.config=dc0:3,dc1:3,fxp0:4,fxp1:4" -.Pp -will create two completely independent clusters. -.Pp -Finally, interesting configurations involve VLANs and parent interfaces. -As an example, the following configuration will use interface -.Li dc0 -as a -.Dq trunk -interface, and pass packets -for 802.1q VLANs 10 and 20 to physical interfaces -.Li dc1 -and -.Li dc2 , -respectively: -.Bd -literal -offset indent -sysctl net.link.ether.bridge.config=vlan0:34,dc1:34,vlan1:56,dc2:56 -ifconfig vlan0 vlan 10 vlandev dc0 -ifconfig vlan1 vlan 20 vlandev dc0 -.Ed -.Pp -Note how there is no relation between the 802.1q VLAN identifiers -(10 and 20) and the cluster-ID's (34 and 56) used in -the -.Va bridge.config -variable. -.Pp -Note also that the trunk interface -does not even appear in the -.Va bridge.config , -as VLAN tag insertion/removal -is performed by the -.Xr vlan 4 -devices. -When using VLAN devices, care must be taken by not creating loops -between these devices and their parent interfaces. -.Sh SEE ALSO -.Xr ip 4 , -.Xr ng_bridge 4 , -.Xr vlan 4 , -.Xr ipf 8 , -.Xr ipfw 8 , -.Xr sysctl 8 -.Sh HISTORY -Bridging was introduced in -.Fx 2.2.8 -by -.An Luigi Rizzo Aq luigi@iet.unipi.it . -.Sh BUGS -Care must be taken not to construct loops in the -.Nm -topology. -The kernel supports only a primitive form of loop detection, by disabling -some interfaces when a loop is detected. -No support for a daemon running the -spanning tree algorithm is currently provided. -.Pp -With bridging active, interfaces are in promiscuous mode, -thus causing some load on the system to receive and filter -out undesired traffic. -.Pp -When passing bridged packets to -.Xr ipfw 8 , -remember that only IP packets are passed to the firewall, while -other packets are silently accepted. -Also remember that bridged packets are accepted after the -first pass through the firewall irrespective of the setting -of the sysctl variable -.Va net.inet.ip.fw.one_pass , -and that some -.Xr ipfw 8 -actions such as -.Cm divert -do not apply to bridged packets. -It might be useful to have a rule of the form -.Pp -.Dl "skipto 20000 ip from any to any bridged" -.Pp -near the beginning of your ruleset to implement specific rulesets -for bridged packets. Index: src/share/man/man4/cardbus.4 diff -u src/share/man/man4/cardbus.4:1.4 src/share/man/man4/cardbus.4:1.6 --- src/share/man/man4/cardbus.4:1.4 Fri Dec 13 17:06:44 2002 +++ src/share/man/man4/cardbus.4 Fri Nov 18 18:52:22 2005 @@ -39,6 +39,21 @@ The .Nm driver supports all cardbus bridges in the system. +.Sh TUNABLES +The driver supports the following tunable parameters, which may be +added to +.Pa /boot/loader.conf +or set via the +.Xr sysctl 8 +command: +.Bl -tag -width ".Cm hw.cardbus.cis_debug" -compact +.It Cm hw.cardbus.debug +Non-zero values cause more verbose information to be printed when a +32-bit CardBus card is inserted or removed. +.It Cm hw.cardbus.cis_debug +Non-zero value causes the CIS parsing of the 32-bit CardBus card to be +much more verbose and include a complete CIS dump. +.El .Sh SEE ALSO .Xr pccard 4 , .Xr pccbb 4 Index: src/share/man/man4/ccd.4 diff -u src/share/man/man4/ccd.4:1.30 src/share/man/man4/ccd.4:1.32 --- src/share/man/man4/ccd.4:1.30 Fri Jan 21 16:36:37 2005 +++ src/share/man/man4/ccd.4 Fri Apr 14 17:20:24 2006 @@ -173,6 +173,81 @@ .Nm partition without first backing up the partition, then replacing the disk, then restoring the partition. +.Ss Linux Compatibility +The +.Tn Linux +compatibility mode does not try to read the label that +.Tn Linux Ns ' +.Xr md 4 +driver leaves on the raw devices. +You will have to give the order +of devices and the interleave factor on your own. +When in +.Tn Linux +compatibility mode, +.Nm +will convert the interleave factor from +.Tn Linux +terminology. +That means you give the same interleave factor that you +gave as chunk size in +.Tn Linux . +.Pp +If you have a +.Tn Linux +.Xr md 4 +device in +.Dq legacy +mode, do not use the +.Dv CCDF_LINUX +flag in +.Xr ccdconfig 8 . +Use the +.Dv CCDF_NO_OFFSET +flag instead. +In that case you have to convert +the interleave factor on your own, usually it is +.Tn Linux Ns ' +chunk size multiplied by two. +.Pp +Using a +.Tn Linux +RAID this way is potentially dangerous and can destroy +the data in there. +Since +.Fx +does not read the label used by +.Tn Linux , +changes in +.Tn Linux +might invalidate the compatibility layer. +.Pp +However, using this is reasonably safe if you test the compatibility +before mounting a RAID read-write for the first time. +Just using +.Xr ccdconfig 8 +without mounting does not write anything to the +.Tn Linux +RAID. +Then you do a +.Nm fsck.ext2fs Pq Pa ports/sysutils/e2fsprogs +on the +.Nm +device using the +.Fl n +flag. +You can mount the file system read-only to check files in there. +If all this works, it is unlikely that there is a problem with +.Nm . +Keep in mind that even when the +.Tn Linux +compatibility mode in +.Nm +is working correctly, bugs in +.Fx Ap s +.Nm ex2fs +implementation would still destroy +your data. .Sh WARNINGS If just one (or more) of the disks in a .Nm Index: src/share/man/man4/coretemp.4 diff -u /dev/null src/share/man/man4/coretemp.4:1.4 --- /dev/null Thu Jan 17 11:57:39 2008 +++ src/share/man/man4/coretemp.4 Tue Oct 16 04:00:19 2007 @@ -0,0 +1,74 @@ +.\"- +.\" Copyright (c) 2007 Dag-Erling Coïdan Smørgrav +.\" 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$ +.\" +.Dd August 23, 2007 +.Dt CORETEMP 4 +.Os +.Sh NAME +.Nm coretemp +.Nd device driver for Intel Core on-die digital thermal sensor +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following line in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device coretemp" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +coretemp_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for the on-die digital thermal sensor present +in Intel Core and newer CPUs. +.Pp +The +.Nm +driver reports each core's temperature through a sysctl node in the +corresponding CPU device's sysctl tree, named +.Va dev.cpu.%d.temperature . +.Sh SEE ALSO +.Xr sysctl 8 +.Sh HISTORY +The +.Nm +driver first appeared in +.Fx 7.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Rui Paulo Aq rpaulo@FreeBSD.org +as part of a Google Summer of Code project. +This manual page was written by +.An Dag-Erling Sm\(/orgrav Aq des@FreeBSD.org . Index: src/share/man/man4/cpufreq.4 diff -u src/share/man/man4/cpufreq.4:1.10.2.4 src/share/man/man4/cpufreq.4:1.15 --- src/share/man/man4/cpufreq.4:1.10.2.4 Mon Jun 19 12:44:20 2006 +++ src/share/man/man4/cpufreq.4 Mon Sep 18 23:24:18 2006 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 03, 2006 +.Dd March 3, 2006 .Dt CPUFREQ 4 .Os .Sh NAME Index: src/share/man/man4/crypto.4 diff -u src/share/man/man4/crypto.4:1.5.8.1 src/share/man/man4/crypto.4:1.7 --- src/share/man/man4/crypto.4:1.5.8.1 Tue Dec 13 14:05:26 2005 +++ src/share/man/man4/crypto.4 Thu Aug 2 16:04:48 2007 @@ -28,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 16, 2004 +.Dd August 1, 2007 .Dt CRYPTO 4 .Os .Sh NAME @@ -105,8 +105,8 @@ crypto access device .El .Sh SEE ALSO -.Xr fast_ipsec 4 , .Xr hifn 4 , +.Xr ipsec 4 , .Xr padlock 4 , .Xr safe 4 , .Xr ubsec 4 , Index: src/share/man/man4/da.4 diff -u src/share/man/man4/da.4:1.46 src/share/man/man4/da.4:1.48 --- src/share/man/man4/da.4:1.46 Mon Feb 14 06:25:17 2005 +++ src/share/man/man4/da.4 Mon Sep 18 23:24:18 2006 @@ -52,39 +52,6 @@ before a .Tn SCSI direct access device can be configured. -.Sh PARTITIONING -The -.Nm -driver allows the disk to have two levels of partitioning. -One layer, called the -.Dq slice layer , -is used to separate the -.Fx -areas of the disk from areas used by other operating systems. -The second layer is the native -.Bx 4.4 -partitioning scheme, -.Xr disklabel 5 , -which is used to subdivide the -.Fx -slices into areas for individual file systems and swap spaces. -For more information, see -.Xr fdisk 8 -and -.Xr disklabel 8 , -respectively. -.Pp -If an uninitialized disk is opened, the slice table will be -initialized with a fictitious -.Fx -slice spanning the entire disk. -Similarly, if an uninitialized -(or -.No non- Ns Fx ) -slice is opened, its disklabel will be initialized with parameters returned -by the drive and a single -.Sq Li c -partition encompassing the entire slice. .Sh CACHE EFFECTS Many direct access devices are equipped with read and/or write caches. Parameters affecting the device's cache are stored in mode page 8, @@ -159,44 +126,6 @@ on the .Tn SCSI bus. -.Sh IOCTLS -The following -.Xr ioctl 2 -calls apply to -.Tn SCSI -disks as well as to other disks. -They are defined in the header file -.In sys/disklabel.h . -.Pp -.Bl -tag -width DIOCSDINFO -.It Dv DIOCSBAD -Usually used to set up a bad-block mapping system on the disk. -.Tn SCSI -drives incorporate their own bad-block mapping so this command is not -implemented. -.It Dv DIOCGDINFO -Read, from the kernel, the in-core copy of the disklabel for the -drive. -This may be a fictitious disklabel if the drive has never -been initialized, in which case it will contain information read -from the -.Tn SCSI -inquiry commands. -.It Dv DIOCSDINFO -Give the driver a new disklabel to use. -The driver -.Em will not -write the new -disklabel to the disk. -.It Dv DIOCWLABEL -Enable or disable the driver's software -write protect of the disklabel on the disk. -.It Dv DIOCWDINFO -Give the driver a new disklabel to use. -The driver -.Em will -write the new disklabel to the disk. -.El .Sh SYSCTL VARIABLES The following variables are available as both .Xr sysctl 8 @@ -259,49 +188,16 @@ the last file descriptor referencing the old device is closed. During this period, all new open attempts will be rejected. .Sh FILES -.Bl -tag -width /dev/rsdXXXXX -compact -.Sm off -.It Pa /dev/da Ar u Pa s Ar n -.Sm on -raw mode -.Tn SCSI -disk unit -.Ar u , -slice -.Ar n , -accessed as an unpartitioned device -.It Pa /dev/da Ns Ar u Ns Ar p -raw mode -.Tn SCSI -disk unit -.Ar u , -first -.Fx -slice, partition -.Ar p -.Sm off -.It Xo -.Pa /dev/da -.Ar u -.Pa s -.Ar n -.Ar p -.Xc -.Sm on -raw mode -.Tn SCSI -disk unit -.Ar u , -.Ar n Ns th -slice, partition -.Ar p +.Bl -tag -width ".Pa /dev/da*" -compact +.It Pa /dev/da* +SCSI disk device nodes .El .Sh DIAGNOSTICS None. .Sh SEE ALSO .Xr ad 4 , -.Xr disklabel 5 , -.Xr disklabel 8 , +.Xr geom 4 , +.Xr bsdlabel 8 , .Xr fdisk 8 .Sh HISTORY The @@ -318,5 +214,3 @@ 2.5 by .An Julian Elischer . -Support for slices was written by -.An Bruce Evans . Index: src/share/man/man4/dc.4 diff -u src/share/man/man4/dc.4:1.35.2.3 src/share/man/man4/dc.4:1.40 --- src/share/man/man4/dc.4:1.35.2.3 Fri Feb 16 21:55:23 2007 +++ src/share/man/man4/dc.4 Tue Jan 30 16:40:03 2007 @@ -199,8 +199,6 @@ Built in 10Mbps only Ethernet on Compaq Presario 7900 series desktops (21143, non-MII) .It -Built in DE500-BA on DEC Alpha workstations (21143, non-MII) -.It Built in Sun DMFE 10/100 Mbps Ethernet on Sun Netra X1 and Sun Fire V100 (DM9102A, MII) .It Index: src/share/man/man4/dcons.4 diff -u src/share/man/man4/dcons.4:1.7.2.2 src/share/man/man4/dcons.4:1.11 --- src/share/man/man4/dcons.4:1.7.2.2 Thu Feb 2 15:50:00 2006 +++ src/share/man/man4/dcons.4 Tue Mar 21 01:10:09 2006 @@ -104,6 +104,7 @@ .Xr firewire 4 , .Xr fwohci 4 , .Xr ttys 5 , +.Xr conscontrol 8 , .Xr dconschat 8 , .Xr fwcontrol 8 .Sh AUTHORS Index: src/share/man/man4/ddb.4 diff -u src/share/man/man4/ddb.4:1.28.2.1 src/share/man/man4/ddb.4:1.47 --- src/share/man/man4/ddb.4:1.28.2.1 Thu Mar 9 17:14:23 2006 +++ src/share/man/man4/ddb.4 Wed Dec 26 20:18:21 2007 @@ -1,6 +1,7 @@ .\" .\" Mach Operating System .\" Copyright (c) 1991,1990 Carnegie Mellon University +.\" Copyright (c) 2007 Robert N. M. Watson .\" All Rights Reserved. .\" .\" Permission to use, copy, modify and distribute this software and its @@ -58,7 +59,8 @@ .\" [90/08/30 dbg] .\" .\" $FreeBSD$ -.Dd February 27, 2006 +.\" +.Dd December 26, 2007 .Dt DDB 4 .Os .Sh NAME @@ -74,7 +76,8 @@ .Sh DESCRIPTION The .Nm -kernel debugger has most of the features of the old kdb, +kernel debugger has most of the features of the old +.Nm kdb , but with a more rational syntax inspired by .Xr gdb 1 . @@ -94,27 +97,47 @@ .Dv KDB_UNATTENDED option is specified. .Pp -The current location is called `dot'. -The `dot' is displayed with +The current location is called +.Va dot . +The +.Va dot +is displayed with a hexadecimal format at a prompt. -Examine and write commands update `dot' to the address of the last line -examined or the last location modified, and set `next' to the address of +The commands +.Ic examine +and +.Ic write +update +.Va dot +to the address of the last line +examined or the last location modified, and set +.Va next +to the address of the next location to be examined or changed. -Other commands do not change `dot', and set `next' to be the same as `dot'. +Other commands do not change +.Va dot , +and set +.Va next +to be the same as +.Va dot . .Pp The general command syntax is: -.Cm command Ns Op Li \&/ Ns Ar modifier +.Ar command Ns Op Li / Ns Ar modifier .Ar address Ns Op Li , Ns Ar count .Pp -A blank line repeats the previous command from the address `next' with +A blank line repeats the previous command from the address +.Va next +with count 1 and no modifiers. Specifying .Ar address -sets `dot' to the -address. +sets +.Va dot +to the address. Omitting .Ar address -uses `dot'. +uses +.Va dot . A missing .Ar count is taken @@ -122,14 +145,14 @@ .Pp The .Nm -debugger has a feature like the +debugger has a pager feature (like the .Xr more 1 -command +command) for the output. If an output line exceeds the number set in the -.Li \&$lines +.Va lines variable, it displays -.Dq Em --db_more-- +.Dq Li --More-- and waits for a response. The valid responses for it are: .Pp @@ -145,56 +168,63 @@ Finally, .Nm provides a small (currently 10 items) command history, and offers -simple emacs-style command line editing capabilities. +simple +.Nm emacs Ns -style +command line editing capabilities. In addition to -the emacs control keys, the usual ANSI arrow keys might be used to +the +.Nm emacs +control keys, the usual +.Tn ANSI +arrow keys might be used to browse through the history buffer, and move the cursor within the current line. .Sh COMMANDS -.Bl -ohang -.It Cm examine -.It Cm x +.Bl -tag -width indent -compact +.It Ic examine +.It Ic x Display the addressed locations according to the formats in the modifier. Multiple modifier formats display multiple locations. -If no format is specified, the last formats specified for this command +If no format is specified, the last format specified for this command is used. .Pp The format characters are: .Bl -tag -compact -width indent -.It Li b +.It Cm b look at by bytes (8 bits) -.It Li h +.It Cm h look at by half words (16 bits) -.It Li l +.It Cm l look at by long words (32 bits) -.It Li a +.It Cm a print the location being displayed -.It Li A +.It Cm A print the location with a line number if possible -.It Li x +.It Cm x display in unsigned hex -.It Li z +.It Cm z display in signed hex -.It Li o +.It Cm o display in unsigned octal -.It Li d +.It Cm d display in signed decimal -.It Li u +.It Cm u display in unsigned decimal -.It Li r +.It Cm r display in current radix, signed -.It Li c +.It Cm c display low 8 bits as a character. -Non-printing characters are displayed as an octal escape code (e.g., `\e000'). -.It Li s +Non-printing characters are displayed as an octal escape code (e.g., +.Ql \e000 ) . +.It Cm s display the null-terminated string at the location. Non-printing characters are displayed as octal escapes. -.It Li m +.It Cm m display in unsigned hex with character dump at the end of each line. The location is also displayed in hex at the beginning of each line. -.It Li i +.It Cm i display as an instruction -.It Li I +.It Cm I display as an instruction with possible alternate formats depending on the machine: .Bl -tag -width ".Tn powerpc" -compact @@ -212,36 +242,39 @@ No alternate format. .El .El -.It Cm xf +.Pp +.It Ic xf Examine forward: -Execute an examine command with the last specified parameters to it +execute an +.Ic examine +command with the last specified parameters to it except that the next address displayed by it is used as the start address. -.It Cm xb +.Pp +.It Ic xb Examine backward: -Execute an examine command with the last specified parameters to it +execute an +.Ic examine +command with the last specified parameters to it except that the last start address subtracted by the size displayed by it is used as the start address. -.It Cm print Ns Op Cm /acdoruxz +.Pp +.It Ic print Ns Op Li / Ns Cm acdoruxz +.It Ic p Ns Op Li / Ns Cm acdoruxz Print .Ar addr Ns s according to the modifier character (as described above for -.Li examine ) . +.Cm examine ) . Valid formats are: -.Li a , -.Li x , -.Li z , -.Li o , -.Li d , -.Li u , -.Li r , +.Cm a , x , z , o , d , u , r , and -.Li c . +.Cm c . If no modifier is specified, the last one specified to it is used. +The argument .Ar addr can be a string, in which case it is printed as it is. For example: .Bd -literal -offset indent -print/x \&"eax = \&" $eax \&"\enecx = \&" $ecx \&"\en\&" +print/x "eax = " $eax "\enecx = " $ecx "\en" .Ed .Pp will print like: @@ -249,20 +282,25 @@ eax = xxxxxx ecx = yyyyyy .Ed +.Pp .It Xo -.Cm write Ns Op Cm /bhl -.Ar addr Ar expr1 Op Ar "expr2 ..." +.Ic write Ns Op Li / Ns Cm bhl +.Ar addr expr1 Op Ar expr2 ... +.Xc +.It Xo +.Ic w Ns Op Li / Ns Cm bhl +.Ar addr expr1 Op Ar expr2 ... .Xc Write the expressions specified after .Ar addr on the command line at succeeding locations starting with -.Ar addr +.Ar addr . The write unit size can be specified in the modifier with a letter -.Li b +.Cm b (byte), -.Li h +.Cm h (half word) or -.Li l +.Cm l (long word) respectively. If omitted, long word is assumed. @@ -271,36 +309,34 @@ since there is no delimiter between expressions, strange things may happen. It is best to enclose each expression in parentheses. -.It Xo -.Cm set -.Li \&$ Ns Ar variable -.Op Li = -.Ar expr -.Xc +.Pp +.It Ic set Li $ Ns Ar variable Oo Li = Oc Ar expr Set the named variable or register with the value of .Ar expr . Valid variable names are described below. -.It Cm break Ns Op Cm /u +.Pp +.It Ic break Ns Op Li / Ns Cm u +.It Ic b Ns Op Li / Ns Cm u Set a break point at .Ar addr . If .Ar count is supplied, continues .Ar count -- 1 times before stopping at the +\- 1 times before stopping at the break point. If the break point is set, a break point number is printed with -.Sq Li \&# . +.Ql # . This number can be used in deleting the break point or adding conditions to it. .Pp If the -.Li u +.Cm u modifier is specified, this command sets a break point in user space address. Without the -.Li u +.Cm u option, the address is considered in the kernel space, and wrong space address is rejected with an error message. This modifier can be used only if it is supported by machine dependent @@ -311,23 +347,61 @@ user space break points may not work correctly. Setting a break point at the low-level code paths may also cause strange behavior. -.It Cm delete Ar addr -.It Cm delete Li \&# Ns Ar number +.Pp +.It Ic delete Ar addr +.It Ic d Ar addr +.It Ic delete Li # Ns Ar number +.It Ic d Li # Ns Ar number Delete the break point. The target break point can be specified by a break point number with -.Li # , +.Ql # , or by using the same .Ar addr specified in the original -.Cm break +.Ic break command. -.It Cm step Ns Op Cm /p +.Pp +.It Ic watch Ar addr Ns Li , Ns Ar size +Set a watchpoint for a region. +Execution stops when an attempt to modify the region occurs. +The +.Ar size +argument defaults to 4. +If you specify a wrong space address, the request is rejected +with an error message. +.Pp +.Sy Warning : +Attempts to watch wired kernel memory +may cause unrecoverable error in some systems such as i386. +Watchpoints on user addresses work best. +.Pp +.It Ic hwatch Ar addr Ns Li , Ns Ar size +Set a hardware watchpoint for a region if supported by the +architecture. +Execution stops when an attempt to modify the region occurs. +The +.Ar size +argument defaults to 4. +.Pp +.Sy Warning : +The hardware debug facilities do not have a concept of separate +address spaces like the watch command does. +Use +.Ic hwatch +for setting watchpoints on kernel address locations only, and avoid +its use on user mode address spaces. +.Pp +.It Ic dhwatch Ar addr Ns Li , Ns Ar size +Delete specified hardware watchpoint. +.Pp +.It Ic step Ns Op Li / Ns Cm p +.It Ic s Ns Op Li / Ns Cm p Single step .Ar count times (the comma is a mandatory part of the syntax). If the -.Li p +.Cm p modifier is specified, print each instruction at each step. Otherwise, only print the last instruction. .Pp @@ -337,10 +411,12 @@ On machines with software-emulated single-stepping (e.g., pmax), stepping through code executed by interrupt handlers will probably do the wrong thing. -.It Cm continue Ns Op Cm /c +.Pp +.It Ic continue Ns Op Li / Ns Cm c +.It Ic c Ns Op Li / Ns Cm c Continue execution until a breakpoint or watchpoint. If the -.Li c +.Cm c modifier is specified, count instructions while executing. Some machines (e.g., pmax) also count loads and stores. .Pp @@ -348,34 +424,53 @@ when counting, the debugger is really silently single-stepping. This means that single-stepping on low-level code may cause strange behavior. -.It Cm until Ns Op Cm /p +.Pp +.It Ic until Ns Op Li / Ns Cm p Stop at the next call or return instruction. If the -.Li p +.Cm p modifier is specified, print the call nesting depth and the cumulative instruction count at each call or return. Otherwise, only print when the matching return is hit. -.It Cm next Ns Op Cm /p -.It Cm match Ns Op Cm /p +.Pp +.It Ic next Ns Op Li / Ns Cm p +.It Ic match Ns Op Li / Ns Cm p Stop at the matching return instruction. If the -.Li p +.Cm p modifier is specified, print the call nesting depth and the cumulative instruction count at each call or return. Otherwise, only print when the matching return is hit. +.Pp +.It Xo +.Ic trace Ns Op Li / Ns Cm u +.Op Ar pid | tid +.Op Li , Ns Ar count +.Xc .It Xo -.Cm trace Ns Op Cm /u -.Op Ar frame -.Op , Ns Ar count +.Ic t Ns Op Li / Ns Cm u +.Op Ar pid | tid +.Op Li , Ns Ar count +.Xc +.It Xo +.Ic where Ns Op Li / Ns Cm u +.Op Ar pid | tid +.Op Li , Ns Ar count +.Xc +.It Xo +.Ic bt Ns Op Li / Ns Cm u +.Op Ar pid | tid +.Op Li , Ns Ar count .Xc Stack trace. The -.Li u +.Cm u option traces user space; if omitted, -.Cm trace +.Ic trace only traces kernel space. +The optional argument .Ar count is the number of frames to be traced. If @@ -385,214 +480,415 @@ .Sy Warning : User space stack trace is valid only if the machine dependent code supports it. +.Pp .It Xo -.Cm search Ns Op Cm /bhl +.Ic search Ns Op Li / Ns Cm bhl .Ar addr .Ar value .Op Ar mask -.Op , Ns Ar count +.Op Li , Ns Ar count .Xc Search memory for .Ar value . This command might fail in interesting ways if it does not find the searched-for value. -This is because ddb does not always recover from touching bad memory. +This is because +.Nm +does not always recover from touching bad memory. The optional .Ar count argument limits the search. -.It Cm show all procs Ns Op Cm /m -.It Cm ps Ns Op Cm /m +.Pp +.It Ic show Cm all procs Ns Op Li / Ns Cm m +.It Ic ps Ns Op Li / Ns Cm m Display all process information. The process information may not be shown if it is not supported in the machine, or the bottom of the stack of the target process is not in the main memory at that time. The -.Li m +.Cm m modifier will alter the display to show VM map addresses for the process and not show other info. -.It Cm show registers Ns Op Cm /u +.Pp +.It Ic show Cm registers Ns Op Li / Ns Cm u Display the register set. If the -.Li u -option is specified, it displays user registers instead of +.Cm u +modifier is specified, it displays user registers instead of kernel or currently saved one. .Pp .Sy Warning : The support of the -.Li u +.Cm u modifier depends on the machine. If not supported, incorrect information will be displayed. -.It Xo -.Cm show map Ns Op Cm /f +.Pp +.It Ic show Cm sysregs +Show system registers (e.g., +.Li cr0-4 +on i386.) +Not present on some platforms. +.Pp +.It Ic show Cm geom Op Ar addr +If the .Ar addr -.Xc +argument is not given, displays the entire GEOM topology. +If the +.Ar addr +is given, displays details about the given GEOM object (class, geom, provider +or consumer). +.Pp +.It Ic show Cm map Ns Oo Li / Ns Cm f Oc Ar addr Prints the VM map at .Ar addr . If the -.Li f +.Cm f modifier is specified the complete map is printed. -.It Xo -.Cm show object Ns Op Cm /f -.Ar addr -.Xc +.Pp +.It Ic show Cm object Ns Oo Li / Ns Cm f Oc Ar addr Prints the VM object at .Ar addr . If the -.Li f +.Cm f option is specified the complete object is printed. -.It Cm "show watches" -Displays all watchpoints. -.It Cm reset -Hard reset the system. -.It Xo -.Cm watch -.Ar addr Ns Li \&, Ns Ar size -.Xc -Set a watchpoint for a region. -Execution stops when an attempt to modify the region occurs. -The -.Ar size -argument defaults to 4. -If you specify a wrong space address, the request is rejected -with an error message. .Pp -.Sy Warning : -Attempts to watch wired kernel memory -may cause unrecoverable error in some systems such as i386. -Watchpoints on user addresses work best. -.It Xo -.Cm hwatch -.Ar addr Ns Li \&, Ns Ar size -.Xc -Set a hardware watchpoint for a region if supported by the -architecture. -Execution stops when an attempt to modify the region occurs. -The -.Ar size -argument defaults to 4. +.It Ic show Cm vnode Ar addr +Displays details about the given vnode. .Pp -.Sy Warning : -The hardware debug facilities do not have a concept of separate -address spaces like the watch command does. -Use -.Cm hwatch -for setting watchpoints on kernel address locations only, and avoid -its use on user mode address spaces. -.It Xo -.Cm dhwatch -.Ar addr Ns Li \&, Ns Ar size -.Xc -Delete specified hardware watchpoint. -.It Cm gdb +.It Ic show Cm watches +Displays all watchpoints. +.Pp +.It Ic gdb Toggles between remote GDB and DDB mode. In remote GDB mode, another machine is required that runs .Xr gdb 1 using the remote debug feature, with a connection to the serial console port on the target machine. Currently only available on the -.Em i386 -and -.Em Alpha -architectures. -.It Cm help +i386 +architecture. +.Pp +.It Ic halt +Halt the system. +.Pp +.It Ic kill Ar sig pid +Send signal +.Ar sig +to process +.Ar pid . +The signal is acted on upon returning from the debugger. +This command can be used to kill a process causing resource contention +in the case of a hung system. +See +.Xr signal 3 +for a list of signals. +Note that the arguments are reversed relative to +.Xr kill 2 . +.Pp +.It Ic reboot +.It Ic reset +Hard reset the system. +.Pp +.It Ic help Print a short summary of the available commands and command abbreviations. +.Pp +.It Ic capture on +.It Ic capture off +.It Ic capture reset +.It Ic capture status +.Nm +supports a basic output capture facility, which can be used to retrieve the +results of debugging commands from userpsace using +.Xr sysctl 2 . +.Ic capture on +enables output capture; +.Ic capture off +disables capture. +.Ic capture reset +will clear the capture buffer and disable capture. +.Ic capture status +will report current buffer use, buffer size, and disposition of output +capture. +.Pp +Userspace processes may inspect and manage +.Nm +capture state using +.Xr sysctl 8 : +.Pp +.Dv debug.ddb.capture.bufsize +may be used to query or set the current capture buffer size. +.Pp +.Dv debug.ddb.capture.maxbufsize +may be used to query the compile-time limit on the capture buffer size. +.Pp +.Dv debug.ddb.capture.bytes +may be used to query the number of bytes of output currently in the capture +buffer. +.Pp +.Dv debug.ddb.capture.data +returns the contents of the buffer as a string to an appropriately privileged +process. +.Pp +This facility is particularly useful in concert with the scripting and +.Xr textdump 4 +facilities, allowing scripted debugging output to be captured and +committed to disk as part of a textdump for later analysis. +The contents of the capture buffer may also be inspected in a kernel core dump +using +.Xr kgdb 1 . +.Pp +.It Ic run +.It Ic script +.It Ic scripts +.It Ic unscript +Run, define, list, and delete scripts. +See the +.Sx SCRIPTING +section for more information on the scripting facility. +.Pp +.It Ic textdump set +.It Ic textdump status +.It Ic textdump unset +The +.Ic textdump set +command may be used to force the next kernel core dump to be a textdump +rather than a traditional memory dump or minidump. +.Ic textdump status +reports whether a textdump has been scheduled. +.Ic textdump unset +cancels a request to perform a textdump as the next kernel core dump. +More information may be found in +.Xr textdump 4 . .El .Sh VARIABLES The debugger accesses registers and variables as -.Li \&$ Ns Em name . +.Li $ Ns Ar name . Register names are as in the -.Dq Cm show registers +.Dq Ic show Cm registers command. Some variables are suffixed with numbers, and may have some modifier following a colon immediately after the variable name. For example, register variables can have a -.Li u +.Cm u modifier to indicate user register (e.g., -.Li $eax:u ) . +.Dq Li $eax:u ) . .Pp Built-in variables currently supported are: -.Bl -tag -width ".Li tabstops" -compact -.It Li radix -Input and output radix -.It Li maxoff -Addresses are printed as 'symbol'+offset unless offset is greater than maxoff. -.It Li maxwidth +.Pp +.Bl -tag -width ".Va tabstops" -compact +.It Va radix +Input and output radix. +.It Va maxoff +Addresses are printed as +.Dq Ar symbol Ns Li + Ns Ar offset +unless +.Ar offset +is greater than +.Va maxoff . +.It Va maxwidth The width of the displayed line. -.It Li lines +.It Va lines The number of lines. -It is used by -.Dq more -feature. -.It Li tabstops +It is used by the built-in pager. +.It Va tabstops Tab stop width. -.It Li work Ns Ar xx -Work variable. +.It Va work Ns Ar xx +Work variable; .Ar xx -can be 0 to 31. +can take values from 0 to 31. .El .Sh EXPRESSIONS -Almost all expression operators in C are supported except -.Sq Li \&~ , -.Sq Li \&^ , +Most expression operators in C are supported except +.Ql ~ , +.Ql ^ , and unary -.Sq Li \&& . +.Ql & . Special rules in .Nm are: -.Bl -tag -width ".Em Identifiers" -.It Em Identifiers +.Bl -tag -width ".No Identifiers" +.It Identifiers The name of a symbol is translated to the value of the symbol, which is the address of the corresponding object. -.Sq Li \&. +.Ql \&. and -.Sq Li \&: +.Ql \&: can be used in the identifier. If supported by an object format dependent routine, .Sm off -.Oo Em filename : Oc Em func : lineno , +.Oo Ar filename : Oc Ar func : lineno , .Sm on -.Oo Em filename : Oc Ns Em variable , +.Oo Ar filename : Oc Ns Ar variable , and -.Oo Em filename : Oc Ns Em lineno +.Oo Ar filename : Oc Ns Ar lineno can be accepted as a symbol. -.It Em Numbers +.It Numbers Radix is determined by the first two letters: -.Li 0x : +.Ql 0x : hex, -.Li 0o : +.Ql 0o : octal, -.Li 0t : +.Ql 0t : decimal; otherwise, follow current radix. .It Li \&. -`dot' -.It Li \&+ -`next' -.It Li \&.. +.Va dot +.It Li + +.Va next +.It Li .. address of the start of the last line examined. -Unlike `dot' or `next', this is only changed by -.Dq Li examine +Unlike +.Va dot or -.Dq Li write +.Va next , +this is only changed by +.Ic examine +or +.Ic write command. -.It Li \&' +.It Li ' last address explicitly specified. -.It Li \&$ Ns Em variable +.It Li $ Ns Ar variable Translated to the value of the specified variable. It may be followed by a -.Li : +.Ql \&: and modifiers as described above. -.It Em a Ns Li \&# Ns Em b -a binary operator which rounds up the left hand side to the next +.It Ar a Ns Li # Ns Ar b +A binary operator which rounds up the left hand side to the next multiple of right hand side. -.It Li \&* Ns Em expr -indirection. +.It Li * Ns Ar expr +Indirection. It may be followed by a -.Sq Li : +.Ql \&: and modifiers as described above. .El +.Sh SCRIPTING +.Nm +supports a basic scripting facility to allow automating tasks or responses to +specific events. +Each script consists of a list of DDB commands to be executed sequentially, +and is assigned a unique name. +Certain script names have special meaning, and will be automatically run on +various +.Nm +events if scripts by those names have been defined. +.Pp +The +.Ic script +command may be used to define a script by name. +Scripts consist of a series of +.Nm +commands separated with the +.Ic ; +character. +For example: +.Bd -literal -offset indent +script kdb.enter.panic=bt; show pcpu +script lockinfo=show alllocks; show lockedvnods +.Ed +.Pp +The +.Ic scripts +command lists currently defined scripts. +.Pp +The +.Ic run +command execute a script by name. +For example: +.Bd -literal -offset indent +run lockinfo +.Ed +.Pp +The +.Ic unscript +command may be used to delete a script by name. +For example: +.Bd -literal -offset indent +unscript kdb.enter.panic +.Ed +.Pp +These functions may also be performed from userspace using the +.Xr ddb 8 +command. +.Pp +Certain scripts are run automatically, if defined, for specific +.Nm +events. +The follow scripts are run when various events occur: +.Bl -tag -width kdb.enter.powerfail +.It Dv kdb.enter.acpi +The kernel debugger was entered as a result of an +.Xr acpi 4 +event. +.It Dv kdb.enter.bootflags +The kernel debugger was entered at boot as a result of the debugger boot +flag being set. +.It Dv kdb.enter.break +The kernel debugger was entered as a result of a serial or console break. +.It Dv kdb.enter.cam +The kernel debugger was entered as a result of a +.Xr CAM 4 +event. +.It Dv kdb.enter.mac +The kernel debugger was entered as a result of an assertion failure in the +.Xr mac_test 4 +module of the +TrustedBSD MAC Framework. +.It Dv kdb.enter.ndis +The kernel debugger was entered as a result of an +.Xr ndis 4 +breakpoint event. +.It Dv kdb.enter.netgraph +The kernel debugger was entered as a result of a +.Xr netgraph 4 +event. +.It Dv kdb.enter.panic +.Xr panic 9 +was called. +.It Dv kdb.enter.powerfail +The kernel debugger was entered as a result of a powerfail NMI on the sparc64 +platform. +.It Dv kdb.enter.powerpc +The kernel debugger was entered as a result of an unimplemented interrupt +type on the powerpc platform. +.It Dv kdb.enter.sysctl +The kernel debugger was entered as a result of the +.Dv debug.kdb.enter +sysctl being set. +.It Dv kdb.enter.trapsig +The kernel debugger was entered as a result of a trapsig event on the sparc64 +or sun4v platform. +.It Dv kdb.enter.unionfs +The kernel debugger was entered as a result of an assertion failure in the +union file system. +.It Dv kdb.enter.unknown +The kernel debugger was entered, but no reason has been set. +.It Dv kdb.enter.vfslock +The kernel debugger was entered as a result of a VFS lock violation. +.It Dv kdb.enter.watchdog +The kernel debugger was entered as a result of a watchdog firing. +.It Dv kdb.enter.witness +The kernel debugger was entered as a result of a +.Xr witness 4 +violation. +.El +.Pp +In the event that none of these scripts is found, +.Nm +will attempt to execute a default script: +.Bl -tag -width kdb.enter.powerfail +.It Dv kdb.enter.default +The kernel debugger was entered, but a script exactly matching the reason for +entering was not defined. +This can be used as a catch-all to handle cases not specifically of interest; +for example, +.Dv kdb.enter.witness +might be defined to have special handling, and +.Dv kdb.enter.default +might be defined to simply panic and reboot. +.El .Sh HINTS On machines with an ISA expansion bus, a simple NMI generation card can be constructed by connecting a push button between the A01 and B01 (CHCHK# and @@ -606,12 +902,32 @@ Other bus' bridge chipsets may be able to generate NMI using bus specific methods. .Sh SEE ALSO -.Xr gdb 1 +.Xr gdb 1 , +.Xr kgdb 1 , +.Xr acpi 4 , +.Xr CAM 4 , +.Xr mac_text 4 , +.Xr ndis 4 , +.Xr netgraph 4 , +.Xr textdump 4 , +.Xr witness 4 , +.Xr ddb 8 , +.Xr sysctl 8 , +.Xr panic 9 .Sh HISTORY The .Nm debugger was developed for Mach, and ported to .Bx 386 0.1 . This manual page translated from -.Fl man -macros by Garrett Wollman. +.Xr man 7 +macros by +.An Garrett Wollman . +.Pp +.An Robert N. M. Watson +added support for +.Nm +output capture, +.Xr textdump 4 +and scripting in +.Fx 8.0 . Index: src/share/man/man4/devctl.4 diff -u src/share/man/man4/devctl.4:1.3.12.2 src/share/man/man4/devctl.4:1.5 --- src/share/man/man4/devctl.4:1.3.12.2 Sun Aug 13 04:30:10 2006 +++ src/share/man/man4/devctl.4 Fri Aug 4 15:56:32 2006 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 23, 2006 +.Dd February 11, 2003 .Dt DEVCTL 4 .Os .Sh NAME Index: src/share/man/man4/divert.4 diff -u src/share/man/man4/divert.4:1.37 src/share/man/man4/divert.4:1.38 --- src/share/man/man4/divert.4:1.37 Mon Feb 14 07:45:49 2005 +++ src/share/man/man4/divert.4 Sun Sep 24 21:58:44 2006 @@ -12,6 +12,23 @@ .In netinet/in.h .Ft int .Fn socket PF_INET SOCK_RAW IPPROTO_DIVERT +.Pp +To enable support for divert sockets, place the following lines in the +kernel configuration file: +.Bd -ragged -offset indent +.Cd "options IPFIREWALL" +.Cd "options IPDIVERT" +.Ed +.Pp +Alternatively, to load +.Ns Nm +as a module at boot time, add the following lines into the +.Xr loader.conf 5 +file: +.Bd -literal -offset indent +ipfw_load="YES" +ipdivert_load="YES" +.Ed .Sh DESCRIPTION Divert sockets are similar to raw IP sockets, except that they can be bound to a specific @@ -112,14 +129,6 @@ to avoid loops, where the same packet is diverted more than once at the same rule. .Sh DETAILS -To enable divert sockets, a kernel must be compiled with -.Cd "options IPDIVERT" -or the -.Pa ipdivert.ko -module can be loaded at run-time: -.Pp -.Dl "kldload ipdivert" -.Pp If a packet is diverted but no socket is bound to the port, or if .Dv IPDIVERT @@ -163,6 +172,7 @@ .Xr recvfrom 2 , .Xr sendto 2 , .Xr socket 2 , +.Xr ipfw 4 , .Xr ipfw 8 .Sh AUTHORS .An Archie Cobbs Aq archie@FreeBSD.org , Index: src/share/man/man4/dummynet.4 diff -u src/share/man/man4/dummynet.4:1.21.2.1 src/share/man/man4/dummynet.4:1.23 --- src/share/man/man4/dummynet.4:1.21.2.1 Sat Sep 2 14:41:55 2006 +++ src/share/man/man4/dummynet.4 Sun Aug 27 05:24:22 2006 @@ -58,7 +58,6 @@ pipes. .Sh SEE ALSO .Xr setsockopt 2 , -.Xr bridge 4 , .Xr if_bridge 4 , .Xr ip 4 , .Xr ipfw 8 , Index: src/share/man/man4/ed.4 diff -u src/share/man/man4/ed.4:1.45.2.3 src/share/man/man4/ed.4:1.55 --- src/share/man/man4/ed.4:1.45.2.3 Fri Feb 16 21:55:23 2007 +++ src/share/man/man4/ed.4 Wed Jan 2 05:41:39 2008 @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 5, 2005 +.Dd January 1, 2008 .Dt ED 4 .Os .Sh NAME @@ -57,6 +57,14 @@ driver provides support for 8 and 16bit Ethernet cards that are based on the National Semiconductor DS8390 and similar NICs manufactured by other companies. +The +.Nm +driver also supports many PC Card chips which interface via MII to a PHY. +Axiom's AX88790, AX88190 and AX88190A; +DLink's DL10019 and DL10022; and +Tamarack's TC5299J chips all support internal or external MII/PHY combinations. +Realtek's PCI and ISA RTL80x9-based cards are also supported. +For these chipsets, autonegotiation and status reporting are supported. .Pp The .Nm @@ -155,6 +163,8 @@ .It Compex Net-A adapter .It +Compex RL2000 +.It Contec C-NET(98), RT-1007(98), C-NET(9N) (110pin) (flags 0xa00000) (PC-98) .It Contec C-NET(98)E-A, C-NET(98)L-A, C-NET(98)P (flags 0x300000) (PC-98) @@ -163,6 +173,8 @@ .It Corega Ether PCC-T/EtherII PCC-T/FEther PCC-TXF/PCC-TXD .It +Corega LAPCCTXD (TC5299J) +.It CyQ've ELA-010 .It DEC EtherWorks DE305 @@ -181,6 +193,8 @@ .It ELECOM Laneed LD-CDL/TX, LD-CDF, LD-CDS, LD-10/100CD, LD-CDWA (DP83902A) .It +Hawking PN652TX PC Card (AX88790) +.It HP PC Lan+ 27247B and 27252A .Pq Cd "options ED_HPP" .It @@ -199,6 +213,8 @@ .It Kingston KNE-PC2, CIO10T, KNE-PCM/x Ethernet .It +KTI ET32P2 PCI +.It Linksys EC2T/PCMPC100/PCM100, PCMLM56 .It Linksys EtherFast 10/100 PC Card, Combo PCMCIA Ethernet Card (PCMPC100 V2) @@ -229,7 +245,7 @@ .It NetGear FA-410TX .It -NetVin 5000 +NetVin NV5000SC .It Network Everywhere Ethernet 10BaseT PC Card .It @@ -253,6 +269,8 @@ .It Psion 10/100 LANGLOBAL Combine iT .It +RealTek 8019 +.It RealTek 8029 .It Relia Combo-L/M-56k PC Card @@ -265,7 +283,7 @@ .It SMC WD8003E/WD8003EBT/WD8003S/WD8003SBT/WD8003W/WD8013EBT/WD8013W and clones .It -SMC EZCard PC Card, 8040-TX, 8041-TX +SMC EZCard PC Card, 8040-TX, 8041-TX, 8041-TX V.2 .It Socket LP-E, ES-1000 Ethernet/Serial, LP-E CF, LP-FE CF .It @@ -284,6 +302,8 @@ VIA VT86C926 .It Winbond W89C940 +.It +Winbond W89C940F .El .Pp C-Bus, ISA, PCI and PC Card devices are supported. @@ -389,6 +409,6 @@ have been received but not yet transferred from the card to main memory. .Pp The -.Nm -PC Card attachment supports the D-Link DMF650TX Lan/Modem card's ethernet +.Nm +PC Card attachment supports the D-Link DMF650TX LAN/Modem card's Ethernet port only at this time. Index: src/share/man/man4/em.4 diff -u src/share/man/man4/em.4:1.20.2.5 src/share/man/man4/em.4:1.28 --- src/share/man/man4/em.4:1.20.2.5 Fri Feb 16 21:55:23 2007 +++ src/share/man/man4/em.4 Tue Jan 30 16:40:03 2007 @@ -31,7 +31,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 27, 2005 +.Dd September 15, 2006 .Dt EM 4 .Os .Sh NAME @@ -58,7 +58,9 @@ the Intel 82540, 82541ER, 82541PI, 82542, 82543, 82544, 82545, 82546, 82546EB, 82546GB, 82547, 82571, 81572 and 82573 Ethernet controller chips. The driver supports Transmit/Receive checksum offload -and Jumbo Frames only on 82540, 82543, 82544 and 82546-based adapters. +and Jumbo Frames on all but 82542-based adapters. +Furthermore it supports TCP segmentation offload (TSO) on all adapters but +those based on the 82543, 82544 and 82547 controller chips. For further hardware information, see the .Pa README included with the driver. @@ -75,8 +77,6 @@ The maximum MTU size for Jumbo Frames is 16114. .Pp This driver version supports VLANs. -For information on enabling VLANs, see the -.Pa README . The .Nm driver supports the following media types: @@ -218,10 +218,6 @@ the network connection (cable). .El .Sh SUPPORT -For additional information regarding building and installation, -see the -.Pa README -included with the driver. For general information and support, go to the Intel support website at: .Pa http://support.intel.com . Index: src/share/man/man4/enc.4 diff -u src/share/man/man4/enc.4:1.2.2.2 src/share/man/man4/enc.4:1.6 --- src/share/man/man4/enc.4:1.2.2.2 Fri Feb 16 01:24:31 2007 +++ src/share/man/man4/enc.4 Thu Nov 29 06:35:48 2007 @@ -31,7 +31,7 @@ .\" .\" $FreeBSD$ .\" -.Dd June 16, 2006 +.Dd November 28, 2007 .Dt ENC 4 .Os .Sh NAME @@ -49,39 +49,85 @@ .Nm interface is a software loopback mechanism that allows hosts or firewalls to filter -.Xr fast_ipsec 4 +.Xr ipsec 4 traffic using any firewall package that hooks in via the .Xr pfil 9 framework. .Pp The .Nm -interface allows an administrator -to see outgoing packets before they have been processed by -.Xr fast_ipsec 4 , -or incoming packets after they have been similarly processed, via +interface allows an administrator to see incoming and outgoing packets +before and after they will be or have been processed by +.Xr ipsec 4 +via .Xr tcpdump 1 . .Pp The -.Dq enc0 +.Dq Li enc0 interface inherits all IPsec traffic. Thus all IPsec traffic can be filtered based on -.Dq enc0 , +.Dq Li enc0 , and all IPsec traffic could be seen by invoking .Xr tcpdump 1 on the -.Dq enc0 +.Dq Li enc0 interface. +.Pp +What can be seen with +.Xr tcpdump 1 +and what will be passed on to the firewalls via the +.Xr pfil 9 +framework can be independently controlled using the following +.Xr sysctl 8 +variables: +.Bl -column net.enc.out.ipsec_filter_mask 0x00000000 0x00000000 +.It Sy "Name Defaults Suggested" +.It "net.enc.out.ipsec_bpf_mask" 0x00000003 0x00000001 +.It "net.enc.out.ipsec_filter_mask" 0x00000001 0x00000001 +.It "net.enc.in.ipsec_bpf_mask" 0x00000001 0x00000002 +.It "net.enc.in.ipsec_filter_mask" 0x00000001 0x00000002 +.El +.Pp +For the incoming path a value of +.Li 0x1 +means +.Dq Li before stripping off the outer header +and +.Li 0x2 +means +.Dq Li after stripping off the outer header . +For the outgoing path +.Li 0x1 +means +.Dq Li with only the inner header +and +.Li 0x2 +means +.Dq Li with outer and inner headers . +.Bd -literal +incoming path |------| +---- IPsec processing ---- (before) ---- (after) ----> | | + | Host | +<--- IPsec processing ---- (after) ----- (before) ---- | | +outgoing path |------| +.Ed +.Pp +Most people will want to run with the suggested defaults for +.Cm ipsec_filter_mask +and rely on the security policy database for the outer headers. .Sh EXAMPLES -To see all outgoing packets before they have been processed via -.Xr fast_ipsec 4 , -or all incoming packets after they have been similarly processed: +To see the packets the processed via +.Xr ipsec 4 , +adjust the +.Xr sysctl 8 +variables according to your need and run: .Pp -.Dl # tcpdump -i enc0 +.Dl "tcpdump -i enc0" .Sh SEE ALSO .Xr tcpdump 1 , .Xr bpf 4 , -.Xr fast_ipsec 4 , .Xr ipf 4 , .Xr ipfw 4 , -.Xr pf 4 +.Xr ipsec 4 , +.Xr pf 4 , +.Xr tcpdump 8 Index: src/share/man/man4/fast_ipsec.4 diff -u src/share/man/man4/fast_ipsec.4:1.3.2.1 src/share/man/man4/fast_ipsec.4:removed --- src/share/man/man4/fast_ipsec.4:1.3.2.1 Tue Jul 25 07:20:58 2006 +++ src/share/man/man4/fast_ipsec.4 Thu Jan 17 11:57:39 2008 @@ -1,122 +0,0 @@ -.\" Copyright (c) 2003 -.\" Sam Leffler . 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 Sam Leffler 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 Bill Paul OR THE VOICES IN HIS HEAD -.\" 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$ -.\" -.Dd January 20, 2003 -.Dt FAST_IPSEC 4 -.Os -.Sh NAME -.Nm "Fast IPsec" -.Nd hardware-accelerated IP Security Protocols -.Sh SYNOPSIS -.Cd "options FAST_IPSEC" -.Cd "device crypto" -.Pp -.Bl -item -compact -.It -.Va net.inet.esp.enable -.It -.Va net.inet.ah.enable -.It -.Va net.inet.ipcomp.enable -.El -.Sh DESCRIPTION -.Tn IPsec -is a set of protocols, -.Tn ESP -(for Encapsulating Security Payload) -.Tn AH -(for Authentication Header), -and -.Tn IPComp -(for IP Payload Compression Protocol) -that provide security services for IP datagrams. -.Nm -is an experimental implementation of these protocols that uses the -.Xr crypto 4 -subsystem to carry out cryptographic operations. -This means, in particular, that cryptographic hardware devices are -employed whenever possible to optimize the performance of these protocols. -.Pp -In general, the -.Nm -implementation is intended to be compatible with the -.Tn KAME IPsec -implementation. -This documentation concentrates on differences from that software. -The user should refer to -.Xr ipsec 4 -for basic information on setting up and using these protocols. -.Pp -System configuration requires the -.Xr crypto 4 -subsystem. -When the -.Nm -protocols are configured for use, all protocols are included in the system. -To selectively enable/disable protocols, use -.Xr sysctl 8 . -.Pp -The packets can be passed to a virtual interface, -.Dq enc0 , -to perform packet filtering before outbound encryption and after decapsulation -inbound. -.Sh DIAGNOSTICS -To be added. -.Sh SEE ALSO -.Xr crypto 4 , -.Xr enc 4 , -.Xr ipsec 4 , -.Xr setkey 8 , -.Xr sysctl 8 -.Sh HISTORY -The protocols draw heavily on the -.Ox -implementation of the -.Tn IPsec -protocols. -The policy management code is derived from the -.Tn KAME -implementation found -in their -.Tn IPsec -protocols. -The -.Nm -protocols first appeared in -.Fx 5.0 . -.Sh BUGS -There is presently no support for IPv6. -.Pp -The -.Tn IPcomp -protocol support does not work. -.Pp -Certain legacy authentication algorithms are not supported because of -issues with the -.Xr crypto 4 -subsystem. -.Pp -This documentation is incomplete. Index: src/share/man/man4/fdc.4 diff -u src/share/man/man4/fdc.4:1.34.8.2 src/share/man/man4/fdc.4:1.37 --- src/share/man/man4/fdc.4:1.34.8.2 Tue Oct 31 01:01:16 2006 +++ src/share/man/man4/fdc.4 Fri Dec 15 00:40:57 2006 @@ -157,7 +157,7 @@ In that case, the CMOS configuration memory will be consulted to obtain the value for that drive. The ACPI probe automatically determines these values via the _FDE and -_FDI methods, but this can be overriden by specifying a drive type hint. +_FDI methods, but this can be overridden by specifying a drive type hint. .Pp Normally, each configured drive will be probed at initialization time, using a short seek sequence. Index: src/share/man/man4/fwohci.4 diff -u src/share/man/man4/fwohci.4:1.14.2.1 src/share/man/man4/fwohci.4:1.16 --- src/share/man/man4/fwohci.4:1.14.2.1 Wed Apr 5 05:01:05 2006 +++ src/share/man/man4/fwohci.4 Sun Jun 17 18:40:25 2007 @@ -52,6 +52,15 @@ .Bd -literal -offset indent firewire_load="YES" .Ed +.Pp +To disable physical access (see +.Sx BUGS +section for detail), put the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +hw.firewire.phydma_enable=0 +.Ed +.Pp .Sh HARDWARE The .Nm Index: src/share/man/man4/fxp.4 diff -u src/share/man/man4/fxp.4:1.34.2.3 src/share/man/man4/fxp.4:1.40 --- src/share/man/man4/fxp.4:1.34.2.3 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/fxp.4 Tue Jan 30 16:40:03 2007 @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 16, 2005 +.Dd January 7, 2007 .Dt FXP 4 .Os .Sh NAME @@ -122,6 +122,8 @@ .It Intel PRO/100 VE Desktop Adapter .It +Intel PRO/100 VM Network Connection +.It Intel PRO/100 M Desktop Adapter .It Intel PRO/100 S Desktop, Server and Dual-Port Server Adapters @@ -145,13 +147,6 @@ .It "fxp%d: device timeout" The device has stopped responding to the network, or there is a problem with the network connection (cable). -.It "fxp%d: Ethernet address ff:ff:ff:ff:ff:ff" -In some Alpha's (AXPpci and Multia) you must tell the driver to use (slower) -I/O rather than memory to access the card. -Create, if it does not yet exist, and add to the file -.Pa /boot/device.hints -the line -.Dq Li hint.fxp.0.prefer_iomap="0" . .It "fxp%d: Microcode loaded, int_delay: %d usec bundle_max: %d" The chip has successfully downloaded the microcode, and changed the parameterized values to the given settings. Index: src/share/man/man4/gbde.4 diff -u src/share/man/man4/gbde.4:1.10 src/share/man/man4/gbde.4:1.11 --- src/share/man/man4/gbde.4:1.10 Fri Mar 7 17:36:14 2003 +++ src/share/man/man4/gbde.4 Wed Jan 11 02:55:24 2006 @@ -66,7 +66,7 @@ .Pp If, on the other hand, the device is .Dq cold , -it should present an formidable +it should present a formidable challenge for an attacker to gain access to the contents in the absence of a valid pass-phrase. .Pp @@ -101,7 +101,7 @@ The lock-sector contains an encrypted copy of an architecture neutral byte-sequence which encodes the fields of the lock-structure. The order in which these fields are encoded is determined from the key-material. -The encoded bytestream is encrypted with 256bit AES in CBC mode. +The encoded byte stream is encrypted with 256bit AES in CBC mode. .Ss Third barrier: decryption of the sector key. For each sector, an MD5 hash over a .Dq salt Index: src/share/man/man4/gem.4 diff -u src/share/man/man4/gem.4:1.4.8.1 src/share/man/man4/gem.4:1.8 --- src/share/man/man4/gem.4:1.4.8.1 Sun Sep 3 04:31:55 2006 +++ src/share/man/man4/gem.4 Thu Sep 27 05:14:16 2007 @@ -33,7 +33,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 2, 2006 +.Dd September 26, 2007 .Dt GEM 4 .Os .Sh NAME @@ -74,6 +74,17 @@ .It Sun GEM Gigabit Ethernet .El +.Pp +The +following add-on cards are known to work with the +.Nm +driver at this time: +.Pp +.Bl -bullet -compact +.It +Sun Gigabit Ethernet PCI 2.0/3.0 (GBE/P) +(part no.\& 501-4373) +.El .Sh NOTES On sparc64 the .Nm @@ -100,13 +111,10 @@ .Sh CAVEATS Currently the .Nm -driver fails to attach to Sun Gigabit Ethernet 2.0/3.0 (GBE/P) cards, -as the SERDES used on these cards is not supported so far. -The -.Nm -driver will also fail to probe and attach to Sun Gigabit Ethernet 2.0/3.0 (GBE/S) cards, +driver fails to attach to Sun Gigabit Ethernet SBus 2.0/3.0 (GBE/S) cards, as no SBus front-end has been written so far. .Sh SEE ALSO +.Xr altq 4 , .Xr hme 4 , .Xr miibus 4 , .Xr netintro 4 , Index: src/share/man/man4/geom.4 diff -u src/share/man/man4/geom.4:1.13 src/share/man/man4/geom.4:1.16 --- src/share/man/man4/geom.4:1.13 Wed Jun 15 21:31:22 2005 +++ src/share/man/man4/geom.4 Thu May 25 21:39:27 2006 @@ -34,27 +34,36 @@ .\" .\" $FreeBSD$ .\" -.Dd March 27, 2002 +.Dd May 25, 2006 .Os .Dt GEOM 4 .Sh NAME .Nm GEOM -.Nd modular disk I/O request transformation framework. +.Nd "modular disk I/O request transformation framework" .Sh DESCRIPTION -The GEOM framework provides an infrastructure in which "classes" +The +.Nm +framework provides an infrastructure in which +.Dq classes can perform transformations on disk I/O requests on their path from the upper kernel to the device drivers and back. .Pp -Transformations in a GEOM context range from the simple geometric +Transformations in a +.Nm +context range from the simple geometric displacement performed in typical disk partitioning modules over RAID algorithms and device multipath resolution to full blown cryptographic protection of the stored data. .Pp -Compared to traditional "volume management", GEOM differs from most +Compared to traditional +.Dq "volume management" , +.Nm +differs from most and in some cases all previous implementations in the following ways: .Bl -bullet .It -GEOM is extensible. +.Nm +is extensible. It is trivially simple to write a new class of transformation and it will not be given stepchild treatment. If @@ -62,10 +71,11 @@ recognizing and configuring their VTOC information would be a trivial matter. .It -GEOM is topologically agnostic. +.Nm +is topologically agnostic. Most volume management implementations have very strict notions of how classes can fit together, very often -one fixed hierarchy is provided for instance subdisk - plex - +one fixed hierarchy is provided, for instance, subdisk - plex - volume. .El .Pp @@ -74,34 +84,56 @@ .Pp Fixed hierarchies are bad because they make it impossible to express the intent efficiently. -In the fixed hierarchy above it is not possible to mirror two +In the fixed hierarchy above, it is not possible to mirror two physical disks and then partition the mirror into subdisks, instead one is forced to make subdisks on the physical volumes and to mirror -these two and two resulting in a much more complex configuration. -GEOM on the other hand does not care in which order things are done, +these two and two, resulting in a much more complex configuration. +.Nm +on the other hand does not care in which order things are done, the only restriction is that cycles in the graph will not be allowed. -.Pp -.Sh "TERMINOLOGY and TOPOLOGY" -GEOM is quite object oriented and consequently the terminology +.Sh "TERMINOLOGY AND TOPOLOGY" +.Nm +is quite object oriented and consequently the terminology borrows a lot of context and semantics from the OO vocabulary: .Pp -A "class", represented by the data structure g_class implements one +A +.Dq class , +represented by the data structure +.Vt g_class +implements one particular kind of transformation. Typical examples are MBR disk partition, BSD disklabel, and RAID5 classes. .Pp -An instance of a class is called a "geom" and represented by the -data structure "g_geom". -In a typical i386 FreeBSD system, there +An instance of a class is called a +.Dq geom +and represented by the data structure +.Vt g_geom . +In a typical i386 +.Fx +system, there will be one geom of class MBR for each disk. .Pp -A "provider", represented by the data structure "g_provider", is -the front gate at which a geom offers service. -A provider is "a disk-like thing which appears in /dev" - a logical +A +.Dq provider , +represented by the data structure +.Vt g_provider , +is the front gate at which a geom offers service. +A provider is +.Do +a disk-like thing which appears in +.Pa /dev +.Dc - a logical disk in other words. -All providers have three main properties: name, sectorsize and size. -.Pp -A "consumer" is the backdoor through which a geom connects to another +All providers have three main properties: +.Dq name , +.Dq sectorsize +and +.Dq size . +.Pp +A +.Dq consumer +is the backdoor through which a geom connects to another geom provider and through which I/O requests are sent. .Pp The topological relationship between these entities are as follows: @@ -126,7 +158,7 @@ assigned as follows: .Bl -enum .It -A geom with no attached consumers has rank=1 +A geom with no attached consumers has rank=1. .It A geom with attached consumers has a rank one higher than the highest rank of the geoms of the providers its consumers are @@ -137,74 +169,83 @@ to a provider, and detach, which breaks the bond, a number of special topological maneuvers exists to facilitate configuration and to improve the overall flexibility. -.Pp -.Em TASTING +.Bl -inset +.It Em TASTING is a process that happens whenever a new class or new provider -is created and it provides the class a chance to automatically configure an -instance on providers, which it recognize as its own. +is created, and it provides the class a chance to automatically configure an +instance on providers which it recognizes as its own. A typical example is the MBR disk-partition class which will look for -the MBR table in the first sector and if found and validated it will +the MBR table in the first sector and, if found and validated, will instantiate a geom to multiplex according to the contents of the MBR. .Pp A new class will be offered to all existing providers in turn and a new provider will be offered to all classes in turn. .Pp Exactly what a class does to recognize if it should accept the offered -provider is not defined by GEOM, but the sensible set of options are: +provider is not defined by +.Nm , +but the sensible set of options are: .Bl -bullet .It Examine specific data structures on the disk. .It -Examine properties like sectorsize or mediasize for the provider. +Examine properties like +.Dq sectorsize +or +.Dq mediasize +for the provider. .It Examine the rank number of the provider's geom. .It Examine the method name of the provider's geom. .El -.Pp -.Em ORPHANIZATION +.It Em ORPHANIZATION is the process by which a provider is removed while it potentially is still being used. .Pp When a geom orphans a provider, all future I/O requests will -"bounce" on the provider with an error code set by the geom. +.Dq bounce +on the provider with an error code set by the geom. Any consumers attached to the provider will receive notification about -the orphanization when the eventloop gets around to it, and they +the orphanization when the event loop gets around to it, and they can take appropriate action at that time. .Pp A geom which came into being as a result of a normal taste operation -should selfdestruct unless it has a way to keep functioning lacking -the orphaned provider. -Geoms like diskslicers should therefore selfdestruct whereas -RAID5 or mirror geoms will be able to continue, as long as they do -not loose quorum. +should self-destruct unless it has a way to keep functioning whilst +lacking the orphaned provider. +Geoms like disk slicers should therefore self-destruct whereas +RAID5 or mirror geoms will be able to continue as long as they do +not lose quorum. .Pp When a provider is orphaned, this does not necessarily result in any immediate change in the topology: any attached consumers are still attached, any opened paths are still open, any outstanding I/O requests are still outstanding. .Pp -The typical scenario is +The typical scenario is: +.Pp .Bl -bullet -offset indent -compact .It A device driver detects a disk has departed and orphans the provider for it. .It The geoms on top of the disk receive the orphanization event and -orphans all their providers in turn. -Providers, which are not attached to, will typically self-destruct +orphan all their providers in turn. +Providers which are not attached to will typically self-destruct right away. This process continues in a quasi-recursive fashion until all -relevant pieces of the tree has heard the bad news. +relevant pieces of the tree have heard the bad news. .It Eventually the buck stops when it reaches geom_dev at the top of the stack. .It -Geom_dev will call destroy_dev(9) to stop any more request from +Geom_dev will call +.Xr destroy_dev 9 +to stop any more requests from coming in. -It will sleep until all (if any) outstanding I/O requests have +It will sleep until any and all outstanding I/O requests have been returned. -It will explicitly close (ie: zero the access counts), a change +It will explicitly close (i.e.: zero the access counts), a change which will propagate all the way down through the mesh. It will then detach and destroy its geom. .It @@ -218,93 +259,120 @@ While this approach seems byzantine, it does provide the maximum flexibility and robustness in handling disappearing devices. .Pp -The one absolutely crucial detail to be aware is that if the +The one absolutely crucial detail to be aware of is that if the device driver does not return all I/O requests, the tree will not unravel. -.Pp -.Em SPOILING +.It Em SPOILING is a special case of orphanization used to protect against stale metadata. It is probably easiest to understand spoiling by going through an example. .Pp -Imagine a disk, "da0" on top of which a MBR geom provides -"da0s1" and "da0s2" and on top of "da0s1" a BSD geom provides -"da0s1a" through "da0s1e", both the MBR and BSD geoms have +Imagine a disk, +.Pa da0 , +on top of which an MBR geom provides +.Pa da0s1 +and +.Pa da0s2 , +and on top of +.Pa da0s1 +a BSD geom provides +.Pa da0s1a +through +.Pa da0s1e , +and that both the MBR and BSD geoms have autoconfigured based on data structures on the disk media. -Now imagine the case where "da0" is opened for writing and those -data structures are modified or overwritten: Now the geoms would +Now imagine the case where +.Pa da0 +is opened for writing and those +data structures are modified or overwritten: now the geoms would be operating on stale metadata unless some notification system can inform them otherwise. .Pp -To avoid this situation, when the open of "da0" for write happens, -all attached consumers are told about this, and geoms like -MBR and BSD will selfdestruct as a result. -When "da0" is closed again, it will be offered for tasting again -and if the data structures for MBR and BSD are still there, new +To avoid this situation, when the open of +.Pa da0 +for write happens, +all attached consumers are told about this and geoms like +MBR and BSD will self-destruct as a result. +When +.Pa da0 +is closed, it will be offered for tasting again +and, if the data structures for MBR and BSD are still there, new geoms will instantiate themselves anew. .Pp Now for the fine print: .Pp If any of the paths through the MBR or BSD module were open, they -would have opened downwards with an exclusive bit rendering it -impossible to open "da0" for writing in that case and conversely +would have opened downwards with an exclusive bit thus rendering it +impossible to open +.Pa da0 +for writing in that case. +Conversely, the requested exclusive bit would render it impossible to open a -path through the MBR geom while "da0" is open for writing. +path through the MBR geom while +.Pa da0 +is open for writing. .Pp From this it also follows that changing the size of open geoms can only be done with their cooperation. .Pp Finally: the spoiling only happens when the write count goes from -zero to non-zero and the retasting only when the write count goes +zero to non-zero and the retasting happens only when the write count goes from non-zero to zero. -.Pp -.Em INSERT/DELETE -are a very special operation which allows a new geom +.It Em INSERT/DELETE +are very special operations which allow a new geom to be instantiated between a consumer and a provider attached to each other and to remove it again. .Pp -To understand the utility of this, imagine a provider with +To understand the utility of this, imagine a provider being mounted as a file system. -Between the DEVFS geoms consumer and its provider we insert +Between the DEVFS geom's consumer and its provider we insert a mirror module which configures itself with one mirror copy and consequently is transparent to the I/O requests on the path. We can now configure yet a mirror copy on the mirror geom, request a synchronization, and finally drop the first mirror copy. -We have now in essence moved a mounted file system from one +We have now, in essence, moved a mounted file system from one disk to another while it was being used. At this point the mirror geom can be deleted from the path -again, it has served its purpose. -.Pp -.Em CONFIGURE +again; it has served its purpose. +.It Em CONFIGURE is the process where the administrator issues instructions for a particular class to instantiate itself. There are multiple -ways to express intent in this case, a particular provider can be -specified with a level of override forcing for instance a BSD +ways to express intent in this case - a particular provider may be +specified with a level of override forcing, for instance, a BSD disklabel module to attach to a provider which was not found palatable during the TASTE operation. .Pp -Finally IO is the reason we even do this: it concerns itself with +Finally, I/O is the reason we even do this: it concerns itself with sending I/O requests through the graph. -.Pp -.Em "I/O REQUESTS -represented by struct bio, originate at a consumer, -are scheduled on its attached provider, and when processed, returned +.It Em "I/O REQUESTS" , +represented by +.Vt "struct bio" , +originate at a consumer, +are scheduled on its attached provider and, when processed, are returned to the consumer. -It is important to realize that the struct bio which -enters through the provider of a particular geom does not "come -out on the other side". +It is important to realize that the +.Vt "struct bio" +which enters through the provider of a particular geom does not +.Do +come out on the other side +.Dc . Even simple transformations like MBR and BSD will clone the -struct bio, modify the clone, and schedule the clone on their +.Vt "struct bio" , +modify the clone, and schedule the clone on their own consumer. -Note that cloning the struct bio does not involve cloning the -actual data area specified in the IO request. -.Pp -In total four different IO requests exist in GEOM: read, write, -delete, and get attribute. +Note that cloning the +.Vt "struct bio" +does not involve cloning the +actual data area specified in the I/O request. +.Pp +In total, four different I/O requests exist in +.Nm : +read, write, delete, and +.Dq "get attribute". .Pp Read and write are self explanatory. .Pp @@ -320,24 +388,32 @@ request and consequently there is no guarantee that the data actually will be erased or made unavailable unless guaranteed by specific geoms in the graph. -If "secure delete" semantics are required, a +If +.Dq "secure delete" +semantics are required, a geom should be pushed which converts delete indications into (a sequence of) write requests. .Pp -Get attribute supports inspection and manipulation +.Dq "Get attribute" +supports inspection and manipulation of out-of-band attributes on a particular provider or path. -Attributes are named by ascii strings and they will be discussed in +Attributes are named by +.Tn ASCII +strings and they will be discussed in a separate section below. +.El .Pp -(stay tuned while the author rests his brain and fingers: more to come.) +(Stay tuned while the author rests his brain and fingers: more to come.) .Sh DIAGNOSTICS -Several flags are provided for tracing GEOM operations and unlocking +Several flags are provided for tracing +.Nm +operations and unlocking protection mechanisms via the .Va kern.geom.debugflags sysctl. All of these flags are off by default, and great care should be taken in turning them on. -.Bl -tag -width FAIL +.Bl -tag -width indent .It 0x01 Pq Dv G_T_TOPOLOGY Provide tracing of topology change events. .It 0x02 Pq Dv G_T_BIO @@ -350,22 +426,29 @@ This would, for example, allow the super-user to overwrite the MBR on the root disk or write random sectors elsewhere to a mounted disk. The implications are obvious. -.It 0x20 Pq Dv G_T_DETAILS -This appears to be unused at this time. .It 0x40 Pq Dv G_F_DISKIOCTL -This appears to be unused at this time. +This is unused at this time. .It 0x80 Pq Dv G_F_CTLDUMP Dump contents of gctl requests. .El .Sh HISTORY -This software was developed for the FreeBSD Project by Poul-Henning Kamp +This software was developed for the +.Fx +Project by +.An Poul-Henning Kamp and NAI Labs, the Security Research Division of Network Associates, Inc.\& -under DARPA/SPAWAR contract N66001-01-C-8035 ("CBOSS"), as part of the +under DARPA/SPAWAR contract N66001-01-C-8035 +.Pq Dq CBOSS , +as part of the DARPA CHATS research program. .Pp -The first precursor for GEOM was a gruesome hack to Minix 1.2 and was +The first precursor for +.Nm +was a gruesome hack to Minix 1.2 and was never distributed. An earlier attempt to implement a less general scheme -in FreeBSD never succeeded. +in +.Fx +never succeeded. .Sh AUTHORS .An "Poul-Henning Kamp" Aq phk@FreeBSD.org Index: src/share/man/man4/geom_fox.4 diff -u src/share/man/man4/geom_fox.4:1.1.2.2 src/share/man/man4/geom_fox.4:1.3 --- src/share/man/man4/geom_fox.4:1.1.2.2 Mon Jun 26 03:47:45 2006 +++ src/share/man/man4/geom_fox.4 Sat Sep 30 23:14:48 2006 @@ -47,7 +47,7 @@ .Ed .Sh DESCRIPTION The intent of the -.Nm +.Nm framework is to provide basic multipathing support to access direct access devices. Basic in the above sentence should be read as: @@ -88,7 +88,7 @@ .Pp .Bl -bullet -compact .It -.Nm +.Nm needs a label on the disk as follows in order to work properly: .Bd -literal "0123456789abcdef0123456789abcdef" @@ -96,14 +96,14 @@ .Ed .Pp For the unique ID 16 bytes are available. -The -.Li GEOM::FOX +The +.Dq Li GEOM::FOX is the magic to mark a .Nm device. .Pp The actual labelling is accomplished by -.Bd -literal +.Bd -literal echo "GEOM::FOX someid" | dd of=/dev/da2 conv=sync .Ed .Pp @@ -190,8 +190,16 @@ devices. Safety belts are not provided. For FibreChannel devices it is suggested to use the Port WWN of the device. -The World Wide Name is guaranteed to be worldwide unique per the +The World Wide Name is guaranteed to be worldwide unique per the FibreChannel standard. +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An "Poul-Henning Kamp" Aq phk@FreeBSD.org . +This manual page was written by +.An "Wilko Bulte" Aq wilko@FreeBSD.org . .Sh BUGS The .Nm @@ -204,11 +212,3 @@ Just remember that any sly fox has multiple exits from its hole. .Pp The examples provided are too FibreChannel-centric. -.Sh AUTHORS -.An -nosplit -The -.Nm -driver was written by -.An "Poul-Henning Kamp" Aq phk@FreeBSD.org . -This manual page was written by -.An "Wilko Bulte" Aq wilko@FreeBSD.org . Index: src/share/man/man4/hptiop.4 diff -u /dev/null src/share/man/man4/hptiop.4:1.1 --- /dev/null Thu Jan 17 11:57:39 2008 +++ src/share/man/man4/hptiop.4 Sat May 12 06:52:19 2007 @@ -0,0 +1,80 @@ +.\" Copyright (c) 2007 Christian Brueffer +.\" 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$ +.\" +.Dd May 12, 2007 +.Dt HPTIOP 4 +.Os +.Sh NAME +.Nm hptiop +.Nd "HighPoint RocketRAID 3xxx device driver" +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following line in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device hptiop" +.Cd "device scbus" +.Cd "device da" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +hptiop_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for the HighPoint RocketRAID 3xxx series +of SATA RAID controllers. +.Sh HARDWARE +The +.Nm +driver supports the following SATA RAID controllers: +.Pp +.Bl -bullet -compact +.It +HighPoint RocketRAID 3220 +.El +.Sh NOTES +The +.Nm +driver only works on the i386 and amd64 platforms. +.Sh SEE ALSO +.Xr cam 4 , +.Xr hptmv 4 , +.Xr rr232x 4 +.Sh HISTORY +The +.Nm +device driver first appeared in +.Fx 7.0 . +.Pp +.Sh AUTHORS +The +.Nm +driver was written by HighPoint Technologies, Inc. Index: src/share/man/man4/hptmv.4 diff -u src/share/man/man4/hptmv.4:1.4.2.3 src/share/man/man4/hptmv.4:1.8 --- src/share/man/man4/hptmv.4:1.4.2.3 Tue Jun 6 03:30:28 2006 +++ src/share/man/man4/hptmv.4 Mon Sep 18 23:24:18 2006 @@ -68,8 +68,8 @@ blob object from the manufacturer which they only supply for these platforms. The .Nm -driver -.Em does not +driver does +.Em not work on i386 with .Xr pae 4 enabled. Index: src/share/man/man4/hwpmc.4 diff -u src/share/man/man4/hwpmc.4:1.6.2.5 src/share/man/man4/hwpmc.4:1.22 --- src/share/man/man4/hwpmc.4:1.6.2.5 Mon May 15 09:43:53 2006 +++ src/share/man/man4/hwpmc.4 Fri Dec 7 16:29:46 2007 @@ -1,6 +1,10 @@ -.\" Copyright (c) 2003-2005 Joseph Koshy +.\" Copyright (c) 2003-2007 Joseph Koshy +.\" Copyright (c) 2007 The FreeBSD Foundation .\" All rights reserved. .\" +.\" Portions of this software were developed by A. Joseph Koshy under +.\" sponsorship from the FreeBSD Foundation and Google, Inc. +.\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: @@ -24,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 15, 2005 +.Dd November 24, 2007 .Dt HWPMC 4 .Os .Sh NAME @@ -50,27 +54,23 @@ request. A successful .Dv PMC_OP_PMCALLOCATE -request will return an integer handle to the requesting process. +request will return a handle to the requesting process. Subsequent operations on the allocated PMC use this handle to denote the specific PMC. A process that has successfully allocated a PMC is termed an .Dq "owner process" . .Pp -PMCs may be allocated to operate in process-private or in system-wide -modes. -.Bl -tag -width ".Em Process-private" -.It Em Process-private -In process-private mode, a PMC is active only when a thread belonging +PMCs may be allocated with process or system scope. +.Bl -tag -width ".Em Process-scope" +.It Em "Process-scope" +The PMC is active only when a thread belonging to a process it is attached to is scheduled on a CPU. -.It Em System-wide -In system-wide mode, a PMC operates independently of processes and +.It Em "System-scope" +The PMC operates independently of processes and measures hardware events for the system as a whole. .El .Pp -The -.Nm -driver supports the use of hardware PMCs for counting or for -sampling: +PMCs may be allocated for counting or for sampling: .Bl -tag -width ".Em Counting" .It Em Counting In counting modes, the PMCs count hardware events. @@ -80,16 +80,17 @@ Some architectures offer faster methods of reading these counts. .It Em Sampling In sampling modes, the PMCs are configured to sample the CPU -instruction pointer after a configurable number of hardware events -have been observed. -These instruction pointer samples are usually directed to a log file -for subsequent analysis. +instruction pointer (and optionally to capture the call chain leading +upto the sampled instruction pointer) after a configurable number of +hardware events have been observed. +Instruction pointer samples and call chain records are usually +directed to a log file for subsequent analysis. .El .Pp -These modes of operation are orthogonal; a PMC may be configured to -operate in one of four modes: +Scope and operational mode are orthogonal; a PMC may thus be +configured to operate in one of the following four modes: .Bl -tag -width indent -.It Process-private, counting +.It Process-scope, counting These PMCs count hardware events whenever a thread in their attached process is scheduled on a CPU. These PMCs normally count from zero, but the initial count may be @@ -99,7 +100,7 @@ Applications can read the value of the PMC anytime using the .Dv PMC_OP_PMCRW operation. -.It Process-private, sampling +.It Process-scope, sampling These PMCs sample the target processes instruction pointer after they have seen the configured number of hardware events. The PMCs only count events when a thread belonging to their attached @@ -110,7 +111,7 @@ Log files are configured using the .Dv PMC_OP_CONFIGURELOG operation. -.It System-wide, counting +.It System-scope, counting These PMCs count hardware events seen by them independent of the processes that are executing. The current count on these PMCs can be read using the @@ -120,7 +121,7 @@ set using the .Dv PMC_OP_SETCOUNT operation. -.It System-wide, sampling +.It System-scope, sampling These PMCs will periodically sample the instruction pointer of the CPU they are allocated on, and will write the sample to a log for further processing. @@ -139,10 +140,7 @@ current operating conditions permit. Processes may mix allocations of system-wide and process-private PMCs. -Multiple processes are allowed to be concurrently using the facilities -of the -.Nm -driver. +Multiple processes may be using PMCs simultaneously. .Pp Allocated PMCs are started using the .Dv PMC_OP_PMCSTART @@ -188,6 +186,13 @@ operation supports the following flags that modify the behavior of an allocated PMC: .Bl -tag -width indent +.It Dv PMC_F_CALLCHAIN +This modifier informs sampling PMCs to record a callchain when +capturing a sample. +The maximum depth to which call chains are recorded is specified +by the +.Va "kern.hwpmc.callchaindepth" +kernel tunable. .It Dv PMC_F_DESCENDANTS This modifier is valid only for a PMC being allocated in process-private mode. @@ -199,6 +204,7 @@ It signifies that the PMC's sampling interrupt is to be used to drive kernel profiling via .Xr kgmon 8 . +This functionality is currently unimplemented. .It Dv PMC_F_LOG_PROCCSW This modifier is valid only for a PMC being allocated in process-private mode. @@ -245,6 +251,27 @@ .Nm driver is being unloaded from the kernel. .El +.Ss PMC ROW DISPOSITIONS +A PMC row is defined as the set of PMC resources at the same hardware +address in the CPUs in a system. +Since process scope PMCs need to move between CPUs following their +target threads, allocation of a process scope PMC reserves all PMCs in +a PMC row for use only with process scope PMCs. +Accordingly a PMC row will be in one of the following dispositions: +.Bl -tag -width ".Dv PMC_DISP_STANDALONE" -compact +.It Dv PMC_DISP_FREE +Hardware counters in this row are free and may be use to satisfy +either of system scope or process scope allocation requests. +.It Dv PMC_DISP_THREAD +Hardware counters in this row are in use by process scope PMCs +and are only available for process scope allocation requests. +.It Dv PMC_DISP_STANDALONE +Some hardware counters in this row have been administratively +disabled or are in use by system scope PMCs. +Non-disabled hardware counters in such a row may be used +for satisfying system scope allocation requests. +No process scope PMCs will use hardware counters in this row. +.El .Sh PROGRAMMING API The recommended way for application programs to use the facilities of the @@ -263,13 +290,22 @@ driver supports the following operations: .Bl -tag -width indent .It Dv PMC_OP_CONFIGURELOG -Configure a log file for sampling mode PMCs. +Configure a log file for PMCs that require a log file. +The +.Nm +driver will write log data to this file asynchronously. +If it encounters an error, logging will be stopped and the error code +encountered will be saved for subsequent retrieval by a +.Dv PMC_OP_FLUSHLOG +request. .It Dv PMC_OP_FLUSHLOG Transfer buffered log data inside .Nm to a configured output file. This operation returns to the caller after the write operation has returned. +The returned error code reflects any pending error state inside +.Nm . .It Dv PMC_OP_GETCPUINFO Retrieve information about the number of CPUs on the system and the number of hardware performance monitoring counters available per-CPU. @@ -287,9 +323,12 @@ the hardware PMCs managed by the .Nm driver. +The invoking process needs to possess the +.Dv PRIV_PMC_MANAGE +privilege. .It Dv PMC_OP_PMCALLOCATE Allocate and configure a PMC. -On successful allocation, a handle to the PMC (a small integer) +On successful allocation, a handle to the PMC (a 32 bit value) is returned. .It Dv PMC_OP_PMCATTACH Attach a process mode PMC to a target process. @@ -364,6 +403,9 @@ .Xr loader 8 tunables: .Bl -tag -width indent +.It Va kern.hwpmc.callchaindepth Pq integer, read-only +The maximum number of call chain records to capture per sample. +The default is 8. .It Va kern.hwpmc.debugflags Pq string, read-write (Only available if the .Nm @@ -532,6 +574,10 @@ .Nm driver may fail with the following errors: .Bl -tag -width Er +.It Bq Er EAGAIN +Helper process creation failed for a +.Dv PMC_OP_CONFIGURELOG +request due to a temporary resource shortage in the kernel. .It Bq Er EBUSY A .Dv PMC_OP_CONFIGURELOG @@ -567,6 +613,11 @@ and .Dv PMC_F_LOG_PROCEXIT modifiers. +.It Bq Er EDOOFUS +A +.Dv PMC_OP_PMCSTART +operation was requested on a system-wide sampling PMC without a log +file being configured. .It Bq Er EEXIST A .Dv PMC_OP_PMCATTACH @@ -575,12 +626,21 @@ .It Bq Er EFAULT A bad address was passed in to the driver. .It Bq Er EINVAL -A process specified an invalid PMC handle. +An invalid PMC handle was specified. .It Bq Er EINVAL An invalid CPU number was passed in for a .Dv PMC_OP_GETPMCINFO operation. .It Bq Er EINVAL +A +.Dv PMC_OP_CONFIGURELOG +request to de-configure a log file was issued without a log file +being configured. +.It Bq Er EINVAL +A +.Dv PMC_OP_FLUSHLOG +request was issued without a log file being configured. +.It Bq Er EINVAL An invalid CPU number was passed in for a .Dv PMC_OP_PMCADMIN operation. @@ -608,13 +668,13 @@ A CPU other than .Dv PMC_CPU_ANY was specified in a -.Dv PMC_OP_ALLOCATE +.Dv PMC_OP_PMCALLOCATE request for a process-private PMC. .It Bq Er EINVAL A CPU number of .Dv PMC_CPU_ANY was specified in a -.Dv PMC_OP_ALLOCATE +.Dv PMC_OP_PMCALLOCATE request for a system-wide PMC. .It Bq Er EINVAL The @@ -623,14 +683,24 @@ .Dv PMC_OP_PMCALLOCATE request contained unknown flags. .It Bq Er EINVAL +(On Intel Pentium 4 CPUs with HTT support) +A +.Dv PMC_OP_PMCALLOCATE +request for a process-private PMC was issued for an event that does +not support counting on a per-logical CPU basis. +.It Bq Er EINVAL A PMC allocated for system-wide operation was specified with a .Dv PMC_OP_PMCATTACH +or +.Dv PMC_OP_PMCDETACH request. .It Bq Er EINVAL The .Ar pm_pid argument to a .Dv PMC_OP_PMCATTACH +or +.Dv PMC_OP_PMCDETACH request specified an illegal process ID. .It Bq Er EINVAL A @@ -650,14 +720,14 @@ a PMC that was allocated with flag .Dv PMC_F_DESCENDANTS . .It Bq Er EINVAL -(On Intel Pentium 4 CPUs with HTT support) -An allocation request for -a process-private PMC was issued for an event that does not support -counting on a per-logical CPU basis. +A +.Dv PMC_OP_WRITELOG +request was issued for an owner process without a log file +configured. .It Bq Er ENOMEM The system was not able to allocate kernel memory. .It Bq Er ENOSYS -(i386 architectures) +(On i386 and amd64 architectures) A .Dv PMC_OP_PMCX86GETMSR operation was requested for hardware that does not support reading @@ -709,13 +779,14 @@ .It Bq Er ESRCH A .Dv PMC_OP_PMCATTACH +or +.Dv PMC_OP_PMCDETACH request specified a non-existent process ID. .It Bq Er ESRCH The target process for a .Dv PMC_OP_PMCDETACH -operation is not being monitored by the -.Nm -driver. +operation is not being monitored by +.Nm . .El .Sh SEE ALSO .Xr kenv 1 , @@ -726,12 +797,19 @@ .Xr pmccontrol 8 , .Xr pmcstat 8 , .Xr sysctl 8 , +.Xr kproc_create 9 , .Xr p_candebug 9 .Sh HISTORY The .Nm driver first appeared in .Fx 6.0 . +.Sh AUTHORS +The +.Nm +driver was written by +.An "Joseph Koshy" +.Aq jkoshy@FreeBSD.org . .Sh BUGS The driver samples the state of the kernel's logical processor support at the time of initialization (i.e., at module load time). Index: src/share/man/man4/ichwd.4 diff -u /dev/null src/share/man/man4/ichwd.4:1.1 --- /dev/null Thu Jan 17 11:57:39 2008 +++ src/share/man/man4/ichwd.4 Fri Aug 24 04:05:09 2007 @@ -0,0 +1,72 @@ +.\"- +.\" Copyright (c) 2007 Dag-Erling Coïdan Smørgrav +.\" 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$ +.\" +.Dd August 23, 2007 +.Dt ICHWD 4 +.Os +.Sh NAME +.Nm ichwd +.Nd device driver for the Intel ICH watchdog interrupt timer +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following line in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device ichwd" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +ichwd_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides +.Xr watchdog 4 +support for the watchdog interrupt timer present in +the Intel ICH motherboard chipsets. +.Sh SEE ALSO +.Xr watchdog 4 , +.Xr watchdog 8 , +.Xr watchdogd 8 +.Sh HISTORY +The +.Nm +driver first appeared in +.Fx 5.3 . +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was originally written by +.An Wm. Daryl Hawkins +of Texas A&M University. +This manual page was written by +.An Dag-Erling Sm\(/orgrav Aq des@FreeBSD.org . Index: src/share/man/man4/icmp.4 diff -u src/share/man/man4/icmp.4:1.16.2.1 src/share/man/man4/icmp.4:1.20 --- src/share/man/man4/icmp.4:1.16.2.1 Sat Feb 10 20:01:39 2007 +++ src/share/man/man4/icmp.4 Fri Feb 9 20:30:17 2007 @@ -206,6 +206,20 @@ An interface name used for the ICMP reply source in response to packets which are not directly addressed to us. By default continue with normal source selection. +.It Va reply_from_interface +.Pq Vt boolean +Use the IP address of the interface the packet came through in for +responses to packets which are not directly addressed to us. +If enabled, this rule is processed before all others. +By default, continue with normal source selection. +Enabling this option is particularly useful on routers because it +makes external traceroutes show the actual path a packet has taken +instead of the possibly different return path. +.It Va quotelen +.Pq Vt integer +Number of bytes from original packet to quote in ICMP reply. +This number is internally enforced to be at least 8 bytes (per RFC792) +and at most the maximal space left in the ICMP reply mbuf. .El .Sh ERRORS A socket operation may fail with one of the following errors returned: Index: src/share/man/man4/ieee80211.4 diff -u src/share/man/man4/ieee80211.4:1.9 src/share/man/man4/ieee80211.4:1.10 --- src/share/man/man4/ieee80211.4:1.9 Mon Feb 14 07:45:49 2005 +++ src/share/man/man4/ieee80211.4 Sun Jul 1 18:25:06 2007 @@ -239,7 +239,6 @@ .Xr ancontrol 8 , .Xr ifconfig 8 , .Xr raycontrol 8 , -.Xr wicontrol 8 .Sh HISTORY The .Nm Index: src/share/man/man4/if_bridge.4 diff -u src/share/man/man4/if_bridge.4:1.5.2.16 src/share/man/man4/if_bridge.4:1.30 --- src/share/man/man4/if_bridge.4:1.5.2.16 Fri Oct 12 04:28:53 2007 +++ src/share/man/man4/if_bridge.4 Mon Sep 17 05:14:47 2007 @@ -50,10 +50,11 @@ .Ed .Pp Alternatively, to load the driver as a -module at boot time, place the following line in +module at boot time, place the following lines in .Xr loader.conf 5 : .Bd -literal -offset indent if_bridge_load="YES" +bridgestp_load="YES" .Ed .Sh DESCRIPTION The @@ -136,8 +137,10 @@ will exchange information with neighbouring switches to quickly transition to forwarding without creating loops. .Pp -The code will default to STP and can be set to operate in RSTP mode with -rapid state transitions via the +The code will default to RSTP mode but will downgrade any port connected to a +legacy STP network so is fully backward compatible. +A bridge can be forced to operate in STP mode without rapid state transitions +via the .Va proto command in .Xr ifconfig 8 . @@ -348,7 +351,7 @@ Tree enabled to be created: .Bd -literal -offset indent ifconfig bridge0 create -ifconfig bridge0 proto rstp \e +ifconfig bridge0 \e addm fxp0 stp fxp0 \e addm fxp1 stp fxp1 \e addm fxp2 stp fxp2 \e Index: src/share/man/man4/iic.4 diff -u src/share/man/man4/iic.4:1.11 src/share/man/man4/iic.4:1.15 --- src/share/man/man4/iic.4:1.11 Sun Jul 4 02:29:20 2004 +++ src/share/man/man4/iic.4 Fri Dec 15 00:40:57 2006 @@ -1,3 +1,4 @@ +.\" Copyright (c) 2006, M. Warner Losh .\" Copyright (c) 1998, Nicolas Souchu .\" All rights reserved. .\" @@ -24,35 +25,142 @@ .\" .\" $FreeBSD$ .\" -.Dd October 25, 1998 +.Dd September 6, 2006 .Dt IIC 4 .Os .Sh NAME .Nm iic -.Nd I2C generic i/o device driver +.Nd I2C generic I/O device driver .Sh SYNOPSIS .Cd "device iic" +.Pp +.In dev/iicbus/iic.h .Sh DESCRIPTION The -.Em iic -character device driver provides generic i/o to any +.Nm +device driver provides generic I/O to any .Xr iicbus 4 instance. In order to control I2C devices, use .Pa /dev/iic? with the following ioctls: -.Pp -.Bl -column "I2CRSTCARD" -compact -.It Em Ioctl Ta Em Description -.It Sy I2CSTART Ta "send start condition to the specified device (with 7-bit address) on the bus" -.It Sy I2CSTOP Ta "send stop condition to the bus" -.It Sy I2CRSTCARD Ta "reset the bus" +.Bl -tag -width ".Dv I2CRSTCARD" +.It Dv I2CSTART +.Pq Vt "struct iiccmd" +Sends the start condition to the slave specified by the +.Va slave +element to the bus. +All other elements are ignored. +.It Dv I2CSTOP +No argument is passed. +Sends the stop condition to the bus. +This terminates the current transaction. +.It Dv I2CRSTCARD +.Pq Vt "struct iiccmd" +Resets the bus. +The argument is completely ignored. +.It Dv I2CWRITE +.Pq Vt "struct iiccmd" +Writes data to the +.Xr iicbus 4 . +The bus should already be started. +The +.Va slave +element is ignored. +The +.Va count +element is the number of bytes to write. +The +.Va last +element is a boolean flag. +It is non-zero when additional write commands will follow. +The +.Va buf +element is a pointer to the data to write to the bus. +.It Dv I2CREAD +.Pq Vt "struct iiccmd" +Reads data from the +.Xr iicbus 4 . +The bus should already be started. +The +.Va slave +element is ignored. +The +.Va count +element is the number of bytes to write. +The +.Va last +element is a boolean flag. +It is non-zero when additional write commands will follow. +The +.Va buf +element is a pointer to where to store the data read from the bus. +Short reads on the bus produce undefined results. +.It Dv I2CRDWR +.Pq Vt "struct iic_rdwr_data" +Generic read/write interface. +Allows for an arbitrary number of commands to be sent to +an arbitrary number of devices on the bus. +A read transfer is specified if +.Dv IIC_M_RD +is set in +.Va flags . +Otherwise the transfer is a write transfer. +The +.Va slave +element specifies the 7-bit address for the transfer. +The +.Va len +element is the length of the data. +The +.Va buf +element is a buffer for that data. +This ioctl is intended to be +.Tn Linux +compatible. .El .Pp -You may also use read/write routines, then I2C start/stop handshake is -managed by the iicbus system. +The following data structures are defined in +.In dev/iicbus/iic.h +and referenced above: +.Bd -literal -offset indent +struct iiccmd { + u_char slave; + int count; + int last; + char *buf; +}; + +/* Designed to be compatible with linux's struct i2c_msg */ +struct iic_msg +{ + uint16_t slave; + uint16_t flags; +#define IIC_M_RD 0x0001 /* read vs write */ + uint16_t len; /* msg legnth */ + uint8_t * buf; +}; + +struct iic_rdwr_data { + struct iic_msg *msgs; + uint32_t nmsgs; +}; +.Ed +.Pp +It is also possible to use read/write routines, then I2C start/stop handshake is +managed by the +.Xr iicbus 4 +system. +However, the address used for the read/write routines is the one +passed to last +.Dv I2CSTART +.Xr ioctl 2 +to this device. .Sh SEE ALSO +.Xr ioctl 2 , +.Xr read 2 , +.Xr write 2 , .Xr iicbus 4 .Sh HISTORY The @@ -60,6 +168,15 @@ manual page first appeared in .Fx 3.0 . .Sh AUTHORS +.An -nosplit This manual page was written by -.An Nicolas Souchu . +.An Nicolas Souchu +and +.An M. Warner Losh . +.Sh BUGS +Only the +.Dv I2CRDWR +.Xr ioctl 2 +is thread safe. +All other interfaces suffer from some kind of race. Index: src/share/man/man4/inet.4 diff -u src/share/man/man4/inet.4:1.36.2.2 src/share/man/man4/inet.4:1.39 --- src/share/man/man4/inet.4:1.36.2.2 Mon Aug 29 17:10:22 2005 +++ src/share/man/man4/inet.4 Fri Dec 15 00:40:57 2006 @@ -229,7 +229,7 @@ By setting to 2, an .Tn ICMP .Dq "prohibited by filter" -message will be sent back in respose to incoming packets with IP options. +message will be sent back in response to incoming packets with IP options. Default is 1. This .Xr sysctl 8 Index: src/share/man/man4/ip.4 diff -u src/share/man/man4/ip.4:1.43.2.3 src/share/man/man4/ip.4:1.49 --- src/share/man/man4/ip.4:1.43.2.3 Wed Mar 21 08:43:30 2007 +++ src/share/man/man4/ip.4 Wed Jun 13 00:24:55 2007 @@ -32,7 +32,7 @@ .\" @(#)ip.4 8.2 (Berkeley) 11/30/93 .\" $FreeBSD$ .\" -.Dd March 18, 2007 +.Dd April 9, 2007 .Dt IP 4 .Os .Sh NAME @@ -420,6 +420,16 @@ address of the desired interface or .Dv INADDR_ANY to specify the default interface. +.Pp +To specify an interface by index, an instance of +.Vt ip_mreqn +should be passed instead. +The +.Vt imr_ifindex +member should be set to the index of the desired interface, +or 0 to specify the default interface. +The kernel differentiates between these two structures by their size. +.\" An interface's local IP address and multicast capability can be obtained via the .Dv SIOCGIFCONF @@ -672,3 +682,7 @@ .Nm protocol appeared in .Bx 4.2 . +The +.Vt ip_mreqn +structure appeared in +.Tn Linux 2.4 . Index: src/share/man/man4/ip6.4 diff -u src/share/man/man4/ip6.4:1.20 src/share/man/man4/ip6.4:1.22 --- src/share/man/man4/ip6.4:1.20 Mon Feb 14 06:25:17 2005 +++ src/share/man/man4/ip6.4 Sat Sep 30 00:16:41 2006 @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 29, 2004 +.Dd September 29, 2006 .Dt IP6 4 .Os .Sh NAME @@ -179,7 +179,7 @@ disabled on the sending socket. Multicast datagrams with a hop limit greater than 1 may be forwarded to the other networks if a multicast router (such as -.Xr mrouted 8 ) +.Xr mrouted 8 Pq Pa ports/net/mrouted ) is attached to the local network. .It Dv IPV6_MULTICAST_LOOP Fa "u_int *" Get or set the status of whether multicast datagrams will be looped back Index: src/share/man/man4/ipsec.4 diff -u src/share/man/man4/ipsec.4:1.16.2.1 src/share/man/man4/ipsec.4:1.22 --- src/share/man/man4/ipsec.4:1.16.2.1 Thu Mar 9 20:41:34 2006 +++ src/share/man/man4/ipsec.4 Mon Aug 6 00:16:14 2007 @@ -29,46 +29,77 @@ .\" .\" $FreeBSD$ .\" -.Dd February 14, 2006 +.Dd August 5, 2007 .Dt IPSEC 4 .Os .Sh NAME -.Nm ipsec -.Nd IP security protocol +.Nm IPsec +.Nd Internet Protocol Security protocol .Sh SYNOPSIS +.Cd "options IPSEC" +.Cd "options IPSEC_FILTERTUNNEL" +.Cd "device crypto" +.Pp .In sys/types.h .In netinet/in.h -.In netinet6/ipsec.h +.In netipsec/ipsec.h +.In netipsec/ipsec6.h .Sh DESCRIPTION .Nm is a security protocol implemented within the Internet Protocol layer -of the TCP/IP stack. +of the networking stack. .Nm is defined for both IPv4 and IPv6 .Xr ( inet 4 and .Xr inet6 4 ) . .Nm -contains two protocols, -ESP, the encapsulated security payload protocol and -AH, the authentication header protocol. -ESP prevents unauthorized parties from reading the payload of an IP packet -by encrypting it using -secret key cryptography algorithms. -AH both authenticates guarantees the integrity of an IP packet +is a set of protocols, +.Tn ESP +(for Encapsulating Security Payload) +.Tn AH +(for Authentication Header), +and +.Tn IPComp +(for IP Payload Compression Protocol) +that provide security services for IP datagrams. +AH both authenticates and guarantees the integrity of an IP packet by attaching a cryptographic checksum computed using one-way hash functions. +ESP, in addition, prevents unauthorized parties from reading the payload of +an IP packet by also encrypting it. +IPComp tries to increase communication performance by compressing IP payload, +thus reducing the amount of data sent. +This will help nodes on slow links but with enough computing power. .Nm -has operates in one of two modes: transport mode or tunnel mode. +operates in one of two modes: transport mode or tunnel mode. Transport mode is used to protect peer-to-peer communication between end nodes. Tunnel mode encapsulates IP packets within other IP packets and is designed for security gateways such as VPN endpoints. +.Pp +System configuration requires the +.Xr crypto 4 +subsystem. +.Pp +The packets can be passed to a virtual +.Xr enc 4 +interface, +to perform packet filtering before outbound encryption and after decapsulation +inbound. +.Pp +To properly filter on the inner packets of an +.Nm +tunnel with firewalls, add +.Cd "options IPSEC_FILTERTUNNEL" +to the kernel configuration file. .\" .Ss Kernel interface .Nm is controlled by a key management and policy engine, -that reside in the operating system kernel. Key management +that reside in the operating system kernel. +Key management is the process of associating keys with security associations, also -know as SAs. Policy management dictates when new security +know as SAs. +Policy management dictates when new security associations created or destroyed. .Pp The key management engine can be accessed from userland by using @@ -88,8 +119,9 @@ The kernel implements an extended version of the .Dv PF_KEY -interface, and allows the programmer to define IPsec policies -which are similar to the per-packet filters. The +interface and allows the programmer to define IPsec policies +which are similar to the per-packet filters. +The .Xr setsockopt 2 interface is used to define per-socket behavior, and .Xr sysctl 3 @@ -103,40 +135,42 @@ .Nm APIs. .\" .Ss Policy management -IPsec policies can be managed in one of two ways, either by +IPsec policies can be managed in one of two ways, either by configuring per-socket policies using the -.Xr setsockopt 2 +.Xr setsockopt 2 system calls, or by configuring kernel level packet filter-based policies using the .Dv PF_KEY interface, via the -.Xr setkey 8 -command. -In either case, IPsec policies must be specified using the syntax described in -.Xr ipsec_set_policy 3 . -Please refer to the .Xr setkey 8 -man page for instructions on its use. +you can define IPsec policies against packets using rules similar to packet +filtering rules. +Refer to +.Xr setkey 8 +on how to use it. .Pp When setting policies using the .Xr setkey 8 -command the +command, the .Dq Li default -option you can have the system use its default policy, explained -below, for processing packets. +option instructs the system to use its default policy, as +explained below, for processing packets. The following sysctl variables are available for configuring the -system's IPsec behavior. The variables can have one of two values. +system's IPsec behavior. +The variables can have one of two values. A .Li 1 means .Dq Li use , which means that if there is a security association then use it but if -there is not then the packets are not processed by IPsec. The value +there is not then the packets are not processed by IPsec. +The value .Li 2 is synonymous with .Dq Li require , which requires that a security association must exist for the packets -to move, and not be dropped. These terms are defined in +to move, and not be dropped. +These terms are defined in .Xr ipsec_set_policy 8 . .Bl -column net.inet6.ipsec6.esp_trans_deflev integerxxx .It Sy "Name Type Changeable" @@ -151,7 +185,8 @@ .El .Pp If the kernel does not find a matching, system wide, policy then the -default value is applied. The system wide default policy is specified +default value is applied. +The system wide default policy is specified by the following .Xr sysctl 8 variables. @@ -169,7 +204,19 @@ .El .\" .Ss Miscellaneous sysctl variables -The following variables are accessible via +When the +.Nm +protocols are configured for use, all protocols are included in the system. +To selectively enable/disable protocols, use +.Xr sysctl 8 . +.Bl -column net.inet.ipcomp.ipcomp_enable +.It Sy "Name Default" +.It "net.inet.esp.esp_enable On" +.It "net.inet.ah.ah_enable On" +.It "net.inet.ipcomp.ipcomp_enable Off" +.El +.Pp +In addition the following variables are accessible via .Xr sysctl 8 , for tweaking the kernel's IPsec behavior: .Bl -column net.inet6.ipsec6.inbonud_call_ike integerxxx @@ -235,12 +282,13 @@ and .Xr inet6 4 protocols and therefore supports most of the protocols defined upon -those IP-layer protocols. The +those IP-layer protocols. +The .Xr icmp 4 and -.Xr icmp6 4 +.Xr icmp6 4 protocols may behave differently with -.Nm +.Nm because .Nm can prevent @@ -253,6 +301,8 @@ .Xr ioctl 2 , .Xr socket 2 , .Xr ipsec_set_policy 3 , +.Xr crypto 4 , +.Xr enc 4 , .Xr icmp6 4 , .Xr intro 4 , .Xr ip6 4 , @@ -289,12 +339,42 @@ .%O work in progress material .Re .Sh HISTORY -The implementation described herein appeared in WIDE/KAME IPv6/IPsec stack. -.Sh BUGS -The IPsec support is subject to change as the IPsec protocols develop. +The original +.Nm +implementation appeared in the WIDE/KAME IPv6/IPsec stack. .Pp +For +.Fx 5.0 +a fully locked IPsec implementation called fast_ipsec was brought in. +The protocols drew heavily on the +.Ox +implementation of the +.Tn IPsec +protocols. +The policy management code was derived from the +.Tn KAME +implementation found +in their +.Tn IPsec +protocols. +The fast_ipsec implementation lacked +.Xr ip6 4 +support but made use of the +.Xr crypto 4 +subsystem. +.Pp +For +.Fx 7.0 +.Xr ip6 4 +support was added to fast_ipsec. +After this the old KAME IPsec implementation was dropped and fast_ipsec +became what now is the only +.Nm +implementation in +.Fx . +.Sh BUGS There is no single standard for the policy engine API, -so the policy engine API described herein is just for KAME implementation. +so the policy engine API described herein is just for this implementation. .Pp AH and tunnel mode encapsulation may not work as you might expect. If you configure inbound @@ -320,5 +400,12 @@ .Dv SADB_SPDDUMP operations on .Dv PF_KEY -sockets may fail due to lack of space. Increasing the socket buffer +sockets may fail due to lack of space. +Increasing the socket buffer size may alleviate this problem. +.Pp +The +.Tn IPcomp +protocol support is currently broken. +.Pp +This documentation needs more review. Index: src/share/man/man4/ipw.4 diff -u src/share/man/man4/ipw.4:1.3.2.3 src/share/man/man4/ipw.4:1.17 --- src/share/man/man4/ipw.4:1.3.2.3 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/ipw.4 Wed Nov 14 00:42:22 2007 @@ -1,4 +1,4 @@ -.\" Copyright (c) 2004 +.\" Copyright (c) 2004-2006 .\" Damien Bergamini . All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 16, 2005 +.Dd March 6, 2007 .Os .Dt IPW 4 .Sh NAME @@ -39,6 +39,7 @@ .Cd "device ipw" .Cd "device pci" .Cd "device wlan" +.Cd "device firmware" .Ed .Pp Alternatively, to load the driver as a @@ -47,6 +48,16 @@ .Bd -literal -offset indent if_ipw_load="YES" wlan_load="YES" +firmware_load="YES" +.Ed +.Pp +In both cases, place the following lines in +.Xr loader.conf 5 +to load the firmware modules: +.Bd -literal -offset indent +ipw_bss_load="YES" +ipw_ibss_load="YES" +ipw_monitor_load="YES" .Ed .Sh DESCRIPTION The @@ -64,12 +75,18 @@ .Xr ifconfig 8 . .Pp This driver requires firmware to be loaded before it will work. -You need to obtain -.Xr ipwcontrol 8 -from the IPW web page listed below to accomplish loading the firmware -before -.Xr ifconfig 8 -will work. +For the loaded firmware to work the license at +.Pa /usr/share/doc/legal/intel_ipw/LICENSE +must be agreed to and the following line be added to +.Xr loader.conf 5 : +.Pp +.Dl "legal.intel_ipw.license_ack=1" +.Sh FILES +.Bl -tag -width ".Pa /usr/share/doc/legal/intel_ipw/LICENSE" -compact +.It Pa /usr/share/doc/legal/intel_ipw/LICENSE +.Nm +firmware license +.El .Sh EXAMPLES Join an existing BSS network (i.e., connect to an access point): .Pp @@ -83,41 +100,48 @@ Join a specific BSS network with 40-bit WEP encryption: .Bd -literal -offset indent ifconfig ipw0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e - wepmode on wepkey 0x1234567890 + wepmode on wepkey 0x1234567890 weptxkey 1 .Ed .Pp Join a specific BSS network with 104-bit WEP encryption: .Bd -literal -offset indent ifconfig ipw0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e - wepmode on wepkey 0x01020304050607080910111213 + wepmode on wepkey 0x01020304050607080910111213 weptxkey 1 .Ed .Sh DIAGNOSTICS .Bl -diag .It "ipw%d: device timeout" The driver will reset the hardware. This should not happen. -.It "ipw%d: Please load firmware" -The required firmware has not been loaded into the card, and therefore -the card cannot operate. -Load the firmware with -.Xr ipwcontrol 8 -before proceeding. +.It "ipw%d: firmware error" +The onboard microcontroller crashes for some reason. +The driver will reset the hardware. +This should not happen. +.It "ipw%d: timeout waiting for firmware initialization to complete" +The onboard microcontroller failed to initialize in time. +This should not happen. +.It "ipw%d: could not load firmware image '%s'" +The driver failed to load the firmware image using the +.Xr firmware 9 +subsystem. +Verify that the necessary firmware modules are loaded and the +license agreement +.Xr loader 8 +tunable has been set. +.It "ipw%d: could not load microcode" +An attempt to upload the microcode image to the onboard microcontroller failed. +This should not happen. +.It "ipw%d: could not load firmware" +An attempt to upload the firmware image to the onboard microcontroller failed. +This should not happen. .El .Sh SEE ALSO .Xr altq 4 , -.Xr an 4 , -.Xr ath 4 , .Xr iwi 4 , .Xr pci 4 , -.Xr wi 4 , .Xr wlan 4 , -.Xr ifconfig 8 , -.Xr ipwcontrol 8 , -.Xr wicontrol 8 -.Rs -.%T The IPW Web Page -.%O http://damien.bergamini.free.fr/ipw/ -.Re +.Xr wpi 4 , +.Xr ifconfig 8 .Sh AUTHORS The .Nm Index: src/share/man/man4/iscsi_initiator.4 diff -u /dev/null src/share/man/man4/iscsi_initiator.4:1.2 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/iscsi_initiator.4 Wed Jul 25 02:08:16 2007 @@ -0,0 +1,105 @@ +.\" Copyright (c) 2007 Daniel Braniss +.\" 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$ +.\" +.Dd February 23, 2007 +.Os +.Dt ISCSI_INITIATOR 4 +.Sh NAME +.Nm iscsi_initiator +.Nd kernel driver for the iSCSI protocol +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device iscsi_initiator" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +iscsi_initiator_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +implements the kernel side of the Internet SCSI (iSCSI) network +protocol standard, the user land companion is +.Xr iscontrol 8 , +and permits access to remote +.Em virtual +SCSI devices via +.Xr cam 4 . +.Sh SYSCTL VARIABLES +.Bl -tag -width ".Va net.iscsi.n.targeaddress" +.It Va debug.iscsi_initiator +set the debug-level, 0 means no debugging, 9 for maximum. +.It Va net.iscsi.isid +the initiator part of the Session Identifier. +.It "the following are informative only:" +.It Va net.iscsi.driver_version +the current version of the driver. +.It Va net.iscsi.sessions +the number of current active sessions. +.It Va net.iscsi.n.targetname +is the targe name of session +.Em n . +.It Va net.iscsi.n.targeaddress +is the IP address of the target of session +.Em n . +.It Va net.iscsi.n.stats +are some statistics for session +.EM n +.It Va net.iscsi.n.pid +is the +.Em "process id" +of the userland side of session +.Em n , +see +.Xr iscontrol 8 . +.El +.Sh FILES +The +.Nm +driver creates the following: +.Bl -tag -width ".Pa /dev/iscsi%dxx" -compact +.Pp +.It Pa /dev/iscsi +used to create new sessions. +.It Pa /dev/iscsi%d +for each new session. +.El +.Sh SEE ALSO +.Xr cam 4 , +.Xr camcontrol 8 , +.Xr iscontrol 8 +.Sh STANDARDS +iSCSI RFC 3720 +.\" .Sh HISTORY +.\" .Sh AUTHORS +.Sh BUGS +The lun discovery method is old-fashioned. Index: src/share/man/man4/iwi.4 diff -u src/share/man/man4/iwi.4:1.4.2.5 src/share/man/man4/iwi.4:1.19 --- src/share/man/man4/iwi.4:1.4.2.5 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/iwi.4 Wed Nov 14 00:42:22 2007 @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 17, 2006 +.Dd March 6, 2007 .Os .Dt IWI 4 .Sh NAME @@ -50,6 +50,15 @@ wlan_load="YES" firmware_load="YES" .Ed +.Pp +In both cases, place the following lines in +.Xr loader.conf 5 +to load the firmware modules: +.Bd -literal -offset indent +iwi_bss_load="YES" +iwi_ibss_load="YES" +iwi_monitor_load="YES" +.Ed .Sh DESCRIPTION The .Nm @@ -66,11 +75,18 @@ .Xr ifconfig 8 . .Pp This driver requires firmware to be loaded before it will work. -You need to install the -.Pa ports/net/iwi-firmware-kmod -port before -.Xr ifconfig 8 -will work. +For the loaded firmware to work the license at +.Pa /usr/share/doc/legal/intel_iwi/LICENSE +must be agreed to and the following line be added to +.Xr loader.conf 5 : +.Pp +.Dl "legal.intel_iwi.license_ack=1" +.Sh FILES +.Bl -tag -width ".Pa /usr/share/doc/legal/intel_iwi/LICENSE" -compact +.It Pa /usr/share/doc/legal/intel_iwi/LICENSE +.Nm +firmware license +.El .Sh EXAMPLES Join an existing BSS network (i.e., connect to an access point): .Pp @@ -108,9 +124,10 @@ The driver failed to load the firmware image using the .Xr firmware 9 subsystem. -Verify that the -.Pa ports/net/iwi-firmware-kmod -port is installed correctly. +Verify that the necessary firmware modules are loaded and the +license agreement +.Xr loader 8 +tunable has been set. .It "iwi%d: could not load boot firmware" An attempt to upload the boot firmware image to the onboard microcontroller failed. @@ -125,17 +142,11 @@ .El .Sh SEE ALSO .Xr altq 4 , -.Xr an 4 , -.Xr ath 4 , .Xr ipw 4 , .Xr pci 4 , -.Xr wi 4 , .Xr wlan 4 , +.Xr wpi 4 , .Xr ifconfig 8 -.Rs -.%T The IWI Web Page -.%O http://damien.bergamini.free.fr/ipw/ -.Re .Sh AUTHORS The .Nm Index: src/share/man/man4/joy.4 diff -u src/share/man/man4/joy.4:1.26.2.1 src/share/man/man4/joy.4:1.30 --- src/share/man/man4/joy.4:1.26.2.1 Tue Feb 13 05:24:56 2007 +++ src/share/man/man4/joy.4 Tue Feb 13 04:58:32 2007 @@ -26,6 +26,8 @@ .Pa /boot/device.hints : .Cd hint.joy.0.at="isa" .Cd hint.joy.0.port="0x201" +.Cd hint.joy.1.at="isa" +.Cd hint.joy.1.port="0x201" .Pp .In sys/joystick.h .Sh DESCRIPTION @@ -102,7 +104,7 @@ .Ed .Pp Pots are normally 0-150k variable resistors (0-100k sometimes), and -according to the IBM techref, the time is given by +according to the IBM technical reference, the time is given by Time = 24.2e-6s + 0.011e-6s * R/Ohms .Sh FILES .Bl -tag -width /dev/joy? Index: src/share/man/man4/kbdmux.4 diff -u src/share/man/man4/kbdmux.4:1.1.2.3 src/share/man/man4/kbdmux.4:1.5 --- src/share/man/man4/kbdmux.4:1.1.2.3 Sat Mar 4 08:08:20 2006 +++ src/share/man/man4/kbdmux.4 Wed May 17 17:33:06 2006 @@ -3,12 +3,12 @@ .\" .Dd July 12, 2005 .Os -.Dt kbdmux 4 +.Dt KBDMUX 4 .Sh NAME .Nm kbdmux -.Nd keyboard multiplexer +.Nd "keyboard multiplexer" .Sh SYNOPSIS -.Cd device kbdmux +.Cd "device kbdmux" .Pp In .Pa /boot/device.hints : @@ -18,8 +18,10 @@ .Nm keyboard driver provides support for basic keyboard multiplexing. It is built around the idea of a -.Dq super keyboard . +.Dq "super keyboard" . +The .Nm +driver acts as a master keyboard consuming input from all slave keyboards attached to it. .Pp @@ -31,7 +33,6 @@ .Sh SEE ALSO .Xr kbdcontrol 1 , .Xr atkbd 4 , -.Xr pcvt 4 , .Xr syscons 4 , .Xr ukbd 4 .Sh CAVEATS Index: src/share/man/man4/kue.4 diff -u src/share/man/man4/kue.4:1.20.2.3 src/share/man/man4/kue.4:1.24 --- src/share/man/man4/kue.4:1.20.2.3 Tue Nov 14 20:54:38 2006 +++ src/share/man/man4/kue.4 Sun Oct 8 02:03:39 2006 @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 14, 2006 +.Dd October 7, 2006 .Dt KUE 4 .Os .Sh NAME Index: src/share/man/man4/le.4 diff -u src/share/man/man4/le.4:1.2.2.2 src/share/man/man4/le.4:1.7 --- src/share/man/man4/le.4:1.2.2.2 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/le.4 Tue Jan 30 16:40:04 2007 @@ -36,12 +36,12 @@ .\" from: @(#)le.4 8.1 (Berkeley) 6/9/93 .\" $FreeBSD$ .\" -.Dd January 30, 2006 +.Dd January 20, 2007 .Dt LE 4 .Os .Sh NAME .Nm le -.Nd "AMD Am7900 LANCE and Am79C9xx PCnet Ethernet interface driver" +.Nd "AMD Am7900 LANCE and Am79C9xx ILACC/PCnet Ethernet interface driver" .Sh SYNOPSIS To compile this driver into the kernel, place the following line in your @@ -56,48 +56,68 @@ .Bd -literal -offset indent if_le_load="YES" .Ed -.\" .Pp -.\" In -.\" .Pa /boot/device.hints : -.\" .Cd hint.le.0.at="isa" -.\" .Cd hint.le.0.port="0x280" -.\" .Cd hint.le.0.irq="10" -.\" .Cd hint.le.0.drq="0" +.Pp +For C-Bus non-PnP adapters, the port address and the IRQ number have to be +specified in +.Pa /boot/device.hints : +.Cd hint.le.0.at="isa" +.Cd hint.le.0.port="0x03d0" +.Cd hint.le.0.irq="6" +.Pp +For ISA non-PnP adapters, the port address as well as the IRQ and the DRQ +numbers have to be specified in +.Pa /boot/device.hints : +.Cd hint.le.0.at="isa" +.Cd hint.le.0.port="0x280" +.Cd hint.le.0.irq="10" +.Cd hint.le.0.drq="0" .Sh DESCRIPTION The .Nm driver provides support for Ethernet adapters based on the -.Tn AMD -Am7990 and Am79C90 (CMOS, pin-compatible) +.Tn AMD Am7990 +and +.Tn Am79C90 +.Pq CMOS, pin-compatible Local Area Network Controller for Ethernet .Pq Tn LANCE -chip set. +chips. .Pp The .Nm -driver also supports PCnet adapters based on the -.Tn AMD 79C9xx +driver also supports Ethernet adapters based on the +.Tn AMD Am79C900 +Integrated Local Area Communications Controller +.Pq Tn ILACC +as well as the +.Tn Am79C9xx PCnet family of chips, which are single-chip implementations of a .Tn LANCE chip and a DMA engine. This includes a superset of the .Tn PCI -bus Ethernet chip sets supported by the +bus Ethernet chips supported by the .Xr pcn 4 driver. The .Nm driver treats all of these .Tn PCI -bus Ethernet chip sets as an +bus Ethernet chips as an .Tn AMD Am79C970 PCnet-PCI and does not support the additional features like the MII bus and burst mode of .Tn AMD Am79C971 PCnet-FAST -and greater chip sets. +and greater chips. Thus the .Xr pcn 4 driver should be preferred for the latter. .Pp +Generally, the +.Nm +driver aims at supporting as many different chips on as many different +platforms as possible, +partially at the cost of the best performance with some of these. +.Pp The .Nm driver supports reception and transmission of extended frames for @@ -106,21 +126,80 @@ multicast destination addresses are hashed to a bit entry using the Ethernet CRC function. .Sh HARDWARE -.\" .Ss ISA -.\" The -.\" .Tn ISA -.\" bus Ethernet cards supported by the -.\" .Nm -.\" driver are: -.\" .Pp -.\" .Bl -bullet -compact -.\" .It -.\" .Tn BICC Isolan -.\" .It -.\" .Tn Novell NE2100 +.Ss C-Bus and ISA +The +.Nm +driver supports +.Tn C-Bus +and +.Tn ISA +bus Ethernet adapters which are based on the following chips: +.Pp +.Bl -bullet -compact +.It +.Tn AMD Am7990 and Am79C90 LANCE +.It +.Tn AMD Am79C960 PCnet-ISA +.It +.Tn AMD Am79C961 PCnet-ISA+ +.It +.Tn AMD Am79C961A PCnet-ISA II +.El +.Pp +This includes support for the following Ethernet adapters: +.Pp +C-Bus non-PnP: +.Pp +.Bl -bullet -compact +.It +.Tn Contec C-NET(98)S +.El +.Pp +ISA non-PnP: +.Pp +.Bl -bullet -compact +.It +.Tn BICC Isolan .\" .It .\" .Tn Digital DEPCA -.\" .El +.It +.Tn Novell NE2100 +.El +.Pp +ISA PnP: +.Pp +.Bl -bullet -compact +.It +.Tn AMD AM1500T/AM2100 +.It +.Tn AMD PCnet-32 +.It +.Tn AMD PCnet-ISA +.It +.Tn Allied Telesyn AT-1500 +.It +.Tn Boca LANCard Combo +.It +.Tn Cabletron E2100 Series DNI +.It +.Tn Cabletron E2200 Single Chip +.It +.Tn Melco Inc. LGY-IV +.It +.Tn Novell NE2100 +.It +.Tn Racal InterLan EtherBlaster +.El +.Pp +The +.Nm +driver does not support the selection of media types and options via +.Xr ifconfig 8 +with +.Tn C-Bus +and +.Tn ISA +bus Ethernet adapters. .\" .Ss EISA .\" The .\" .Tn EISA @@ -148,7 +227,7 @@ .Ss PCI The .Tn PCI -bus Ethernet chip sets supported by the +bus Ethernet chips supported by the .Nm driver are: .Pp @@ -169,23 +248,36 @@ .Tn AMD Am79C978 PCnet-Home .El .Pp +This includes support for the following Ethernet adapters: +.Pp +.Bl -bullet -compact +.It +.Tn AcerLAN NIC P20 +.It +.Tn Allied Telesyn AT-2450 and AT-2700 series +.It +.Tn VMware emulated AMD Am79C970A PCnet-PCI II interface +.El +.Pp The .Nm -driver supports the following media types with these chip sets: -.Pp -.Bl -tag -width xxxxxxxxxxxxxxxxxxxx -.It autoselect +driver supports the selection of the following media types via +.Xr ifconfig 8 +with +.Tn PCI +bus Ethernet adapters: +.Bl -tag -width ".Cm 10base5/AUI" +.It Cm autoselect Enable autoselection of the media type. -.It 10baseT/UTP +.It Cm 10baseT/UTP Select UTP media. -.It 10base5/AUI +.It Cm 10base5/AUI Select AUI/BNC media. .El .Pp The following media option is supported with these media types: -.Pp -.Bl -tag -width xxxxxxxxxxxxxxxxxxxx -.It full-duplex +.Bl -tag -width ".Cm full-duplex" +.It Cm full-duplex Select full duplex operation. .El .Pp @@ -202,14 +294,17 @@ interfaces found in .Tn Sun Ultra 1 machines. -The following media types are available with these: -.Pp -.Bl -tag -width xxxxxxxxxxxxxxxxxxxx -.It autoselect +The +.Nm +driver allows the selection of the following media types via +.Xr ifconfig 8 +with these on-board interfaces: +.Bl -tag -width ".Cm 10base5/AUI" +.It Cm autoselect Enable autoselection of the media type. -.It 10baseT/UTP +.It Cm 10baseT/UTP Select UTP media. -.It 10base5/AUI +.It Cm 10base5/AUI Select AUI media. .El .Pp @@ -218,26 +313,29 @@ The first media type with which a carrier is detected will be selected. Additionally, if carrier is dropped on a port, the driver will switch between the possible ports until one with carrier is found. -.\" .Pp -.\" The -.\" .Nm -.\" driver also supports -.\" .Tn SBus -.\" Ethernet cards. -.\" These include: -.\" .Bl -bullet -compact -.\" .It -.\" SBE/S -.\" .Tn SCSI -.\" and Buffered Ethernet -.\" (Sun P/N 501-1860) -.\" .It -.\" FSBE/S -.\" Fast -.\" .Tn SCSI -.\" and Buffered Ethernet -.\" (Sun P/N 501-2015) -.\" .El +.Pp +The +.Nm +driver also supports the following +.Tn Sun SBus +Ethernet add-on adapters: +.Pp +.Bl -bullet -compact +.It +.Tn SCSI HBA and Buffered Ethernet +.Pq SBE/S, P/N 501-1869 +.It +.Tn Fast SCSI and Buffered Ethernet +.Pq FSBE/S, P/N 501-2015 and 501-2981 +.El +.Pp +The +.Nm +driver does not support the selection of media types and options via +.Xr ifconfig 8 +with +.Tn SBus +Ethernet add-on adapters. .Pp For further information on configuring media types and options, see .Xr ifconfig 8 . Index: src/share/man/man4/led.4 diff -u src/share/man/man4/led.4:1.11 src/share/man/man4/led.4:1.14 --- src/share/man/man4/led.4:1.11 Mon May 30 05:23:50 2005 +++ src/share/man/man4/led.4 Tue Apr 24 15:10:10 2007 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 29, 2005 +.Dd April 24, 2007 .Dt LED 4 .Os .Sh NAME @@ -35,6 +35,8 @@ .Pp .Fd "typedef void led_t(void *priv, int onoff);" .Ft struct cdev * +.Fn led_create_state "led_t *func" "void *priv" "char const *name" "int state" +.Ft struct cdev * .Fn led_create "led_t *func" "void *priv" "char const *name" .Ft void .Fn led_destroy "struct cdev *" @@ -166,7 +168,7 @@ .Sq Li sAaAbBa flashes .Pp -.Dl _*_**__* +.Dl *_*__**_ .Pp .Bd -literal /usr/games/morse -l "Soekris rocks" > /dev/led/error Index: src/share/man/man4/lmc.4 diff -u /dev/null src/share/man/man4/lmc.4:1.11 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/lmc.4 Fri Dec 15 00:40:57 2006 @@ -0,0 +1,766 @@ +.\" +.\" $FreeBSD$ +.\" +.\" Copyright (c) 2002-2005 David Boggs. (boggs@boggs.palo-alto.ca.us) +.\" All rights reserved. +.\" +.\" BSD License: +.\" +.\" 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. +.\" +.\" GNU General Public License: +.\" +.\" This program is free software; you can redistribute it and/or modify it +.\" under the terms of the GNU General Public License as published by the Free +.\" Software Foundation; either version 2 of the License, or (at your option) +.\" any later version. +.\" +.\" This program is distributed in the hope that it will be useful, but WITHOUT +.\" ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +.\" FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +.\" more details. +.\" +.\" You should have received a copy of the GNU General Public License along with +.\" this program; if not, write to the Free Software Foundation, Inc., 59 +.\" Temple Place - Suite 330, Boston, MA 02111-1307, USA. +.\" +.Dd May 20, 2006 +.Dt LMC 4 +.Os +.\" +.Sh NAME +.\" +.Nm lmc +.Nd device driver for +.Tn LMC +(now +.Tn SBE ) +wide-area network interface cards +.\" +.Sh SYNOPSIS +.\" +To wire this driver into your kernel, +add the following line to your kernel configuration file: +.Bd -ragged -offset indent +.Cd "device lmc" +.Ed +.Pp +Alternatively, to load this module at boot time, add +.Bd -literal -offset indent +if_lmc_load="YES" +.Ed +.Pp +to +.Pa /boot/loader.conf ; +see +.Xr loader.conf 5 . +.Pp +To wire a line protocol into your kernel, add: +.Bd -ragged -offset indent +.Cd "options NETGRAPH" +.Cd "device sppp" +.Ed +.Pp +It is not necessary to wire line protocols into your kernel, +they can be loaded later with +.Xr kldload 8 . +The driver can send and receive raw IP packets even if neither +SPPP nor Netgraph are configured into the kernel. +Netgraph and SPPP can both be enabled; Netgraph will be used if the +.Va rawdata +hook is connected. +.\" +.Sh DESCRIPTION +.\" +This is an open-source +.Ux +device driver for PCI-bus WAN interface cards. +It sends and receives packets in HDLC frames over synchronous circuits. +A generic PC plus +.Ux +plus some +.Tn LMC / SBE +cards makes an +.Em open +router. +This driver works with +.Fx , +.Nx , +.Ox , +.Bsx +and +.Tn Linux +OSs. +It has been tested on i386 (SMP 32-bit little-endian) and Sparc (64-bit big-endian) +architectures. +.Pp +The +.Nm +driver works with the following cards: +.Bl -bullet +.It +SBE wanADAPT-HSSI (LMC5200) +.Pp +High Speed Serial Interface, +EIA612/613, 50-pin connector, +0 to 52 Mb/s, DTE only. +.It +SBE wanADAPT-T3 (LMC5245) +.Pp +T3: two 75-ohm BNC connectors, +C-Parity or M13 Framing, +44.736 Mb/s, up to 950 ft. +.It +SBE wanADAPT-SSI (LMC1000) +.Pp +Synchronous Serial Interface, +V.35, X.21, EIA449, EIA530(A), EIA232, +0 to 10 Mb/s, DTE or DCE. +.It +SBE wanADAPT-T1E1 (LMC1200) +.Pp +T1 or E1: RJ45 conn, 100 or 120 ohms, +T1-ESF-B8ZS, T1-SF-AMI, E1-(many)-HDB3, +1.544 Mb/s or 2.048 Mb/s, up to 6 Kft. +.El +.Pp +Cards contain a high-performance +.Sy "PCI" +interface, an +.Sy "HDLC" +function and +either integrated +.Sy "modems" +(T1, T3) or +.Sy "modem" +interfaces (HSSI and SSI). +.Bl -tag -width "Modem" +.It Sy "PCI" +The PCI interface is a DEC 21140A "Tulip" Fast Ethernet chip. +This chip has an efficient PCI implementation with scatter/gather DMA, +and can run at 100 Mb/s full duplex (twice as fast as needed here). +.It Sy "HDLC" +The HDLC functions (ISO-3309: flags, bit-stuffing, CRC) are implemented +in a Field Programmable Gate Array (FPGA) which talks to the Ethernet +chip through a Media Independent Interface (MII). +The hardware in the FPGA translates between Ethernet packets and +HDLC frames on-the-fly; think it as a WAN PHY chip for Ethernet. +.It Sy "Modem" +The modem chips are the main differences between cards. +HSSI cards use ECL10K chips to implement the EIA-612/613 interface. +T3 cards use a TranSwitch TXC-03401 framer chip. +SSI cards use Linear Technology LTC1343 modem interface chips. +T1 cards use a BrookTree/Conexant/Mindspeed Bt8370 framer +and line interface chip. +.El +.Pp +Line protocols exist above device drivers and below internet protocols. +They typically encapsulate packets in HDLC frames and deal with +higher-level issues like protocol multiplexing and security. +This driver is compatible with several line protocol packages: +.Bl -tag -width "Generic HDLC" +.It Sy "Netgraph" +.Xr Netgraph 4 +implements many basic packet-handling functions as kernel loadable modules. +They can be interconnected in a graph to implement many protocols. +Configuration is done from userland without rebuilding the kernel. +Packets are sent and received through this interface if the driver's +.Em rawdata +hook is connected, otherwise the ifnet interface (SPPP and RawIP) is used. +ASCII configuration control messages are +.Em not +currently supported. +.It Sy "SPPP" +.Xr sppp 4 +implements Synchronous-PPP, Frame-Relay and Cisco-HDLC in the kernel. +.It Sy "RawIP" +This null line protocol, built into the driver, sends and receives +raw IPv4 and IPv6 packets in HDLC frames (aka IP-in-HDLC) with +no extra bytes of overhead and no state at the end points. +.El +.\" +.Sh EXAMPLES +.\" +.Ss "ifconfig and lmcconfig" +.\" +The program +.Xr lmcconfig 8 +manipulates interface parameters beyond the scope of +.Xr ifconfig 8 . +In normal operation only a few arguments are needed: +.Pp +.Bl -tag -width ".Fl X" -offset indent -compact +.It Fl X +selects the external +SPPP +line protocol package. +.It Fl x +selects the built-in RawIP line protocol package. +.It Fl Z +selects PPP line protocol. +.It Fl z +selects Cisco-HDLC line protocol. +.It Fl F +selects Frame-Relay line protocol. +.El +.Bl -tag -width indent +.It Li "lmcconfig lmc0" +displays interface configuration and status. +.It Li "lmcconfig lmc0 -D" +enables debugging output from the device driver only. +.It Li "ifconfig lmc0 debug" +enables debugging output from the device driver and from +the line protocol module above it. +Debugging messages that appear on the console are also +written to file +.Pa "/var/log/messages" . +.Em Caution : +when things go very wrong, a torrent of debugging messages +can swamp the console and bring a machine to its knees. +.El +.\" +.Ss Operation +.\" +Activate a PPP link using SPPP and Netgraph with: +.Bd -literal -offset indent +ngctl mkpeer lmc0: sppp rawdata downstream +ifconfig sppp0 10.0.0.1 10.0.0.2 +.Ed +.Pp +Activate a PPP link using only SPPP with: +.Bd -literal -offset indent +lmcconfig lmc0 -XYZ +ifconfig lmc0 10.0.0.1 10.0.0.2 +.Ed +.Pp +Activate a Cisco-HDLC link using SPPP and Netgraph with: +.Bd -literal -offset indent +ngctl mkpeer lmc0: sppp rawdata downstream +ifconfig sppp0 10.0.0.1 10.0.0.2 link2 +.Ed +.Pp +Activate a Cisco-HDLC link using only SPPP with: +.Bd -literal -offset indent +lmcconfig lmc0 -XYz +ifconfig lmc0 10.0.0.1 10.0.0.2 +.Ed +.Pp +Activate a Cisco-HDLC link using only Netgraph with: +.Bd -literal -offset indent +ngctl mkpeer lmc0: cisco rawdata downstream +ngctl mkpeer lmc0:rawdata iface inet inet +ifconfig ng0 10.0.0.1 10.0.0.2 +.Ed +.Pp +Activate a Frame-Relay DTE link using SPPP with: +.Bd -literal -offset indent +lmcconfig lmc0 -XYF +ifconfig lmc0 10.0.0.1 10.0.0.2 +.Ed +.Pp +(SPPP implements the ANSI T1.617 annex D LMI.) +.Pp +Activate a Frame-Relay DTE link using Netgraph with: +.Bd -literal -offset indent +ngctl mkpeer lmc0: frame_relay rawdata downstream +ngctl mkpeer lmc0:rawdata lmi dlci0 auto0 +ngctl connect lmc0:rawdata dlci0 dlci1023 auto1023 +ngctl mkpeer lmc0:rawdata rfc1490 dlci500 downstream +ngctl mkpeer lmc0:rawdata.dlci500 iface inet inet +ifconfig ng0 10.0.0.1 10.0.0.2 +.Ed +This is +.Em ONE +possible Frame Relay configuration; there are many. +.Pp +Activate a RAWIP link using only the driver with: +.Bd -literal -offset indent +lmcconfig lmc0 -x +ifconfig lmc0 10.0.0.1 10.0.0.2 +.Ed +.Pp +Activate a RAWIP link using Netgraph with: +.Bd -literal -offset indent +ngctl mkpeer lmc0: iface rawdata inet +ifconfig ng0 10.0.0.1 10.0.0.2 +.Ed +.Pp +If the driver is unloaded and then loaded, reconnect hooks by: +.Pp +.Dl "ngctl connect lmc0: ng0: rawdata inet" +.\" +.Sh TESTING +.\" +.Ss Testing with Loopbacks +.\" +Testing with loopbacks requires only one card. +Packets can be looped back at many points: in the PCI chip, +in the modem chips, through a loopback plug, in the +local external equipment, or at the far end of a circuit. +.Pp +Activate the card with +.Xr ifconfig 8 : +.Pp +.Dl "ifconfig lmc0 10.0.0.1 10.0.0.1" +.Pp +All cards can be looped through the PCI chip. +Cards with internal modems can be looped through +the modem framer and the modem line interface. +Cards for external modems can be looped through +the driver/receiver chips. +See +.Xr lmcconfig 8 +for details. +.Pp +Loopback plugs test everything on the card. +.Bl -tag -width ".Sy T1/E1" +.It Sy HSSI +Loopback plugs can be ordered from SBE (and others). +Transmit clock is normally supplied by the external modem. +When an HSSI card is operated with a loopback plug, the PCI bus +clock must be used as the transmit clock, typically 33 MHz. +When testing an HSSI card with a loopback plug, +configure it with +.Xr lmcconfig 8 : +.Pp +.Dl "lmcconfig lmc0 -a 2" +.Pp +.Dq Fl a Li 2 +selects the PCI bus clock as the transmit clock. +.It Sy T3 +Connect the two BNC jacks with a short coax cable. +.It Sy SSI +Loopback plugs can be ordered from SBE (only). +Transmit clock is normally supplied by the external modem. +When an SSI card is operated with a loopback plug, +the on-board clock synthesizer must be used. +When testing an SSI card with a loopback plug, +configure it with +.Xr lmcconfig 8 : +.Pp +.Dl "lmcconfig lmc0 -E -f 10000000" +.Pp +.Fl E +puts the card in DCE mode to source a transmit clock. +.Dq Fl f Li 10000000 +sets the internal clock source to 10 Mb/s. +.It Sy T1/E1 +A loopback plug is a modular plug with two wires +connecting pin 1 to pin 4 and pin 2 to pin 5. +.El +.Pp +One can also test by connecting to a local modem (HSSI and SSI) +or NI (T1 and T3) configured to loop back. +Cards can generate signals to loopback remote equipment +so that complete circuits can be tested; see +.Xr lmcconfig 8 +for details. +.\" +.Ss Testing with a Modem +.\" +Testing with a modem requires two cards of different types. +.Bl -tag -width ".Sy T3/HSSI" +.It Sy T3/HSSI +If you have a T3 modem with an HSSI interface +(made by Digital Link, Larscom, Kentrox etc.\&) +then use an HSSI card in one machine and a T3 card in the other machine. +The T3 coax cables must use the null modem configuration (see below). +.It Sy T1/V.35 +If you have a T1 (or E1) modem with a V.35, X.21 or EIA530 interface, +then use an SSI card in one machine and a T1 card in the other machine. +Use a T1 null modem cable (see below). +.El +.\" +.Ss Testing with a Null Modem Cable +.\" +Testing with a null modem cable requires two cards of the same type. +.Bl -tag -width ".Sy T1/E1" +.It Sy HSSI +Three-meter HSSI null-modem cables can be ordered from SBE. +In a pinch, a 50-pin SCSI-II cable up to a few meters will +work as a straight HSSI cable (not a null modem cable). +Longer cables should be purpose-built HSSI cables because +the cable impedance is different. +Transmit clock is normally supplied by the external modem. +When an HSSI card is connected by a null modem cable, the PCI bus +clock can be used as the transmit clock, typically 33 MHz. +When testing an HSSI card with a null modem cable, configure it +with +.Xr lmcconfig 8 : +.Pp +.Dl "lmcconfig lmc0 -a 2 +.Pp +.Dq Fl a Li 2 +selects the PCI bus clock as the transmit clock. +.It Sy T3 +T3 null modem cables are just 75-ohm coax cables with BNC connectors. +TX OUT on one card should be connected to RX IN on the other card. +In a pinch, 50-ohm thin Ethernet cables +.Em usually +work up to a few meters, but they will +.Em not +work for longer runs \[em] 75-ohm coax is +.Em required . +.It Sy SSI +Three-meter SSI null modem cables can be ordered from SBE. +An SSI null modem cable reports a cable type of V.36/EIA449. +Transmit clock is normally supplied by the external modem. +When an SSI card is connected by a null modem cable, +an on-board clock synthesizer is used. +When testing an SSI card with a null modem cable, configure it +with +.Xr lmcconfig 8 : +.Pp +.Dl "lmcconfig lmc0 -E -f 10000000" +.Pp +.Fl E +puts the card in DCE mode to source a transmit clock. +.Dq Fl f Li 10000000 +sets the internal clock source to 10 Mb/s. +.It Sy T1/E1 +A T1 null modem cable has two twisted pairs that connect +pins 1 and 2 on one plug to pins 4 and 5 on the other plug. +Looking into the cable entry hole of a plug, +with the locking tab oriented down, +pin 1 is on the left. +A twisted pair Ethernet cable makes an excellent straight T1 cable. +Alas, Ethernet cross-over cables do not work as T1 null modem cables. +.El +.\" +.Sh OPERATION NOTES +.\" +.Ss Packet Lengths +Maximum transmit and receive packet length is unlimited. +Minimum transmit and receive packet length is one byte. +.Pp +Cleaning up after one packet and setting up for the next +packet involves making several DMA references. +This can take longer than the duration of a short packet, +causing the adapter to fall behind. +For typical PCI bus traffic levels and memory system latencies, +back-to-back packets longer than about 20 bytes will always +work (53 byte cells work), but a burst of several hundred +back-to-back packets shorter than 20 bytes will cause packets +to be dropped. +This usually is not a problem since an IPv4 packet header is +at least 20 bytes long. +.Pp +This device driver imposes no constraints on packet size. +Most operating systems set the default Maximum Transmission +Unit (MTU) to 1500 bytes; the legal range is usually (72..65535). +This can be changed with +.Pp +.Dl "ifconfig lmc0 mtu 2000" +.Pp +SPPP enforces an MTU of (128..far-end-MRU) for PPP +and 1500 bytes for Cisco-HDLC. +RAWIP sets the default MTU to 4032 bytes, +but it can be changed to anything. +.\" +.Ss BPF - Berkeley Packet Filter +.\" +This driver has hooks for +.Xr bpf 4 , +the Berkeley Packet Filter. +The line protocol header length reported to BPF is four bytes +for SPPP and P2P line protocols and zero bytes for RawIP. +.Pp +To include BPF support into your kernel, +add the following line to +.Pa conf/YOURKERNEL : +.Pp +.Dl "device bpf" +.Pp +To test the BPF kernel interface, +bring up a link between two machines, then run +.Xr ping 8 +and +.Xr tcpdump 1 : +.Pp +.Dl "ping 10.0.0.1" +.Pp +and in a different window: +.Pp +.Dl "tcpdump -i lmc0" +.Pp +The output from +.Xr tcpdump 1 +should look like this: +.Bd -literal -offset indent +03:54:35.979965 10.0.0.2 > 10.0.0.1: icmp: echo request +03:54:35.981423 10.0.0.1 > 10.0.0.2: icmp: echo reply +.Ed +.Pp +Line protocol control packets will appear among the +.Xr ping 8 +packets occasionally. +.\" +.Ss Device Polling +.\" +A T3 receiver can generate over 100K interrupts per second, +This can cause a system to +.Dq live-lock : +spend all of its +time servicing interrupts. +.Fx +has a polling mechanism to prevent live-lock. +.Pp +.Fx Ns 's +mechanism permanently disables interrupts from the card +and instead the card's interrupt service routine is called each +time the kernel is entered (syscall, timer interrupt, etc.\&) and +from the kernel idle loop; this adds some latency. +The driver is permitted to process a limited number of packets. +The percentage of the CPU that can be consumed this way is settable. +.Pp +See the +.Xr polling 4 +manpage for details on how to enable the polling mode. +.\" +.Ss SNMP: Simple Network Management Protocol +.\" +This driver is aware of what is required to be a Network Interface +Object managed by an Agent of the Simple Network Management Protocol. +The driver exports SNMP-formatted configuration and status +information sufficient for an SNMP Agent to create MIBs for: +.Pp +.Bl -item -offset indent -compact +.It +.%T "RFC-2233: Interfaces group" , +.It +.%T "RFC-2496: DS3 interfaces" , +.It +.%T "RFC-2495: DS1/E1 interfaces" , +.It +.%T "RFC-1659: RS232-like interfaces" . +.El +.Pp +An SNMP Agent is a user program, not a kernel function. +Agents can retrieve configuration and status information +by using +Netgraph control messages or +.Xr ioctl 2 +system calls. +User programs should poll +.Va sc->cfg.ticks +which increments once per second after the SNMP state has been updated. +.\" +.Ss HSSI and SSI LEDs +.\" +The card should be operational if all three green LEDs are on +(the upper-left one should be blinking) and the red LED is off. +All four LEDs turn on at power-on and module unload. +.Pp +.Bl -column -compact -offset indent "YELLOW" "upper-right" "Software" +.It "RED" Ta "upper-right" Ta "No Transmit clock" +.It "GREEN" Ta "upper-left" Ta "Device driver is alive if blinking" +.It "GREEN" Ta "lower-right" Ta "Modem signals are good" +.It "GREEN" Ta "lower-left" Ta "Cable is plugged in (SSI only)" +.El +.\" +.Ss T1E1 and T3 LEDs +.\" +The card should be operational if the upper-left green LED is blinking +and all other LEDs are off. +For the T3 card, if other LEDs are on or +blinking, try swapping the coax cables! +All four LEDs turn on at power-on and module unload. +.Pp +.Bl -column -compact -offset indent "YELLOW" "upper-right" "Received" +.It "RED" Ta "upper-right" Ta "Received signal is wrong" +.It "GREEN" Ta "upper-left" Ta "Device driver is alive if blinking" +.It "BLUE" Ta "lower-right" Ta "Alarm Information Signal (AIS)" +.It "YELLOW" Ta "lower-left" Ta "Remote Alarm Indication (RAI)" +.El \" YELLOW +.Pp +.Bl -column -compact "The yellow" "LED" +.It "The green" Ta "LED blinks if the device driver is alive." +.It "The red" Ta "LED blinks if an outward loopback is active." +.It "The blue" Ta "LED blinks if sending AIS, on solid if receiving AIS." +.It "The yellow" Ta "LED blinks if sending RAI, on solid if receiving RAI." +.El \" LED +.\" +.Ss E1 Framing +.\" +Phone companies usually insist that customers put a +.Em Frame Alignment Signal +(FAS) in time slot 0. +A Cyclic Redundancy Checksum (CRC) can also ride in time slot 0. +.Em Channel Associated Signalling +(CAS) uses Time Slot 16. +In telco-speak +.Em signalling +is on/off hook, ringing, busy, etc. +Signalling is not needed here and consumes 64 Kb/s. +Only use E1-CAS formats if the other end insists on it! +Use E1-FAS+CRC framing format on a public circuit. +Depending on the equipment installed in a private circuit, +it may be possible to use all 32 time slots for data (E1-NONE). +.\" +.Ss T3 Framing +.\" +M13 is a technique for multiplexing 28 T1s into a T3. +Muxes use the C-bits for speed-matching the tributaries. +Muxing is not needed here and usurps the FEBE and FEAC bits. +Only use T3-M13 format if the other end insists on it! +Use T3-CParity framing format if possible. +Loop Timing, Fractional T3, and HDLC packets in +the Facility Data Link are +.Em not +supported. +.\" +.Ss T1 & T3 Frame Overhead Functions +.\" +.Bl -item -compact +.It +Performance Report Messages (PRMs) are enabled in T1-ESF. +.It +Bit Oriented Protocol (BOP) messages are enabled in T1-ESF. +.It +In-band loopback control (framed or not) is enabled in T1-SF. +.It +Far End Alarm and Control (FEAC) msgs are enabled in T3-CPar. +.It +Far End Block Error (FEBE) reports are enabled in T3-CPar. +.It +Remote Alarm Indication (RAI) is enabled in T3-Any. +.It +Loopbacks initiated remotely time out after 300 seconds. +.El +.\" +.Ss T1/E1 'Fractional' 64 kb/s Time Slots +.\" +T1 uses time slots 24..1; E1 uses time slots 31..0. +E1 uses TS0 for FAS overhead and TS16 for CAS overhead. +E1-NONE has +.Em no +overhead, so all 32 TSs are available for data. +Enable/disable time slots by setting 32 1s/0s in a config param. +Enabling an E1 overhead time slot, +or enabling TS0 or TS25-TS31 for T1, +is ignored by the driver, which knows better. +The default TS param, 0xFFFFFFFF, enables the maximum number +of time slots for whatever frame format is selected. +56 Kb/s time slots are +.Em not +supported. +.\" +.Ss T1 Raw Mode +.\" +Special gate array microcode exists for the T1/E1 card. +Each T1 frame of 24 bytes is treated as a packet. +A raw T1 byte stream can be delivered to main memory +and transmitted from main memory. +The T1 card adds or deletes framing bits but does not +touch the data. +ATM cells can be transmitted and received this way, with +the software doing all the work. +But that is not hard; after all it is only 1.5 Mb/s second! +.\" +.Ss T3 Circuit Emulation Mode +.\" +Special gate array microcode exists for the T3 card. +Each T3 frame of 595 bytes is treated as a packet. +A raw T3 signal can be +.Em packetized , +transported through a +packet network (using some protocol) and then +.Em reconstituted +as a T3 signal at the far end. +The output transmitter's +bit rate can be controlled from software so that it can be +.Em frequency locked +to the distant input signal. +.\" +.Ss HSSI and SSI Transmit Clocks +.\" +Synchronous interfaces use two transmit clocks to eliminate +.Em skew +caused by speed-of-light delays in the modem cable. +DCEs (modems) drive ST, Send Timing, the first transmit clock. +DTEs (hosts) receive ST and use it to clock transmit data, TD, +onto the modem cable. +DTEs also drive a copy of ST back towards the DCE and call it TT, +Transmit Timing, the second transmit clock. +DCEs receive TT and TD and use TT to clock TD into a flip flop. +TT experiences the same delay as (and has no +.Em skew +relative to) TD. +Thus, cable length does not affect data/clock timing. +.\" +.Sh SEE ALSO +.\" +.Xr tcpdump 1 , +.Xr ioctl 2 , +.Xr bpf 4 , +.Xr kld 4 , +.Xr netgraph 4 , +.Xr polling 4 , +.Xr sppp 4 , +.Xr loader.conf 5 , +.Xr ifconfig 8 , +.Xr lmcconfig 8 , +.Xr mpd 8 Pq Pa ports/net/mpd , +.Xr ngctl 8 , +.Xr ping 8 , +.Xr ifnet 9 +.Pp +.Pa http://www.sbei.com/ +.\" +.Sh HISTORY +.\" +.An Ron Crane +had the idea to use a Fast Ethernet chip as a PCI interface +and add an Ethernet-to-HDLC gate array to make a WAN card. +.An David Boggs +designed the Ethernet-to-HDLC gate array and PC cards. +We did this at our company, LAN Media Corporation +.Tn (LMC) . +.Tn SBE +Corp.\& acquired +.Tn LMC +and continues to make the cards. +.Pp +Since the cards use Tulip Ethernet chips, we started with +.An Matt Thomas Ns ' +ubiquitous +.Xr de 4 +driver. +.An Michael Graff +stripped out the Ethernet stuff and added HSSI stuff. +.An Basil Gunn +ported it to +.Tn Solaris +(lost) and +.Tn Rob Braun +ported it to +.Tn Linux . +.An Andrew Stanley-Jones +added support +for three more cards and wrote the first version of +.Xr lmcconfig 8 . +.An David Boggs +rewrote everything and now feels responsible for it. +.\" +.Sh AUTHORS +.\" +.An "David Boggs" Aq boggs@boggs.palo-alto.ca.us Index: src/share/man/man4/mac.4 diff -u src/share/man/man4/mac.4:1.12.8.1 src/share/man/man4/mac.4:1.14 --- src/share/man/man4/mac.4:1.12.8.1 Sun Nov 4 23:18:40 2007 +++ src/share/man/man4/mac.4 Tue Oct 30 23:59:44 2007 @@ -109,10 +109,6 @@ .Pa /dev ) corresponding to the file system on which to enable multilabel support. .Ss Policy Enforcement -MAC can be configured to enforce only specific portions of -policies -(see -.Sx "Runtime Configuration" ) . Policy enforcement is divided into the following areas of the system: .Bl -ohang .It Sy "File System" @@ -187,40 +183,6 @@ is documented in the .Xr mac 3 man page. -.Ss Runtime Configuration -The following -.Xr sysctl 8 -MIBs are available for fine-tuning the enforcement of MAC policies. -Unless specifically noted, all MIBs default to 1 -(that is, all areas are enforced by default): -.Bl -tag -width ".Va security.mac.enforce_network" -.It Va security.mac.enforce_fs -Enforce MAC policies for file system accesses. -.It Va security.mac.enforce_kld -Enforce MAC policies on -.Xr kld 4 . -.It Va security.mac.enforce_network -Enforce MAC policies on network interfaces. -.It Va security.mac.enforce_pipe -Enforce MAC policies on pipes. -.It Va security.mac.enforce_process -Enforce MAC policies between system processes -(e.g.\& -.Xr ps 1 , -.Xr ktrace 2 ) . -.It Va security.mac.enforce_socket -Enforce MAC policies on sockets. -.It Va security.mac.enforce_system -Enforce MAC policies on system-related items -(e.g.\& -.Xr kenv 1 , -.Xr acct 2 , -.Xr reboot 2 ) . -.It Va security.mac.enforce_vm -Enforce MAC policies on -.Xr mmap 2 -and -.Xr mprotect 2 . .\" *** XXX *** .\" Support for this feature is poor and should not be encouraged. .\" Index: src/share/man/man4/mac_seeotheruids.4 diff -u src/share/man/man4/mac_seeotheruids.4:1.10 src/share/man/man4/mac_seeotheruids.4:1.12 --- src/share/man/man4/mac_seeotheruids.4:1.10 Sun Jul 4 02:29:20 2004 +++ src/share/man/man4/mac_seeotheruids.4 Fri Nov 18 18:52:22 2005 @@ -30,7 +30,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 8, 2002 +.Dd October 6, 2005 .Os .Dt MAC_SEEOTHERUIDS 4 .Sh NAME @@ -67,6 +67,10 @@ set the sysctl OID .Va security.mac.seeotheruids.enabled to 1. +To permit superuser awareness of other credentials by virtue of privilege, +set the sysctl OID +.Va security.mac.seeotheruids.suser_privileged +to 1. .Pp To allow users to see processes and sockets owned by the same primary group, set the sysctl OID Index: src/share/man/man4/md.4 diff -u src/share/man/man4/md.4:1.11.12.1 src/share/man/man4/md.4:1.14 --- src/share/man/man4/md.4:1.11.12.1 Sat May 19 19:30:32 2007 +++ src/share/man/man4/md.4 Wed Oct 31 00:02:49 2007 @@ -7,7 +7,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 9, 2001 +.Dd October 30, 2007 .Dt MD 4 .Os .Sh NAME @@ -62,6 +62,23 @@ .Pp For more information, please see .Xr mdconfig 8 . +.Sh EXAMPLES +To create a kernel with a ramdisk or MD file system, your kernel config +needs the following options: +.Bd -literal -offset indent +options MD_ROOT #MD is a potential root device +options MD_ROOT_SIZE=8192 # 8MB ram disk +makeoptions MFS_IMAGE=/h/foo/ARM-MD +options ROOTDEVNAME=\"ufs:md0\" +.Ed +The image in +.Pa /h/foo/ARM-MD +will be loaded as the initial image each boot. +To create the image to use, please follow the steps to create a file-backed +disk found in the +.Xr mdconfig 8 +man page. +Other tools will also create these images, such as NanoBSD. .Sh SEE ALSO .Xr disklabel 5 , .Xr disklabel 8 , Index: src/share/man/man4/miibus.4 diff -u src/share/man/man4/miibus.4:1.15.2.5 src/share/man/man4/miibus.4:1.21 --- src/share/man/man4/miibus.4:1.15.2.5 Tue Mar 27 15:21:16 2007 +++ src/share/man/man4/miibus.4 Tue Jun 12 10:18:04 2007 @@ -8,7 +8,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 11, 2007 +.Dd June 12, 2007 .Dt MIIBUS 4 .Os .Sh NAME @@ -69,6 +69,8 @@ Level 1 LXT1001 NetCellerator Gigabit Ethernet .It Xr msk 4 Marvell/SysKonnect Yukon II Gigabit Ethernet +.It Xr nfe 4 +NVIDIA nForce MCP Networking Adapter .It Xr nge 4 National Semiconductor DP83820/DP83821 Gigabit Ethernet .It Xr nve 4 @@ -130,6 +132,7 @@ .Xr lge 4 , .Xr msk 4 , .Xr netintro 4 , +.Xr nfe 4 , .Xr nge 4 , .Xr nve 4 , .Xr pcn 4 , Index: src/share/man/man4/mmc.4 diff -u /dev/null src/share/man/man4/mmc.4:1.1 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/mmc.4 Sun May 27 13:01:19 2007 @@ -0,0 +1,61 @@ +.\" +.\" Copyright (c) 2007 M. Warner Losh +.\" 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. 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 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$ +.\" +.Dd May 26, 2007 +.Dt MMC 4 +.Os +.Sh NAME +.Nm mmc +.Nd MultiMediaCard and SD Card bus driver +.Sh SYNOPSIS +.Cd device mmc +.Sh DESCRIPTION +The +.Nm +driver implements the MMC and SD Card bus. +The +.Nm +driver supports all MMC and SD bridges in the system. +All SD or MMC cards in the system attach to an instance of +.Nm . +The +.Nm +bus typically has only one slot, and only memory cards. +MultiMediaCards exist only in memory. +SD Cards exist as memory, I/O, or combination cards. +.Sh SEE ALSO +.Xr mmcsd 4 , +.Xr at91_mci 4 +.Rs +.%T "SD Specifications, Part 1, Physical Layer, Simplified Specification" +.Re +.Rs +.%T "The MultiMediaCard System Specification" +.Re +.Sh BUGS +Memory MultMediaCards do not currently work. +SDIO cards currently do not work. +SDHC cards currently do not work. Index: src/share/man/man4/mmcsd.4 diff -u /dev/null src/share/man/man4/mmcsd.4:1.1 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/mmcsd.4 Sun May 27 13:01:19 2007 @@ -0,0 +1,51 @@ +.\" +.\" Copyright (c) 2007 M. Warner Losh +.\" 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. 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 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$ +.\" +.Dd May 26, 2007 +.Dt MMCSD 4 +.Os +.Sh NAME +.Nm mmcsd +.Nd MMC and SD card driver. +.Sh SYNOPSIS +.Cd device mmcsd +.Sh DESCRIPTION +The +.Nm +driver implements the MMC and SD memory cards. +.Sh SEE ALSO +.Xr mmc 4 , +.Xr at91_mci 4 +.Rs +.%T "SD Specifications, Part 1, Physical Layer, Simplified Specification" +.Re +.Rs +.%T "The MultiMediaCard System Specification" +.Re +.Sh BUGS +Memory MultMediaCards do not currently work. +SDIO cards currently do not work. +SDHC cards currently do not work. Index: src/share/man/man4/msk.4 diff -u src/share/man/man4/msk.4:1.3.2.3 src/share/man/man4/msk.4:1.6 --- src/share/man/man4/msk.4:1.3.2.3 Sat Dec 8 20:18:02 2007 +++ src/share/man/man4/msk.4 Wed Dec 5 17:41:58 2007 @@ -194,6 +194,8 @@ .It Marvell Yukon 88E8056 Gigabit Ethernet .It +Marvell Yukon 88E8058 Gigabit Ethernet +.It SysKonnect SK-9Sxx Gigabit Ethernet .It SysKonnect SK-9Exx Gigabit Ethernet Index: src/share/man/man4/multicast.4 diff -u src/share/man/man4/multicast.4:1.4.8.1 src/share/man/man4/multicast.4:1.6 --- src/share/man/man4/multicast.4:1.4.8.1 Wed Mar 21 08:45:13 2007 +++ src/share/man/man4/multicast.4 Sun Mar 18 23:34:57 2007 @@ -179,7 +179,7 @@ The .Dv VIFF_TUNNEL flag is no longer supported by -.Fx 7.0 . +.Fx . Users who wish to forward multicast datagrams over a tunnel should consider configuring a .Xr gif 4 @@ -196,7 +196,7 @@ The .Va max_rate_limit argument is no longer supported in -.Fx 7.0 +.Fx and should be set to 0. Users who wish to rate-limit multicast datagrams should consider the use of .Xr dummynet 4 Index: src/share/man/man4/my.4 diff -u src/share/man/man4/my.4:1.4.8.4 src/share/man/man4/my.4:1.9 --- src/share/man/man4/my.4:1.4.8.4 Tue Mar 20 00:56:48 2007 +++ src/share/man/man4/my.4 Sun Mar 11 23:20:03 2007 @@ -32,7 +32,7 @@ .Nd "Myson Technology Ethernet PCI driver" .Sh SYNOPSIS To compile this driver into the kernel, -place the following lines in your +place the following line in your kernel configuration file: .Bd -ragged -offset indent .Cd "device my" Index: src/share/man/man4/netgraph.4 diff -u src/share/man/man4/netgraph.4:1.50 src/share/man/man4/netgraph.4:1.52 --- src/share/man/man4/netgraph.4:1.50 Wed Jan 12 18:22:58 2005 +++ src/share/man/man4/netgraph.4 Tue Mar 7 01:37:42 2006 @@ -153,7 +153,7 @@ This can be used when the data is sent from an interrupt handler, and processing must be quick so as not to block other interrupts. .It -A hook may supply overriding receive data and receive message functions +A hook may supply overriding receive data and receive message functions, which should be used for data and messages received through that hook in preference to the general node-wide methods. .El @@ -175,15 +175,15 @@ in a chain must have the .Dv M_PKTHDR flag set. -Each node decides how to handle data coming in on its hooks. +Each node decides how to handle data received through one of its hooks. .Pp Along with data, nodes can also receive control messages. There are generic and type-specific control messages. Control messages have a common -header format, followed by a type-specific data, and are binary structures +header format, followed by type-specific data, and are binary structures for efficiency. However, node types may also support conversion of the -type specific data between binary and +type-specific data between binary and .Tn ASCII formats, for debugging and human interface purposes (see the @@ -205,10 +205,10 @@ If the destination is adjacent to the source, then the source node may simply specify (as a pointer in the code) the hook across which the message should be sent. -Otherwise, the recipient node global +Otherwise, the recipient node's global .Tn ASCII name -(or equivalent ID based name) is used as the destination address +(or equivalent ID-based name) is used as the destination address for the message (absolute addressing). The two types of .Tn ASCII @@ -217,8 +217,8 @@ of hooks. Only the .Tn ASCII -addressing modes are available to control programs outside the kernel, -as use of direct pointers is limited of course to kernel modules. +addressing modes are available to control programs outside the kernel; +use of direct pointers is limited to kernel modules. .Pp Messages often represent commands that are followed by a reply message in the reverse direction. @@ -227,9 +227,9 @@ .Dq return address that is suitable for addressing a reply. .Pp -Each control message contains a 32 bit value called a -.Em typecookie -indicating the type of the message, i.e., how to interpret it. +Each control message contains a 32-bit value, called a +.Dq typecookie , +indicating the type of the message, i.e.\& how to interpret it. Typically each type defines a unique typecookie for the messages that it understands. However, a node may choose to recognize and Index: src/share/man/man4/nfe.4 diff -u /dev/null src/share/man/man4/nfe.4:1.9 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/nfe.4 Tue Nov 27 14:54:13 2007 @@ -0,0 +1,195 @@ +.\" $OpenBSD: nfe.4,v 1.7 2006/02/28 08:13:47 jsg Exp $ +.\" +.\" Copyright (c) 2006 Jonathan Gray +.\" +.\" Permission to use, copy, modify, and distribute this software for any +.\" purpose with or without fee is hereby granted, provided that the above +.\" copyright notice and this permission notice appear in all copies. +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +.\" +.\" $FreeBSD$ +.\" +.Dd Nov 27, 2007 +.Dt NFE 4 +.Os +.Sh NAME +.Nm nfe +.Nd "NVIDIA nForce MCP Ethernet driver" +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device miibus" +.Cd "device nfe" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +if_nfe_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver supports PCI Ethernet adapters based on the NVIDIA +nForce Media and Communications Processors (MCP), such as +the nForce, nForce 2, nForce 3, CK804, MCP04, MCP51, MCP55, +MCP61, MCP65 and MCP67 Ethernet controller chips. +.Pp +Supported features include (hardware support provided): +.Pp +.Bl -bullet -compact +.It +Receive/Transmit IP/TCP/UDP checksum offload +.It +Hardware VLAN tag insertion/stripping +.It +TCP segmentation offload (TSO) +.It +MSI/MSI-X +.It +Jumbo Frames +.El +.Pp +Support for Jumbo Frames is provided via the interface MTU setting. +Selecting an MTU larger than 1500 bytes with the +.Xr ifconfig 8 +utility configures the adapter to receive and transmit Jumbo Frames. +.Pp +The +.Nm +driver supports the following media types: +.Bl -tag -width "10baseT/UTP" +.It Cm autoselect +Enable autoselection of the media type and options. +.It Cm 10baseT/UTP +Set 10Mbps operation. +.It Cm 100baseTX +Set 100Mbps (Fast Ethernet) operation. +.It Cm 1000baseT +Set 1000Mbps (Gigabit Ethernet) operation (recent models only). +.El +.Pp +The +.Nm +driver supports the following media options: +.Bl -tag -width ".Cm 10baseT/UTP" +.It Cm half-duplex +Force half duplex operation. +.It Cm full-duplex +Force full duplex operation. +.El +.Pp +For more information on configuring this device, see +.Xr ifconfig 8 . +.Sh HARDWARE +The +.Nm +driver supports the following NVIDIA MCP onboard adapters: +.Pp +.Bl -bullet -compact +.It +NVIDIA nForce MCP Networking Adapter +.It +NVIDIA nForce MCP04 Networking Adapter +.It +NVIDIA nForce 430 MCP12 Networking Adapter +.It +NVIDIA nForce 430 MCP13 Networking Adapter +.It +NVIDIA nForce MCP51 Networking Adapter +.It +NVIDIA nForce MCP55 Networking Adapter +.It +NVIDIA nForce MCP61 Networking Adapter +.It +NVIDIA nForce MCP65 Networking Adapter +.It +NVIDIA nForce MCP67 Networking Adapter +.It +NVIDIA nForce2 MCP2 Networking Adapter +.It +NVIDIA nForce2 400 MCP4 Networking Adapter +.It +NVIDIA nForce2 400 MCP5 Networking Adapter +.It +NVIDIA nForce3 MCP3 Networking Adapter +.It +NVIDIA nForce3 250 MCP6 Networking Adapter +.It +NVIDIA nForce3 MCP7 Networking Adapter +.It +NVIDIA nForce4 CK804 MCP8 Networking Adapter +.It +NVIDIA nForce4 CK804 MCP9 Networking Adapter +.El +.Sh LOADER TUNABLES +Tunables can be set at the +.Xr loader 8 +prompt before booting the kernel or stored in +.Xr loader.conf 5 . +.Bl -tag -width indent +.It Va hw.nfe.msi_disable +Whether or not MSI support is enabled in the driver. +The default value is 0. +.It Va hw.nfe.msix_disable +Whether or not MSI-X support is enabled in the driver. +The default value is 0. +.El +.Sh SYSCTL VARIABLES +The following +.Xr sysctl 8 +variables can be used to modify or monitor +.Nm +behavior. +.Bl -tag -width indent +.It Va dev.nfe.%d.process_limit +Maximum number of Rx events to be processed in the event loop +before rescheduling a taskqueue. +The accepted range is 50 to 255, the default value is 192. +The interface does not need to be brought down and up again +before a change takes effect. +.El +.Sh SEE ALSO +.Xr altq 4 , +.Xr arp 4 , +.Xr intro 4 , +.Xr miibus 4 , +.Xr netintro 4 , +.Xr pci 4 , +.Xr polling 4 , +.Xr sysctl 8 , +.Xr ifconfig 8 +.Sh HISTORY +The +.Nm +device driver first appeared in +.Ox 3.9 , +and then in +.Fx 7.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Jonathan Gray +.Aq jsg@openbsd.org +and +.An Damien Bergamini +.Aq damien@openbsd.org . +The +.Nm +driver was ported to +.Fx +by +.An Shigeaki Tagashira +.Aq shigeaki@se.hiroshima-u.ac.jp . Index: src/share/man/man4/nfsmb.4 diff -u src/share/man/man4/nfsmb.4:1.2.2.1 src/share/man/man4/nfsmb.4:1.3 --- src/share/man/man4/nfsmb.4:1.2.2.1 Thu Aug 17 19:01:26 2006 +++ src/share/man/man4/nfsmb.4 Sat Sep 30 23:14:48 2006 @@ -38,14 +38,14 @@ The .Nm driver provides access to NVIDIA nForce2/3/4 SMBus 2.0 controllers. +.Sh SEE ALSO +.Xr smb 4 , +.Xr smbus 4 .Sh HISTORY The .Nm driver first appeared in .Fx 6.2 . -.Sh SEE ALSO -.Xr smb 4 , -.Xr smbus 4 .Sh AUTHORS .An -nosplit The Index: src/share/man/man4/ng_bpf.4 diff -u src/share/man/man4/ng_bpf.4:1.21 src/share/man/man4/ng_bpf.4:1.22 --- src/share/man/man4/ng_bpf.4:1.21 Sat Feb 5 19:31:31 2005 +++ src/share/man/man4/ng_bpf.4 Wed May 30 17:05:49 2007 @@ -35,7 +35,7 @@ .\" $FreeBSD$ .\" $Whistle: ng_bpf.8,v 1.2 1999/12/03 01:57:12 archie Exp $ .\" -.Dd December 2, 1999 +.Dd May 30, 2007 .Dt NG_BPF 4 .Os .Sh NAME @@ -91,7 +91,7 @@ char ifMatch[NG_HOOKSIZ]; /* match dest hook */ char ifNotMatch[NG_HOOKSIZ]; /* !match dest hook */ int32_t bpf_prog_len; /* #isns in program */ - struct bpf_insn bpf_prog[0]; /* bpf program */ + struct bpf_insn bpf_prog[]; /* bpf program */ }; .Ed .Pp @@ -175,7 +175,7 @@ ngctl msg ${NODEPATH} setprogram { thisHook=\\"${INHOOK}\\" \\ ifMatch=\\"${MATCHHOOK}\\" \\ ifNotMatch=\\"${NOTMATCHHOOK}\\" \\ - ${BPFPROG} } } + ${BPFPROG} } .Ed .Sh SEE ALSO .Xr bpf 4 , Index: src/share/man/man4/ng_bridge.4 diff -u src/share/man/man4/ng_bridge.4:1.10 src/share/man/man4/ng_bridge.4:1.11 --- src/share/man/man4/ng_bridge.4:1.10 Sat Apr 17 20:42:17 2004 +++ src/share/man/man4/ng_bridge.4 Wed Sep 28 02:10:42 2005 @@ -192,7 +192,7 @@ Example script showing how to set up a bridging network .El .Sh SEE ALSO -.Xr bridge 4 , +.Xr if_bridge 4 , .Xr netgraph 4 , .Xr ng_ether 4 , .Xr ng_hub 4 , Index: src/share/man/man4/ng_bt3c.4 diff -u src/share/man/man4/ng_bt3c.4:1.10 src/share/man/man4/ng_bt3c.4:1.11 --- src/share/man/man4/ng_bt3c.4:1.10 Fri Jan 21 16:36:37 2005 +++ src/share/man/man4/ng_bt3c.4 Sat Feb 10 05:05:47 2007 @@ -59,22 +59,6 @@ .Pp .Dl "MD5 (BT3CPCC.BIN) = 36170fda56ea9fdbf1702c966f8a97f1" .Pp -For -.Pa OLDCARD -systems the entry in -.Xr pccard.conf 5 -might look like this: -.Bd -literal -offset indent -# 3Com 3CRWB60-A Bluetooth PC Card -card "3COM" "3CRWB60-A" "Bluetooth PC Card" - config auto "btccc" ? - insert /usr/sbin/bt3cfw -n $device -f /etc/BT3CPCC.bin -.Ed -.Pp -Do not forget to load the module and -.Dv SIGHUP -.Xr pccardd 8 . -.Pp The node has a single hook called .Dv hook . Incoming bytes received on the device are re-assembled into HCI frames @@ -131,9 +115,7 @@ .Xr pcic 4 , .Xr pccard.conf 5 , .Xr bt3cfw 8 , -.Xr ngctl 8 , -.Xr pccardc 8 , -.Xr pccardd 8 +.Xr ngctl 8 .Sh HISTORY The .Nm btccc Index: src/share/man/man4/ng_car.4 diff -u /dev/null src/share/man/man4/ng_car.4:1.7 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/ng_car.4 Sat Dec 22 21:31:01 2007 @@ -0,0 +1,214 @@ +.\" Copyright (c) 2005 Nuno Antunes +.\" Copyright (c) 2007 Alexander Motin +.\" 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$ +.\" +.Dd March 11, 2007 +.Dt NG_CAR 4 +.Os +.Sh NAME +.Nm ng_car +.Nd Commited Access Rate netgraph node type +.Sh SYNOPSIS +.In netgraph/ng_car.h +.Sh DESCRIPTION +The +.Nm car +node type limits traffic flowing through it using: +.Pp +.Bl -bullet -compact +.It +Single rate three color marker as described in RFC 2697, +.It +Two rate three color marker as described in RFC 2698, +.It +RED-like rate limit algorithm used by Cisco, +.It +Traffic shaping with RED. +.El +.Sh HOOKS +This node type supports the following hooks: +.Bl -tag -width indent +.It Va upper +Hook leading to upper layer protocols. +.It Va lower +Hook leading to lower layer protocols. +.El +.Pp +Traffic flowing from +.Va upper +to +.Va lower +is considered +.Sy downstream +traffic. +Traffic flowing from +.Va lower +to +.Va upper +is considered +.Sy upstream +traffic. +.Sh MODES OF OPERATION +Each hook can operate in one of the following modes: +.Bl -tag -width indent +.It Dv NG_CAR_SINGLE_RATE +Single rate three color marker as described in RFC 2697. +Committed burst packets are counted as green, extended burst packets are +counted as yellow and exceeding packets are counted as red. +Committed burst getting refilled with CIR (Committed Information Rate) speed. +When it is full, exceeded burst getting refilled. +.It Dv NG_CAR_DOUBLE_RATE +Two rate three color marker as described in RFC 2698. +Committed burst packets are counted as green, peak burst packets are counted +as yellow and exceeding packets are counted as red. +Committed burst getting refilled with CIR speed. +Peak burst getting refilled with PIR (Peak Information Rate) speed at the +same time. +.It Dv NG_CAR_RED +Similar to +.Dv NG_CAR_SINGLE_RATE , +but with different understanding of extended burst. +When normal burst exceeded and extended burst is used, packets are counted +red with probability equal to part of extended burst consumed. +Extended burst getting refilled first. +When it is full, committed burst getting refilled. +This behavior is similar to RED active queue management algorithm. +.Pp +This algorithm is more polite to the TCP traffic than NG_CAR_SINGLE_RATE. +.It Dv NG_CAR_SHAPE +Committed burst packets are counted as green, exceeding packets are delayed +by queue with RED management and counted as yellow. +Packets dropped by queue counted as red. +Queue parameters are hardcoded: length 99 packets, min_th 8 packets, max_p 100%. +.Pp +Traffic shaping is much more polite to the TCP traffic than rate limit on +links with bandwidth * delay product less than 6-8 TCP segments, but it +consumes additional system resources for queue processing. +.El +By default, all information rates are measured in bits per second and bursts +are measured in bytes. But when NG_CAR_COUNT_PACKETS option is enabled, +rates are measured in packets per second and bursts are in packets. +.Sh CONTROL MESSAGES +This node type supports the generic control messages and the following +specific messages. +.Bl -tag -width indent +.It Dv NGM_CAR_SET_CONF Pq Li setconf +Set node configuration to the specified at +.Vt "struct ng_car_bulkconf" +.It Dv NGM_CAR_GET_CONF Pq Li getconf +Return current node configuration as +.Vt "struct ng_car_bulkconf" +.Bd -literal +struct ng_car_hookconf { + u_int64_t cbs; /* Committed burst size */ + u_int64_t ebs; /* Exceeded/Peak burst size */ + u_int64_t cir; /* Committed information rate */ + u_int64_t pir; /* Peak information rate */ + u_int8_t green_action; /* Action for green packets */ + u_int8_t yellow_action; /* Action for yellow packets */ + u_int8_t red_action; /* Action for red packets */ + u_int8_t mode; /* operation mode */ + u_int8_t opt; /* mode options */ +}; + +/* possible actions (..._action) */ +enum { + NG_CAR_ACTION_FORWARD = 1, + NG_CAR_ACTION_DROP +}; + +/* operation modes (mode) */ +enum { + NG_CAR_SINGLE_RATE = 0, + NG_CAR_DOUBLE_RATE, + NG_CAR_RED, + NG_CAR_SHAPE +}; + +/* mode options (opt) */ +#define NG_CAR_COUNT_PACKETS 2 + +struct ng_car_bulkconf { + struct ng_car_hookconf upstream; + struct ng_car_hookconf downstream; +}; +.Ed +.It Dv NGM_CAR_GET_STATS Pq Li getstats +Return node statistics as +.Vt "struct ng_car_bulkstats" +.Bd -literal +struct ng_car_hookstats { + u_int64_t passed_pkts; + u_int64_t droped_pkts; + u_int64_t green_pkts; + u_int64_t yellow_pkts; + u_int64_t red_pkts; + u_int64_t errors; +}; + +struct ng_car_bulkstats { + struct ng_car_hookstats upstream; + struct ng_car_hookstats downstream; +}; +.Ed +.It Dv NGM_CAR_CLR_STATS Pq Li clrstats +Clear node statistics. +.It Dv NGM_CAR_GETCLR_STATS Pq Li getclrstats +Atomically return and clear node statistics. +.El +.Sh SHUTDOWN +This node shuts down upon receipt of a +.Dv NGM_SHUTDOWN +control message, or when all hooks have been disconnected. +.Sh EXAMPLES +Limit outgoing data rate over fxp0 Ethernet interface to 20Mbit/s +and incoming packet rate to 5000pps. +.Bd -literal -offset indent +/usr/sbin/ngctl -f- <<-SEQ + mkpeer fxp0: car lower lower + name fxp0:lower fxp0_car + connect fxp0: fxp0_car: upper upper + msg fxp0_car: setconf { downstream={ cir=20000000 cbs=2500000 ebs=2500000 greenAction=1 yellowAction=1 redAction=2 mode=2 } upstream={ cir=5000 cbs=100 ebs=100 greenAction=1 yellowAction=1 redAction=2 mode=2 opt=2 } } +SEQ +.Ed +.Sh SEE ALSO +.Xr netgraph 4 , +.Xr ngctl 8 +.Rs +.%A J. Heinanen +.%T "A Single Rate Three Color Marker" +.%O RFC 2697 +.Re +.Rs +.%A J. Heinanen +.%T "A Two Rate Three Color Marker" +.%O RFC 2698 +.Re +.Sh AUTHORS +.An Nuno Antunes Aq nuno.antunes@gmail.com +.An Alexander Motin Aq mav@FreeBSD.org +.Sh BUGS +At this moment only DROP and FORWARD actions are implemented. Index: src/share/man/man4/ng_deflate.4 diff -u src/share/man/man4/ng_deflate.4:1.1.2.1 src/share/man/man4/ng_deflate.4:1.2 --- src/share/man/man4/ng_deflate.4:1.1.2.1 Mon Jan 29 17:53:20 2007 +++ src/share/man/man4/ng_deflate.4 Wed Jan 31 04:22:07 2007 @@ -101,7 +101,6 @@ .Fa windowBits specify compression windows size as negotiated by the Compression Control Protocol (CCP) in PPP. -The .It Dv NGM_DEFLATE_RESETREQ Pq Li resetreq This message contains no arguments, and is bi-directional. If an error is detected during decompression, this message is sent by the Index: src/share/man/man4/ng_etf.4 diff -u src/share/man/man4/ng_etf.4:1.7 src/share/man/man4/ng_etf.4:1.8 --- src/share/man/man4/ng_etf.4:1.7 Sat Feb 5 19:31:31 2005 +++ src/share/man/man4/ng_etf.4 Tue May 16 04:28:18 2006 @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd February 28, 2001 +.Dd May 16, 2006 .Dt NG_ETF 4 .Os .Sh NAME @@ -113,7 +113,7 @@ as follows: .Bd -literal -offset 4n #!/bin/sh -ETHER_IF=lnc0 +ETHER_IF=fxp0 MATCH1=0x834 MATCH2=0x835 cat </tmp/xwert Index: src/share/man/man4/ng_iface.4 diff -u src/share/man/man4/ng_iface.4:1.16.2.1 src/share/man/man4/ng_iface.4:1.20 --- src/share/man/man4/ng_iface.4:1.16.2.1 Wed Nov 9 19:36:07 2005 +++ src/share/man/man4/ng_iface.4 Fri Nov 18 18:52:22 2005 @@ -149,11 +149,11 @@ is a special case, since it is not a physical interface with limited bandwidth. One should not turn ALTQ on .Nm -if the latter corresponds to some tunneled connection, e.g. PPPoE or PPTP. -In this case ALTQ should be configured on the interface, that is used to +if the latter corresponds to some tunneled connection, e.g.\& PPPoE or PPTP. +In this case, ALTQ should be configured on the interface that is used to transmit the encapsulated packets. In case when your graph ends up with some kind of serial line, either -synchronous or modem, then +synchronous or modem, the .Nm is the right place to turn ALTQ on. .Sh SEE ALSO Index: src/share/man/man4/ng_ksocket.4 diff -u src/share/man/man4/ng_ksocket.4:1.20.2.1 src/share/man/man4/ng_ksocket.4:1.22 --- src/share/man/man4/ng_ksocket.4:1.20.2.1 Wed Nov 16 16:14:27 2005 +++ src/share/man/man4/ng_ksocket.4 Sat Dec 16 18:32:10 2006 @@ -225,7 +225,8 @@ .Xr netgraph 4 , .Xr ng_socket 4 , .Xr ngctl 8 , -.Xr mbuf_tags 9 +.Xr mbuf_tags 9 , +.Xr socket 9 .Sh HISTORY The .Nm Index: src/share/man/man4/ng_netflow.4 diff -u src/share/man/man4/ng_netflow.4:1.11.2.2 src/share/man/man4/ng_netflow.4:1.15 --- src/share/man/man4/ng_netflow.4:1.11.2.2 Fri Mar 10 15:35:09 2006 +++ src/share/man/man4/ng_netflow.4 Thu Nov 1 00:07:58 2007 @@ -108,7 +108,7 @@ .Va iface Ns Ar N hook. Currently, supported types are raw IP datagrams and Ethernet. -This messsage type uses +This message type uses .Vt "struct ng_netflow_setdlt" as an argument: .Bd -literal -offset 4n @@ -251,7 +251,7 @@ .Xr flowctl 8 , .Xr ngctl 8 .Pp -.Pa http://www.cisco.com/univercd/cc/td/doc/cisintwk/intsolns/netflsol/nfwhite.htm +.Pa http://www.cisco.com/univercd/cc/td/doc/cisintwk/intsolns/netflsol/\:nfwhite.htm .Sh AUTHORS .An -nosplit The Index: src/share/man/man4/ng_pppoe.4 diff -u src/share/man/man4/ng_pppoe.4:1.31.2.3 src/share/man/man4/ng_pppoe.4:1.41 --- src/share/man/man4/ng_pppoe.4:1.31.2.3 Wed Oct 25 23:23:48 2006 +++ src/share/man/man4/ng_pppoe.4 Sun Jan 6 07:41:15 2008 @@ -35,7 +35,7 @@ .\" $FreeBSD$ .\" $Whistle: ng_pppoe.8,v 1.1 1999/01/25 23:46:27 archie Exp $ .\" -.Dd October 22, 2006 +.Dd December 27, 2007 .Dt NG_PPPOE 4 .Os .Sh NAME @@ -102,11 +102,12 @@ .It Dv NGM_PPPOE_CONNECT Tell a nominated newly created hook that its session should enter the state machine as a client. -It must be newly created and -a service name can be given as an argument. -It is legal to specify a zero-length service name. -This is common on some DSL setups. -A session request packet will be broadcast on the Ethernet. +It must be newly created and a service name can be given as an argument. +It is legal to specify a zero-length service name, this is common +on some DSL setups. +It is possible to request a connection to a specific +access concentrator by its name using the "AC-Name\\Service-Name" syntax. +A session request packet will be broadcasted on the Ethernet. This command uses the .Dv ngpppoe_init_data structure shown below. Index: src/share/man/man4/ng_source.4 diff -u src/share/man/man4/ng_source.4:1.10.2.1 src/share/man/man4/ng_source.4:1.14 --- src/share/man/man4/ng_source.4:1.10.2.1 Tue Jan 10 18:11:48 2006 +++ src/share/man/man4/ng_source.4 Fri Mar 2 20:55:24 2007 @@ -1,4 +1,4 @@ -.\" Copyright 2002 Sandvine Inc. +.\" Copyright 2002-2007 Sandvine Inc. .\" All rights reserved. .\" .\" Subject to the following obligations and disclaimer of warranty, use and @@ -29,10 +29,10 @@ .\" THIS SOFTWARE, EVEN IF SANDVINE IS ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" Author: Dave Chapeskie +.\" Author: Dave Chapeskie .\" $FreeBSD$ .\" -.Dd December 5, 2005 +.Dd March 1, 2007 .Dt NG_SOURCE 4 .Os .Sh NAME @@ -180,6 +180,53 @@ .Vt uint32_t parameter which puts upper limit on the amount of packets sent per second. +.It Dv NGM_SOURCE_SET_TIMESTAMP Pq Ic settimestamp +This message specifies that a timestamp (in the format of a +.Vt "struct timeval" ) +should be inserted in the transmitted packets. +This message requires a structure containing the following fields: +.Bl -tag -width indent +.It Va offset +The offset from the beginning of the packet at which the timestamp is to be +inserted. +.It Va flags +Set to 1 to enable the timestamp. +.El +.It Dv NGM_SOURCE_GET_TIMESTAMP Pq Ic gettimestamp +Returns the current timestamp settings in the form of the structure described +above. +.It Dv NGM_SOURCE_SET_COUNTER Pq Ic setcounter +This message specifies that a counter should be embedded in transmitted +packets. +Up to four counters may be independently configured. +This message requires a structure containing the following fields: +.Bl -tag -width indent +.It Va offset +The offset from the beginning of the packet at which the counter is to be +inserted. +.It Va flags +Set to 1 to enable the counter. +.It Va width +The byte width of the counter. +It may be 1, 2, or 4. +.It Va next_val +The value for the next insertion of the counter. +.It Va min_val +The minimum value to be used by the counter. +.It Va max_val +The maximum value to be used by the counter. +.It Va increment +The value to be added to the counter after each insertion. +It may be negative. +.It Va index +The counter to be configured, from 0 to 3. +.El +.It Dv NGM_SOURCE_GET_COUNTER Pq Ic getcounter +This message requires a single +.Vt uint8_t +parameter which specifies the counter to query. +Returns the current counter settings in the form of the structure described +above. .El .Sh SHUTDOWN This node shuts down upon receipt of a @@ -223,19 +270,27 @@ After which it can be referred to as .Dq Li src0: . .Pp -Once created, packets need to be sent to the node, the TCL net package -can be used to generate these packets: +Once created, packets can be sent to the node as raw binary data. +Each packet must be delivered in a separate netgraph message. .Pp -[Sandvine specific TCL code example omitted] -.Pp -To feed the output of the above TCL script to the +The following example uses a short Perl script to convert the hex +representation of an ICMP packet to binary and deliver it to the .Nm source node's .Va input hook via .Xr nghook 8 : -.Pp -.Dl "tcl genPacket | nghook bge0:orphans input" +.Bd -literal -offset indent +perl -pe 's/(..)[ \et\en]*/chr(hex($1))/ge' < -.Pp -Any parameter definitions cited below can be found in that file. -.Pp -.Em Keyboard related functions -.Pp -Three functions are related to basic keyboard hardware: -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBDRESET -reset keyboard, set defaults; -.It KBDGTPMAT -get current typematic value, parameter is a pointer to int where -the values is stored to; -.It KBDSTPMAT -set current typematic value, similar to above command. -.El -.Pp -Symbolic values are available for the appropriate constants. -To specify the initial typematic delay time, they are -KBD_TPD250 for 250 ms through -KBD_TPD1000 for 1000 ms, in steps of 250 ms. -The typematic repeat -rates are -KBD_TPM300, specifying 30.0 characters per second through -KBD_TPM20 for 2.0 characters per second. -The intermediate values -are: 30.0, 26.7, 24.0, 21.8, 20.0, 18.5, 17.1, 16.0, 15.0, 13.3, -12.0, 10.9, 10.0, 9.2, 8.6, 8.0, 7.5, 6.7, 6.0, 5.5, 5.0, 4.6, 4.3, -4.0, 3.7, 3.3, 3.0, 2.7, 2.5, 2.3, 2.1, 2.0 characters per second. -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBDGREPSW -get key repetition switch, and -.It KBDSREPSW -set key repetition switch -.El -.Pp -again take a pointer to int as argument. -They manipulate the -drivers internal keyboard repetition flag, possible values are: -KBD_REPEATOFF or KBD_REPEATON. -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBDGLEDS -get LED state, and -.It KBDSLEDS -set LED state manipulate the keyboard indicators, but do not influence -the drivers idea of lock key state. -.El -.Pp -The int where the argument points to -may have the values -KBD_SCROLLLOCK, KBD_NUMLOCK, KBD_CAPSLOCK, which may be used in any -conjunction. -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBDGLOCK -gets state of SCROLL,NUM,CAPS, and -.It KBDSLOCK -sets state of SCROLL,NUM,CAPS + LEDs -.El -.Pp -should be used in a same manner to get/set the drivers internal -LED flags. -.Pp -.Em Keyboard remapping -.Pp -One important feature of the -.Nm -driver is its ability to overload the built in key definition. -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBDGCKEY -get current key values, -.It KBDSCKEY -set new key assignment values, and -.It KBDGOKEY -get original key assignment values -.El -.Pp -arrange those functions. -The take a pointer to a -.Em struct kbd_ovlkey -as argument as described below. -In addition, -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBDRMKEY -removes a key assignment, taking a pointer to an int as argument which -contains the affected key number; -.It KBDDEFAULT -removes all key assignments. -.El -.Bd -literal -struct kbd_ovlkey /* complete definition of a key */ -{ - u_short keynum; /* the key itself */ - u_short type; /* type of key, see below */ - u_char subu; /* subtype, ignored on write */ - char unshift[KBDMAXOVLKEYSIZE+1]; /* emitted string, unshifted */ - u_char subs; /* subtype, ignored on write */ - char shift[KBDMAXOVLKEYSIZE+1]; /* emitted string, shifted */ - u_char subc; /* subtype, ignored on write */ - char ctrl[KBDMAXOVLKEYSIZE+1]; /* emitted string, control */ - u_char suba; /* subtype, ignored on write */ - char altgr[KBDMAXOVLKEYSIZE+1]; /* emitted string, altgr */ -}; -.Ed -.Pp -The appropriate values for the -.Em type -field are: -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBD_NONE -no function, key is disabled, -.It KBD_SHIFT -keyboard shift, -.It KBD_META -alternate shift, sets bit8 to ASCII code, -.It KBD_NUM -numeric shift, keypad numeric / application mode, -.It KBD_CTL -control code generation, -.It KBD_CAPS -caps shift - swaps case of letter, -.It KBD_ASCII -ASCII code generating key, -.It KBD_SCROLL -stop output, -.It KBD_FUNC -function key, -.It KBD_KP -keypad keys, -.It KBD_BREAK -ignored, -.It KBD_ALTGR -AltGr translation feature, -.It KBD_SHFTLOCK -shift lock, -.It KBD_CURSOR -cursor keys, and -.It KBD_RETURN -.Dq Return -or -.Dq Enter -keys. -.El -.Pp -The -.Em subtype -field contains one of the values -.Pp -.Bl -tag -width 20n -offset indent -compact -.It KBD_SUBT_STR -key is bound to a string, or -.It KBD_SUBT_FNC -key is bound to a function. -.El -.Pp -.Em Downloadable character set interface -.Pp -EGA and VGA video adaptors provide the capability of downloadable -software fonts. -Since the -.Sq native character set -of any IBM-compatible PC video board does not allow the full interpretation -of DEC multinational character set or ISO Latin-1 -(ISO 8859-1), -this might be very useful for a U**X environment. -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGASETFONTATTR -set font attr, and -.It VGAGETFONTATTR -get font attr -.El -.Pp -are used to manipulate the drivers information about a downloaded -font. -The take a pointer to a -.Em struct vgafontattr -as argument: -.Bd -literal -struct vgafontattr { - int character_set; /* VGA character set */ - int font_loaded; /* Mark font loaded or unloaded */ - int screen_size; /* Character rows per screen */ - int character_scanlines; /* Scanlines per character - 1 */ - int screen_scanlines; /* Scanlines per screen - 1 byte */ -}; -.Ed -.Pp -Each character of each font is to be downloaded with -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGALOADCHAR -load vga char, -.El -.Pp -taking a pointer to -.Em struct vgaloadchar -as its argument: -.Bd -literal -struct vgaloadchar { - int character_set; /* VGA character set to load into */ - int character; /* Character to load */ - int character_scanlines; /* Scanlines per character */ - u_char char_table[32]; /* VGA character shape table */ -}; -.Ed -.Pp -The field -.Em character_set -takes the values -CH_SET0, CH_SET1, CH_SET2, CH_SET3 on EGA's or VGA's. -Since VGA's -might have up to eight simultaneously loaded fonts, they can take -CH_SET4, CH_SET5, CH_SET6, or CH_SET7, too. -.Pp -Note that there is a dependence between the font size -and a possible screen height -(in character rows), -depending on the video adaptor used: -.Bd -literal -Screen size (rows) on: EGA VGA -Font size - -8 x 8 43 50 -8 x 10 35 40 -8 x 14 25 28 -8 x 16 not 25 - applicable -.Ed -.Pp -.Em General screen manipulation commands -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGACURSOR -sets cursor shape, -.El -.Pp -taking a pointer to the following structure as argument: -.Bd -literal -struct cursorshape { - int screen_no; /* screen number for which to set, */ - /* or -1 to set on current active screen */ - int start; /* top scanline, range 0... Character Height - 1 */ - int end; /* end scanline, range 0... Character Height - 1 */ -}; -.Ed -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGASETSCREEN -set screen info, and -.It VGAGETSCREEN -get screen info, -.El -.Pp -provide an interface to some general driver internal variables -which might modify the behaviour of the screens, -or which might simply be used to force the driver to switch -to one certain screen. -Their argument is a pointer to the structure: -.Bd -literal -struct screeninfo { - int adaptor_type; /* type of video adaptor installed */ - /* read only, ignored on write (yet!) */ - int totalfonts; /* no of downloadable fonts */ - /* read only, ignored on write */ - int totalscreens; /* no of virtual screens */ - /* read only, ignored on write */ - int screen_no; /* screen number, this was got from */ - /* on write, if -1, apply pure_vt_mode */ - /* and/or screen_size to current screen*/ - /* else to screen_no supplied */ - int current_screen; /* screen number, which is displayed. */ - /* on write, if -1, make this screen */ - /* the current screen, else set current*/ - /* displayed screen to parameter */ - int pure_vt_mode; /* flag, pure VT mode or HP/VT mode */ - /* on write, if -1, no change */ - int screen_size; /* screen size */ - /* on write, if -1, no change */ - int force_24lines; /* force 24 lines if 25 lines VT mode */ - /* or 28 lines HP mode to get pure */ - /* VT220 screen size */ - /* on write, if -1, no change */ - int vga_family; /* if adaptor_type = VGA, this reflects*/ - /* the chipset family after a read */ - /* nothing happens on write ... */ - int vga_type; /* if adaptor_type = VGA, this reflects*/ - /* the chipset after a read */ - /* nothing happens on write ... */ - int vga_132; /* set to 1 if driver has support for */ - /* 132 column operation for chipset */ - /* currently ignored on write */ -}; -.Ed -.Pp -Its field -.Em pure_vt_mode -may take the values M_HPVT for a mixed VTxxx and HP Mode, with function -key labels and a status line, or M_PUREVT for only VTxxx sequences -recognized, with no labels. -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGASETCOLMS -sets the number of columns for the current screen, -.El -.Pp -its parameter is a pointer to an integer containing either a value of 80, -or a value of 132. -Note that setting the number of columns to 132 is only supported on -some VGA adaptors. -Any unsupported numbers cause the ioctl to fail with -.Va errno -(see -.Xr intro 2 ) -being set to -.Er EINVAL . -.Pp -.Em VGA color palette interface -.Pp -Only on VGA adaptors, there is a color palette register at the output. -It is responsible for the red, green and blue output voltage provided -for each of the 256 internal color codes, each lying in the range of -0 through 63 (with 63 representing the brightest value for a base color). -Thus, these adaptors map each color code to a color of a -.Dq palette -out of 262144 colors. -The commands -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGAREADPEL -read VGA palette entry, and -.It VGAWRITEPEL -write VGA palette entry -.El -.Pp -establish an interface to these palette registers. -Their argument is -a pointer to: -.Bd -literal -struct vgapel { - unsigned idx; /* index into palette, 0 .. 255 valid */ - unsigned r, g, b; /* RGB values, masked by VGA_PMASK (63) */ -}; -.Ed -.Pp -.Em Driver identification -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGAPCVTID -returns information if the current compiled in driver is pcvt and its -major and minor revision numbers. -the call is taking a pointer to the -following structure as argument: -.El -.Bd -literal -struct pcvtid { -#define PCVTIDNAMELN 16 /* driver id - string length */ - char name[PCVTIDNAMELN]; /* driver name, == PCVTIDSTR */ -#define PCVTIDNAME "pcvt" /* driver id - string */ - int rmajor; /* revision number, major */ -#define PCVTIDMAJOR 3 - int rminor; /* revision number, minor */ -#define PCVTIDMINOR 00 -}; -.Ed -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGAPCVTINFO -returns information if the current compiled in driver is pcvt and its -compile time options. -the call is taking a pointer to the following -structure as argument: -.El -.Bd -literal -struct pcvtinfo { - u_int opsys; /* PCVT_xxx(x)BSD */ -#define CONF_UNKNOWNOPSYS 0 -#define CONF_386BSD 1 /* unsupported !!! */ -#define CONF_NETBSD 2 -#define CONF_FREEBSD 3 - u_int opsysrel; /* Release for NetBSD/FreeBSD */ - u_int nscreens; /* PCVT_NSCREENS */ - u_int scanset; /* PCVT_SCANSET */ - u_int updatefast; /* PCVT_UPDATEFAST */ - u_int updateslow; /* PCVT_UPDATESLOW */ - u_int sysbeepf; /* PCVT_SYSBEEPF */ - u_int pcburst; /* PCVT_PCBURST */ - u_int kbd_fifo_sz; /* PCVT_KBD_FIFO_SZ */ - -/* config booleans */ - - u_long compile_opts; /* PCVT_xxxxxxxxxxxxxxx */ -}; -.Ed -.Pp -.Em Screen saver -.Pp -Depending on the configuration of a -.Nm -driver, there might be a simple screen saver available. -It is controlled -by the command -.Pp -.Bl -tag -width 20n -offset indent -compact -.It VGASCREENSAVER -set timeout for screen saver in seconds; 0 turns it off, -.El -.Pp -taking a pointer to an integer as argument. -Despite its command name, -this is available on -.Em any -kind of adaptor if configured in by the -.Xr config 8 -option -.Dq PCVT_SCREENSAVER -.Pp -.Em Compatibility commands for USL-style VT's -.Pp -.Nm -supports a subset of the USL-style commands used to control -the virtual terminal interface. -This feature is mainly intended to allow -.Em XFree86 -to switch between virtual screens even when -running an X server. -They are ugly with respect to the implied semantics -(i.e., they break Berkeley semantics). -See the file -.Pa i386/include/pcvt_ioctl.h -for their documentation. -.Sh FILES -.Bl -tag -width /usr/include/machine/pcvt_ioctl.h -.It Pa /usr/include/machine/pcvt_ioctl.h -Definitions for -.Xr ioctl 2 -function calls -.It Pa /dev/ttyv? -.It Pa /dev/console -Device nodes to access the -.Nm -driver -.It Pa i386/isa/pcvt/pcvt_conf.h -(relative to the kernel source tree) -Documents the various compile-time options to tailor -.Nm . -.El -.Sh SEE ALSO -.Xr cursor 1 , -.Xr loadfont 1 , -.Xr scon 1 , -.Xr intro 2 , -.Xr ioctl 2 , -.Xr atkbd 4 , -.Xr keyboard 4 , -.Xr config 8 , -.Xr ispcvt 8 -.Sh HISTORY -The -.Nm -driver has been developed for and contributed to -.Bx 386 0.1 . -Since then -.Nm -has become a standard part of -.Fx , -.Nx -and -.Ox . -Since -.Fx 5.0 , -.Nm -is -.Fx -specific with support for -.Nx -and -.Ox -removed to -ease further maintenance. -.Sh AUTHORS -.An -nosplit -Written by -.An Hellmuth Michaelis Aq hm@FreeBSD.org -with much help from -.An Brian Dunford-Shore Aq brian@morpheus.wustl.edu -and -.An J\(:org Wunsch Aq joerg@FreeBSD.org . -.Pp -This driver is based on several people's previous work, notably -the historic -.Xr pccons 4 -implementation by -.An William Jolitz Aq ljolitz@cardio.ucsf.edu -and -.An Don Ahn , -and the keyboard mapping code from -.An Holger Veit Aq veit@first.gmd.de . -.Sh BUGS -At least one left. Index: src/share/man/man4/pim.4 diff -u src/share/man/man4/pim.4:1.2 src/share/man/man4/pim.4:1.3 --- src/share/man/man4/pim.4:1.2 Fri Jul 9 17:22:36 2004 +++ src/share/man/man4/pim.4 Tue Feb 13 05:30:34 2007 @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 4, 2003 +.Dd February 12, 2007 .Dt PIM 4 .Os .\" @@ -35,7 +35,6 @@ .\" .Sh SYNOPSIS .Cd "options MROUTING" -.Cd "options PIM" .Pp .In sys/types.h .In sys/socket.h Index: src/share/man/man4/polling.4 diff -u src/share/man/man4/polling.4:1.19.2.5 src/share/man/man4/polling.4:1.27 --- src/share/man/man4/polling.4:1.19.2.5 Sat Dec 2 17:05:22 2006 +++ src/share/man/man4/polling.4 Fri Apr 6 22:25:14 2007 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 2, 2006 +.Dd April 6, 2007 .Dt POLLING 4 .Os .Sh NAME @@ -184,6 +184,7 @@ .Xr fwip 4 , .Xr fxp 4 , .Xr ixgb 4 , +.Xr nfe 4 , .Xr nge 4 , .Xr re 4 , .Xr rl 4 , Index: src/share/man/man4/ppbus.4 diff -u src/share/man/man4/ppbus.4:1.23 src/share/man/man4/ppbus.4:1.24 --- src/share/man/man4/ppbus.4:1.23 Mon Feb 14 06:25:17 2005 +++ src/share/man/man4/ppbus.4 Sat Feb 24 00:50:17 2007 @@ -281,7 +281,7 @@ one, current and available modes are separated. .Pp With this level of abstraction a particular chipset may commute from any -native mode the any other mode emulated with extended modes without +native mode to any other mode emulated with extended modes without disturbing upper layers. For example, most chipsets support NIBBLE mode as native and emulated with ECP and/or EPP. @@ -307,7 +307,7 @@ returned each time the driver requests the ppbus. .Ss Bus allocation and interrupts ppbus allocation is mandatory not to corrupt I/O of other devices. -An other +Another usage of ppbus allocation is to reserve the port and receive incoming interrupts. .Pp Index: src/share/man/man4/pty.4 diff -u src/share/man/man4/pty.4:1.14.8.1 src/share/man/man4/pty.4:1.19 --- src/share/man/man4/pty.4:1.14.8.1 Wed May 30 16:26:01 2007 +++ src/share/man/man4/pty.4 Thu May 24 17:43:41 2007 @@ -177,13 +177,60 @@ .Xr select 2 for exceptional conditions. .El +.Pp +There is currently two +.Nm +systems available: the original +.Bx Nm , +and a +SysVR4 pts-like implementation. +It is possible to switch between the two implementations by setting the +.Va kern.pts.enable +sysctl. +Setting it to 0 will use the +.Bx Nm , +to non-zero the pts implementation. +It defaults to 0. +It is possible to set the maximum number of ptys +which can be allocated at the same time with the +.Va kern.pts.max +sysctl. +It defaults to 1000. +It is not recommended to use more than 1000 pseudo-terminals, as all software +which use +.Xr utmp 5 +will not be able to handle pseudo-terminals with number superior to 999. +.Pp +The pts implementation also supports the +.Dv TIOCGPTN +.Xr ioctl 2 +call, which takes a pointer to an +.Vt "unsigned int" +as a parameter and provides the +number of the pty. .Sh FILES -.Bl -tag -width /dev/tty[p-sP-S][0-9a-v]x -compact +The files used by the +.Bx +pseudo terminals implementation are: +.Pp +.Bl -tag -width ".Pa /dev/tty[p-sP-S][0-9a-v]" -compact .It Pa /dev/pty[p-sP-S][0-9a-v] master pseudo terminals .It Pa /dev/tty[p-sP-S][0-9a-v] slave pseudo terminals .El +.Pp +The files used by the pts implementation are: +.Pp +.Bl -tag -width ".Pa /dev/pts/[num]" -compact +.It Pa /dev/ptmx +control device, returns a file descriptor to a new master pseudo terminal +when opened. +.It Pa /dev/pty[num] +master pseudo terminals +.It Pa /dev/pts/[num] +slave pseudo terminals +.El .Sh DIAGNOSTICS None. .Sh SEE ALSO Index: src/share/man/man4/ral.4 diff -u src/share/man/man4/ral.4:1.3.2.6 src/share/man/man4/ral.4:1.13 --- src/share/man/man4/ral.4:1.3.2.6 Fri Sep 14 00:06:30 2007 +++ src/share/man/man4/ral.4 Tue Sep 11 01:54:14 2007 @@ -15,7 +15,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 10, 2006 +.Dd September 10, 2007 .Os .Dt RAL 4 .Sh NAME Index: src/share/man/man4/random.4 diff -u src/share/man/man4/random.4:1.18.2.1 src/share/man/man4/random.4:1.20 --- src/share/man/man4/random.4:1.18.2.1 Sat Jul 22 17:34:38 2006 +++ src/share/man/man4/random.4 Mon Sep 18 23:24:19 2006 @@ -128,7 +128,7 @@ are not considered as an entropy source. Set the variable to 1 (one) if you wish to use them for entropy harvesting. -All hardware interrupt harvesting is setup by the +All hardware interrupt harvesting is set up by the individual device drivers. .Pp The Index: src/share/man/man4/re.4 diff -u src/share/man/man4/re.4:1.12.2.5 src/share/man/man4/re.4:1.20 --- src/share/man/man4/re.4:1.12.2.5 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/re.4 Tue Jan 30 16:40:04 2007 @@ -165,6 +165,8 @@ .It PLANEX COMMUNICATIONS Inc.\& GN-1200TC (8169S) .It +USRobotics USR997902 Gigabit Ethernet (8169S) +.It Xterasys XN-152 10/100/1000 NIC (8169) .El .Sh DIAGNOSTICS Index: src/share/man/man4/rr232x.4 diff -u src/share/man/man4/rr232x.4:1.2.2.1 src/share/man/man4/rr232x.4:1.3 --- src/share/man/man4/rr232x.4:1.2.2.1 Mon May 1 01:11:34 2006 +++ src/share/man/man4/rr232x.4 Sat Sep 30 23:14:48 2006 @@ -25,7 +25,7 @@ .\" $FreeBSD$ .\" .Dd April 27, 2006 -.Dt rr232x 4 +.Dt RR232X 4 .Os .Sh NAME .Nm rr232x @@ -58,9 +58,7 @@ out of drives that are attached to different controllers. Online management is provided by utilities that are available for free download from -.Rs -.%O http://www.highpoint-tech.com/ -.Re +.Pa http://www.highpoint-tech.com/ . .Sh HARDWARE The .Nm @@ -88,12 +86,11 @@ .Nm driver first appeared in .Fx 6.1 . -.Pp .Sh AUTHORS .An -nosplit The .Nm driver was provided by -.An HighPoint Technologies, Inc . +.An "HighPoint Technologies, Inc" . This manual page was written by .An Scott Long Aq scottl@FreeBSD.org . Index: src/share/man/man4/rum.4 diff -u /dev/null src/share/man/man4/rum.4:1.3 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/rum.4 Fri Sep 7 23:28:39 2007 @@ -0,0 +1,168 @@ +.\" +.\" Copyright (c) 2005-2007 +.\" Damien Bergamini +.\" +.\" Permission to use, copy, modify, and distribute this software for any +.\" purpose with or without fee is hereby granted, provided that the above +.\" copyright notice and this permission notice appear in all copies. +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +.\" +.\" $FreeBSD$ +.\" +.Dd September 7, 2007 +.Os +.Dt RUM 4 +.Sh NAME +.Nm rum +.Nd Ralink Technology USB IEEE 802.11a/b/g wireless network device +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device ehci" +.Cd "device uhci" +.Cd "device ohci" +.Cd "device usb" +.Cd "device rum" +.Cd "device wlan" +.Cd "device wlan_amrr" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +if_rum_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver supports USB 2.0 and PCI Express Mini Card wireless adapters based on the +Ralink RT2501USB and RT2601USB chipsets. +.Pp +Ralink PCI Express Mini Card adapters show up as normal USB 2.0 devices and are +thus handled by the +.Nm +driver. +.Pp +The RT2501USB chipset is the second generation of 802.11a/b/g adapters from +Ralink. +It consists of two integrated chips, an RT2571W MAC/BBP and an RT2528 or +RT5226 radio transceiver. +.Pp +The RT2601USB chipset consists of two integrated chips, an RT2671 MAC/BBP and +an RT2527 or RT5225 radio transceiver. +This chipset uses the MIMO (multiple-input multiple-output) technology with +multiple antennas to extend the operating range of the adapter and to achieve +higher throughput. +.Sh HARDWARE +The +.Nm +driver supports USB 2.0 and PCI Express Mini Card wireless +adapters based on the Ralink RT2501USB and RT2601USB chipsets, +including: +.Pp +.Bl -column -compact "Atlantis Land A02-PCM-W54" "Bus" +.It Em Card Ta Em Bus +.It "3Com Aolynk WUB320g" Ta USB +.It "Abocom WUG2700 Ta" Ta USB +.It "Airlink101 AWLL5025" Ta USB +.It "ASUS WL-167g ver 2" Ta USB +.It "Belkin F5D7050 ver 3" Ta USB +.It "Belkin F5D9050 ver 3" Ta USB +.It "Buffalo WLI-U2-SG54HP" Ta USB +.It "Buffalo WLI-U2-G54HP" Ta USB +.It "CNet CWD-854 ver F" Ta USB +.It "Conceptronic C54RU ver 2" Ta USB +.It "Corega CG-WLUSB2GO" Ta USB +.It "D-Link DWL-G122 rev C1" Ta USB +.It "D-Link WUA-1340" Ta USB +.It "Digitus DN-7003GR" Ta USB +.It "Edimax EW-7318USG" Ta USB +.It "Gigabyte GN-WB01GS" Ta USB +.It "Gigabyte GN-WI05GS" Ta USB +.It "Hawking HWUG1" Ta USB +.It "Hawking HWU54DM" Ta USB +.It "Hercules HWGUSB2-54-LB" Ta USB +.It "Hercules HWGUSB2-54V2-AP" Ta USB +.It "LevelOne WNC-0301USB v3" Ta USB +.It "Linksys WUSB54G rev C" Ta USB +.It "Linksys WUSB54GR" Ta USB +.It "Planex GW-US54HP" Ta USB +.It "Planex GW-US54Mini2" Ta USB +.It "Planex GW-USMM" Ta USB +.It "Senao NUB-3701" Ta USB +.It "Sitecom WL-113 ver 2" Ta USB +.It "Sitecom WL-172" Ta USB +.It "Sweex LW053" Ta USB +.It "TP-LINK TL-WN321G" Ta USB +.El +.Sh EXAMPLES +Join an existing BSS network (i.e., connect to an access point): +.Pp +.Dl "ifconfig rum0 inet 192.168.0.20 netmask 0xffffff00" +.Pp +Join a specific BSS network with network name +.Dq Li my_net : +.Pp +.Dl "ifconfig rum0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net" +.Pp +Join a specific BSS network with 40-bit WEP encryption: +.Bd -literal -offset indent +ifconfig rum0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e + wepmode on wepkey 0x1234567890 weptxkey 1 +.Ed +.Pp +Join a specific BSS network with 104-bit WEP encryption: +.Bd -literal -offset indent +ifconfig rum0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e + wepmode on wepkey 0x01020304050607080910111213 weptxkey 1 +.Ed +.Sh DIAGNOSTICS +.Bl -diag +.It "rum%d: could not load 8051 microcode" +An error occurred while attempting to upload the microcode to the onboard 8051 +microcontroller unit. +The driver will reset the hardware. +This should not happen. +.El +.Sh SEE ALSO +.Xr altq 4 , +.Xr arp 4 , +.Xr netintro 4 , +.Xr usb 4 , +.Xr wlan 4 , +.Xr wlan_amrr 4 , +.Xr ifconfig 8 +.Rs +.%T "Ralink Technology" +.%O http://www.ralinktech.com/ +.Re +.Sh HISTORY +The +.Nm +driver first appeared in +.Ox 4.0 . +.Sh CAVEATS +.Pp +The +.Nm +driver supports automatic control of the transmit speed in BSS mode only. +Therefore the use of a +.Nm +adapter in Host AP mode is discouraged. +.Sh AUTHORS +The +.Nm +driver was written by +.An Niall O'Higgins Aq niallo@openbsd.org +and +.An Damien Bergamini Aq damien@openbsd.org . Index: src/share/man/man4/sab.4 diff -u src/share/man/man4/sab.4:1.2 src/share/man/man4/sab.4:removed --- src/share/man/man4/sab.4:1.2 Thu Jul 8 20:55:24 2004 +++ src/share/man/man4/sab.4 Thu Jan 17 11:57:40 2008 @@ -1,84 +0,0 @@ -.\" $OpenBSD: sab.4,v 1.6 2003/06/06 10:29:42 jmc Exp $ -.\" -.\" Copyright (c) 2001 Jason L. Wright (jason@thought.net) -.\" 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 ``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. -.\" -.\" $FreeBSD$ -.\" -.Dd October 29, 2001 -.Dt SAB 4 sparc64 -.Os -.Sh NAME -.Nm sab -.Nd Infineon SAB82532 (ESCC2) serial communications driver -.Sh SYNOPSIS -.Cd "device sab" -.Sh DESCRIPTION -The -.Nm -is a -.Tn Infineon -(formerly -.Tn Siemens ) -SAB82532 (ESCC2) serial interface chip used in PCI-based UltraSPARC -.Tn Sun -workstations. -The ESCC2 provides two independent input/output channels per instance. -These chips are normally used to provide RS-423 and RS232 serial ports -for general purpose use. -.Pp -The -.Nm -driver supports all of the standard -.Xr tty 4 -ioctl calls. -The status of the DTR, RTS, CTS, and DCD signals can be queried with -.Dv TIOCMGET -command, but, due to limitations in the hardware, -only the DTR and RTS signals can be modified with -.Dv TIOCMSET , TIOCMBIC , -and -.Dv TIOCMBIS -.Xr ioctl 2 -commands. -.Sh FILES -.Bl -tag -width ".Pa /dev/tty[a-b]" -compact -.It Pa /dev/tty[a-b] -Serial ports. -.El -.Sh SEE ALSO -.Xr ioctl 2 , -.Xr intro 4 , -.Xr tty 4 -.Sh HISTORY -The -.Nm -driver first appeared in -.Fx 5.1 . -.Sh BUGS -The -.Nm -does not support -.Pa cua -minor devices. Index: src/share/man/man4/scc.4 diff -u /dev/null src/share/man/man4/scc.4:1.1 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/scc.4 Fri Mar 31 02:33:22 2006 @@ -0,0 +1,75 @@ +.\" +.\" Copyright (c) 2006 Marcel Moolenaar +.\" 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 ``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. +.\" +.\" $FreeBSD$ +.\" +.Dd March 29, 2006 +.Dt SCC 4 +.Os +.\" +.Sh NAME +.Nm scc +.Nd driver for Serial Communications Controllers (SCC) devices +.\" +.Sh SYNOPSIS +.Cd "device scc" +.Cd "device uart" +.\" +.Sh DESCRIPTION +The +.Nm +device driver provides support for various classes of SCCs. +It is an umbrella driver that delegates control of each independent +communication channel to subordinate drivers. +These subordinate drivers, like +.Xr uart 4 , +take care of the details of the communication itself. +.\" +.Sh HARDWARE +The +.Nm +driver supports the following classes of SCCs: +.Pp +.Bl -bullet -compact +.It +SAB82532: Siemens SAB 82532 based serial communications controllers. +.It +Z8530: Zilog 8530 based serial communications controllers. +.El +.\" +.Sh SEE ALSO +.Xr puc 4 , +.Xr uart 4 +.\" +.Sh HISTORY +The +.Nm +device driver first appeared in +.Fx 7.0 . +.Sh AUTHORS +The +.Nm +driver and this manual page were written by +.An Marcel Moolenaar Aq marcel@xcllnt.net . Index: src/share/man/man4/sched_4bsd.4 diff -u src/share/man/man4/sched_4bsd.4:1.3 src/share/man/man4/sched_4bsd.4:1.5 --- src/share/man/man4/sched_4bsd.4:1.3 Fri Jun 17 02:46:16 2005 +++ src/share/man/man4/sched_4bsd.4 Tue Jun 5 09:09:28 2007 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 7, 2005 +.Dd June 5, 2007 .Os .Dt SCHED_4BSD 4 .Sh NAME Index: src/share/man/man4/sched_ule.4 diff -u src/share/man/man4/sched_ule.4:1.2.2.1 src/share/man/man4/sched_ule.4:1.7 --- src/share/man/man4/sched_ule.4:1.2.2.1 Tue Oct 10 02:41:37 2006 +++ src/share/man/man4/sched_ule.4 Tue Jun 5 09:31:04 2007 @@ -24,12 +24,12 @@ .\" .\" $FreeBSD$ .\" -.Dd April 7, 2005 +.Dd June 5, 2007 .Os .Dt SCHED_ULE 4 .Sh NAME .Nm sched_ule -.Nd ULE Scheduler +.Nd ULE scheduler .Sh SYNOPSIS .Cd "options SCHED_ULE" .Sh DESCRIPTION @@ -79,11 +79,3 @@ .Sh AUTHORS .An Jeff Roberson .Aq jeff@FreeBSD.org -.Sh BUGS -As an experimental scheduler, -.Nm -is not enabled by default due to a number of known issues, including weak -performance with several known workloads, and reports of instability. -Deployment of -.Nm -in production environments is not recommended at this time. Index: src/share/man/man4/sctp.4 diff -u /dev/null src/share/man/man4/sctp.4:1.3 --- /dev/null Thu Jan 17 11:57:40 2008 +++ src/share/man/man4/sctp.4 Wed Sep 26 00:03:10 2007 @@ -0,0 +1,425 @@ +.\" Copyright (c) 2006, Randall Stewart. +.\" +.\" 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 the University of +.\" California, Berkeley and its contributors. +.\" 4. Neither the name of the University nor the names of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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$ +.\" +.Dd December 15, 2006 +.Dt SCTP 4 +.Os +.Sh NAME +.Nm sctp +.Nd Internet Stream Control Transmission Protocol +.Sh SYNOPSIS +.In sys/types.h +.In sys/socket.h +.In netinet/sctp.h +.Ft int +.Fn socket AF_INET SOCK_STREAM IPPROTO_SCTP +.Ft int +.Fn socket AF_INET SOCK_SEQPACKET IPPROTO_SCTP +.Sh DESCRIPTION +The +.Tn SCTP +protocol provides reliable, flow-controlled, two-way +transmission of data. +It is a message oriented protocol and can +support the +.Dv SOCK_STREAM +and +.Dv SOCK_SEQPACKET +abstractions. +.Tn SCTP +uses the standard +Internet address format and, in addition, provides a per-host +collection of +.Dq "port addresses" . +Thus, each address is composed of an Internet address specifying +the host and network, with a specific +.Tn SCTP +port on the host identifying the peer entity. +.Pp +There are two models of programming in SCTP. +The first uses the +.Dv SOCK_STREAM +abstraction. +In this abstraction sockets utilizing the +.Tn SCTP +protocol are either +.Dq active +or +.Dq passive . +Active sockets initiate connections to passive +sockets. +By default, +.Tn SCTP +sockets are created active; to create a +passive socket, the +.Xr listen 2 +system call must be used after binding the socket with the +.Xr bind 2 +or +.Xr sctp_bindx 3 +system calls. +Only passive sockets may use the +.Xr accept 2 +call to accept incoming connections. +Only active sockets may use the +.Xr connect 2 +call to initiate connections. +.Pp +The other abstraction +.Dv SOCK_SEQPACKET +provides a +.Dq connectionless +mode of operation in that the user may send to an address +(using any of the valid send calls that carry a +socket address) and an association will be setup +implicitly by the underlying +.Tn SCTP +transport stack. +This abstraction is the only one capable of sending data on the +third leg of the four-way handshake. +A user must still call +.Xr listen 2 +to allow the socket to accept connections. +Calling +.Xr listen 2 +however does not restrict the user from still initiating +implicit connections to other peers. +.Pp +The +.Tn SCTP +protocol directly supports multi-homing. +So when binding a socket with the +.Dq wildcard +address +.Dv INADDR_ANY , +the +.Tn SCTP +stack will inform the peer about all of the local addresses +that are deemed in scope of the peer. +The peer will then possibly have multiple paths to reach the local host. +.Pp +The +.Tn SCTP +transport protocol is also multi-streamed. +Multi-streaming refers to the ability to send sub-ordered flows of +messages. +A user performs this by specifying a specific stream in one of the +extended send calls such as the +.Xr sctp_send 3 +function call. +Sending messages on different streams will allow parallel delivery +of data i.e., a message loss in stream 1 will not block the delivery +of messages sent in stream 2. +.Pp +The +.Tn SCTP +transport protocol also provides a unordered service as well. +The unordered service allows a message to be sent and delivered +with no regard to the ordering of any other message. +.Ss Extensions +The FreeBSD implementation of +.Tn SCTP +also supports the following extensions: +.Bl -hang -width indent +.It "sctp partial reliability" +This extension allows one to have message be skipped and +not delivered based on some user specified parameters. +.It "sctp dynamic addressing" + This extension allows addresses to be added and deleted +dynammically from an existing association. +.It "sctp authentication" +This extension allows the user to authenticate specific +peer chunks (including data) to validate that the peer +who sent the message is in fact the peer who setup the +association. +A shared key option is also provided for +so that two stacks can pre-share keys. +.It "packet drop" + Some routers support a special satellite protocol that +will report losses due to corruption. +This allows retransmissions without subsequent loss in bandwidth +utilization. +.It "stream reset" +This extension allows a user on either side to reset the +stream sequence numbers used by any or all streams. +.El +.Pp +.Tn SCTP +supports a number of socket options which can be set with +.Xr setsockopt 2 +and tested with +.Xr getsockopt 2 +or +.Xr sctp_opt_info 2 : +.Bl -tag -width ".Dv SCTP_SET_PEER_PRIMARY_ADDR" +.It Dv SCTP_NODELAY +Under most circumstances, +.Tn SCTP +sends data when it is presented; when outstanding data has not +yet been acknowledged, it gathers small amounts of output to be +sent in a single packet once an acknowledgement is received. +For some clients, such as window systems that send a stream of +mouse events which receive no replies, this packetization may +cause significant delays. +The boolean option +.Dv SCTP_NODELAY +defeats this algorithm. +.It Dv SCTP_RTOINFO +This option returns specific information about an associations +.Dq "Retransmission Time Out" . +It can also be used to change the default values. +.It Dv SCTP_ASSOCINFO +This option returns specific information about the requested +association. +.It Dv SCTP_INITMSG +This option allows you to get or set the default sending +parameters when an association is implicitly setup. +It allows you to change such things as the maxium number of +streams allowed inbound and the number of streams requested +of the peer. +.It Dv SCTP_AUTOCLOSE +For the one-to-many model +.Dv ( SOCK_SEQPACKET ) +associations are setup implicitly. +This option allows the user to specify a default number of idle +seconds to allow the association be maintained. +After the idle timer (where no user message have been sent or have +been received from the peer) the association will be gracefully +closed. +The default for this value is 0, or unlimited (i.e., no automatic +close). +.It Dv SCTP_SET_PEER_PRIMARY_ADDR +The dynamic address extension allows a peer to also request a +particular address of its be made into the primary address. +This option allows the caller to make such a request to a peer. +Note that if the peer does not also support the dynamic address +extension, this call will fail. +Note the caller must provide a valid local address that the peer has +been told about during association setup or dynamically. +.It Dv SCTP_PRIMARY_ADDR +This option allows the setting of the primary address +that the caller wishes to send to. +The caller provides the address of a peer that is to be made primary. +.It Dv SCTP_ADAPTATION_LAYER +The dynamic address extension also allows a user to +pass a 32 bit opaque value upon association setup. +This option allows a user to set or get this value. +.It Dv SCTP_DISABLE_FRAGMENTS +By default +.Tn SCTP +will fragment user messages into multiple pieces that +will fit on the network and then later, upon reception, reassemble +the pieces into a single user message. +If this option is enabled instead, any send that exceeds the path +maximum transfer unit (P-MTU) will fail and the message will NOT be +sent. +.It Dv SCTP_PEER_ADDR_PARAMS +This option will allow a user to set or get specific +peer address parameters. +.It Dv SCTP_DEFAULT_SEND_PARAM +When a user does not use one of the extended send +calls (e.g., +.Xr sctp_sendmsg 3 ) +a set of default values apply to each send. +These values include things like the stream number to send +to as well as the per-protocol id. +This option lets a caller both get and set these values. +If the user changes these default values, then these new values will +be used as the default whenever no information is provided by the +sender (i.e., the non-extended API is used). +.It Dv SCTP_EVENTS +.Tn SCTP +has non-data events that it can communicate +to its application. +By default these are all disabled since they arrive in the data path +with a special flag +.Dv MSG_NOTIFICATION +set upon the received message. +This option lets a caller +both get what events are current being received +as well as set different events that they may be interested +in receiving. +.It Dv SCTP_I_WANT_MAPPED_V4_ADDR +.Tn SCTP +supports both IPV4 and IPV6. +An association may span both IPV4 and IPV6 addresses since +.Tn SCTP +is multi-homed. +By default, when opening an IPV6 socket, when +data arrives on the socket from a peer's +V4 address the V4 address will be presented with an address family +of AF_INET. +If this is undesireable, then this option +can be enabled which will then convert all V4 addresses +into mapped V6 representations. +.It Dv SCTP_MAXSEG +By default +.Tn SCTP +chooses its message fragmentation point +based upon the smallest P-MTU of the peer. +This option lets the caller set it to a smaller value. +Note that while the user can change this value, if the P-MTU +is smaller than the value set by the user, then the P-MTU +value will override any user setting. +.It Dv SCTP_DELAYED_ACK_TIME +This option lets the user both set and get the +delayed ack time (in milliseconds) that +.Tn SCTP +is using. +The default is 200 milliseconds. +.It Dv SCTP_PARTIAL_DELIVERY_POINT +.Tn SCTP +at times may need to start delivery of a +very large message before the entire message has +arrived. +By default SCTP waits until the incoming +message is larger than one fourth of the receive +buffer. +This option allows the stacks value +to be overridden with a smaller value. +.It Dv SCTP_FRAGMENT_INTERLEAVE +.Tn SCTP +at times will start partial delivery (as mentioned above). +In the normal case successive reads will continue to return +the rest of the message, blocking if needed, until all of +that message is read. +However this means other messages may have arrived and be ready +for delivery and be blocked behind the message being partially +delivered. +If this option is enabled, when a partial delivery +message has no more data to be received, then a subsequent +read may return a different message that is ready for delivery. +By default this option is off since the user must be using the +extended API's to be able to tell the difference between +messages (via the stream and stream sequence number). +.It Dv SCTP_AUTH_CHUNK +By default only the dynamic addressing chunks are +authenticated. +This option lets a user request an +additional chunk be authenticated as well. +Note that successive calls to this option will work and continue +to add more chunks that require authentication. +Note that this option only effects future associations and +not existing ones. +.It Dv SCTP_AUTH_KEY +This option allows a user to specify a shared +key that can be later used to authenticate +a peer. +.It Dv SCTP_HMAC_IDENT +This option will let you get or set the list of +HMAC algorithms used to authenticate peers. +Note that the HMAC values are in priority order where +the first HMAC identifier is the most prefered +and the last is the least prefered. +.It Dv SCTP_AUTH_ACTIVE_KEY +This option allows you to make a key active for +the generation of authentication information. +Note that the peer must have the same key or else the +data will be discarded. +.It Dv SCTP_AUTH_DELETE_KEY +This option allows you to delete an old key. +.It Dv SCTP_USE_EXT_RECVINFO +The sockets api document allows an extended +send/receive information structure to be used. +The extended structure includes additional fields +related to the next message to be received (after the +current receive completes) if such information is known. +By default the system will not pass this information. +This option allows the user to request this information. +.It Dv SCTP_AUTO_ASCONF +By default when bound to all address and the system administrator has +enables automatic dynamic addresses, the +.Tn SCTP +stack will automatically generate address changes into add and +delete requests to any peers by setting this option to +true. +This option allows an endpoint to disable that behavior. +.It Dv SCTP_MAXBURST +By default +.Tn SCTP +implements micro-burst control so that as the congestion window +opens up no large burst of packets can be generated. +The default burst limit is four. +This option lets the user change this value. +.It Dv SCTP_CONTEXT +Many sctp extended calls have a context field. +The context field is a 32 bit opaque value that will be returned in +send failures. +This option lets the caller set the default +context value to use when none is provided by the user. +.It Dv SCTP_EXPLICIT_EOR +By default, a single send is a complete message. +.Tn SCTP +generates an implied record boundary. +If this option is enabled, then all sends are part of the same message +until the user indicates an end of record with the +special flag +.Dv SCTP_EOR +passed in the sctp_sndrcvinfo flags field. +This effectively makes all sends part of the same message +until the user specifices differently. +This means that a caller must NOT change the stream number until +after the +.Dv SCTP_EOR +is passed to +.Tn SCTP +else an error will be returned. +.It Dv SCTP_STATUS +This option is a read only option that returns +various status information about the specified association. +.It Dv SCTP_GET_PEER_ADDR_INFO +This read only option returns information about a peer +address. +.It Dv SCTP_PEER_AUTH_CHUNKS +This read only option returns a list of the chunks +the peer requires to be authenticated. +.It Dv SCTP_LOCAL_AUTH_CHUNKS +This read only option returns a list of the locally +required chunks that must be authenticated. +.It Dv SCTP_RESET_STREAMS +This socket option is used to cause a stream sequence +number or all stream sequence numbers to be reset. +Note that the peer +.Tn SCTP +endpoint must also support the stream reset extension +as well. +.El +.Sh SEE ALSO +.Xr accept 2 , +.Xr bind 2 , +.Xr connect 2 , +.Xr listen 2 , +.Xr sctp_bindx 3 , +.Xr sctp_connectx 3 , +.Xr sctp_opt_info 3 , +.Xr sctp_recvmsg 3 , +.Xr sctp_sendmsg 3 Index: src/share/man/man4/sem.4 diff -u src/share/man/man4/sem.4:1.2 src/share/man/man4/sem.4:1.3 --- src/share/man/man4/sem.4:1.2 Mon Jun 2 19:19:23 2003 +++ src/share/man/man4/sem.4 Sun Nov 12 00:49:28 2006 @@ -24,19 +24,26 @@ .\" .\" $FreeBSD$ .\" -.Dd January 14, 2003 +.Dd November 11, 2006 .Dt SEM 4 .Os .Sh NAME .Nm sem .Nd POSIX semaphores .Sh SYNOPSIS -To link into the kernel: +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: .Bd -ragged -offset indent .Cd "options P1003_1B_SEMAPHORES" .Ed .Pp -To load as a kernel loadable module: +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +sem_load="YES" +.Ed .Pp .Dl "kldload sem" .Sh DESCRIPTION @@ -47,6 +54,10 @@ to implement .Tn POSIX semaphores. +This facility offers support for such functions as +.Fn sem_init +and +.Fn sem_wait . It is available both as a kernel option for static inclusion and as a dynamic kernel module. .Sh SEE ALSO Index: src/share/man/man4/smp.4 diff -u src/share/man/man4/smp.4:1.21 src/share/man/man4/smp.4:1.23 --- src/share/man/man4/smp.4:1.21 Sat Dec 18 09:13:37 2004 +++ src/share/man/man4/smp.4 Mon Sep 18 23:24:19 2006 @@ -39,7 +39,7 @@ Support for multi-processor systems is present for all Tier-1 architectures on .Fx . -Currently, this includes alpha, amd64, i386, ia64, and sparc64. +Currently, this includes amd64, i386, ia64, and sparc64. Support is enabled using .Cd options SMP . It is permissible to use the SMP kernel configuration on non-SMP equipped @@ -104,6 +104,6 @@ .Bsx . .Pp .Fx 5.0 -also introduced support for SMP on the alpha, ia64, and sparc64 architectures. +also introduced support for SMP on the ia64 and sparc64 architectures. .Sh AUTHORS .An Steve Passe Aq fsmp@FreeBSD.org Index: src/share/man/man4/sn.4 diff -u src/share/man/man4/sn.4:1.8.2.2 src/share/man/man4/sn.4:1.14 --- src/share/man/man4/sn.4:1.8.2.2 Thu Feb 2 15:50:01 2006 +++ src/share/man/man4/sn.4 Fri Oct 7 10:32:15 2005 @@ -55,9 +55,10 @@ .Pp .Bl -bullet -compact .It -3Com Megahertz X-Jack Ethernet PC-Card XJ10BT +3Com Megahertz X-Jack Ethernet PC Card XJ10BT, XJ10BC .It -3Com Megahertz X-Jack Ethernet PC-Card XJ10BC +3Com Megahertz XJEM and CCEM series: CCEM3288C, CCEM3288T, CCEM3336, +CEM3336C, CCEM3336T, XJEM1144C, XJEM1144T, XJEM3288C, XJEM3288T, XJEM3336 .It Farallon EtherMac PC Card 595a .It Index: src/share/man/man4/snd_atiixp.4 diff -u src/share/man/man4/snd_atiixp.4:1.2.2.2 src/share/man/man4/snd_atiixp.4:1.5 --- src/share/man/man4/snd_atiixp.4:1.2.2.2 Tue Jan 31 08:10:09 2006 +++ src/share/man/man4/snd_atiixp.4 Sat May 12 14:33:52 2007 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 28, 2005 +.Dd November 29, 2006 .Dt SND_ATIIXP 4 .Os .Sh NAME @@ -52,6 +52,21 @@ to attach to ATI IXP audio devices. This driver supports 16bit playback and recording, and 32bit native playback and recording. +.Ss Runtime Configuration +The following +.Xr sysctl 8 +variables are available in addition to those available to all +.Xr sound 4 +devices: +.Bl -tag -width ".Va dev.pcm.%d.polling" -offset indent +.It Va dev.pcm.%d.polling +Experimental polling mode, where the driver operates by querying the device +state on each tick using +.Xr callout 9 . +Polling is disabled by default. +Do not enable it unless you are facing weird interrupt problems or if the +device cannot generate interrupts at all. +.El .Sh HARDWARE The .Nm Index: src/share/man/man4/snd_emu10kx.4 diff -u /dev/null src/share/man/man4/snd_emu10kx.4:1.5 --- /dev/null Thu Jan 17 11:57:41 2008 +++ src/share/man/man4/snd_emu10kx.4 Wed Sep 12 15:43:43 2007 @@ -0,0 +1,292 @@ +.\" +.\" Copyright (c) 2003-2007 Yuriy Tsibizov +.\" 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$ +.\" +.Dd July 15, 2007 +.Dt SND_EMU10KX 4 +.Os +.Sh NAME +.Nm snd_emu10kx +.Nd Creative SoundBlaster Live! and Audigy sound cards device driver +.Sh SYNOPSIS +To compile this driver into the kernel, place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device sound" +.Cd "device snd_emu10kx" +.Ed +.Pp +Alternatively, to load the driver as a module at boot time, place the +following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +snd_emu10kx_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +bridge driver allows the generic audio driver +.Xr sound 4 +to attach to Creative sound cards based on the EMU10K1, CA0100, CA0101, CA0102 +and CA0108 DSPs. +.Pp +The +.Nm +sound cards have a PCM part, which is accessible through one to five +.Xr pcm 4 +devices (see +.Sx MULTICHANNEL PLAYBACK +for details), and MPU401-compatible MIDI I/O controller, which is accessible +through the midi device. +Wave table synthesizer is not supported. +.Sh HARDWARE +The +.Nm +driver supports the following sound cards: +.Pp +.Bl -bullet -compact +.It +Creative Sound Blaster Live!\& (EMU10K1 Chipset). +Both PCM and MIDI interfaces are available. +.It +Creative Sound Blaster Audigy (CA0100 and CA0101 Chipset). +PCM and two MIDI interfaces available. +.It +Creative Sound Blaster Audigy 2 and Creative Sound Blaster Audigy 4 (CA0102 +Chipset). +PCM support is limited to 48kHz/16 bit stereo (192kHz/24 bit part +of this chipset is not supported). +.It +Creative Sound Blaster Audigy 2 Value (CA0108 Chipset). +PCM support is limited +to 48kHz/16 bit stereo (192kHz/24 bit part of this chipset is not supported). +There is no MIDI support for this card. +.El +.Pp +The +.Nm +driver does +.Em not +support the following sound cards (although they are named +similar to some supported ones): +.Pp +.Bl -bullet -compact +.It +Creative Sound Blaster Live!\& 24-Bit, identified by +.Fx +as +.Qq Li "emu10k1x Soundblaster Live! 5.1" . +.It +Creative Sound Blaster Audigy LS / ES, identified by +.Fx +as +.Qq Li "CA0106-DAT Audigy LS" . +.It +All other Creative sound cards with -DAT chipsets. +.It +All Creative X-Fi series sound cards. +.El +.Sh MULTICHANNEL PLAYBACK +By default driver is loaded with multichannel playback capabilities enabled. +If you do not set the +.Dv hint.emu10kx.0.multichannel_disabled +option in your +.Xr loader.conf 5 +configuration file you will get up to +five DSP devices, one for each sound card output. +You can use additional software (like +.Em audio/pulseaudio +from +.Em The Ports Collection +) to do sound stream demultiplexing. +Only +.Dq FRONT +output can play and record sound from external +sources (like line or S/PDIF inputs). +.Sh MULTICHANNEL RECORDING +By default multichannel recording capabilities are not enabled when you load +this driver. +If you enable the +.Dv hint.emu10kx.0.multichannel_recording +option in +.Xr loader.conf 5 +you will get one more DSP device that is rate-locked to 48kHz/16bit/mono. +This is actually 48kHz/16bit/32 channels on SB Live! cards and +48kHz/16bit/64channels on Audigy cards, but the current implementation of +sound subsystem does not support such an amount of PCM channels. +This device can not be opened for read, thus confusing many applications. +.Pp +Within multichannel stream first half (0-15 or 0-31) is a copy of all DSP +outputs, second half (15-30 or 32-63) is a copy of some DSP inputs. +On Live! cards the last substream (31) is used as a sync stream and always +set to 0xc0de. +Audigy cards do not need such sync data, because stream always start with +substream 0. +.Ss SB Live! substream map (in byte offsets, each substream is 2 bytes LE) +.Bl -tag -width ".Dv +0x00..+0x1E" +.It Dv Offset +Substream +.It +0x00..+0x1E +PCM streams 0..15 +.It +0x20, +0x22 +Empty +.It +0x24..+0x2A +PCM inputs: front left, front right, rear left, rear right, center, sub +.It +0x2C..+0x3C +DSP inputs 0..8: +.It +0x3E +sync substream (0xc0de) +.El +.Pp +.Ss Audigy substream map (in byte offsets, each substream is 2 bytes LE) +.Bl -tag -width ".Dv +0x00..+0x3E" +.It Dv Offset +Substream +.It +0x00..+0x3E +PCM streams 0..31 +.It +0x40..+0x5E +PCM inputs: front LR, rear LR, center, sub, ... +.It +0x60..+0x7E +DSP inputs 0..16 +.El +.Sh OSS MIXER CONTROLS +These are the controls available through the standard OSS programming interface. +You can use +.Xr mixer 8 +to change them. +.Pp +On EMU10K1-based cards the OSS mixer directly controls the AC97 codec. +On newer cards the OSS mixer controls some parameters of the AC97 codec and +some DSP-based mixer controls. +.Bl -inset +.It Qq vol +mixer control is overall sound volume. +.It Qq pcm +mixer control is PCM playback volume. +It controls only front output +volume in multichannel mode and all output volume in single channel mode. +.It Qq rec +mixer control acts very different on EMU10K1 and other cards. +On EMU10K1 cards it controls the AC97 codec recording level. +On non-EMU10K1 cards it controls the amount of AC97 "stereo mix" entering +the DSP. +AC97 recording level and AC97 recording source are fixed on CA0100, CA0101, +CA0102 and CA0108 cards. +AC97 recording level are always set to maximum and recording source is always +.Dq Li "stereo mix" . +.It Qq dig1 +is a CD S/PDIF (on-card) volume control +.It Qq dig2 +is an AudigyDrive S/PDIF (Audigy series) or TOSLink (SB Live! series) volume +control +.It Qq dig3 +is an on-card S/PDIF volume control +.It Qq line2 +is AudigyDrive "Line In 2" volume control +.It Qq line3 +is AudigyDrive "AUX In 2" volume control +.El +.Pp +Other OSS mixer controls control inputs of AC97 codec. +.Sh PRIVATE DEVICE CONTROLS +You can control some of EMU10Kx operation and configuration parameters through +.Va dev.emu10kx. Ns Aq Ar X +sysctls. +These +.Xr sysctl 8 +values are temporary and should not be relied +upon. +.Sh DRIVER CONFIGURATION +Loader tunables are used to set driver configuration. +Tunables can be set at the +.Xr loader 8 +prompt before booting the kernel or they can be stored in +.Pa /boot/loader.conf . +These tunables can't be changed from a maching +.Xr sysctl 8 +entry after boot, but you can change them using +.Xr kenv 1 +while the driver is not loaded. +.Bl -tag -width indent +.It Va hint.emu10kx. Ns Ao Ar X Ac Ns Va .disabled +Disables loading a driver instance. +.It Va hint.emu10kx. Ns Ao Ar X Ac Ns Va .multichannel_disabled +Disables multichannel playback support, when one card is represented as +several PCM devices. +.It Va hint.emu10kx. Ns Ao Ar X Ac Ns Va .multichannel_recording +Enables experimental multichannel recording support. +.It Va hint.emu10kx. Ns Ao Ar X Ac Ns Va .debug +Set debug output level. +.Bl -tag -width 2n +.It 0 +No additional debug options enabled +.It 1 +Enables all DSP outputs to be connected, even those +that are known to be unused on a particular card. +.It 2 +Additional debug messages about in-driver events will be printed. +.It 2 +Additional debug messages will be printed when memory allocation fails. +.El +.El +.Sh FILES +.Bl -tag -width ".Pa /dev/emu10kx?" -compact +.It Pa /dev/emu10kx? +.Nm +management interface +.El +.Sh SEE ALSO +.Xr sound 4 +.Sh HISTORY +The +.Nm +device driver first appeared in +.Fx 7.0 . +.Sh AUTHORS +.An -nosplit +The PCM part of the driver is based on the +.Xr snd_emu10k1 4 +SB Live!\& driver by +.An "Cameron Grant" Aq cg@freebsd.org . +The MIDI interface is based on the +.Xr snd_emu10k1 4 +MIDI interface code by +.An "Mathew Kanner" Aq matk@freebsd.org . +The +.Nm +device driver and this manual page were written by +.An Yuriy Tsibizov . +.Sh BUGS +.Pp +The driver does not detect lost S/PDIF signals and produces noise when +S/PDIF is not connected and S/PDIF volume is not zero. +.Pp +The PCM driver cannot detect the presence of Live!Drive or AudigyDrive +breakout boxes and tries to use them (and list their connectors in the +mixer). +.Pp +The MIDI driver cannot detect the presence of Live!Drive or AudigyDrive +breakout boxes and tries to enable the IR receiver on them anyway. Index: src/share/man/man4/snd_es137x.4 diff -u src/share/man/man4/snd_es137x.4:1.4.2.2 src/share/man/man4/snd_es137x.4:1.9 --- src/share/man/man4/snd_es137x.4:1.4.2.2 Sat Dec 31 03:55:55 2005 +++ src/share/man/man4/snd_es137x.4 Thu Nov 30 01:07:02 2006 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 15, 2005 +.Dd November 29, 2006 .Dt SND_ES137X 4 .Os .Sh NAME @@ -53,15 +53,26 @@ .Ss Runtime Configuration The following .Xr sysctl 8 -variable are available in addition to those available to all +variables are available in addition to those available to all .Xr sound 4 devices: -.Bl -tag -width ".Va hw.snd.pcm%d.spdif_enabled" -offset indent +.Bl -tag -width ".Va hw.snd.pcm%d.latency_timer" -offset indent +.It Va hw.snd.pcm%d.latency_timer +Controls the PCI latency timer setting. +Increasing this value will solve most popping and crackling issues +(especially on VIA motherboards). .It Va hw.snd.pcm%d.spdif_enabled Enables S/PDIF output on the primary playback channel. This .Xr sysctl 8 variable is available only if the device is known to support S/PDIF output. +.It Va dev.pcm.%d.polling +Experimental polling mode, where the driver operates by querying the device +state on each tick using +.Xr callout 9 . +Polling is disabled by default. +Do not enable it unless you are facing weird interrupt problems or if the +device cannot generate interrupts at all. .El .Sh HARDWARE The Index: src/share/man/man4/snd_hda.4 diff -u src/share/man/man4/snd_hda.4:1.10.2.2 src/share/man/man4/snd_hda.4:1.13 --- src/share/man/man4/snd_hda.4:1.10.2.2 Fri Jan 4 21:01:38 2008 +++ src/share/man/man4/snd_hda.4 Fri Jan 4 20:57:06 2008 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 5, 2007 +.Dd July 14, 2007 .Dt SND_HDA 4 .Os .Sh NAME @@ -146,6 +146,8 @@ .It Intel 82801H .It +Intel 82801I +.It nVidia MCP51 .It nVidia MCP55 @@ -169,13 +171,15 @@ .Pp .Bl -bullet -compact .It -Analog Device AD1981HD +Analog Devices AD1981HD +.It +Analog Devices AD1983 .It -Analog Device AD1983 +Analog Devices AD1986A .It -Analog Device AD1986A +Analog Devices AD1988 .It -Analog Device AD1988 +Analog Devices AD1988B .It CMedia CMI9880 .It @@ -187,6 +191,10 @@ .It Realtek ALC262 .It +Realtek ALC268 +.It +Realtek ALC660 +.It Realtek ALC861 .It Realtek ALC861VD Index: src/share/man/man4/snd_sbc.4 diff -u src/share/man/man4/snd_sbc.4:1.14.2.3 src/share/man/man4/snd_sbc.4:1.19 --- src/share/man/man4/snd_sbc.4:1.14.2.3 Wed Jun 21 12:28:05 2006 +++ src/share/man/man4/snd_sbc.4 Sat Feb 17 19:31:58 2007 @@ -25,11 +25,13 @@ .\" .\" $FreeBSD$ .\" -.Dd December 15, 2005 +.Dd February 17, 2007 .Dt SND_SBC 4 .Os .Sh NAME -.Nm snd_sbc +.Nm snd_sbc , +.Nm snd_sb16 , +.Nm snd_sb8 .Nd Creative Sound Blaster ISA and compatible bridge device driver .Sh SYNOPSIS To compile this driver into the kernel, place the following lines in your @@ -37,13 +39,17 @@ .Bd -ragged -offset indent .Cd "device sound" .Cd "device snd_sbc" +.Cd "device snd_sb16" +.Cd "device snd_sb8" .Ed .Pp Alternatively, to load the driver as a module at boot time, place the -following line in +following lines in .Xr loader.conf 5 : .Bd -literal -offset indent snd_sbc_load="YES" +snd_sb16_load="YES" +snd_sb8_load="YES" .Ed .Pp Non-PnP cards require the following lines in @@ -60,7 +66,8 @@ .Nm bridge driver allows the generic audio driver .Xr sound 4 -to attach to Creative Sound Blaster ISA compatible audio cards. +to attach to Creative Sound Blaster ISA (mostly SB16 or SB8, known as +SoundBlaster Pro) compatible audio cards. .Pp The value of flags specifies the secondary DMA channel. If the secondary Index: src/share/man/man4/snd_spicds.4 diff -u src/share/man/man4/snd_spicds.4:1.2.2.2 src/share/man/man4/snd_spicds.4:1.4 --- src/share/man/man4/snd_spicds.4:1.2.2.2 Fri Jan 4 21:02:04 2008 +++ src/share/man/man4/snd_spicds.4 Fri Jan 4 20:57:34 2008 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 30, 2006 +.Dd May 28, 2007 .Dt SND_SPICDS 4 .Os .Sh NAME @@ -59,6 +59,8 @@ .It AK4381 .It +AK4396 +.It AK4524 .It AK4528 Index: src/share/man/man4/snd_via8233.4 diff -u src/share/man/man4/snd_via8233.4:1.2.2.2 src/share/man/man4/snd_via8233.4:1.7 --- src/share/man/man4/snd_via8233.4:1.2.2.2 Thu Apr 27 02:45:39 2006 +++ src/share/man/man4/snd_via8233.4 Sat May 12 14:41:41 2007 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 25, 2006 +.Dd November 29, 2006 .Dt SND_VIA8233 4 .Os .Sh NAME @@ -52,6 +52,21 @@ to attach to the VIA VT8233 audio devices. These audio chipsets are integrated in the southbridge on many VIA based motherboards. +.Ss Runtime Configuration +The following +.Xr sysctl 8 +variables are available in addition to those available to all +.Xr sound 4 +devices: +.Bl -tag -width ".Va dev.pcm.%d.polling" -offset indent +.It Va dev.pcm.%d.polling +Experimental polling mode, where the driver operates by querying the device +state on each tick using +.Xr callout 9 . +Polling is disabled by default. +Do not enable it unless you are facing weird interrupt problems or if the +device cannot generate interrupts at all. +.El .Sh HARDWARE The .Nm Index: src/share/man/man4/splash.4 diff -u src/share/man/man4/splash.4:1.25.2.1 src/share/man/man4/splash.4:1.28 --- src/share/man/man4/splash.4:1.25.2.1 Fri Jan 20 06:12:20 2006 +++ src/share/man/man4/splash.4 Wed May 17 17:33:06 2006 @@ -219,8 +219,6 @@ Both the splash screen and the screen saver work with .Xr syscons 4 only. -They are not available for the alternative console driver -.Xr pcvt 4 . .Sh SEE ALSO .Xr vidcontrol 1 , .Xr syscons 4 , Index: src/share/man/man4/stge.4 diff -u src/share/man/man4/stge.4:1.3.2.2 src/share/man/man4/stge.4:1.5 --- src/share/man/man4/stge.4:1.3.2.2 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/stge.4 Tue Jan 30 16:40:04 2007 @@ -77,7 +77,7 @@ and GMII transceivers, which means it can be used with either copper or 1000baseX fiber applications. .Pp -The Sundance/Tamarack TC9021 also support jumbo frames, which can be +The Sundance/Tamarack TC9021 also supports jumbo frames, which can be configured via the interface MTU setting. Selecting an MTU larger than 1500 bytes with the .Xr ifconfig 8 @@ -139,7 +139,6 @@ The .Nm driver also supports one special link option for 1000baseTX cards: -.Pp .Bl -tag -width ".Cm link0" .It Cm link0 With 1000baseTX cards, establishing a link between two ports requires @@ -152,7 +151,7 @@ .Nm driver configures the ports as slaves by default. Setting the -.Ar link0 +.Cm link0 flag with .Xr ifconfig 8 will set a port as a master instead. @@ -192,12 +191,13 @@ tunables: .Bl -tag -width indent .It Va dev.stge.%d.rxint_nframe -Number of frames between RxDMAComplete interrupt. +Number of frames between RxDMAComplete interrupts. The accepted range is 1 to 255, default value is 8 frames. The interface has to be brought down and up again before a change takes effect. .It Va dev.stge.%d.rxint_dmawait Maximum amount of time to wait in 1us increments before issuing -a Rx interrupt if number of frames received is less than rxint_nframe. +an Rx interrupt if the number of frames received is less than +.Va rxint_nframe . The accepted range is 0 to 4194, default value is 30 microseconds. The interface has to be brought down and up again before a change takes effect. .El Index: src/share/man/man4/syncache.4 diff -u src/share/man/man4/syncache.4:1.1.14.2 src/share/man/man4/syncache.4:1.4 --- src/share/man/man4/syncache.4:1.1.14.2 Fri Apr 14 22:14:30 2006 +++ src/share/man/man4/syncache.4 Thu Dec 20 00:58:54 2007 @@ -12,7 +12,7 @@ .\" .\" $FreeBSD$ .\" -.Dd August 31, 2001 +.Dd December 18, 2007 .Dt SYNCACHE 4 .Os .Sh NAME @@ -132,7 +132,7 @@ .Xr loader 8 . .It Va rexmtlimit Maximum number of times a SYN,ACK is retransmitted before being discarded. -The default of 3 retransmits corresponds to a 15 second timeout, this value +The default of 3 retransmits corresponds to a 45 second timeout, this value may be increased depending on the RTT to client machines. Tunable via .Xr sysctl 3 . Index: src/share/man/man4/syscons.4 diff -u src/share/man/man4/syscons.4:1.40.2.2 src/share/man/man4/syscons.4:1.45 --- src/share/man/man4/syscons.4:1.40.2.2 Wed Oct 25 23:26:53 2006 +++ src/share/man/man4/syscons.4 Fri Dec 15 00:40:57 2006 @@ -288,7 +288,7 @@ entering the kernel debugger (KDB) by pressing the key combination. KDB will still be invoked when the kernel panics or hits a break point if it is included in the kernel. -If this option is not defined, this behavior may be controled at runtime +If this option is not defined, this behavior may be controlled at runtime by the .Xr sysctl 8 variable @@ -297,7 +297,7 @@ This option disables the ``reboot'' key (by default, it is .Dv Ctl-Alt-Del ) , so that the casual user may not accidentally reboot the system. -If this option is not defined, this behavior may be controled at runtime +If this option is not defined, this behavior may be controlled at runtime by the .Xr sysctl 8 variable Index: src/share/man/man4/sysmouse.4 diff -u src/share/man/man4/sysmouse.4:1.25 src/share/man/man4/sysmouse.4:1.26 --- src/share/man/man4/sysmouse.4:1.25 Mon Feb 14 06:25:17 2005 +++ src/share/man/man4/sysmouse.4 Mon Mar 6 21:05:50 2006 @@ -358,7 +358,7 @@ .Pp .Bl -tag -width MOUSE_MOVEABS -compact .It Dv MOUSE_ACTION -.It Dv MOUSE_MOTIONEVENT +.It Dv MOUSE_MOTION_EVENT These operations take the information in .Dv u.data and act upon it. @@ -369,7 +369,7 @@ also processes button press actions and sends signal to the process if requested or performs cut and paste operations if the current console is a text interface. -.It Dv MOUSE_BUTTONEVENT +.It Dv MOUSE_BUTTON_EVENT .Dv u.data specifies a button and its click count. The console driver will @@ -377,9 +377,9 @@ for cut and paste operations if the console is in text mode. .El .Pp -.Dv MOUSE_MOTIONEVENT +.Dv MOUSE_MOTION_EVENT and -.Dv MOUSE_BUTTONEVENT +.Dv MOUSE_BUTTON_EVENT are newer interface and are designed to be used together. They are intended to replace functions performed by .Dv MOUSE_ACTION Index: src/share/man/man4/tcp.4 diff -u src/share/man/man4/tcp.4:1.51.2.2 src/share/man/man4/tcp.4:1.59 --- src/share/man/man4/tcp.4:1.51.2.2 Tue Sep 19 16:43:56 2006 +++ src/share/man/man4/tcp.4 Wed Apr 4 02:57:09 2007 @@ -32,7 +32,7 @@ .\" From: @(#)tcp.4 8.1 (Berkeley) 6/5/93 .\" $FreeBSD$ .\" -.Dd September 13, 2006 +.Dd February 28, 2007 .Dt TCP 4 .Os .Sh NAME @@ -117,6 +117,23 @@ and tested with .Xr getsockopt 2 : .Bl -tag -width ".Dv TCP_NODELAY" +.It Dv TCP_INFO +Information about a socket's underlying TCP session may be retrieved +by passing the read-only option +.Dv TCP_INFO +to +.Xr getsockopt 2 . +It accepts a single argument: a pointer to an instance of +.Vt "struct tcp_info" . +.Pp +This API is subject to change; consult the source to determine +which fields are currently filled out by this option. +.Fx +specific additions include +send window size, +receive window size, +and +bandwidth-controlled window space. .It Dv TCP_NODELAY Under most circumstances, .Tn TCP @@ -457,9 +474,12 @@ which allows the receiver to inform the sender about all successfully arrived segments, allowing the sender to retransmit the missing segments only. -.It Va sack.initburst -Control the number of SACK retransmissions done upon initiation of SACK -recovery. +.It Va sack.maxholes +Maximum number of SACK holes per connection. +Defaults to 128. +.It Va sack.globalmaxholes +Maximum number of SACK holes per system, across all connections. +Defaults to 65536. .It Va maxtcptw When a TCP connection enters the .Dv TIME_WAIT @@ -478,6 +498,22 @@ .It Va nolocaltimewait Suppress creating of compressed TCP TIME_WAIT states for connections in which both endpoints are local. +.It Va fast_finwait2_recycle +Recycle +.Tn TCP +.Dv FIN_WAIT_2 +connections faster when the socket is marked as +.Dv SBS_CANTRCVMORE +(no user process has the socket open, data received on +the socket cannot be read). +The timeout used here is +.Va finwait2_timeout . +.It Va finwait2_timeout +Timeout to use for fast recycling of +.Tn TCP +.Dv FIN_WAIT_2 +connections. +Defaults to 60 seconds. .El .Sh ERRORS A socket operation may fail with one of the following errors returned: @@ -540,3 +576,9 @@ The RFC 1323 extensions for window scaling and timestamps were added in .Bx 4.4 . +The +.Dv TCP_INFO +option was introduced in +.Tn Linux 2.6 +and is +.Em subject to change . Index: src/share/man/man4/tdfx.4 diff -u src/share/man/man4/tdfx.4:1.7 src/share/man/man4/tdfx.4:1.8 --- src/share/man/man4/tdfx.4:1.7 Fri Jan 21 16:36:37 2005 +++ src/share/man/man4/tdfx.4 Sat Mar 4 05:37:38 2006 @@ -9,8 +9,7 @@ .Nd Voodoo Graphics and VoodooII Memory Access GLIDE device driver .Sh SYNOPSIS .Cd device tdfx -.Pp -.Cd options TDFX_LINUX +.Cd device tdfx_linux .Sh DESCRIPTION This driver creates an entry in .Pa /dev @@ -51,11 +50,9 @@ It also does not yet handle the SLI feature of the Voodoo II boards. You can only use each of them separately. .Pp -The following kernel configuration options are available: -.Pp -.Cd options LINUX_TDFX -.Pp -Enable the linux ioctl code for this driver, where the only supported +By including +.Nm tdfx_linux , +you can enable the linux ioctl code for this driver, where the only supported applications currently reside. .Sh FILES .Bl -tag -width /dev/voodoo* -compact Index: src/share/man/man4/textdump.4 diff -u /dev/null src/share/man/man4/textdump.4:1.3 --- /dev/null Thu Jan 17 11:57:41 2008 +++ src/share/man/man4/textdump.4 Tue Jan 8 00:47:30 2008 @@ -0,0 +1,162 @@ +.\" +.\" Copyright (c) 2007 Robert N. M. Watson +.\" 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(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), 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 COPYRIGHT HOLDER(S) ``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 COPYRIGHT HOLDER(S) 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$ +.\" +.Dd December 26, 2007 +.Dt textdump 4 +.Os +.Sh NAME +.Nm textdump +.Nd textdump kernel dumping facility +.Sh SYNOPSIS +.Cd options KDB +.Cd options DDB +.Sh DESCRIPTION +The +.Nm +facility allows the capture of kernel debugging information to disk in a +human-readable rather than the machine-readable form normally used with +kernel memory dumps and minidumps. +This representation, while less complete in that it does not capture full +kernel state, can provide debugging information in a more compact, portable, +and persistent form than a traditional dump. +By combining +.Nm +with other +.Xr DDB 4 +facilities, such as scripting and output capture, detailed bug information +can be captured in a fully automated manner. +.Sh FORMAT +.Nm +data is stored in a dump partition in the same style as a regular memory +dump, and will be automatically extracted by +.Xr savecore 8 +if present on boot. +.Pp +.Nm +files are stored in the +.Xr tar 5 +format, and consist of one or more text files, each storing a particular type +of debugging output. +The following parts may be present: +.Bl -tag -width version.txt +.It Pa ddb.txt +Captured +.Xr DDB 4 +output, if the capture facility has been used. +May be disabled by clearing the +.Dv debug.ddb.textdump.do_ddb +sysctl. +.It Pa config.txt +Kernel configuration, if +.Od options INCLUDE_CONFIG_FILE +has been compiled into the kernel. +May be disabled by clearing the +.Dv debug.ddb.textdump.do_config +sysctl. +.It Pa msgbuf.txt +Kernel message buffer, including recent console output if the capture +facility has been used. +May be disabled by clearing the +.Dv debug.ddb.textdump.do_msgbuf +sysctl. +.It Pa panic.txt +Kernel panic string, if the kernel panicked before the dump was generated. +May be disabled by clearing the +.Dv debug.ddb.textdump.do_panic +sysctl. +.It Pa version.txt +Kernel version string. +My be disabled by clearing the +.Dv debug.ddb.textdump.do_version +sysctl. +.El +.Pp +Kernel textdumps may be extracted using +.Xr bsdtar 1 . +.Sh CONFIGURATION +The +.Nm +facility is enabled as part of the kernel debugger using +.Cd options KDB +and +.Cd options DDB . +By default, kernel dumps generated on panic or via explicit requests for a +dump will be regular memory dumps; however, by using the +.Ic textdump set +command in +.Xr DDB 4 , +or by setting the +.Dv debug.ddb.textdump.pending +sysctl to 1 using +.Xr sysctl 8 , +it is possible to request that the next dump be a textdump. +.Pp +If at the +.Xr DDB 4 +command line, the commands +.Ic textdump set , +.Ic textdump status , +and +.Ic textdump unset +may be used to set, query, and clear the textdump pending flag. +.Pp +As with regular kernel dumps, a dump partition must be automatically or +manually configured using +.Xr dumpon 8 . +.Sh EXAMPLES +In the following example, the script +.Dv kdb.enter.panic +will run when the kernel debugger is entered as a result of a panic, enable +output capture, dump several useful pieces of debugging information, and then +invoke panic in order to force a kernel dump to be written out followed by a +reboot: +.Bd -literal -offset indent +script kdb.enter.panic=textdump set; capture on; show allpcpu; bt; + ps; alltrace; show alllock; call doadump; reset +.Ed +.Pp +In the following example, the script +.Dv kdb.enter.witness +will run when the kernel debugger is entered as a result of a witness +violation, printing lock-related information for the user: +.Bd -literal -offset indent +script kdb.enter.witness=show locks +.Ed +.Sh SEE ALSO +.Xr bsdtar 1 , +.Xr ddb 4 , +.Xr tar 5 , +.Xr dumpon 8 , +.Xr savecore 8 , +.Xr sysctl 8 +.Sh AUTHORS +The +.Nm +facility was created by +.An Robert N. M. Watson . Index: src/share/man/man4/txp.4 diff -u src/share/man/man4/txp.4:1.8.2.2 src/share/man/man4/txp.4:1.13 --- src/share/man/man4/txp.4:1.8.2.2 Thu Feb 2 15:50:01 2006 +++ src/share/man/man4/txp.4 Fri Nov 18 18:52:22 2005 @@ -76,10 +76,6 @@ segmentation, nor .Xr ipsec 4 acceleration. -Note that hardware checksumming is only used when the interface is not -in -.Xr bridge 4 -mode. .Pp Each of the host's network addresses is specified at boot time with an Index: src/share/man/man4/uark.4 diff -u src/share/man/man4/uark.4:1.2.2.2 src/share/man/man4/uark.4:1.3 --- src/share/man/man4/uark.4:1.2.2.2 Fri Feb 16 01:27:19 2007 +++ src/share/man/man4/uark.4 Sat Feb 10 04:53:19 2007 @@ -16,23 +16,35 @@ .\" .\" $FreeBSD$ .\" -.Dd November 9, 2006 +.Dd November 15, 2006 .Dt UARK 4 .Os .Sh NAME .Nm uark .Nd Arkmicro Technologies ARK3116 based USB serial adapter .Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent .Cd "device uark" .Cd "device ucom" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +uark_load="YES" +.Ed .Sh DESCRIPTION The .Nm driver supports Arkmicro Technologies ARK3116 based serial adapters. -.Pp -The following devices should work with the +.Sh HARDWARE +The .Nm -driver: +driver supports the following adapters: .Pp .Bl -bullet -compact .It @@ -53,6 +65,10 @@ .Nm device driver first appeared in .Ox 4.0 . +The first +.Fx +release to include it was +.Fx 7.0 . .Sh AUTHORS .An -nosplit The Index: src/share/man/man4/uart.4 diff -u src/share/man/man4/uart.4:1.5.8.2 src/share/man/man4/uart.4:1.11 --- src/share/man/man4/uart.4:1.5.8.2 Sun Apr 2 16:24:47 2006 +++ src/share/man/man4/uart.4 Mon Sep 18 23:24:19 2006 @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd August 25, 2003 +.Dd March 29, 2006 .Dt UART 4 .Os .\" @@ -38,6 +38,9 @@ .Pp .Cd "device puc" .Cd "device uart" +.Pp +.Cd "device scc" +.Cd "device uart" .\" .Sh DESCRIPTION The @@ -51,15 +54,21 @@ The primary support for devices that contain multiple serial interfaces or that contain other functionality besides one or more serial interfaces is provided by the -.Xr puc 4 -device driver. +.Xr puc 4 , +or +.Xr scc 4 +device drivers. However, the serial interfaces of those devices that are managed by the -.Xr puc 4 -driver are controlled by the +.Xr puc 4 , +or +.Xr scc 4 +driver are each independently controlled by the .Nm driver. As such, the -.Xr puc 4 +.Xr puc 4 , +or +.Xr scc 4 driver provides umbrella functionality for the .Nm driver and hides the complexities that are inherent when elementary components @@ -112,17 +121,15 @@ .Bl -bullet -compact .It NS8250: standard hardware based on the 8250, 16450, 16550, 16650, 16750 or -the 16950 UARTs -.It -SAB82532: Siemens SAB 82532 based serial communications controllers in -asynchronuous mode. +the 16950 UARTs. .It -Z8530: Zilog 8530 based serial communications controllers in asynchronuous -mode. +SCC: serial communications controllers supported by the +.Xr scc 4 +device driver. .El .\" .Sh FILES -.Bl -tag -width /dev/ttyu?.init -compact +.Bl -tag -width ".Pa /dev/ttyu?.init" -compact .It Pa /dev/ttyu? for callin ports .It Pa /dev/ttyu?.init @@ -136,7 +143,8 @@ corresponding callout initial-state and lock-state devices .El .Sh SEE ALSO -.Xr puc 4 +.Xr puc 4 , +.Xr scc 4 .\" .Sh HISTORY The @@ -144,5 +152,7 @@ device driver first appeared in .Fx 5.2 . .Sh AUTHORS -This manual page was written by +The +.Nm +device driver and this manual page were written by .An Marcel Moolenaar Aq marcel@xcllnt.net . Index: src/share/man/man4/ubtbcmfw.4 diff -u src/share/man/man4/ubtbcmfw.4:1.6.2.1 src/share/man/man4/ubtbcmfw.4:1.8 --- src/share/man/man4/ubtbcmfw.4:1.6.2.1 Sat Nov 25 20:03:55 2006 +++ src/share/man/man4/ubtbcmfw.4 Fri Dec 15 00:40:57 2006 @@ -74,7 +74,7 @@ .Xr write 2 should be used. All I/O operations on a bulk endpoint are unbuffered. -Outgoing bulk endpoint is always enpoint 2. +Outgoing bulk endpoint is always endpoint 2. .Pp The control endpoint (endpoint 0) handles the following .Xr ioctl 2 Index: src/share/man/man4/ucom.4 diff -u src/share/man/man4/ucom.4:1.6.2.2 src/share/man/man4/ucom.4:1.8 --- src/share/man/man4/ucom.4:1.6.2.2 Thu Jan 4 17:05:37 2007 +++ src/share/man/man4/ucom.4 Sat Jun 30 22:36:37 2007 @@ -75,9 +75,18 @@ .Va portno locater can be used to decide which port to use for devices that have multiple external ports. +.Sh BUGS +Prior to +.Fx 6.0 +.Nm +created +.Pa /dev/ucom? +rather than the uniform device names created today. +Old scripts must be adjusted accordingly. .Sh FILES .Bl -tag -width ".Pa /dev/cuaU?" .It Pa /dev/cuaU? +.It Pa /dev/ttyU? .El .Sh SEE ALSO .Xr tty 4 , Index: src/share/man/man4/udav.4 diff -u src/share/man/man4/udav.4:1.3.2.3 src/share/man/man4/udav.4:1.8 --- src/share/man/man4/udav.4:1.3.2.3 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/udav.4 Tue Jul 24 22:49:25 2007 @@ -43,6 +43,7 @@ place the following lines in your kernel configuration file: .Bd -ragged -offset indent +.Cd "device ehci" .Cd "device uhci" .Cd "device ohci" .Cd "device usb" @@ -64,6 +65,8 @@ .Bl -bullet -compact .It Corega FEther USB-TXC +.It +ShanTou ST268 USB NIC .El .Sh DESCRIPTION The Index: src/share/man/man4/ufoma.4 diff -u /dev/null src/share/man/man4/ufoma.4:1.6 --- /dev/null Thu Jan 17 11:57:41 2008 +++ src/share/man/man4/ufoma.4 Thu Nov 23 05:30:02 2006 @@ -0,0 +1,140 @@ +.\" Copyright (c) 2006 Takanori Watanabe. +.\" All rights reserved. +.\" +.\" This code is derived from software contributed to The NetBSD Foundation +.\" by Lennart Augustsson. +.\" +.\" 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. +.\" +.\" $FreeBSD$ +.\" +.Dd November 22, 2006 +.Dt UFOMA 4 +.Os +.Sh NAME +.Nm ufoma +.Nd USB mobile phone support +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device ufoma" +.Cd "device ucom" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +ufoma_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for USB mobile phone terminals in the subset of +the Mobile Computing Promotion Consortium USB Implementation Guideline, +which is adopted by FOMA, the NTT DoCoMo 3G system, terminal. +These are partly like CDC ACM model based modems, which are supported +by +.Xr umodem 4 , +but the +.Nm +driver recognizes a specific USB descriptor that describes its role and +interface structure, and it will negotiate its role when the device is open. +They support a regular AT command set and +the commands can either be multiplexed with the data stream +or handled through separate pipes. +In the latter case the AT +commands have to be given on a device separate from the data device. +.Pp +The device is accessed through the +.Xr ucom 4 +driver which makes it behave like a +.Xr tty 4 . +.Sh SYSCTLS +These devices often have a few interface sets and these interfaces +have their role, sometimes multiplexed. +These roles are identified with the following sysctl MIBs: +.Bl -tag -width indent +.It Va dev.ucom.%d.supportmode +The modes which are supported by the interface. +.It Va dev.ucom.%d.currentmode +Current mode of the interface. +.It Va dev.ucom.%d.openmode +Mode to transit when the device is open next. +.El +The modes are as follows: +.Bl -tag -width indent +.It Li modem +Accepts AT commands and go and pass packet communication data. +.It Li handsfree +Accepts AT commands but it does not pass data. +.It Li obex +Accepts OBEX frame which is used to exchange telephone book, etc. +.It Li vendor1 , vendor2 +Vendor specific data may be passed. +.It Li deactivated +When an interface is recognized by the system but not used, the interface +will be set to this mode. +.It Li unlinked +When an interface is not yet negotiated, the interface is in this mode. +.El +.Sh HARDWARE +Devices supported by the +.Nm +driver include: +.Pp +.Bl -bullet -compact +.It +SHARP FOMA SH902i +.It +KYOCERA PHS AH-K3001V (a.k.a Kyopon) +.It +SANYO Vodafone3G V801SA +.El +.Sh SEE ALSO +Specification can be found at: +.Pp +.Bl -item -compact +.It +.Pa http://www.nttdocomo.co.jp/corporate/technology/document/foma/index.html +.It +.Pa http://www.mcpc-jp.org/doclist.htm +.El +.Pp +.Xr tty 4 , +.Xr ucom 4 , +.Xr umodem 4 , +.Xr usb 4 +.Sh HISTORY +The +.Nm +driver +appeared in +.Fx 7.0 , +partly derived from the +.Xr umodem 4 +code. +.Sh BUGS +Interfaces with multiplexed commands and data and interfaces with +commands only are supported. Index: src/share/man/man4/uftdi.4 diff -u src/share/man/man4/uftdi.4:1.7.2.1 src/share/man/man4/uftdi.4:1.11 --- src/share/man/man4/uftdi.4:1.7.2.1 Sat Nov 25 20:03:55 2006 +++ src/share/man/man4/uftdi.4 Sat May 5 16:23:05 2007 @@ -76,11 +76,17 @@ .It B&B Electronics USB->RS422/485 adapter .It +Elexol USB MOD1 +.It HP USB-Serial adapter shipped with some HP laptops .It Inland UAS111 .It QVS USC-1000 +.It +Buffalo PC-OP-RS / Kurouto-shikou KURO-RS universal remote +.It +Prologix GPIB-USB Controller .El .Sh SEE ALSO .Xr tty 4 , Index: src/share/man/man4/uhid.4 diff -u src/share/man/man4/uhid.4:1.4.8.3 src/share/man/man4/uhid.4:1.8 --- src/share/man/man4/uhid.4:1.4.8.3 Sat Nov 25 20:03:55 2006 +++ src/share/man/man4/uhid.4 Sat Jun 30 13:07:51 2007 @@ -77,8 +77,8 @@ without any processing. .Bd -literal struct usb_ctl_report_desc { - int size; - u_char data[1024]; /* filled data size will vary */ + int ucrd_size; + u_char ucrd_data[1024]; /* filled data size will vary */ }; .Ed .It Dv USB_SET_IMMED Pq Vt int @@ -106,8 +106,8 @@ This call may fail if the device does not support this feature. .Bd -literal struct usb_ctl_report { - int report; - u_char data[1024]; /* used data size will vary */ + int ucr_report; + u_char ucr_data[1024]; /* used data size will vary */ }; .Ed .It Dv USB_SET_REPORT Pq Vt "struct usb_ctl_report" Index: src/share/man/man4/umass.4 diff -u src/share/man/man4/umass.4:1.40.2.3 src/share/man/man4/umass.4:1.44 --- src/share/man/man4/umass.4:1.40.2.3 Sat Nov 25 20:03:55 2006 +++ src/share/man/man4/umass.4 Thu Nov 23 05:30:02 2006 @@ -147,7 +147,7 @@ .It Panasonic floppy drive .It -Qware BeatZkey! Pro +Qware BeatZkey!\& Pro .It RATOC Systems USB2.0 Removable HDD Case U2-MDK1, U2-MDK1B .It Index: src/share/man/man4/umodem.4 diff -u src/share/man/man4/umodem.4:1.5.2.3 src/share/man/man4/umodem.4:1.10 --- src/share/man/man4/umodem.4:1.5.2.3 Sat Nov 25 20:03:55 2006 +++ src/share/man/man4/umodem.4 Tue Aug 21 21:20:13 2007 @@ -85,6 +85,10 @@ .It Curitel PC5740 Wireless Modem .It +Kyocera AH-K3001V Mobile Phone(WILLCOM) +.It +Kyocera WX320K Mobile Phone(WILLCOM) +.It Metricom Ricochet GS USB wireless modem .It Sierra MC5720 Wireless Modem Index: src/share/man/man4/uplcom.4 diff -u src/share/man/man4/uplcom.4:1.11.2.2 src/share/man/man4/uplcom.4:1.16 --- src/share/man/man4/uplcom.4:1.11.2.2 Sat Nov 25 20:03:55 2006 +++ src/share/man/man4/uplcom.4 Thu Nov 23 05:30:02 2006 @@ -86,6 +86,8 @@ .It Hama USB RS-232 Serial Adapter .It +Hamlet exagerate XURS232 +.It IOGEAR UC-232A .It I/O DATA USB-RSAQ @@ -98,11 +100,15 @@ .It RATOC REX-USB60 .It +Radio Shack USB Serial Cable +.It Sandberg USB to Serial Link (model number 133-08) .It SOURCENEXT KeikaiDenwa 8 (with and without charger) .It Sony Ericsson USB Cable (Susteen USB Data Cable) +.It +Willcom W-SIM DD PHS terminal.(WS002IN) .El .Sh SEE ALSO .Xr tty 4 , Index: src/share/man/man4/ural.4 diff -u src/share/man/man4/ural.4:1.3.2.7 src/share/man/man4/ural.4:1.15 --- src/share/man/man4/ural.4:1.3.2.7 Fri Sep 14 00:06:30 2007 +++ src/share/man/man4/ural.4 Tue Sep 11 01:54:14 2007 @@ -1,4 +1,4 @@ -.\" Copyright (c) 2005 +.\" Copyright (c) 2005, 2006 .\" Damien Bergamini .\" .\" Permission to use, copy, modify, and distribute this software for any @@ -32,6 +32,7 @@ .Cd "device usb" .Cd "device ural" .Cd "device wlan" +.Cd "device wlan_amrr" .Ed .Pp Alternatively, to load the driver as a @@ -103,13 +104,13 @@ Join a specific BSS network with 40-bit WEP encryption: .Bd -literal -offset indent ifconfig ural0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e - wepmode on wepkey 0x1234567890 + wepmode on wepkey 0x1234567890 weptxkey 1 .Ed .Pp Join a specific BSS network with 104-bit WEP encryption: .Bd -literal -offset indent ifconfig ural0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e - wepmode on wepkey 0x01020304050607080910111213 + wepmode on wepkey 0x01020304050607080910111213 weptxkey 1 .Ed .Sh DIAGNOSTICS .Bl -diag @@ -123,6 +124,7 @@ .Xr netintro 4 , .Xr usb 4 , .Xr wlan 4 , +.Xr wlan_amrr 4 , .Xr ifconfig 8 .Rs .%T "Ralink Technology" @@ -137,7 +139,8 @@ .Pp The .Nm -driver does not support automatic adaptation of the transmit speed. +driver does not support automatic adaptation of the transmit speed in IBSS +and HostAP operating modes. .Sh AUTHORS The .Nm Index: src/share/man/man4/usb.4 diff -u src/share/man/man4/usb.4:1.32.2.1 src/share/man/man4/usb.4:1.36 --- src/share/man/man4/usb.4:1.32.2.1 Sat Nov 25 20:03:55 2006 +++ src/share/man/man4/usb.4 Tue Jul 24 22:51:21 2007 @@ -318,7 +318,7 @@ events are reported via the .Pa /dev/usb device. -This devices can be opened for reading and each +This device can be opened for reading and each .Xr read 2 will yield an event record (if something has happened). The @@ -404,12 +404,15 @@ .D1 Pa http://www.usb.org/developers/docs/ .Pp .Xr aue 4 , +.Xr axe 4 , .Xr cue 4 , .Xr ehci 4 , .Xr kue 4 , .Xr ohci 4 , .Xr pci 4 , +.Xr rue 4 , .Xr ucom 4 , +.Xr udav 4 , .Xr ugen 4 , .Xr uhci 4 , .Xr uhid 4 , @@ -421,7 +424,6 @@ .Xr urio 4 , .Xr uscanner 4 , .Xr uvscom 4 , -.Xr usbd 8 , .Xr usbdevs 8 .Sh HISTORY The Index: src/share/man/man4/uscanner.4 diff -u src/share/man/man4/uscanner.4:1.18.2.7 src/share/man/man4/uscanner.4:1.31 --- src/share/man/man4/uscanner.4:1.18.2.7 Sun Nov 4 11:54:16 2007 +++ src/share/man/man4/uscanner.4 Fri Oct 5 23:17:14 2007 @@ -146,42 +146,6 @@ .It Visioneer OneTouch: 3000, 5300, 7600, 6100, 6200, 8100, 8600; .El -.Sh EXAMPLES -To use a scanner supported by SANE, you must install the two ports -.Xr graphics/sane-backends -and -.Xr graphics/sane-frontends . -Then you must tell the appropriate backend where the scanner is. -As an example, for a scanner using the Epson backend, you must add -the following line to the file -.Xr /usr/local/etc/sane.d/epson.conf : -.Bd -literal -offset indent -usb /dev/uscanner0 -.Ed -.Pp -Also, in order to set permissions correctly when the device is connected, -you can put a section like this in the file -.Xr /etc/usbd.conf : -.Bd -literal -offset indent -device "usb scanner for sane" - devname "uscanner[0-9]+" - attach "/usr/sbin/chown yourname:wheel /dev/${DEVNAME}" -.Ed -.Pp -After this, you should be able to access the scanner with -.Xr xscanimage . -.Pp -More programs of interest are -.Xr graphics/unpaper , -a filter to clean up scanned images, and -.Xr graphics/ImageMagick , -a set of image manipulation tools, and -.Xr graphics/tesseract , -a command line OCR program. -.Sh FILES -.Bl -tag -compact -width /dev/uscannerX -.It Pa /dev/uscanner Ns Sy N -the scanner device .Sh SEE ALSO .Xr ohci 4 , .Xr uhci 4 , Index: src/share/man/man4/vga.4 diff -u src/share/man/man4/vga.4:1.21 src/share/man/man4/vga.4:1.22 --- src/share/man/man4/vga.4:1.21 Sun Jul 4 02:29:20 2004 +++ src/share/man/man4/vga.4 Tue Feb 14 05:34:18 2006 @@ -154,7 +154,6 @@ module as desired: .Pp .Dl kldload vesa -.Pp .\".Sh DIAGNOSTICS .\".Sh CAVEATS .\".Sh BUGS Index: src/share/man/man4/vkbd.4 diff -u src/share/man/man4/vkbd.4:1.5.2.1 src/share/man/man4/vkbd.4:1.7 --- src/share/man/man4/vkbd.4:1.5.2.1 Sat Jul 30 17:34:57 2005 +++ src/share/man/man4/vkbd.4 Wed May 17 17:33:06 2006 @@ -128,7 +128,6 @@ .Sh SEE ALSO .Xr kbdcontrol 1 , .Xr atkbdc 4 , -.Xr pcvt 4 , .Xr psm 4 , .Xr syscons 4 .Sh CAVEATS Index: src/share/man/man4/vlan.4 diff -u src/share/man/man4/vlan.4:1.23.2.9 src/share/man/man4/vlan.4:1.44 --- src/share/man/man4/vlan.4:1.23.2.9 Wed May 2 18:26:32 2007 +++ src/share/man/man4/vlan.4 Wed May 9 17:02:11 2007 @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 24, 2007 +.Dd May 7, 2007 .Dt VLAN 4 .Os .Sh NAME @@ -122,7 +122,9 @@ .Pp By now, the list of physical interfaces able of full VLAN processing in the hardware is limited to the following devices: +.Xr bce 4 , .Xr bge 4 , +.Xr cxgb 4 , .Xr em 4 , .Xr ixgb 4 , .Xr msk 4 , @@ -156,15 +158,20 @@ natively: .Xr bfe 4 , .Xr dc 4 , +.Xr fwe 4 , .Xr fxp 4 , .Xr gem 4 , .Xr hme 4 , .Xr le 4 , +.Xr nfe 4 , +.Xr nve 4 , .Xr rl 4 , .Xr sis 4 , .Xr sk 4 , .Xr ste 4 , +.Xr tl 4 , .Xr tx 4 , +.Xr vr 4 , and .Xr xl 4 . .Pp Index: src/share/man/man4/wi.4 diff -u src/share/man/man4/wi.4:1.64.2.4 src/share/man/man4/wi.4:1.73 --- src/share/man/man4/wi.4:1.64.2.4 Fri Feb 16 21:55:24 2007 +++ src/share/man/man4/wi.4 Wed Jul 11 12:17:02 2007 @@ -202,9 +202,9 @@ Intel PRO/Wireless 2011 Spectrum24 PCMCIA Intersil Prism II Prism-II PCMCIA Intersil Mini-PCI Prism-2.5 PCI -Intersil ISL37100P Prism-3 PCMCIA -Intersil ISL37110P Prism-3 PCMCIA -Intersil ISL37300P Prism-3 PCMCIA +Intersil ISL37100P Prism-3 PCMCIA +Intersil ISL37110P Prism-3 PCMCIA +Intersil ISL37300P Prism-3 PCMCIA Laneed Wireless PCMCIA Linksys Instant Wireless WPC11 Prism-II PCMCIA Linksys Instant Wireless WPC11 2.5 Prism-2.5 PCMCIA @@ -234,6 +234,7 @@ Samsung MagicLAN SWL-2000N Prism-II PCMCIA SENAO SL-2511CD Prism-3 PCMCIA Siemens SpeedStream SS1021 Prism-II PCMCIA +SMC 2532W-B Prism-II PCMCIA SMC 2602 EZ Connect (3.3V) Prism-II PCI or PCMCIA SMC 2632 EZ Connect Prism-II PCMCIA Socket Low Power WLAN-CF Prism-II CF @@ -357,7 +358,6 @@ .Xr pcic 4 , .Xr wlan 4 , .Xr ifconfig 8 , -.Xr wicontrol 8 .Rs .%T HCF Light programming specification .%O http://www.wavelan.com @@ -380,10 +380,6 @@ See .Xr ifconfig 8 for information on how to change the channel. -See -.Xr wicontrol 8 -for information on different regulatory domains. -.Pp The Intersil Prism family of chips' host-based access point mode has bugs for station firmware versions prior to 0.8.3. The driver currently precludes hostap functionality with older station Index: src/share/man/man4/wlan.4 diff -u src/share/man/man4/wlan.4:1.8.2.1 src/share/man/man4/wlan.4:1.14 --- src/share/man/man4/wlan.4:1.8.2.1 Sat Dec 3 00:45:03 2005 +++ src/share/man/man4/wlan.4 Wed Nov 14 00:42:22 2007 @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 26, 2005 +.Dd September 6, 2007 .Dt WLAN 4 .Os .Sh NAME @@ -48,9 +48,12 @@ .Xr ipw 4 , .Xr iwi 4 , .Xr ral 4 , +.Xr rum 4 , .Xr ural 4 , +.Xr wi 4 , +.Xr wpi 4 , and -.Xr wi 4 +.Xr zyd 4 drivers, with other drivers to follow. .Pp The @@ -125,13 +128,16 @@ .Xr iwi 4 , .Xr netintro 4 , .Xr ral 4 , +.Xr rum 4 , .Xr ural 4 , .Xr wi 4 , .Xr wlan_acl 4 , .Xr wlan_ccmp 4 , .Xr wlan_tkip 4 , .Xr wlan_wep 4 , -.Xr wlan_xauth 4 +.Xr wlan_xauth 4 , +.Xr wpi 4 , +.Xr zyd 4 .Sh STANDARDS More information can be found in the IEEE 802.11 Standard. .Sh HISTORY Index: src/share/man/man4/wlan_amrr.4 diff -u /dev/null src/share/man/man4/wlan_amrr.4:1.2 --- /dev/null Thu Jan 17 11:57:41 2008 +++ src/share/man/man4/wlan_amrr.4 Tue Sep 11 02:17:50 2007 @@ -0,0 +1,59 @@ +.\" +.\" Copyright (c) 2007 Kevin Lo +.\" 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$ +.\" +.Dd September 10, 2007 +.Dt WLAN_AMRR 4 +.Os +.Sh NAME +.Nm wlan_amrr +.Nd AMRR rate adaptation algorithm support for 802.11 devices +.Sh SYNOPSIS +.Cd "device wlan_amrr" +.Sh DESCRIPTION +The +.Nm +module implements the Adaptive Multi-Rate Retry tx rate control +algorithm for use with 802.11 devices. +The +.Nm +module is an 802.11 tx rate control module for use by the +device-independent implementation. +.Sh SEE ALSO +.Xr rum 4 , +.Xr ural 4 , +.Xr wlan 4 , +.Xr zyd 4 +.Sh STANDARDS +More information can be found in the paper describing the +.Em AMRR +algorithm at +.Pa http://hal.inria.fr/inria-00070784/en/ . +.Sh HISTORY +The +.Nm +driver first appeared in +.Fx 6.0 . Index: src/share/man/man4/worm.4 diff -u src/share/man/man4/worm.4:1.29 src/share/man/man4/worm.4:removed --- src/share/man/man4/worm.4:1.29 Mon Feb 14 06:25:17 2005 +++ src/share/man/man4/worm.4 Thu Jan 17 11:57:41 2008 @@ -1,110 +0,0 @@ -.\" -.\" Copyright (C) 1996 -.\" interface business GmbH -.\" Tolkewitzer Strasse 49 -.\" D-01277 Dresden -.\" F.R. Germany -.\" -.\" All rights reserved. -.\" -.\" Written by Joerg Wunsch -.\" -.\" -.\" 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(S) ``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(S) 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$ -.\" " -.Dd October 15, 1998 -.Dt WORM 4 -.Os -.Sh NAME -.Nm worm -.Nd write-once (CD-R) disk driver -.Sh SYNOPSIS -None. -.Sh DESCRIPTION -The -.Nm -driver was provided under -.Fx -releases prior to -.Fx 3.0 . -.Pp -The -.Fx -.Tn SCSI -layer was replaced for -.Fx 3.0 -by a CAM-compliant -.Tn SCSI -layer. -The new -.Tn SCSI -layer does not include a -.Nm -driver, and is not likely to include one in the future. -Future in-kernel -support for CD-R/CD-RW/DVD drives will likely be implemented through the -.Xr cd 4 -driver. -Users who wish to write CDs on a WORM, CD-R, or CD-RW drive should use -.Nm cdrtools , -which is in the -.Fx -ports collection. -.Pp -The -.Xr cd 4 -driver provides read-only access to CD, CD-R, and CD-RW drives, as well as -WORM drives that support the CDROM command set. -Therefore, users wishing to mount CDs in a WORM drive should use the -.Xr cd 4 -driver instead. -.Sh SEE ALSO -.Xr close 2 , -.Xr ioctl 2 , -.Xr open 2 , -.Xr write 2 , -.Xr cd 4 , -.Xr pass 4 , -.Xr xpt 4 -.Sh HISTORY -The -.Nm -driver appeared in -.Fx 2.1 , -and disappeared in -.Fx 3.0 -with the advent of the CAM -.Tn SCSI -layer. -.Sh AUTHORS -.An -nosplit -The first skeleton for a -.Nm -driver has been written by -.An Peter Dufault -in May, 1995. -The driver has then been improved and made actually usable at all by -.An J\(:org Wunsch -in January, 1996. Index: src/share/man/man4/wpi.4 diff -u /dev/null src/share/man/man4/wpi.4:1.3 --- /dev/null Thu Jan 17 11:57:41 2008 +++ src/share/man/man4/wpi.4 Wed Nov 14 20:51:02 2007 @@ -0,0 +1,151 @@ +.\" Copyright (c) 2004-2007 +.\" Damien Bergamini . All rights reserved. +.\" Benjamin Close . 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 unmodified, 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$ +.\" +.Dd March 6, 2007 +.Os +.Dt WPI 4 +.Sh NAME +.Nm wpi +.Nd "Intel 3945ABG Wireless LAN IEEE 802.11 driver" +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device wpi" +.Cd "device pci" +.Cd "device wlan" +.Cd "device wlan_amrr" +.Cd "device firmware" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following lines in +.Xr loader.conf 5 : +.Bd -literal -offset indent +if_wpi_load="YES" +wlan_load="YES" +wlan_amrr_load="YES" +firmware_load="YES" +.Ed +.Pp +In both cases, place the following line in +.Xr loader.conf 5 +to load the firmware modules: +.Bd -literal -offset indent +wpifw_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver is an experimental driver providing support for the +.Tn Intel +3945ABG Wireless network adapter +.Pp +By default, the +.Nm +driver configures the adapter for BSS operation (aka infrastructure mode). +This mode requires the use of an access point. +.Pp +For more information on configuring this device, see +.Xr ifconfig 8 . +.Pp +This driver requires firmware to be loaded before it will work. +For the loaded firmware to work the license at +.Pa /usr/share/doc/legal/intel_wpi/LICENSE +must be agreed to and the following line be added to +.Xr loader.conf 5 : +.Pp +.Dl "legal.intel_wpi.license_ack=1" +.Sh FILES +.Bl -tag -width ".Pa /usr/share/doc/legal/intel_wpi/LICENSE" -compact +.It Pa /usr/share/doc/legal/intel_wpi/LICENSE +.Nm +firmware license +.El +.Sh EXAMPLES +Join an existing BSS network (i.e., connect to an access point): +.Pp +.Dl "ifconfig wpi0 inet 192.168.0.20 netmask 0xffffff00" +.Pp +Join a specific BSS network with network name +.Dq Li my_net : +.Pp +.Dl "ifconfig wpi0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net" +.Pp +Join a specific BSS network with 40-bit WEP encryption: +.Bd -literal -offset indent +ifconfig wpi0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e + wepmode on wepkey 0x1234567890 weptxkey 1 +.Ed +.Pp +Join a specific BSS network with 104-bit WEP encryption: +.Bd -literal -offset indent +ifconfig wpi0 inet 192.168.0.20 netmask 0xffffff00 ssid my_net \e + wepmode on wepkey 0x01020304050607080910111213 weptxkey 1 +.Ed +.Sh DIAGNOSTICS +.Bl -diag +.Xr firmware 9 +subsystem. +Verify that the necessary firmware modules are loaded and the +license agreement +.Xr loader 8 +tunable has been set. +.It "wpi%d: could not load firmware" +An attempt to upload the firmware image to the onboard microcontroller failed. +This should not happen. +.It "wpi%d: fatal firmware error" +An unknown error has occurred in the uploaded firmware, you may have to +unload/reload the driver to continue. +.It "wpi%d: Radio transmitter is switched off" +The hardware switch controlling the radio is currently turned off. +Data transmission is not possible in this state. +.Sh BUGS +Not all the error messages are documented here. +.Pp +Automatic recovery of firmware failures is not currently supported, nor is +detection of toggling the radio switch on. +.Pp +Background scanning is not currently supported. +.El +.Sh SEE ALSO +.Xr altq 4 , +.Xr ipw 4 , +.Xr iwi 4 , +.Xr pci 4 , +.Xr wlan 4 , +.Xr ifconfig 8 +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Damien Bergamini Aq damien.bergamini@free.fr +and +.An Benjamin Close Aq benjsc@FreeBSD.org . Index: src/share/man/man4/zyd.4 diff -u /dev/null src/share/man/man4/zyd.4:1.3 --- /dev/null Thu Jan 17 11:57:41 2008 +++ src/share/man/man4/zyd.4 Fri Sep 7 04:13:27 2007 @@ -0,0 +1,205 @@ +.\" $OpenBSD: zyd.4,v 1.22 2007/05/24 02:49:57 cnst Exp $ +.\" $NetBSD: zyd.4,v 1.1 2007/06/09 11:20:55 kiyohara Exp $ +.\" $FreeBSD$ +.\" +.\" Copyright (c) 1997, 1998, 1999 +.\" Bill Paul . 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 Bill Paul. +.\" 4. Neither the name of the author nor the names of any co-contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY Bill Paul 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 Bill Paul OR THE VOICES IN HIS HEAD +.\" 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 September 6, 2007 +.Dt ZYD 4 +.Os +.Sh NAME +.Nm zyd +.Nd ZyDAS ZD1211/ZD1211B USB IEEE 802.11b/g wireless network device +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following lines in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device ehci" +.Cd "device uhci" +.Cd "device ohci" +.Cd "device usb" +.Cd "device zyd" +.Cd "device wlan" +.Cd "device wlan_amrr" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +if_zyd_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for wireless network adapters based around +the ZyDAS ZD1211 and ZD1211B USB chips. +.Pp +These are the modes the +.Nm +driver can operate in: +.Bl -tag -width "IBSS-masterXX" +.It BSS mode +Also known as +.Em infrastructure +mode, this is used when associating with an access point, through +which all traffic passes. +This mode is the default. +.It monitor mode +In this mode the driver is able to receive packets without +associating with an access point. +This disables the internal receive filter and enables the card to +capture packets from networks which it wouldn't normally have access to, +or to scan for access points. +.El +.Pp +.Nm +supports software WEP. +Wired Equivalent Privacy (WEP) is the de facto encryption standard +for wireless networks. +It can be typically configured in one of three modes: +no encryption; 40-bit encryption; or 104-bit encryption. +Unfortunately, due to serious weaknesses in WEP protocol +it is strongly recommended that it not be used as the +sole mechanism to secure wireless communication. +WEP is not enabled by default. +.Sh HARDWARE +The following devices are known to be supported by the +.Nm +driver: +.Pp +.Bl -tag -width Ds -offset indent -compact +.It 3COM 3CRUSB10075 +.It Acer WLAN-G-US1 +.It Airlink+ AWLL3025 +.It Airlink 101 AWLL3026 +.It AOpen 802.11g WL54 +.It Asus A9T integrated wirless +.It Asus WL-159g +.It Belkin F5D7050 v.4000 +.It Billion BiPAC 3011G +.It Buffalo WLI-U2-KG54L +.It CC&C WL-2203B +.It DrayTek Vigor 550 +.It Edimax EW-7317UG +.It Edimax EW-7317LDG +.It Fiberline Networks WL-43OU +.It iNexQ UR055g +.It Linksys WUSBF54G +.It Longshine LCS-8131G3 +.It MSI US54SE +.It Philips SNU5600 +.It Planet WL-U356 +.It Planex GW-US54GZ +.It Planex GW-US54GZL +.It Planex GW-US54Mini +.It Safecom SWMULZ-5400 +.It Sagem XG 760A +.It Sagem XG 76NA +.It Sandberg Wireless G54 USB +.It Sitecom WL-113 +.It SMC SMCWUSB-G +.It Sweex wireless USB 54 Mbps +.It Tekram/Siemens USB adapter +.It Telegent TG54USB +.It Trendnet TEW-424UB +.It Trendnet TEW-429UB +.It TwinMOS G240 +.It Unicorn WL-54G +.It US Robotics 5423 +.It X-Micro XWL-11GUZX +.It Yakumo QuickWLAN USB +.It Zonet ZEW2501 +.It ZyXEL ZyAIR G-220 +.El +.Sh EXAMPLES +The following +examples configures zyd0 to join whatever network is available on boot, +using WEP key +.Dq 0x1deadbeef1 , +channel 11: +.Bd -literal -offset indent +inet 192.168.1.1 netmask 255.255.255.0 wepkey 0x1deadbeef1 channel 11 +.Ed +.Pp +Configure zyd0 for WEP, using hex key +.Dq 0x1deadbeef1 : +.Bd -literal -offset indent +# ifconfig zyd0 wepkey 0x1deadbeef1 +.Ed +.Pp +Join an existing BSS network, +.Dq my_net : +.Bd -literal -offset indent +# ifconfig zyd0 192.168.0.2 netmask 0xffffff00 ssid my_net +.Ed +.Sh DIAGNOSTICS +.Bl -diag +.It "zyd%d: could not load firmware (error=%d)" +An error occurred while attempting to upload the firmware to the onboard +microcontroller unit. +.It "zyd%d: could not send command (error=%s)" +An attempt to send a command to the firmware failed. +.It "zyd%d: sorry, radio %s is not supported yet" +Support for the specified radio chip is not yet implemented in the driver. +The device will not attach. +.It "zyd%d: device version mismatch: 0x%x (only >= 43.30 supported)" +Early revisions of the ZD1211 chipset are not supported by this driver. +The device will not attach. +.It "zyd%d: device timeout" +A frame dispatched to the hardware for transmission did not complete in time. +The driver will reset the hardware. +This should not happen. +.El +.Sh SEE ALSO +.Xr arp 4 , +.Xr intro 4 , +.Xr netintro 4 , +.Xr usb 4 , +.Xr wlan 4 , +.Xr wlan_amrr 4 , +.Xr ifconfig 8 +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Florian Stoehr Aq ich@florian-stoehr.de , +.An Damien Bergamini Aq damien@openbsd.org , +and +.An Jonathan Gray Aq jsg@openbsd.org . +.Sh CAVEATS +The +.Nm +driver does not support a lot of the functionality available in the hardware. +More work is required to properly support the IBSS and power management +features. Index: src/share/man/man4/man4.alpha/Makefile diff -u src/share/man/man4/man4.alpha/Makefile:1.4 src/share/man/man4/man4.alpha/Makefile:removed --- src/share/man/man4/man4.alpha/Makefile:1.4 Tue Mar 27 21:48:21 2001 +++ src/share/man/man4/man4.alpha/Makefile Thu Jan 17 11:57:41 2008 @@ -1,7 +0,0 @@ -# $FreeBSD$ - -MAN= linux.4 osf1.4 - -MANSUBDIR=/alpha - -.include Index: src/share/man/man4/man4.alpha/linux.4 diff -u src/share/man/man4/man4.alpha/linux.4:1.5 src/share/man/man4/man4.alpha/linux.4:removed --- src/share/man/man4/man4.alpha/linux.4:1.5 Fri Dec 13 01:25:56 2002 +++ src/share/man/man4/man4.alpha/linux.4 Thu Jan 17 11:57:41 2008 @@ -1,124 +0,0 @@ -.\" Copyright (c) 2000 Sheldon Hearn -.\" 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$ -.Dd August 17, 2000 -.Dt LINUX 4 Alpha -.Os -.Sh NAME -.Nm linux -.Nd Linux ABI support -.Sh SYNOPSIS -To link Linux ABI support into the kernel: -.Cd "options COMPAT_LINUX" -.Pp -To load the Linux ABI support kernel module: -.Dl kldload linux -.Sh DESCRIPTION -The -.Nm -module provides limited -Linux ABI (application binary interface) compatibility -for userland applications. -The module provides the following significant facilities: -.Bl -bullet -.It -An image activator -for correctly branded -.Xr elf 5 -executable images -.It -Special signal handling for activated images -.It -Linux to native system call translation -.El -.Pp -It is important to note that the Linux ABI support -it not provided through an emulator. -Rather, a true (albeit limited) ABI implementation is provided. -.Pp -The following -.Xr sysctl 8 -tunable variables are available: -.Bl -tag -width compat.linux.oss_version -.It compat.linux.osname -Linux kernel operating system name. -.It compat.linux.osrelease -Linux kernel operating system release. -.It compat.linux.oss_version -Linux Open Sound System version. -.El -.Pp -The -.Nm -module can be linked into the kernel statically with the -.Dv COMPAT_LINUX -kernel configuration option -or loaded as required. -The following command will load the module -if it is neither linked into the kernel -nor already loaded as a module: -.Bd -literal -offset indent -if ! kldstat -v | grep -E 'linux(aout|elf)' > /dev/null; then - kldload linux > /dev/null 2>&1 -fi -.Ed -.Pp -Note that dynamically linked Linux executables -will require a suitable environment in -.Pa /compat/linux . -Specifically, the Linux run-time linker's hints files -should be correctly initialized. -For this reason, it is common to execute the following commands -to prepare the system to correctly run Linux executables: -.Bd -literal -offset indent -if [ -x /compat/linux/sbin/ldconfig ]; then - /compat/linux/sbin/ldconfig -fi -.Ed -.Pp -For information on loading the -.Nm -kernel loadable module automatically on system startup, -see -.Xr rc.conf 5 . -This information applies -regardless of whether the -.Nm -module is statically linked into the kernel -or loaded as a module. -.Sh FILES -.Bl -tag -width /compat/linux/proc -compact -.It Pa /compat/linux -minimal Linux run-time environment -.It Pa /compat/linux/proc -limited Linux process file system -.El -.Sh SEE ALSO -.Xr brandelf 1 , -.Xr elf 5 , -.Xr linprocfs 5 -.Sh HISTORY -Linux ABI support first appeared in -.Fx 2.1 . Index: src/share/man/man4/man4.alpha/osf1.4 diff -u src/share/man/man4/man4.alpha/osf1.4:1.6 src/share/man/man4/man4.alpha/osf1.4:removed --- src/share/man/man4/man4.alpha/osf1.4:1.6 Fri Jan 21 16:36:38 2005 +++ src/share/man/man4/man4.alpha/osf1.4 Thu Jan 17 11:57:41 2008 @@ -1,95 +0,0 @@ -.\" Copyright (c) 2000 Sheldon Hearn -.\" 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$ -.\" -.Dd November 13, 2000 -.Dt OSF/1 4 Alpha -.Os -.Sh NAME -.Nm osf1 -.Nd OSF/1 ABI support -.Sh SYNOPSIS -To link OSF/1 ABI support into the kernel: -.Cd "options COMPAT_OSF1" -.Pp -To load the OSF/1 ABI support kernel module: -.Dl kldload osf1 -.Sh DESCRIPTION -The -.Nm -module provides limited -alpha OSF/1 (also known as Digital UNIX, later known as Tru64 UNIX) -ABI (application binary interface) -compatibility for userland applications. -The module provides the following significant facilities: -.Bl -bullet -.It -An image activator -for ecoff executable images -.It -Special signal handling for activated images -.It -OSF/1 to native system call translation -.El -.Pp -It is important to note that the OSF/1 ABI support -it not provided through an emulator. -Rather, a true (albeit limited) ABI implementation is provided. -.Pp -The -.Nm -module can be loaded as required. -The following command will load the module -if it is not already loaded as a module: -.Bd -literal -offset indent -if ! kldstat -v | grep -E osf1_ecoff > /dev/null; then - kldload osf1 > /dev/null 2>&1 -fi -.Ed -.Pp -Note that dynamically linked OSF/1 executables -will require a suitable environment in -.Pa /compat/osf1 . -.Pp -For information on loading the -.Nm -kernel loadable module automatically on system startup, -see -.Xr rc.conf 5 . -.Sh FILES -.Bl -tag -width /compat/osf1 -compact -.It Pa /compat/osf1 -minimal OSF1 run-time environment -.El -.Sh HISTORY -OSF/1 ABI support first appeared in -.Fx 4.0 . -.Sh BUGS -We cannot run OSF/1 applications which rely on the -.Xr pthread 3 -API, such as the JDK. -OSF/1's pthreads library uses Mach system calls. -Mach system calls would be very difficult to support in -.Fx . Index: src/share/man/man4/man4.i386/Makefile diff -u src/share/man/man4/man4.i386/Makefile:1.178.2.4 src/share/man/man4/man4.i386/Makefile:1.185 --- src/share/man/man4/man4.i386/Makefile:1.178.2.4 Sat Mar 11 07:27:41 2006 +++ src/share/man/man4/man4.i386/Makefile Sat Mar 31 05:19:10 2007 @@ -1,6 +1,7 @@ # $FreeBSD$ -MAN= acpi_asus.4 \ +MAN= acpi_aiboost.4 \ + acpi_asus.4 \ acpi_fujitsu.4 \ acpi_ibm.4 \ acpi_panasonic.4 \ @@ -19,7 +20,6 @@ ct.4 \ ctau.4 \ cx.4 \ - el.4 \ ep.4 \ ex.4 \ fe.4 \ @@ -27,7 +27,6 @@ ie.4 \ io.4 \ linux.4 \ - lnc.4 \ longrun.4 \ mcd.4 \ mse.4 \ Index: src/share/man/man4/man4.i386/acpi_aiboost.4 diff -u /dev/null src/share/man/man4/man4.i386/acpi_aiboost.4:1.3 --- /dev/null Thu Jan 17 11:57:41 2008 +++ src/share/man/man4/man4.i386/acpi_aiboost.4 Sat Mar 31 05:59:55 2007 @@ -0,0 +1,102 @@ +.\" $NetBSD: aiboost.4,v 1.2 2007/03/14 07:10:51 wiz Exp $ +.\" +.\" Copyright (c) 2007 Takanori Watanabe +.\" Copyright (c) 2007 Juan Romero Pardines +.\" 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 ``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. +.\" +.\" $FreeBSD$ +.\" +.Dd March 14, 2007 +.Dt ACPI_AIBOOST 4 +.O