Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Apr 2005 02:13:37 GMT
From:      David Xu <davidxu@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 74707 for review
Message-ID:  <200504080213.j382Db2A001911@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=74707

Change 74707 by davidxu@davidxu_celeron on 2005/04/08 02:13:08

	IFC.

Affected files ...

.. //depot/projects/davidxu_thread/src/bin/dd/dd.1#3 integrate
.. //depot/projects/davidxu_thread/src/lib/libc/amd64/string/Makefile.inc#1 branch
.. //depot/projects/davidxu_thread/src/lib/libc/amd64/string/bcopy.S#1 branch
.. //depot/projects/davidxu_thread/src/lib/libc/amd64/string/bzero.S#1 branch
.. //depot/projects/davidxu_thread/src/lib/libc/amd64/string/memcpy.S#1 branch
.. //depot/projects/davidxu_thread/src/lib/libc/amd64/string/memmove.S#1 branch
.. //depot/projects/davidxu_thread/src/lib/libc/amd64/string/memset.S#1 branch
.. //depot/projects/davidxu_thread/src/lib/libc/i386/sys/_amd64_get_fsbase.c#2 integrate
.. //depot/projects/davidxu_thread/src/lib/libc/i386/sys/_amd64_get_gsbase.c#2 integrate
.. //depot/projects/davidxu_thread/src/lib/libthr/arch/arm/Makefile.inc#2 integrate
.. //depot/projects/davidxu_thread/src/lib/libthr/arch/arm/include/pthread_md.h#2 integrate
.. //depot/projects/davidxu_thread/src/lib/libthr/thread/thr_list.c#4 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/Makefile#8 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/man/lround.3#2 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/man/round.3#3 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/src/math.h#7 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/src/s_llround.c#2 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/src/s_llroundf.c#2 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/src/s_llroundl.c#1 branch
.. //depot/projects/davidxu_thread/src/lib/msun/src/s_lround.c#2 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/src/s_lroundf.c#2 integrate
.. //depot/projects/davidxu_thread/src/lib/msun/src/s_lroundl.c#1 branch
.. //depot/projects/davidxu_thread/src/lib/msun/src/s_roundl.c#1 branch
.. //depot/projects/davidxu_thread/src/libexec/rexecd/rexecd.c#8 integrate
.. //depot/projects/davidxu_thread/src/libexec/rtld-elf/arm/rtld_machdep.h#4 integrate
.. //depot/projects/davidxu_thread/src/sbin/geom/class/Makefile.inc#2 integrate
.. //depot/projects/davidxu_thread/src/sbin/geom/core/geom.c#6 integrate
.. //depot/projects/davidxu_thread/src/sbin/nfsiod/nfsiod.c#2 integrate
.. //depot/projects/davidxu_thread/src/share/man/man4/Makefile#12 integrate
.. //depot/projects/davidxu_thread/src/share/man/man4/atkbdc.4#2 integrate
.. //depot/projects/davidxu_thread/src/share/man/man4/carp.4#3 integrate
.. //depot/projects/davidxu_thread/src/share/man/man4/geom.4#2 integrate
.. //depot/projects/davidxu_thread/src/share/man/man4/sched_4bsd.4#1 branch
.. //depot/projects/davidxu_thread/src/share/man/man4/sched_ule.4#1 branch
.. //depot/projects/davidxu_thread/src/share/man/man9/Makefile#7 integrate
.. //depot/projects/davidxu_thread/src/sys/arm/arm/pmap.c#9 integrate
.. //depot/projects/davidxu_thread/src/sys/arm/include/asmacros.h#3 integrate
.. //depot/projects/davidxu_thread/src/sys/arm/include/atomic.h#4 integrate
.. //depot/projects/davidxu_thread/src/sys/arm/include/pmap.h#5 integrate
.. //depot/projects/davidxu_thread/src/sys/arm/xscale/i80321/iq31244_machdep.c#8 integrate
.. //depot/projects/davidxu_thread/src/sys/arm/xscale/i80321/obio_space.c#3 integrate
.. //depot/projects/davidxu_thread/src/sys/conf/files.arm#4 integrate
.. //depot/projects/davidxu_thread/src/sys/dev/acpica/acpi_perf.c#7 integrate
.. //depot/projects/davidxu_thread/src/sys/dev/kbd/atkbdc.c#2 integrate
.. //depot/projects/davidxu_thread/src/sys/fs/msdosfs/denode.h#6 integrate
.. //depot/projects/davidxu_thread/src/sys/fs/msdosfs/msdosfs_denode.c#7 integrate
.. //depot/projects/davidxu_thread/src/sys/kern/vfs_hash.c#3 integrate
.. //depot/projects/davidxu_thread/src/sys/sys/disklabel.h#3 integrate
.. //depot/projects/davidxu_thread/src/usr.bin/make/job.c#12 integrate
.. //depot/projects/davidxu_thread/src/usr.bin/make/parse.c#10 integrate
.. //depot/projects/davidxu_thread/src/usr.sbin/boot0cfg/boot0cfg.8#3 integrate

Differences ...

==== //depot/projects/davidxu_thread/src/bin/dd/dd.1#3 (text+ko) ====

@@ -30,7 +30,7 @@
 .\" SUCH DAMAGE.
 .\"
 .\"     @(#)dd.1	8.2 (Berkeley) 1/13/94
