PERFORCE change 78461 for review
Marcel Moolenaar
marcel at FreeBSD.org
Sun Jun 12 18:41:33 GMT 2005
http://perforce.freebsd.org/chv.cgi?CH=78461
Change 78461 by marcel at marcel_nfs on 2005/06/12 18:41:23
IFC @78457
Affected files ...
.. //depot/projects/tty/lib/libthr/Makefile#9 integrate
.. //depot/projects/tty/lib/libthr/libthr.3#1 branch
.. //depot/projects/tty/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#28 integrate
.. //depot/projects/tty/sys/alpha/osf1/osf1_mount.c#9 integrate
.. //depot/projects/tty/sys/compat/freebsd32/freebsd32_misc.c#10 integrate
.. //depot/projects/tty/sys/conf/files#33 integrate
.. //depot/projects/tty/sys/conf/files.alpha#16 integrate
.. //depot/projects/tty/sys/conf/files.amd64#19 integrate
.. //depot/projects/tty/sys/conf/files.i386#25 integrate
.. //depot/projects/tty/sys/conf/files.ia64#19 integrate
.. //depot/projects/tty/sys/conf/files.pc98#20 integrate
.. //depot/projects/tty/sys/conf/files.powerpc#10 integrate
.. //depot/projects/tty/sys/conf/files.sparc64#17 integrate
.. //depot/projects/tty/sys/contrib/pf/net/if_pfsync.c#7 integrate
.. //depot/projects/tty/sys/contrib/pf/net/pf_ioctl.c#6 integrate
.. //depot/projects/tty/sys/dev/fe/if_fe_cbus.c#5 integrate
.. //depot/projects/tty/sys/dev/gem/if_gem.c#9 integrate
.. //depot/projects/tty/sys/dev/snc/dp83932.c#12 integrate
.. //depot/projects/tty/sys/dev/snc/if_snc_pccard.c#6 integrate
.. //depot/projects/tty/sys/kern/uipc_accf.c#7 integrate
.. //depot/projects/tty/sys/kern/vfs_cache.c#9 integrate
.. //depot/projects/tty/sys/kern/vfs_subr.c#20 integrate
.. //depot/projects/tty/sys/kern/vfs_syscalls.c#17 integrate
.. //depot/projects/tty/sys/net/if.c#18 integrate
.. //depot/projects/tty/sys/netinet/ip_fw2.c#18 integrate
.. //depot/projects/tty/sys/netinet6/nd6_nbr.c#9 integrate
.. //depot/projects/tty/sys/powerpc/include/profile.h#5 integrate
.. //depot/projects/tty/sys/sys/syscallsubr.h#11 integrate
.. //depot/projects/tty/tools/regression/sockets/accf_data_attach/accf_data_attach.c#3 integrate
Differences ...
==== //depot/projects/tty/lib/libthr/Makefile#9 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/lib/libthr/Makefile,v 1.12 2005/04/23 02:48:58 davidxu Exp $
+# $FreeBSD: src/lib/libthr/Makefile,v 1.13 2005/06/11 15:27:56 rwatson Exp $
#
# All library objects contain FreeBSD revision strings by default; they may be
# excluded as a space-saving measure. To produce a library that does
@@ -23,6 +23,8 @@
LDFLAGS= -Wl,--version-script=${.CURDIR}/pthread.map
+MAN= libthr.3
+
# enable extra internal consistancy checks
CFLAGS+=-D_PTHREADS_INVARIANTS -Wall
CFLAGS+=-g
==== //depot/projects/tty/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#28 (text+ko) ====
@@ -3,7 +3,7 @@
<corpauthor>The &os; Project</corpauthor>
- <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.874 2005/06/08 12:57:47 hrs Exp $</pubdate>
+ <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.876 2005/06/12 08:55:59 hrs Exp $</pubdate>
<copyright>
<year>2000</year>
@@ -195,8 +195,27 @@
<ulink url="ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:09.htt.asc">FreeBSD-SA-05:09.htt</ulink>.
&merged;</para>
- <para>
+ <para>A bug in the &man.tcpdump.1; utility which allows
+ a malicious remote user to cause a denial-of-service
+ by using specially crafted packets, has been fixed.
+ For more information, see security advisory
+ <ulink url="ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:10.tcpdump.asc">FreeBSD-SA-05:10.tcpdump</ulink>.
+ &merged;</para>
+
+ <para>Two problems in the &man.gzip.1; utility have been fixed.
+ These may allow a local user to modify permissions
+ of arbitrary files and overwrite arbitrary local
+ files when uncompressing a file.
+ For more information, see security advisory
+ <ulink url="ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:11.gzip.asc">FreeBSD-SA-05:11.gzip</ulink>.
+ &merged;</para>
+ <para>A bug in <application>BIND 9</application> DNSSEC has been fixed.
+ When DNSSEC is enabled, this bug may allow a remote attacker to inject
+ a specially crafted packet which will cause &man.named.8; to terminate.
+ For more information, see security advisory
+ <ulink url="ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:12.bind9.asc">FreeBSD-SA-05:12.bind9</ulink>.
+ &merged;</para>
</sect2>
<sect2 id="kernel">
@@ -222,6 +241,43 @@
treated as an unprivileged user; if set to <literal>1</literal>, then
a jailed root user is treated the same as an unjailed <username>root</username> user. &merged;</para>
+ <para>A sysctl <varname>security.jail.getfsstatroot_only</varname> has been
+ renamed to <varname>security.jail.enforce_statfs</varname> and
+ now supports the following policies:</para>
+
+ <informaltable frame="none">
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>Value</entry>
+ <entry>Policy</entry>
+ </row>
+ </thead>
+
+ <tbody>
+ <row>
+ <entry>0</entry>
+ <entry>show all mount-points without any restrictions</entry>
+ </row>
+
+ <row>
+ <entry>1</entry>
+ <entry>show only mount-points below jail's chroot and show only part of the
+ mount-point's path (if jail's chroot directory is
+ <filename>/jails/foo</filename> and
+ mount-point is
+ <filename>/jails/foo/usr/home</filename>
+ only <filename>/usr/home</filename> will be shown)</entry>
+ </row>
+
+ <row>
+ <entry>2</entry>
+ <entry>show only mount-point where jail's chroot directory is placed.</entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable>
+
<para arch="alpha,amd64,i386,sparc64">The loader tunable <varname>debug.mpsafevm</varname>
has been enabled by default. &merged;</para>
@@ -231,6 +287,11 @@
DEBUG_MEMGUARD</literal>, plus small kernel modifications. It
is generally intended for use by kernel developers.</para>
+ <para><varname>struct ifnet</varname> and network interface API
+ have been changed. Due to ABI incompatibility, all drivers
+ not in the &os; base system need to be updated to use
+ the new API and recompiled.</para>
+
<para>A number of bugs have been fixed in the ULE
scheduler. &merged;</para>
@@ -357,6 +418,10 @@
<para arch="i386,amd64">The &man.acpi.ibm.4; driver for IBM laptops
has been added.</para>
+ <para arch="i386,amd64">The &man.acpi.ibm.4; driver has been
+ improved to support hotkeys and reading fan status and thermal
+ sensors.</para>
+
<para arch="i386,amd64">The &man.acpi.fujitsu.4; driver for handling
&man.acpi.4;-controlled buttons Fujitsu laptops has been added.</para>
@@ -364,6 +429,23 @@
which supports the Sony Notebook Controller on various
Sony laptops has been added.</para>
+ <para>The &man.atkbdc.4;, &man.atkbd.4;, and &man.psm.4;
+ drivers have been rewritten in more bus-independent way,
+ and now support EBus found on sparc64 platform.</para>
+
+ <para arch="sparc64">The following device drivers have been
+ added and enabled by default:
+ &man.atkbdc.4;,
+ &man.atkbd.4;,
+ creator(4),
+ machfb(4),
+ &man.syscons.4;,
+ &man.ohci.4;,
+ &man.psm.4;,
+ &man.ukbd.4;,
+ &man.ums.4;,
+ and &man.usb.4;.</para>
+
<para arch="sparc64">The &man.auxio.4; driver has been to drive
some auxiliary I/O functions found on various SBus/EBus
&ultrasparc; models. &merged;</para>
@@ -382,7 +464,7 @@
in the &man.acpi.4; driver. These can individually be disabled by setting device
hints such as <varname>hint.<replaceable>ichss</replaceable>.0.disabled="1"</varname>.</para>
- <para arch="amd64,i386">The &man.hwpmc.4; hardware performance
+ <para>The &man.hwpmc.4; hardware performance
monitoring counter driver has been added.
This driver virtualizes the hardware performance monitoring
facilities in modern CPUs and provides support for using
@@ -635,6 +717,9 @@
<para>A new &man.ng.netflow.4; NetGraph node allows a router
running &os; to do NetFlow version 5 exports. &merged;</para>
+ <para>A new &man.ng.tcpmss.4; NetGraph node has been added.
+ This supports altering MSS options of TCP packets.</para>
+
<para>The &man.sppp.4; driver now includes Frame Relay
support. &merged;</para>
@@ -1070,6 +1155,11 @@
it behaving as if the <option>-i</option> option is always
specified has been fixed. &merged;</para>
+ <para>The &man.rexecd.8; utility has been removed.
+ There are no rexec clients in the &os; tree, and the client
+ function &man.rexec.3; is present only in
+ <application>libcompat</application>.</para>
+
<para>The &man.rm.1; utility now supports an <option>-I</option>
option that asks for confirmation (once) if recursively
removing directories or if more than 3 files are listed in the
==== //depot/projects/tty/sys/alpha/osf1/osf1_mount.c#9 (text+ko) ====
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/alpha/osf1/osf1_mount.c,v 1.23 2005/06/09 17:44:45 pjd Exp $");
+__FBSDID("$FreeBSD: src/sys/alpha/osf1/osf1_mount.c,v 1.25 2005/06/11 14:58:20 pjd Exp $");
#include "opt_mac.h"
#include "opt_nfs.h"
@@ -168,14 +168,10 @@
if (uap->flags & OSF1_MNT_NOWAIT)
flags |= MNT_NOWAIT;
- count = uap->bufsize / sizeof(struct ostatfs);
+ count = uap->bufsize / sizeof(struct osf1_statfs);
size = count * sizeof(struct statfs);
- if (size > 0)
- buf = malloc(size, M_TEMP, M_WAITOK);
- else
- buf = NULL;
- error = kern_getfsstat(td, buf, size, UIO_SYSSPACE, flags);
- if (buf != NULL) {
+ error = kern_getfsstat(td, &buf, size, UIO_SYSSPACE, flags);
+ if (size > 0) {
count = td->td_retval[0];
sp = buf;
while (count > 0 && error == 0) {
==== //depot/projects/tty/sys/compat/freebsd32/freebsd32_misc.c#10 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/freebsd32/freebsd32_misc.c,v 1.34 2005/06/09 17:44:46 pjd Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/freebsd32/freebsd32_misc.c,v 1.35 2005/06/11 14:58:20 pjd Exp $");
#include "opt_compat.h"
@@ -163,12 +163,8 @@
count = uap->bufsize / sizeof(struct statfs32);
size = count * sizeof(struct statfs);
- if (size > 0)
- buf = malloc(size, M_TEMP, M_WAITOK);
- else
- buf = NULL;
- error = kern_getfsstat(td, buf, size, UIO_SYSSPACE, uap->flags);
- if (buf != NULL) {
+ error = kern_getfsstat(td, &buf, size, UIO_SYSSPACE, uap->flags);
+ if (size > 0) {
count = td->td_retval[0];
sp = buf;
while (count > 0 && error == 0) {
==== //depot/projects/tty/sys/conf/files#33 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/files,v 1.1025 2005/06/10 08:05:12 glebius Exp $
+# $FreeBSD: src/sys/conf/files,v 1.1026 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -291,8 +291,10 @@
crypto/blowfish/bf_skey.c optional ipsec ipsec_esp
crypto/des/des_ecb.c optional crypto
crypto/des/des_ecb.c optional ipsec ipsec_esp
+crypto/des/des_ecb.c optional netsmbcrypto
crypto/des/des_setkey.c optional crypto
crypto/des/des_setkey.c optional ipsec ipsec_esp
+crypto/des/des_setkey.c optional netsmbcrypto
crypto/rc4/rc4.c optional netgraph_mppc_encryption
crypto/rijndael/rijndael-alg-fst.c optional crypto
crypto/rijndael/rijndael-alg-fst.c optional geom_bde
==== //depot/projects/tty/sys/conf/files.alpha#16 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.alpha,v 1.119 2005/06/10 20:56:36 marius Exp $
+# $FreeBSD: src/sys/conf/files.alpha,v 1.120 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -155,10 +155,11 @@
compat/linux/linux_sysctl.c optional compat_linux
compat/linux/linux_stats.c optional compat_linux
compat/linux/linux_util.c optional compat_linux
+crypto/blowfish/bf_enc.c optional crypto
crypto/blowfish/bf_enc.c optional ipsec ipsec_esp
+crypto/des/des_enc.c optional crypto
crypto/des/des_enc.c optional ipsec ipsec_esp
-crypto/blowfish/bf_enc.c optional crypto
-crypto/des/des_enc.c optional crypto
+crypto/des/des_enc.c optional netsmbcrypto
dev/advansys/adv_isa.c optional adv isa
dev/aic/aic_isa.c optional aic isa
dev/atkbdc/atkbd.c optional atkbd atkbdc
==== //depot/projects/tty/sys/conf/files.amd64#19 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.amd64,v 1.67 2005/06/10 20:56:36 marius Exp $
+# $FreeBSD: src/sys/conf/files.amd64,v 1.68 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -120,11 +120,9 @@
amd64/pci/pci_cfgreg.c optional pci
crypto/blowfish/bf_enc.c optional crypto
crypto/blowfish/bf_enc.c optional ipsec ipsec_esp
-crypto/des/des_ecb.c optional netsmbcrypto
crypto/des/des_enc.c optional crypto
crypto/des/des_enc.c optional ipsec ipsec_esp
crypto/des/des_enc.c optional netsmbcrypto
-crypto/des/des_setkey.c optional netsmbcrypto
dev/acpica/acpi_if.m standard
dev/arcmsr/arcmsr.c optional arcmsr pci
dev/atkbdc/atkbd.c optional atkbd atkbdc
==== //depot/projects/tty/sys/conf/files.i386#25 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.i386,v 1.535 2005/06/10 20:56:36 marius Exp $
+# $FreeBSD: src/sys/conf/files.i386,v 1.536 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -122,9 +122,7 @@
compile-with "${CC} -c -I$S/crypto/blowfish/arch/i386 ${ASM_CFLAGS} ${WERROR} ${.IMPSRC}" \
no-implicit-rule
crypto/des/arch/i386/des_enc.S optional ipsec ipsec_esp
-crypto/des/des_ecb.c optional netsmbcrypto
crypto/des/arch/i386/des_enc.S optional netsmbcrypto
-crypto/des/des_setkey.c optional netsmbcrypto
bf_enc.o optional crypto \
dependency "$S/crypto/blowfish/arch/i386/bf_enc.S $S/crypto/blowfish/arch/i386/bf_enc_586.S $S/crypto/blowfish/arch/i386/bf_enc_686.S" \
compile-with "${CC} -c -I$S/crypto/blowfish/arch/i386 ${ASM_CFLAGS} ${WERROR} ${.IMPSRC}" \
==== //depot/projects/tty/sys/conf/files.ia64#19 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.ia64,v 1.78 2005/06/10 20:56:36 marius Exp $
+# $FreeBSD: src/sys/conf/files.ia64,v 1.79 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -36,6 +36,7 @@
crypto/blowfish/bf_enc.c optional ipsec ipsec_esp
crypto/des/des_enc.c optional crypto
crypto/des/des_enc.c optional ipsec ipsec_esp
+crypto/des/des_enc.c optional netsmbcrypto
dev/advansys/adv_isa.c optional adv isa
dev/aic/aic_isa.c optional aic isa
dev/atkbdc/atkbd.c optional atkbd atkbdc
==== //depot/projects/tty/sys/conf/files.pc98#20 (text+ko) ====
@@ -3,7 +3,7 @@
#
# modified for PC-9801/PC-9821
#
-# $FreeBSD: src/sys/conf/files.pc98,v 1.325 2005/06/09 19:45:07 jkoshy Exp $
+# $FreeBSD: src/sys/conf/files.pc98,v 1.326 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -83,9 +83,7 @@
compile-with "${CC} -c -I$S/crypto/blowfish/arch/i386 ${ASM_CFLAGS} ${WERROR} ${.IMPSRC}" \
no-implicit-rule
crypto/des/arch/i386/des_enc.S optional ipsec ipsec_esp
-crypto/des/des_ecb.c optional netsmbcrypto
crypto/des/arch/i386/des_enc.S optional netsmbcrypto
-crypto/des/des_setkey.c optional netsmbcrypto
bf_enc.o optional crypto \
dependency "$S/crypto/blowfish/arch/i386/bf_enc.S $S/crypto/blowfish/arch/i386/bf_enc_586.S $S/crypto/blowfish/arch/i386/bf_enc_686.S" \
compile-with "${CC} -c -I$S/crypto/blowfish/arch/i386 ${ASM_CFLAGS} ${WERROR} ${.IMPSRC}" \
==== //depot/projects/tty/sys/conf/files.powerpc#10 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.powerpc,v 1.43 2005/06/09 19:45:07 jkoshy Exp $
+# $FreeBSD: src/sys/conf/files.powerpc,v 1.44 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -52,6 +52,7 @@
crypto/blowfish/bf_enc.c optional ipsec ipsec_esp
crypto/des/des_enc.c optional ipsec ipsec_esp
+crypto/des/des_enc.c optional netsmbcrypto
dev/ofw/openfirm.c standard
dev/ofw/ofw_bus_if.m standard
==== //depot/projects/tty/sys/conf/files.sparc64#17 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.sparc64,v 1.72 2005/06/10 20:58:59 marius Exp $
+# $FreeBSD: src/sys/conf/files.sparc64,v 1.73 2005/06/12 00:47:21 marcel Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -18,10 +18,11 @@
clean "ukbdmap.h"
#
#
+crypto/blowfish/bf_enc.c optional crypto
crypto/blowfish/bf_enc.c optional ipsec ipsec_esp
+crypto/des/des_enc.c optional crypto
crypto/des/des_enc.c optional ipsec ipsec_esp
-crypto/blowfish/bf_enc.c optional crypto
-crypto/des/des_enc.c optional crypto
+crypto/des/des_enc.c optional netsmbcrypto
dev/atkbdc/atkbd.c optional atkbd atkbdc
dev/atkbdc/atkbd_atkbdc.c optional atkbd atkbdc
dev/atkbdc/atkbdc.c optional atkbdc
==== //depot/projects/tty/sys/contrib/pf/net/if_pfsync.c#7 (text+ko) ====
@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/contrib/pf/net/if_pfsync.c,v 1.17 2005/06/10 17:23:49 mlaier Exp $ */
+/* $FreeBSD: src/sys/contrib/pf/net/if_pfsync.c,v 1.18 2005/06/12 16:46:20 mlaier Exp $ */
/* $OpenBSD: if_pfsync.c,v 1.46 2005/02/20 15:58:38 mcbride Exp $ */
/*
@@ -220,15 +220,10 @@
ifp->if_baudrate = IF_Mbps(100);
ifp->if_softc = sc;
pfsync_setmtu(sc, MCLBYTES);
- /*
- * XXX
- * The 2nd arg. 0 to callout_init(9) shoule be set to CALLOUT_MPSAFE
- * if Gaint lock is removed from the network stack.
- */
- callout_init(&sc->sc_tmo, 0);
- callout_init(&sc->sc_bulk_tmo, 0);
- callout_init(&sc->sc_bulkfail_tmo, 0);
- callout_init(&sc->sc_send_tmo, 0);
+ callout_init(&sc->sc_tmo, NET_CALLOUT_MPSAFE);
+ callout_init(&sc->sc_bulk_tmo, NET_CALLOUT_MPSAFE);
+ callout_init(&sc->sc_bulkfail_tmo, NET_CALLOUT_MPSAFE);
+ callout_init(&sc->sc_send_tmo, NET_CALLOUT_MPSAFE);
mtx_init(&sc->sc_ifq.ifq_mtx, ifp->if_xname, "pfsync send queue",
MTX_DEF);
if_attach(ifp);
==== //depot/projects/tty/sys/contrib/pf/net/pf_ioctl.c#6 (text+ko) ====
@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/contrib/pf/net/pf_ioctl.c,v 1.19 2005/05/03 16:43:32 mlaier Exp $ */
+/* $FreeBSD: src/sys/contrib/pf/net/pf_ioctl.c,v 1.20 2005/06/12 16:46:20 mlaier Exp $ */
/* $OpenBSD: pf_ioctl.c,v 1.139 2005/03/03 07:13:39 dhartmei Exp $ */
/*
@@ -335,12 +335,7 @@
my_timeout[PFTM_SRC_NODE] = PFTM_SRC_NODE_VAL;
my_timeout[PFTM_TS_DIFF] = PFTM_TS_DIFF_VAL;
- /*
- * XXX
- * The 2nd arg. 0 to callout_init(9) shoule be set to CALLOUT_MPSAFE
- * if Gaint lock is removed from the network stack.
- */
- callout_init(&pf_expire_to, 0);
+ callout_init(&pf_expire_to, NET_CALLOUT_MPSAFE);
callout_reset(&pf_expire_to, my_timeout[PFTM_INTERVAL] * hz,
pf_purge_timeout, &pf_expire_to);
==== //depot/projects/tty/sys/dev/fe/if_fe_cbus.c#5 (text+ko) ====
@@ -22,7 +22,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/fe/if_fe_cbus.c,v 1.12 2005/02/20 19:33:13 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/fe/if_fe_cbus.c,v 1.13 2005/06/11 16:30:43 brooks Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -317,16 +317,16 @@
return ENXIO;
/* Get our station address from EEPROM. */
- fe_inblk(sc, 0x18, sc->sc_enaddr, ETHER_ADDR_LEN);
+ fe_inblk(sc, 0x18, sc->enaddr, ETHER_ADDR_LEN);
/* Make sure it is Allied-Telesis's. */
- if (!fe_valid_Ether_p(sc->sc_enaddr, 0x0000F4))
+ if (!fe_valid_Ether_p(sc->enaddr, 0x0000F4))
return ENXIO;
#if 1
/* Calculate checksum. */
sum = fe_inb(sc, 0x1e);
for (i = 0; i < ETHER_ADDR_LEN; i++)
- sum ^= sc->sc_enaddr[i];
+ sum ^= sc->enaddr[i];
if (sum != 0)
return ENXIO;
#endif
@@ -370,8 +370,8 @@
/* Get our station address from EEPROM, and make sure the
EEPROM contains Allied-Telesis's address. */
- bcopy(eeprom + 8, sc->sc_enaddr, ETHER_ADDR_LEN);
- if (!fe_valid_Ether_p(sc->sc_enaddr, 0x0000F4))
+ bcopy(eeprom + 8, sc->enaddr, ETHER_ADDR_LEN);
+ if (!fe_valid_Ether_p(sc->enaddr, 0x0000F4))
return NULL;
/* I don't know any sub-model identification. */
@@ -541,14 +541,14 @@
return ENXIO;
/* Get our station address from EEPROM. */
- fe_inblk(sc, 0x18, sc->sc_enaddr, ETHER_ADDR_LEN);
+ fe_inblk(sc, 0x18, sc->enaddr, ETHER_ADDR_LEN);
/* Make sure it is Contec's. */
- if (!fe_valid_Ether_p(sc->sc_enaddr, 0x00804C))
+ if (!fe_valid_Ether_p(sc->enaddr, 0x00804C))
return ENXIO;
/* Determine the card type. */
- if (sc->sc_enaddr[3] == 0x06) {
+ if (sc->enaddr[3] == 0x06) {
sc->typestr = "C-NET(9N)C";
/* We seems to need our own IDENT bits... FIXME. */
@@ -632,7 +632,7 @@
/* Make sure the Ethernet (MAC) station address is of Contec's. */
if (!fe_valid_Ether_p(eeprom + FE_SSI_EEP_ADDR, 0x00804C))
return ENXIO;
- bcopy(eeprom + FE_SSI_EEP_ADDR, sc->sc_enaddr, ETHER_ADDR_LEN);
+ bcopy(eeprom + FE_SSI_EEP_ADDR, sc->enaddr, ETHER_ADDR_LEN);
/* Setup the board type. */
sc->typestr = "C-NET(98)P2";
@@ -702,7 +702,7 @@
/* Make sure the Ethernet (MAC) station address is of TDK/LANX's. */
if (!fe_valid_Ether_p(eeprom, 0x008098))
return ENXIO;
- bcopy(eeprom, sc->sc_enaddr, ETHER_ADDR_LEN);
+ bcopy(eeprom, sc->enaddr, ETHER_ADDR_LEN);
/* Setup the board type. */
sc->typestr = "LAC-98012/98013";
@@ -767,13 +767,13 @@
return ENXIO;
/* Get our station address from EEPROM. */
- fe_inblk(sc, 0x18, sc->sc_enaddr, ETHER_ADDR_LEN);
- if (!fe_valid_Ether_p(sc->sc_enaddr, 0x000000))
+ fe_inblk(sc, 0x18, sc->enaddr, ETHER_ADDR_LEN);
+ if (!fe_valid_Ether_p(sc->enaddr, 0x000000))
return ENXIO;
/* Determine the card type. */
sc->typestr = "Generic MB86960 Ethernet";
- if (fe_valid_Ether_p(sc->sc_enaddr, 0x000061))
+ if (fe_valid_Ether_p(sc->enaddr, 0x000061))
sc->typestr = "Gateway Ethernet (Fujitsu chipset)";
/* Gateway's board requires an explicit IRQ to work, since it
@@ -833,14 +833,14 @@
sc->proto_dlcr7 | FE_D7_RBS_BMPR | FE_D7_POWER_UP);
/* Get our station address form ID ROM and make sure it is UBN's. */
- fe_inblk(sc, 0x18, sc->sc_enaddr, ETHER_ADDR_LEN);
- if (!fe_valid_Ether_p(sc->sc_enaddr, 0x00DD01))
+ fe_inblk(sc, 0x18, sc->enaddr, ETHER_ADDR_LEN);
+ if (!fe_valid_Ether_p(sc->enaddr, 0x00DD01))
goto fail_ubn;
#if 1
/* Calculate checksum. */
sum = fe_inb(sc, 0x1e);
for (i = 0; i < ETHER_ADDR_LEN; i++)
- sum ^= sc->sc_enaddr[i];
+ sum ^= sc->enaddr[i];
if (sum != 0)
goto fail_ubn;
#endif
@@ -972,11 +972,11 @@
are not yet sure we have a REX-9880 board here.) */
fe_read_eeprom_rex(sc, eeprom);
for (i = 0; i < ETHER_ADDR_LEN; i++)
- sc->sc_enaddr[i] = eeprom[7 - i];
+ sc->enaddr[i] = eeprom[7 - i];
/* Make sure it is RATOC's. */
- if (!fe_valid_Ether_p(sc->sc_enaddr, 0x00C0D0) &&
- !fe_valid_Ether_p(sc->sc_enaddr, 0x00803D))
+ if (!fe_valid_Ether_p(sc->enaddr, 0x00C0D0) &&
+ !fe_valid_Ether_p(sc->enaddr, 0x00803D))
return 0;
/* Setup the board type. */
==== //depot/projects/tty/sys/dev/gem/if_gem.c#9 (text+ko) ====
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/gem/if_gem.c,v 1.28 2005/06/10 16:49:09 brooks Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/gem/if_gem.c,v 1.29 2005/06/12 15:33:45 brooks Exp $");
/*
* Driver for Sun GEM ethernet controllers.
@@ -363,9 +363,9 @@
struct ifnet *ifp = sc->sc_ifp;
int i;
+ gem_stop(ifp, 1);
ether_ifdetach(ifp);
if_free(ifp);
- gem_stop(ifp, 1);
device_delete_child(sc->sc_dev, sc->sc_miibus);
for (i = 0; i < GEM_NRXDESC; i++) {
==== //depot/projects/tty/sys/dev/snc/dp83932.c#12 (text+ko) ====
@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/dev/snc/dp83932.c,v 1.18 2005/06/10 16:49:14 brooks Exp $ */
+/* $FreeBSD: src/sys/dev/snc/dp83932.c,v 1.19 2005/06/12 15:25:19 scottl Exp $ */
/* $NecBSD: dp83932.c,v 1.5 1999/07/29 05:08:44 kmatsuda Exp $ */
/* $NetBSD: if_snc.c,v 1.18 1998/04/25 21:27:40 scottr Exp $ */
@@ -166,7 +166,8 @@
ifp = sc->sc_ifp = if_alloc(IFT_ETHER);
if (ifp == NULL)
- panic("%s: can not if_alloc()\n", device_get_nameunit(dev));
+ panic("%s: can not if_alloc()\n",
+ device_get_nameunit(sc->sc_dev));
#ifdef SNCDEBUG
device_printf(sc->sc_dev,
==== //depot/projects/tty/sys/dev/snc/if_snc_pccard.c#6 (text+ko) ====
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/snc/if_snc_pccard.c,v 1.7 2005/01/20 20:32:56 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/snc/if_snc_pccard.c,v 1.8 2005/06/12 16:21:44 brooks Exp $");
/*
* National Semiconductor DP8393X SONIC Driver
@@ -88,7 +88,7 @@
snc_pccard_detach(device_t dev)
{
struct snc_softc *sc = device_get_softc(dev);
- struct ifnet *ifp = &sc->sc_if;
+ struct ifnet *ifp = sc->sc_ifp;
if (sc->gone) {
device_printf(dev, "already unloaded\n");
==== //depot/projects/tty/sys/kern/uipc_accf.c#7 (text+ko) ====
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/uipc_accf.c,v 1.18 2005/03/12 12:57:17 rwatson Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/uipc_accf.c,v 1.19 2005/06/11 11:59:47 maxim Exp $");
#define ACCEPT_FILTER_MOD
@@ -176,8 +176,10 @@
error = EINVAL;
goto out;
}
- if ((so->so_options & SO_ACCEPTFILTER) == 0)
+ if ((so->so_options & SO_ACCEPTFILTER) == 0) {
+ error = EINVAL;
goto out;
+ }
strcpy(afap->af_name, so->so_accf->so_accept_filter->accf_name);
if (so->so_accf->so_accept_filter_str != NULL)
strcpy(afap->af_arg, so->so_accf->so_accept_filter_str);
@@ -200,7 +202,7 @@
/*
* Handle the simple delete case first.
*/
- if (sopt == NULL) {
+ if (sopt == NULL || sopt->sopt_val == NULL) {
SOCK_LOCK(so);
if ((so->so_options & SO_ACCEPTCONN) == 0) {
SOCK_UNLOCK(so);
==== //depot/projects/tty/sys/kern/vfs_cache.c#9 (text+ko) ====
@@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/vfs_cache.c,v 1.99 2005/04/13 10:59:09 jeff Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/vfs_cache.c,v 1.100 2005/06/11 08:47:30 jeff Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -474,6 +474,9 @@
int zap;
int len;
+ VNASSERT(vp == NULL || (vp->v_iflag & VI_DOOMED) == 0, vp,
+ ("cahe_enter: Adding a doomed vnode"));
+
if (!doingcache)
return;
==== //depot/projects/tty/sys/kern/vfs_subr.c#20 (text+ko) ====
@@ -39,7 +39,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/vfs_subr.c,v 1.627 2005/06/11 01:16:46 jeff Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/vfs_subr.c,v 1.628 2005/06/11 08:48:09 jeff Exp $");
#include "opt_ddb.h"
#include "opt_mac.h"
@@ -723,6 +723,8 @@
VNASSERT(bo->bo_clean.bv_root == NULL, vp, ("cleanblkroot not NULL"));
VNASSERT(bo->bo_dirty.bv_cnt == 0, vp, ("dirtybufcnt not 0"));
VNASSERT(bo->bo_dirty.bv_root == NULL, vp, ("dirtyblkroot not NULL"));
+ VNASSERT(TAILQ_EMPTY(&vp->v_cache_dst), vp, ("vp has namecache dst"));
+ VNASSERT(LIST_EMPTY(&vp->v_cache_src), vp, ("vp has namecache src"));
#ifdef MAC
mac_destroy_vnode(vp);
#endif
==== //depot/projects/tty/sys/kern/vfs_syscalls.c#17 (text+ko) ====
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/vfs_syscalls.c,v 1.388 2005/06/09 18:49:19 pjd Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/vfs_syscalls.c,v 1.390 2005/06/12 07:03:23 pjd Exp $");
#include "opt_compat.h"
#include "opt_mac.h"
@@ -390,12 +390,17 @@
} */ *uap;
{
- return (kern_getfsstat(td, uap->buf, uap->bufsize, UIO_USERSPACE,
+ return (kern_getfsstat(td, &uap->buf, uap->bufsize, UIO_USERSPACE,
uap->flags));
}
+/*
+ * If (bufsize > 0 && bufseg == UIO_SYSSPACE)
+ * The caller is responsible for freeing memory which will be allocated
+ * in '*buf'.
+ */
int
-kern_getfsstat(struct thread *td, struct statfs *buf, size_t bufsize,
+kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize,
enum uio_seg bufseg, int flags)
{
struct mount *mp, *nmp;
@@ -404,7 +409,22 @@
int error;
maxcount = bufsize / sizeof(struct statfs);
- sfsp = buf;
+ if (bufsize == 0)
+ sfsp = NULL;
+ else if (bufseg == UIO_USERSPACE)
+ sfsp = *buf;
+ else /* if (bufseg == UIO_SYSSPACE) */ {
+ count = 0;
+ mtx_lock(&mountlist_mtx);
+ TAILQ_FOREACH(mp, &mountlist, mnt_list) {
+ count++;
+ }
+ mtx_unlock(&mountlist_mtx);
+ if (maxcount > count)
+ maxcount = count;
+ sfsp = *buf = malloc(maxcount * sizeof(struct statfs), M_TEMP,
+ M_WAITOK);
+ }
count = 0;
mtx_lock(&Giant);
mtx_lock(&mountlist_mtx);
@@ -451,15 +471,16 @@
prison_enforce_statfs(td->td_ucred, mp, &sb);
sp = &sb;
}
- if (bufseg == UIO_USERSPACE) {
+ if (bufseg == UIO_SYSSPACE)
+ bcopy(sp, sfsp, sizeof(*sp));
+ else /* if (bufseg == UIO_USERSPACE) */ {
error = copyout(sp, sfsp, sizeof(*sp));
if (error) {
vfs_unbusy(mp, td);
mtx_unlock(&Giant);
return (error);
}
- } else
- bcopy(sp, sfsp, sizeof(*sp));
+ }
sfsp++;
}
count++;
@@ -561,12 +582,8 @@
count = uap->bufsize / sizeof(struct ostatfs);
size = count * sizeof(struct statfs);
- if (size > 0)
- buf = malloc(size, M_TEMP, M_WAITOK);
- else
- buf = NULL;
- error = kern_getfsstat(td, buf, size, UIO_SYSSPACE, uap->flags);
- if (buf != NULL) {
+ error = kern_getfsstat(td, &buf, size, UIO_SYSSPACE, uap->flags);
+ if (size > 0) {
count = td->td_retval[0];
sp = buf;
while (count > 0 && error == 0) {
==== //depot/projects/tty/sys/net/if.c#18 (text+ko) ====
@@ -27,7 +27,7 @@
* SUCH DAMAGE.
*
* @(#)if.c 8.5 (Berkeley) 1/9/95
- * $FreeBSD: src/sys/net/if.c,v 1.231 2005/06/10 16:49:18 brooks Exp $
+ * $FreeBSD: src/sys/net/if.c,v 1.232 2005/06/12 00:53:03 brooks Exp $
*/
#include "opt_compat.h"
@@ -402,8 +402,10 @@
if (if_com_alloc[type] != NULL) {
ifp->if_l2com = if_com_alloc[type](type, ifp);
- if (ifp->if_l2com == NULL)
+ if (ifp->if_l2com == NULL) {
free(ifp, M_IFNET);
+ return (NULL);
+ }
}
return (ifp);
@@ -426,6 +428,12 @@
return;
}
+ ifnet_byindex(ifp->if_index) = NULL;
+
+ /* XXX: should be locked with if_findindex() */
+ while (if_index > 0 && ifaddr_byindex(if_index) == NULL)
+ if_index--;
+
if (if_com_free[type] != NULL)
if_com_free[type](ifp->if_l2com, type);
@@ -678,15 +686,10 @@
* Remove address from ifindex_table[] and maybe decrement if_index.
* Clean up all addresses.
*/
- ifnet_byindex(ifp->if_index) = NULL;
ifaddr_byindex(ifp->if_index) = NULL;
destroy_dev(ifdev_byindex(ifp->if_index));
ifdev_byindex(ifp->if_index) = NULL;
- while (if_index > 0 && ifaddr_byindex(if_index) == NULL)
- if_index--;
-
-
/* We can now free link ifaddr. */
if (!TAILQ_EMPTY(&ifp->if_addrhead)) {
ifa = TAILQ_FIRST(&ifp->if_addrhead);
==== //depot/projects/tty/sys/netinet/ip_fw2.c#18 (text+ko) ====
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/netinet/ip_fw2.c,v 1.101 2005/06/10 12:28:17 green Exp $
+ * $FreeBSD: src/sys/netinet/ip_fw2.c,v 1.102 2005/06/12 16:27:10 mlaier Exp $
*/
#define DEB(x)
@@ -2332,14 +2332,14 @@
break;
case O_IP_SRC:
- match = (hlen > 0 &&
+ match = is_ipv4 && (hlen > 0 &&
((ipfw_insn_ip *)cmd)->addr.s_addr ==
src_ip.s_addr);
break;
case O_IP_SRC_LOOKUP:
case O_IP_DST_LOOKUP:
- if (hlen > 0) {
+ if (hlen > 0 && is_ipv4) {
uint32_t a =
(cmd->opcode == O_IP_DST_LOOKUP) ?
dst_ip.s_addr : src_ip.s_addr;
@@ -2356,7 +2356,7 @@
case O_IP_SRC_MASK:
case O_IP_DST_MASK:
- if (hlen > 0) {
+ if (hlen > 0 && is_ipv4) {
uint32_t a =
(cmd->opcode == O_IP_DST_MASK) ?
dst_ip.s_addr : src_ip.s_addr;
@@ -2369,7 +2369,7 @@
break;
case O_IP_SRC_ME:
- if (hlen > 0) {
+ if (hlen > 0 && is_ipv4) {
struct ifnet *tif;
INADDR_TO_IFP(src_ip, tif);
@@ -2379,7 +2379,7 @@
case O_IP_DST_SET:
case O_IP_SRC_SET:
- if (hlen > 0) {
+ if (hlen > 0 && is_ipv4) {
u_int32_t *d = (u_int32_t *)(cmd+1);
u_int32_t addr =
cmd->opcode == O_IP_DST_SET ?
@@ -2396,13 +2396,13 @@
break;
case O_IP_DST:
- match = (hlen > 0 &&
+ match = is_ipv4 && (hlen > 0 &&
((ipfw_insn_ip *)cmd)->addr.s_addr ==
dst_ip.s_addr);
break;
case O_IP_DST_ME:
- if (hlen > 0) {
+ if (hlen > 0 && is_ipv4) {
struct ifnet *tif;
INADDR_TO_IFP(dst_ip, tif);
@@ -2605,14 +2605,16 @@
case O_VERSRCREACH:
/* Outgoing packets automatically pass/match */
+ /* XXX: IPv6 missing!?! */
match = (hlen > 0 && ((oif != NULL) ||
- verify_path(src_ip, NULL)));
+ (is_ipv4 && verify_path(src_ip, NULL))));
break;
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list