-.\" $FreeBSD: src/bin/dd/dd.1,v 1.28 2005/01/16 16:41:56 ru Exp $
+.\" $FreeBSD: src/bin/dd/dd.1,v 1.29 2005/04/07 20:50:38 scottl Exp $
 .\"
 .Dd August 15, 2004
 .Dt DD 1
@@ -392,10 +392,19 @@
 Check for (even) parity errors on a file:
 .Pp
 .Dl "dd if=file conv=pareven | cmp -x - file"
+.Sh BUGS
+Protection mechanisms in the
+.Xr geom 4
+subsystem might prevent the super-user from writing blocks to a disk.
+Instructions for temporarily disabling these protectsion mechanisms can be
+found in the
+.Xr geom 4
+manpage.
 .Sh SEE ALSO
 .Xr cp 1 ,
 .Xr mt 1 ,
-.Xr tr 1
+.Xr tr 1 ,
+.Xr geom 4
 .Sh STANDARDS
 The
 .Nm

==== //depot/projects/davidxu_thread/src/lib/libc/i386/sys/_amd64_get_fsbase.c#2 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/libc/i386/sys/_amd64_get_fsbase.c,v 1.1 2004/11/06 03:28:26 peter Exp $");
+__FBSDID("$FreeBSD: src/lib/libc/i386/sys/_amd64_get_fsbase.c,v 1.2 2005/04/07 04:33:15 peter Exp $");
 
 #include <sys/types.h>
 #include <machine/sysarch.h>
@@ -37,7 +37,7 @@
 	int ret;
 
 	addr64 = 0;
-	ret = sysarch(_AMD64_GET_FSBASE, (void **)(&addr64));
+	ret = sysarch(_AMD64_GET_FSBASE, &addr64);
 	if (ret != -1)
 		*addr = (void *)(uintptr_t)addr64;
 	return ret;

==== //depot/projects/davidxu_thread/src/lib/libc/i386/sys/_amd64_get_gsbase.c#2 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/libc/i386/sys/_amd64_get_gsbase.c,v 1.1 2004/11/06 03:28:26 peter Exp $");
+__FBSDID("$FreeBSD: src/lib/libc/i386/sys/_amd64_get_gsbase.c,v 1.2 2005/04/07 04:33:15 peter Exp $");
 
 #include <sys/types.h>
 #include <machine/sysarch.h>
@@ -37,7 +37,7 @@
 	int ret;
 
 	addr64 = 0;
-	ret = sysarch(_AMD64_GET_GSBASE, (void **)(&addr64));
+	ret = sysarch(_AMD64_GET_GSBASE, &addr64);
 	if (ret != -1)
 		*addr = (void *)(uintptr_t)addr64;
 	return ret;

==== //depot/projects/davidxu_thread/src/lib/libthr/arch/arm/Makefile.inc#2 (text+ko) ====

@@ -1,7 +1,5 @@
-# $FreeBSD: src/lib/libthr/arch/arm/Makefile.inc,v 1.1 2005/04/02 01:19:57 davidxu Exp $
+# $FreeBSD: src/lib/libthr/arch/arm/Makefile.inc,v 1.2 2005/04/07 22:06:05 cognet Exp $
 
 .PATH:	${.CURDIR}/arch/${MACHINE_ARCH}/${MACHINE_ARCH}
 
-CFLAGS+= -DARM_HAS_ATOMIC_CMPSET_32
-
 SRCS+=	pthread_md.c

==== //depot/projects/davidxu_thread/src/lib/libthr/arch/arm/include/pthread_md.h#2 (text+ko) ====

@@ -23,7 +23,7 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  *
- * $FreeBSD: src/lib/libthr/arch/arm/include/pthread_md.h,v 1.1 2005/04/02 01:19:57 davidxu Exp $
+ * $FreeBSD: src/lib/libthr/arch/arm/include/pthread_md.h,v 1.2 2005/04/07 22:06:05 cognet Exp $
  */
 
 /*
@@ -37,8 +37,6 @@
 #include <stddef.h>
 #include <errno.h>
 
-static __inline int atomic_cmpset_32(volatile uint32_t *, uint32_t, uint32_t);
-
 #include <sys/umtx.h>
 
 #define	DTV_OFFSET		offsetof(struct tcb, tcb_dtv)
@@ -87,20 +85,4 @@
 
 extern struct umtx arm_umtx;
 
-static __inline int
-atomic_cmpset_32(volatile uint32_t *dst, uint32_t old, uint32_t newval)
-{						
-	int ret;				
-
-	_umtx_lock(&arm_umtx);
-	arm_umtx.u_owner = (void*)((uint32_t)arm_umtx.u_owner | UMTX_CONTESTED);
-	if (*dst == old) {
-		*dst = newval;
-		ret = 1;
-	} else
-		ret = 0;
-	_umtx_unlock(&arm_umtx);
-	return (ret);
-}
-
 #endif /* _PTHREAD_MD_H_ */

==== //depot/projects/davidxu_thread/src/lib/libthr/thread/thr_list.c#4 (text+ko) ====

@@ -24,7 +24,7 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  *
- * $FreeBSD: src/lib/libthr/thread/thr_list.c,v 1.2 2005/04/06 13:57:31 davidxu Exp $
+ * $FreeBSD: src/lib/libthr/thread/thr_list.c,v 1.3 2005/04/07 06:09:17 davidxu Exp $
  */
 
 #include <sys/types.h>
@@ -65,7 +65,7 @@
 LIST_HEAD(thread_hash_head, pthread);
 #define HASH_QUEUES	128
 static struct thread_hash_head	thr_hashtable[HASH_QUEUES];
-#define	THREAD_HASH(thrd)	(((unsigned long)thrd >> 12) % HASH_QUEUES)
+#define	THREAD_HASH(thrd)	(((unsigned long)thrd >> 8) % HASH_QUEUES)
 
 static void thr_destroy(struct pthread *curthread, struct pthread *thread);
 

==== //depot/projects/davidxu_thread/src/lib/msun/Makefile#8 (text+ko) ====

@@ -1,5 +1,5 @@
 #  @(#)Makefile 5.1beta 93/09/24
-# $FreeBSD: src/lib/msun/Makefile,v 1.68 2005/04/05 02:57:39 das Exp $
+# $FreeBSD: src/lib/msun/Makefile,v 1.69 2005/04/08 01:24:08 das Exp $
 #
 #  ====================================================
 #  Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved.
@@ -47,12 +47,12 @@
 	s_fmax.c s_fmaxf.c s_fmaxl.c s_fmin.c \
 	s_fminf.c s_fminl.c s_frexp.c s_frexpf.c s_ilogb.c s_ilogbf.c \
 	s_ilogbl.c s_isfinite.c s_isnan.c s_isnormal.c \
-	s_llrint.c s_llrintf.c s_llround.c s_llroundf.c \
+	s_llrint.c s_llrintf.c s_llround.c s_llroundf.c s_llroundl.c \
 	s_log1p.c s_log1pf.c s_logb.c s_logbf.c s_lrint.c s_lrintf.c \
-	s_lround.c s_lroundf.c s_modff.c \
+	s_lround.c s_lroundf.c s_lroundl.c s_modff.c \
 	s_nearbyint.c s_nextafter.c s_nextafterf.c \
 	s_nexttowardf.c s_remquo.c s_remquof.c \
-	s_rint.c s_rintf.c s_round.c s_roundf.c \
+	s_rint.c s_rintf.c s_round.c s_roundf.c s_roundl.c \
 	s_scalbln.c s_scalbn.c s_scalbnf.c s_signbit.c \
 	s_signgam.c s_significand.c s_significandf.c s_sin.c s_sinf.c s_tan.c \
 	s_tanf.c s_tanh.c s_tanhf.c s_trunc.c s_truncf.c \
@@ -137,14 +137,15 @@
 MLINKS+=j0.3 j0f.3 j0.3 j1f.3 j0.3 jnf.3 j0.3 y0f.3 j0.3 ynf.3
 MLINKS+=lgamma.3 gamma.3 lgamma.3 gammaf.3 lgamma.3 lgammaf.3 lgamma.3 tgamma.3
 MLINKS+=lrint.3 llrint.3 lrint.3 llrintf.3 lrint.3 lrintf.3
-MLINKS+=lround.3 llround.3 lround.3 llroundf.3 lround.3 lroundf.3
+MLINKS+=lround.3 llround.3 lround.3 llroundf.3 lround.3 llroundl.3 \
+	lround.3 lroundf.3 lround.3 lroundl.3
 MLINKS+=nextafter.3 nextafterf.3 nextafter.3 nextafterl.3
 MLINKS+=nextafter.3 nexttoward.3 nextafter.3 nexttowardf.3
 MLINKS+=nextafter.3 nexttowardl.3
 MLINKS+=remainder.3 remainderf.3
 MLINKS+=remainder.3 remquo.3 remainder.3 remquof.3
 MLINKS+=rint.3 rintf.3 rint.3 nearbyint.3 rint.3 nearbyintf.3
-MLINKS+=round.3 roundf.3
+MLINKS+=round.3 roundf.3 round.3 roundl.3
 MLINKS+=scalbn.3 scalbln.3 scalbn.3 scalblnf.3 scalbn.3 scalblnl.3
 MLINKS+=scalbn.3 scalbnf.3 scalbn.3 scalbnl.3
 MLINKS+=sin.3 sinf.3

==== //depot/projects/davidxu_thread/src/lib/msun/man/lround.3#2 (text+ko) ====

@@ -22,16 +22,18 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/lib/msun/man/lround.3,v 1.2 2005/01/13 10:43:01 ru Exp $
+.\" $FreeBSD: src/lib/msun/man/lround.3,v 1.3 2005/04/08 01:24:08 das Exp $
 .\"
-.Dd January 11, 2005
+.Dd April 7, 2005
 .Dt LROUND 3
 .Os
 .Sh NAME
 .Nm llround ,
 .Nm llroundf ,
+.Nm llroundl ,
 .Nm lround ,
-.Nm lroundf
+.Nm lroundf ,
+.Nm lroundl
 .Nd "convert to nearest integral value"
 .Sh LIBRARY
 .Lb libm
@@ -41,10 +43,14 @@
 .Fn llround "double x"
 .Ft "long long"
 .Fn llroundf "float x"
+.Ft "long long"
+.Fn llroundl "long double x"
 .Ft long
 .Fn lround "double x"
 .Ft long
 .Fn lroundf "float x"
+.Ft long
+.Fn lroundl "long double x"
 .Sh DESCRIPTION
 The
 .Fn lround
@@ -70,8 +76,10 @@
 The
 .Fn llround ,
 .Fn llroundf ,
+.Fn llroundl ,
+.Fn lroundf
 and
-.Fn lroundf
+.Fn lroundl
 functions differ from
 .Fn lround
 only in their input and output types.
@@ -84,11 +92,21 @@
 The
 .Fn llround ,
 .Fn llroundf ,
+.Fn llroundl ,
 .Fn lround ,
+.Fn lroundf ,
 and
-.Fn lroundf
+.Fn lroundl
 functions conform to
 .St -isoC-99 .
 .Sh HISTORY
-These routines first appeared in
+The
+.Ft float
+and
+.Ft double
+versions of these routines first appeared in
 .Fx 5.4 .
+The
+.Ft long double
+versions appeared in
+.Fx 6.0 .

==== //depot/projects/davidxu_thread/src/lib/msun/man/round.3#3 (text+ko) ====

@@ -22,14 +22,15 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/lib/msun/man/round.3,v 1.4 2005/01/11 23:12:17 das Exp $
+.\" $FreeBSD: src/lib/msun/man/round.3,v 1.5 2005/04/08 01:24:08 das Exp $
 .\"
-.Dd November 29, 2003
+.Dd April 7, 2005
 .Dt ROUND 3
 .Os
 .Sh NAME
 .Nm round ,
-.Nm roundf
+.Nm roundf ,
+.Nm roundl
 .Nd round to nearest integral value
 .Sh LIBRARY
 .Lb libm
@@ -39,11 +40,14 @@
 .Fn round "double x"
 .Ft float
 .Fn roundf "float x"
+.Ft long double
+.Fn roundl "long double x"
 .Sh DESCRIPTION
 The
-.Fn round
+.Fn round ,
+.Fn roundf ,
 and
-.Fn roundf
+.Fn roundl
 functions return the nearest integral value to
 .Fa x ;
 if
@@ -61,9 +65,7 @@
 .Xr rint 3 ,
 .Xr trunc 3
 .Sh STANDARDS
-The
-.Fn round
-function conforms to
+These functions conform to
 .St -isoC-99 .
 .Sh HISTORY
 The
@@ -72,3 +74,7 @@
 .Fn roundf
 functions appeared in
 .Fx 5.3 .
+The
+.Fn roundl
+function appeared in
+.Fx 6.0 .

==== //depot/projects/davidxu_thread/src/lib/msun/src/math.h#7 (text+ko) ====

@@ -11,7 +11,7 @@
 
 /*
  * from: @(#)fdlibm.h 5.1 93/09/24
- * $FreeBSD: src/lib/msun/src/math.h,v 1.59 2005/04/05 02:57:15 das Exp $
+ * $FreeBSD: src/lib/msun/src/math.h,v 1.60 2005/04/08 01:24:08 das Exp $
  */
 
 #ifndef _MATH_H_
@@ -428,14 +428,18 @@
 #if 0
 long double	lgammal(long double);
 long long	llrintl(long double);
+#endif
 long long	llroundl(long double);
+#if 0
 long double	log10l(long double);
 long double	log1pl(long double);
 long double	log2l(long double);
 long double	logbl(long double);
 long double	logl(long double);
 long		lrintl(long double);
+#endif
 long		lroundl(long double);
+#if 0
 long double	modfl(long double, long double *); /* fundamentally !__pure2 */
 long double	nanl(const char *) __pure2;
 long double	nearbyintl(long double);
@@ -449,8 +453,8 @@
 long double	remainderl(long double, long double);
 long double	remquol(long double, long double, int *);
 long double	rintl(long double);
+#endif
 long double	roundl(long double);
-#endif
 long double	scalblnl(long double, long);
 long double	scalbnl(long double, int);
 #if 0

==== //depot/projects/davidxu_thread/src/lib/msun/src/s_llround.c#2 (text+ko) ====

@@ -1,5 +1,5 @@
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/msun/src/s_llround.c,v 1.1 2005/01/11 23:12:55 das Exp $");
+__FBSDID("$FreeBSD: src/lib/msun/src/s_llround.c,v 1.2 2005/04/08 00:52:27 das Exp $");
 
 #define type		double
 #define	roundit		round
@@ -8,4 +8,4 @@
 #define	DTYPE_MAX	LLONG_MAX
 #define	fn		llround
 
-#include "s_lrint.c"
+#include "s_lround.c"

==== //depot/projects/davidxu_thread/src/lib/msun/src/s_llroundf.c#2 (text+ko) ====

@@ -1,5 +1,5 @@
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/msun/src/s_llroundf.c,v 1.1 2005/01/11 23:12:55 das Exp $");
+__FBSDID("$FreeBSD: src/lib/msun/src/s_llroundf.c,v 1.2 2005/04/08 00:52:27 das Exp $");
 
 #define type		float
 #define	roundit		roundf
@@ -8,4 +8,4 @@
 #define	DTYPE_MAX	LLONG_MAX
 #define	fn		llroundf
 
-#include "s_lrint.c"
+#include "s_lround.c"

==== //depot/projects/davidxu_thread/src/lib/msun/src/s_lround.c#2 (text+ko) ====

@@ -30,7 +30,7 @@
 #include <math.h>
 
 #ifndef type
-__FBSDID("$FreeBSD: src/lib/msun/src/s_lround.c,v 1.1 2005/01/11 23:12:55 das Exp $");
+__FBSDID("$FreeBSD: src/lib/msun/src/s_lround.c,v 1.2 2005/04/08 00:52:16 das Exp $");
 #define type		double
 #define	roundit		round
 #define dtype		long
@@ -44,12 +44,11 @@
  * of the form xxx.5; they are "out of range" because lround() rounds away
  * from 0.  On the other hand, if type has less precision than dtype, then
  * all values that are out of range are integral, so we might as well assume
- * that everything is in range.  (The correct condition in this case is
- * harder to express.)  At compile time, INRANGE(x) should reduce to two
- * floating-point comparisons in the former case, or TRUE otherwise.
+ * that everything is in range.  At compile time, INRANGE(x) should reduce to
+ * two floating-point comparisons in the former case, or TRUE otherwise.
  */
-static const double dtype_min = DTYPE_MIN - 0.5;
-static const double dtype_max = DTYPE_MAX + 0.5;
+static const type dtype_min = DTYPE_MIN - 0.5;
+static const type dtype_max = DTYPE_MAX + 0.5;
 #define	INRANGE(x)	(dtype_max - DTYPE_MAX != 0.5 || \
 			 ((x) > dtype_min && (x) < dtype_max))
 

==== //depot/projects/davidxu_thread/src/lib/msun/src/s_lroundf.c#2 (text+ko) ====

@@ -1,5 +1,5 @@
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/msun/src/s_lroundf.c,v 1.1 2005/01/11 23:12:55 das Exp $");
+__FBSDID("$FreeBSD: src/lib/msun/src/s_lroundf.c,v 1.2 2005/04/08 00:52:27 das Exp $");
 
 #define type		float
 #define	roundit		roundf
@@ -8,4 +8,4 @@
 #define	DTYPE_MAX	LONG_MAX
 #define	fn		lroundf
 
-#include "s_lrint.c"
+#include "s_lround.c"

==== //depot/projects/davidxu_thread/src/libexec/rexecd/rexecd.c#8 (text+ko) ====

@@ -42,7 +42,7 @@
 static char sccsid[] = "@(#)rexecd.c	8.1 (Berkeley) 6/4/93";
 #endif
 static const char rcsid[] =
-  "$FreeBSD: src/libexec/rexecd/rexecd.c,v 1.39 2005/04/05 18:25:27 nectar Exp $";
+  "$FreeBSD: src/libexec/rexecd/rexecd.c,v 1.40 2005/04/07 19:26:35 nectar Exp $";
 #endif /* not lint */
 
 #include <sys/param.h>
@@ -136,9 +136,9 @@
 {
 	char *cmdbuf, *cp;
 	int maxcmdlen;
-	char user[16], pass[16];
+	char userbuf[16], pass[16];
 	struct passwd *pwd, pwd_storage;
-	char *pwdbuf;
+	char *pwdbuf, *user;
 	size_t pwdbuflen;
 	int fd, r, sd;
 	u_short port;
@@ -189,7 +189,8 @@
 		if (connect(sd, fromp, fromp->sa_len) < 0)
 			exit(1);
 	}
-	getstr(user, sizeof(user), "username");
+	user = userbuf;
+	getstr(userbuf, sizeof(userbuf), "username");
 	getstr(pass, sizeof(pass), "password");
 	getstr(cmdbuf, maxcmdlen, "command");
 	(void) alarm(0);

==== //depot/projects/davidxu_thread/src/libexec/rtld-elf/arm/rtld_machdep.h#4 (text+ko) ====

@@ -23,7 +23,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $FreeBSD: src/libexec/rtld-elf/arm/rtld_machdep.h,v 1.4 2005/02/26 22:49:19 cognet Exp $
+ * $FreeBSD: src/libexec/rtld-elf/arm/rtld_machdep.h,v 1.5 2005/04/07 22:04:49 cognet Exp $
  */
 
 #ifndef RTLD_MACHDEP_H
@@ -71,16 +71,4 @@
 
 extern void *__tls_get_addr(tls_index *ti);
 
-#ifndef ARM_HAS_ATOMIC_CMPSET_32
-static __inline u_int32_t
-atomic_cmpset_32(volatile u_int32_t *p, u_int32_t cmpval, u_int32_t newval)
-{
-
-	if (*p == cmpval) {
-		*p = newval;
-		return (1);
-	}
-	return (0);
-}
-#endif
 #endif

==== //depot/projects/davidxu_thread/src/sbin/geom/class/Makefile.inc#2 (text+ko) ====

@@ -1,10 +1,10 @@
-# $FreeBSD: src/sbin/geom/class/Makefile.inc,v 1.6 2004/08/02 09:05:29 pjd Exp $
+# $FreeBSD: src/sbin/geom/class/Makefile.inc,v 1.7 2005/04/07 15:57:38 pjd Exp $
 
 SHLIBDIR?=${CLASS_DIR}
 SHLIB_NAME?=geom_${CLASS}.so
-LINKS=  ${BINDIR}/geom ${BINDIR}/g${CLASS}
+LINKS=	${BINDIR}/geom ${BINDIR}/g${CLASS}
 MAN=	g${CLASS}.8
-SRCS=   geom_${CLASS}.c subr.c
+SRCS+=	geom_${CLASS}.c subr.c
 
 CFLAGS+= -I${.CURDIR}/../..
 

==== //depot/projects/davidxu_thread/src/sbin/geom/core/geom.c#6 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sbin/geom/core/geom.c,v 1.20 2005/03/22 22:05:44 pjd Exp $");
+__FBSDID("$FreeBSD: src/sbin/geom/core/geom.c,v 1.21 2005/04/07 06:46:11 pjd Exp $");
 
 #include <sys/param.h>
 #include <sys/linker.h>
@@ -436,7 +436,7 @@
 		gctl_rw_param(req, "output", sizeof(buf), buf);
 		errstr = gctl_issue(req);
 	}
-	if (errstr != NULL) {  
+	if (errstr != NULL && errstr[0] != '\0') {  
 		fprintf(stderr, "%s\n", errstr);
 		if (strncmp(errstr, "warning: ", strlen("warning: ")) != 0) {
 			gctl_free(req);

==== //depot/projects/davidxu_thread/src/sbin/nfsiod/nfsiod.c#2 (text+ko) ====

@@ -42,7 +42,7 @@
 #endif
 #endif
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sbin/nfsiod/nfsiod.c,v 1.17 2004/04/09 19:58:34 markm Exp $");
+__FBSDID("$FreeBSD: src/sbin/nfsiod/nfsiod.c,v 1.18 2005/04/07 20:37:04 brooks Exp $");
 
 #include <sys/param.h>
 #include <sys/syslog.h>
@@ -119,7 +119,7 @@
 	len = sizeof iodmax;
 	error = sysctlbyname("vfs.nfs.iodmax", &iodmax, &len, NULL, 0);
 	if (error < 0)
-		err(1, "sysctlbyname(\"vfs.nfs.iodmin\")");
+		err(1, "sysctlbyname(\"vfs.nfs.iodmax\")");
 	/* Catch the case where we're lowering num_servers below iodmin */
 	if (iodmin > num_servers) {
 		iodmin = num_servers;

==== //depot/projects/davidxu_thread/src/share/man/man4/Makefile#12 (text+ko) ====

@@ -1,5 +1,5 @@
 #	@(#)Makefile	8.1 (Berkeley) 6/18/93
-# $FreeBSD: src/share/man/man4/Makefile,v 1.311 2005/03/31 19:44:15 scottl Exp $
+# $FreeBSD: src/share/man/man4/Makefile,v 1.312 2005/04/07 21:57:19 rwatson Exp $
 
 MAN=	aac.4 \
 	acpi.4 \
@@ -249,6 +249,8 @@
 	sbp.4 \
 	sbp_targ.4 \
 	sbsh.4 \
+	sched_4bsd.4 \
+	sched_ule.4 \
 	screen.4 \
 	scsi.4 \
 	sem.4 \

==== //depot/projects/davidxu_thread/src/share/man/man4/atkbdc.4#2 (text+ko) ====

@@ -24,7 +24,7 @@
 .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
 .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/share/man/man4/atkbdc.4,v 1.16 2001/10/13 09:08:30 yokota Exp $
+.\" $FreeBSD: src/share/man/man4/atkbdc.4,v 1.18 2005/04/07 23:59:37 sobomax Exp $
 .\"
 .Dd February 9, 1999
 .Dt ATKBDC 4

==== //depot/projects/davidxu_thread/src/share/man/man4/carp.4#3 (text+ko) ====

@@ -23,9 +23,9 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/share/man/man4/carp.4,v 1.4 2005/03/23 08:06:38 rse Exp $
+.\" $FreeBSD: src/share/man/man4/carp.4,v 1.6 2005/04/07 15:28:14 glebius Exp $
 .\"
-.Dd March 23, 2005
+.Dd April 7, 2005
 .Dt CARP 4
 .Os
 .Sh NAME
@@ -70,6 +70,23 @@
 which is used to authenticate
 .Nm
 advertisements.
+The
+.Cm advbase
+parameter stands for
+.Qq advertisement base .
+It is measured in seconds and specifies the base of the adverisement interval.
+The
+.Cm advskew
+parameter stands for
+.Qq advertisement skew .
+It is measured in 1/256 of seconds.
+It is added to the base advertisement interval to make one host advertise
+a bit slower that the other does.
+Both
+.Cm advbase
+and
+.Cm advskew
+are put inside CARP advertisments.
 These configurations can be done using
 .Xr ifconfig 8 ,
 or through the
@@ -127,22 +144,18 @@
 This is the setup for host A:
 .Bd -literal -offset indent
 ifconfig carp0 create
-ifconfig carp0 vhid 1 pass mekmitasdigoat 192.168.1.1 \e
-	255.255.255.0
+ifconfig carp0 vhid 1 pass mekmitasdigoat 192.168.1.1/24
 ifconfig carp1 create
-ifconfig carp1 vhid 2 pass mekmitasdigoat 192.168.2.1 \e
-	255.255.255.0
+ifconfig carp1 vhid 2 pass mekmitasdigoat 192.168.2.1/24
 .Ed
 .Pp
 The setup for host B is identical, but it has a higher
 .Cm advskew :
 .Bd -literal -offset indent
 ifconfig carp0 create
-ifconfig carp0 vhid 1 advskew 100 pass mekmitasdigoat \e
-	192.168.1.1 255.255.255.0
+ifconfig carp0 vhid 1 advskew 100 pass mekmitasdigoat 192.168.1.1/24
 ifconfig carp1 create
-ifconfig carp1 vhid 2 advskew 100 pass mekmitasdigoat \e
-	192.168.2.1 255.255.255.0
+ifconfig carp1 vhid 2 advskew 100 pass mekmitasdigoat 192.168.2.1/24
 .Ed
 .Pp
 Because of the preempt option, when one of the physical interfaces of
@@ -169,11 +182,9 @@
 out slightly less frequently.
 .Bd -literal -offset indent
 ifconfig carp0 create
-ifconfig carp0 vhid 1 pass mekmitasdigoat 192.168.1.10 \e
-	255.255.255.0
+ifconfig carp0 vhid 1 pass mekmitasdigoat 192.168.1.10/24
 ifconfig carp1 create
-ifconfig carp1 vhid 2 advskew 100 pass mekmitasdigoat \e
-	192.168.1.10 255.255.255.0
+ifconfig carp1 vhid 2 advskew 100 pass mekmitasdigoat 192.168.1.10/24
 .Ed
 .Pp
 The configuration for host B is identical, except the
@@ -181,11 +192,9 @@
 is on virtual host 1 rather than virtual host 2.
 .Bd -literal -offset indent
 ifconfig carp0 create
-ifconfig carp0 vhid 1 advskew 100 pass mekmitasdigoat \e
-	192.168.1.10 255.255.255.0
+ifconfig carp0 vhid 1 advskew 100 pass mekmitasdigoat 192.168.1.10/24
 ifconfig carp1 create
-ifconfig carp1 vhid 2 pass mekmitasdigoat 192.168.1.10 \e
-	255.255.255.0
+ifconfig carp1 vhid 2 pass mekmitasdigoat 192.168.1.10/24
 .Ed
 .Pp
 Finally, the ARP balancing feature must be enabled on both hosts:

==== //depot/projects/davidxu_thread/src/share/man/man4/geom.4#2 (text+ko) ====

@@ -32,7 +32,7 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/share/man/man4/geom.4,v 1.11 2004/07/03 18:29:20 ru Exp $
+.\" $FreeBSD: src/share/man/man4/geom.4,v 1.12 2005/04/07 19:59:28 scottl Exp $
 .\"
 .Dd March 27, 2002
 .Os
@@ -330,6 +330,33 @@
 a separate section below.
 .Pp
 (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
+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
+.It 0x01 (G_T_TOPOLOGY)
+Provide tracing of topology change events.
+.It 0x02 (G_T_BIO)
+Provide tracing of buffer I/O requests.
+.It 0x04 (G_T_ACCESS)
+Provide tracing of access check controls.
+.It 0x08 (unused)
+.It 0x10 (allow foot shooting)
+Allow writing to Rank 1 providers.
+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 (G_T_DETAILS)
+This appears to be unused at this time.
+.It 0x40 (G_F_DISKIOCTL)
+This appears to be unused at this time.
+.It 0x80 (G_F_CTLDUMP)
+Dump contents of gctl requests.
+.El
 .Sh HISTORY
 This software was developed for the FreeBSD Project by Poul-Henning Kamp
 and NAI Labs, the Security Research Division of Network Associates, Inc.

==== //depot/projects/davidxu_thread/src/share/man/man9/Makefile#7 (text+ko) ====

@@ -1,4 +1,4 @@
-# $FreeBSD: src/share/man/man9/Makefile,v 1.254 2005/02/22 17:42:12 brueffer Exp $
+# $FreeBSD: src/share/man/man9/Makefile,v 1.255 2005/04/07 17:27:14 njl Exp $
 
 MAN=	accept_filter.9 \
 	accf_data.9 \
@@ -51,6 +51,7 @@
 	devclass_find.9 \
 	devclass_get_device.9 \
 	devclass_get_devices.9 \
+	devclass_get_drivers.9 \
 	devclass_get_maxunit.9 \
 	devclass_get_name.9 \
 	devclass_get_softc.9 \

==== //depot/projects/davidxu_thread/src/sys/arm/arm/pmap.c#9 (text+ko) ====

@@ -147,7 +147,7 @@
 #include "opt_vm.h"
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/arm/arm/pmap.c,v 1.26 2005/03/16 23:56:29 cognet Exp $");
+__FBSDID("$FreeBSD: src/sys/arm/arm/pmap.c,v 1.27 2005/04/07 22:01:53 cognet Exp $");
 #include <sys/param.h>
 #include <sys/systm.h>
 #include <sys/kernel.h>
@@ -402,7 +402,7 @@
 /*
  * Data for the pv entry allocation mechanism
  */
-#define MINPV	1024
+#define MINPV	2048
 
 #ifndef PMAP_SHPGPERPROC
 #define PMAP_SHPGPERPROC 200
@@ -1205,6 +1205,18 @@
 }
 
 /*
+ * this routine defines the region(s) of memory that should
+ * not be tested for the modified bit.
+ */
+static PMAP_INLINE int
+pmap_track_modified(vm_offset_t va)
+{
+	if ((va < kmi.clean_sva) || (va >= kmi.clean_eva)) 
+		return 1;
+	else
+		return 0;
+}
+/*
  * PTE_SYNC_CURRENT:
  *
  *     Make sure the pte is written out to RAM.
@@ -1538,7 +1550,6 @@
 		pm = pv->pv_pmap;
 		oflags = pv->pv_flags;
 		pv->pv_flags &= ~maskbits;
-		pmap_update(pv->pv_pmap);
 
 #if 0
 		pmap_acquire_pmap_lock(pm);
@@ -1549,7 +1560,8 @@
 		ptep = &l2b->l2b_kva[l2pte_index(va)];
 		npte = opte = *ptep;
 
-		if (maskbits & (PVF_WRITE|PVF_MOD)) {
+		if (maskbits & (PVF_WRITE|PVF_MOD) &&
+		    !pmap_track_modified(pv->pv_va)) {
 			if ((pv->pv_flags & PVF_NC)) {
 				/* 
 				 * Entry is not cacheable:
@@ -1570,6 +1582,7 @@
 				}
 			} else
 			if (opte & L2_S_PROT_W) {
+				vm_page_dirty(pg);
 				/* 
 				 * Entry is writable/cacheable: check if pmap
 				 * is current if it is flush it, otherwise it
@@ -1606,7 +1619,7 @@
 			}
 		}
 
-		if (maskbits & PVF_REF) {
+		if (maskbits & PVF_REF && !pmap_track_modified(pv->pv_va)) {
 			if ((pv->pv_flags & PVF_NC) == 0 &&
 			    (maskbits & (PVF_WRITE|PVF_MOD)) == 0) {
 				/*
@@ -1706,6 +1719,7 @@
 	mtx_lock(&pg->md.pvh_mtx);
 #endif
 	TAILQ_INSERT_HEAD(&pg->md.pv_list, pve, pv_list);
+	TAILQ_INSERT_HEAD(&pm->pm_pvlist, pve, pv_plist);
 	pg->md.pvh_attrs |= flags & (PVF_REF | PVF_MOD);
 	if (pm == pmap_kernel()) {
 		if (flags & PVF_WRITE)
@@ -1723,6 +1737,7 @@
 #endif
 	if (pve->pv_flags & PVF_WIRED)
 		++pm->pm_stats.wired_count;
+	vm_page_flag_set(pg, PG_REFERENCED);
 }
 
 /*
@@ -1779,9 +1794,12 @@
 {
 
 	TAILQ_REMOVE(&pg->md.pv_list, pve, pv_list);
+	TAILQ_REMOVE(&pm->pm_pvlist, pve, pv_plist);
 	if (pve->pv_flags & PVF_WIRED)
 		--pm->pm_stats.wired_count;
 	pg->md.pv_list_count--;
+	if (pg->md.pvh_attrs & PVF_MOD)
+		vm_page_dirty(pg);
 	if (pm == pmap_kernel()) {
 		if (pve->pv_flags & PVF_WRITE)
 			pg->md.krw_mappings--;
@@ -1792,8 +1810,18 @@
 			pg->md.urw_mappings--;
 		else
 			pg->md.uro_mappings--;
-	if (TAILQ_FIRST(&pg->md.pv_list) == NULL)
+	if (TAILQ_FIRST(&pg->md.pv_list) == NULL ||
+	    (pg->md.krw_mappings == 0 && pg->md.urw_mappings == 0)) {
+		pg->md.pvh_attrs &= ~PVF_MOD;
+		if (TAILQ_FIRST(&pg->md.pv_list) == NULL)
+			pg->md.pvh_attrs &= ~PVF_REF;
 		vm_page_flag_clear(pg, PG_WRITEABLE);
+	} else if (pmap_track_modified(pve->pv_va))
+		vm_page_dirty(pg);
+	if (TAILQ_FIRST(&pg->md.pv_list))
+		vm_page_flag_set(pg, PG_REFERENCED);
+	if (pve->pv_flags & PVF_WRITE)
+		pmap_vac_me_harder(pg, pm, 0);
 }
 
 static struct pv_entry *
@@ -1869,6 +1897,11 @@
 			pg->md.uro_mappings++;
 			pg->md.urw_mappings--;
 		}
+		if (pg->md.krw_mappings == 0 && pg->md.urw_mappings == 0) {
+			pg->md.pvh_attrs &= ~PVF_MOD;
+			vm_page_flag_clear(pg, PG_WRITEABLE);
+		}
+		pmap_vac_me_harder(pg, pm, 0);
 	}
 
 	return (oflags);
@@ -2014,7 +2047,10 @@
 			goto out;
 		}
 
-		pg->md.pvh_attrs |= PVF_REF | PVF_MOD;
+		if (pmap_track_modified(pv->pv_va)) {
+			pg->md.pvh_attrs |= PVF_REF | PVF_MOD;
+			vm_page_dirty(pg);
+		}
 		pv->pv_flags |= PVF_REF | PVF_MOD;
 
 		/* 
@@ -2038,13 +2074,16 @@
 		struct vm_page *pg;
 
 		/* Extract the physical address of the page */
-		if ((pg = PHYS_TO_VM_PAGE(pa)) == NULL)
+		vm_page_lock_queues();
+		if ((pg = PHYS_TO_VM_PAGE(pa)) == NULL) {
+			vm_page_unlock_queues();
 			goto out;
-
+		}
 		/* Get the current flags for this page. */
 
 		pv = pmap_find_pv(pg, pm, va);
 		if (pv == NULL) {
+			vm_page_unlock_queues();
 			goto out;
 		}
 
@@ -2055,6 +2094,7 @@
 		*ptep = (pte & ~L2_TYPE_MASK) | L2_S_PROTO;
 		PTE_SYNC(ptep);
 		rv = 1;
+		vm_page_unlock_queues();
 	}
 
 	/*
@@ -2486,6 +2526,7 @@
 	kernel_pmap->pm_active = -1;
 	kernel_pmap->pm_domain = PMAP_DOMAIN_KERNEL;
 	LIST_INIT(&allpmaps);
+	TAILQ_INIT(&kernel_pmap->pm_pvlist);
 	LIST_INSERT_HEAD(&allpmaps, kernel_pmap, pm_list);
 	
 	/*
@@ -2585,7 +2626,7 @@
 	vm_paddr_t pa;

>>> TRUNCATED FOR MAIL (1000 lines) <<<



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200504080213.j382Db2A001911>