Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Jan 2008 20:47:19 GMT
From:      Kip Macy <kmacy@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 133496 for review
Message-ID:  <200801172047.m0HKlJTU027592@repoman.freebsd.org>

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

Change 133496 by kmacy@kmacy:storage:toehead on 2008/01/17 20:46:45

	IFC 133494

Affected files ...

.. //depot/projects/toehead/Makefile.inc1#2 integrate
.. //depot/projects/toehead/gnu/usr.bin/cvs/Makefile#3 integrate
.. //depot/projects/toehead/gnu/usr.bin/cvs/contrib/Makefile#3 integrate
.. //depot/projects/toehead/lib/libc/amd64/_fpmath.h#2 integrate
.. //depot/projects/toehead/lib/libc/i386/_fpmath.h#2 integrate
.. //depot/projects/toehead/lib/libc/ia64/_fpmath.h#2 integrate
.. //depot/projects/toehead/lib/libc/sys/access.2#2 integrate
.. //depot/projects/toehead/lib/msun/src/math_private.h#3 integrate
.. //depot/projects/toehead/share/man/man4/mfi.4#2 integrate
.. //depot/projects/toehead/share/misc/pci_vendors#2 integrate
.. //depot/projects/toehead/sys/amd64/amd64/pmap.c#3 integrate
.. //depot/projects/toehead/sys/amd64/include/_types.h#2 integrate
.. //depot/projects/toehead/sys/amd64/include/float.h#2 integrate
.. //depot/projects/toehead/sys/amd64/isa/clock.c#2 integrate
.. //depot/projects/toehead/sys/arm/arm/pmap.c#4 integrate
.. //depot/projects/toehead/sys/boot/forth/loader.conf.5#2 integrate
.. //depot/projects/toehead/sys/dev/acpica/acpi_hpet.c#3 integrate
.. //depot/projects/toehead/sys/dev/acpica/acpi_hpet.h#1 branch
.. //depot/projects/toehead/sys/dev/cxgb/cxgb_main.c#4 integrate
.. //depot/projects/toehead/sys/dev/drm/drm_drv.c#2 integrate
.. //depot/projects/toehead/sys/dev/if_ndis/if_ndis.c#2 integrate
.. //depot/projects/toehead/sys/i386/i386/pmap.c#3 integrate
.. //depot/projects/toehead/sys/i386/isa/clock.c#2 integrate
.. //depot/projects/toehead/sys/kern/kern_rwlock.c#3 integrate
.. //depot/projects/toehead/sys/kern/uipc_shm.c#2 integrate
.. //depot/projects/toehead/sys/net/if_bridge.c#3 integrate
.. //depot/projects/toehead/tools/regression/posixshm/Makefile#1 branch
.. //depot/projects/toehead/tools/regression/posixshm/posixshm.c#1 branch
.. //depot/projects/toehead/tools/regression/posixshm/posixshm.t#1 branch
.. //depot/projects/toehead/tools/regression/posixshm/test.c#1 branch
.. //depot/projects/toehead/tools/regression/posixshm/test.h#1 branch
.. //depot/projects/toehead/tools/tools/aac/aac_checkq.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/cmds.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/convtbl.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/devs.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/fetch.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/icmp.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/icmp6.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/iostat.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/ip.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/ip6.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/keyboard.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/main.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/mbufs.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/netcmds.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/netstat.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/pigs.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/swap.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/tcp.c#2 integrate
.. //depot/projects/toehead/usr.bin/systat/vmstat.c#2 integrate

Differences ...

==== //depot/projects/toehead/Makefile.inc1#2 (text+ko) ====

@@ -1,5 +1,5 @@
 #
-# $FreeBSD: src/Makefile.inc1,v 1.591 2007/12/04 12:55:27 yar Exp $
+# $FreeBSD: src/Makefile.inc1,v 1.592 2008/01/16 15:05:49 brueffer Exp $
 #
 # Make command line options:
 #	-DNO_CLEANDIR run ${MAKE} clean, instead of ${MAKE} cleandir
@@ -227,7 +227,7 @@
 # cross-tools stage
 XMAKE=		TOOLS_PREFIX=${WORLDTMP} ${BMAKE} \
 		TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \
-		-DWITHOUT_FORTRAN -DWITHOUT_GDB
+		-DWITHOUT_GDB
 
 # world stage
 WMAKEENV=	${CROSSENV} \

==== //depot/projects/toehead/gnu/usr.bin/cvs/Makefile#3 (text+ko) ====

@@ -1,5 +1,5 @@
-# $FreeBSD: src/gnu/usr.bin/cvs/Makefile,v 1.17 2008/01/13 08:58:25 obrien Exp $
+# $FreeBSD: src/gnu/usr.bin/cvs/Makefile,v 1.18 2008/01/16 17:16:36 obrien Exp $
 
-SUBDIR = lib libdiff cvs cvsbug doc
+SUBDIR = lib libdiff cvs contrib cvsbug doc
 
 .include <bsd.subdir.mk>

==== //depot/projects/toehead/gnu/usr.bin/cvs/contrib/Makefile#3 (text+ko) ====

@@ -1,4 +1,6 @@
-# $FreeBSD: src/gnu/usr.bin/cvs/contrib/Makefile,v 1.19 2008/01/13 09:45:53 obrien Exp $
+# $FreeBSD: src/gnu/usr.bin/cvs/contrib/Makefile,v 1.20 2008/01/16 17:15:59 obrien Exp $
+
+.POSIX:
 
 .include "../Makefile.inc"
 

==== //depot/projects/toehead/lib/libc/amd64/_fpmath.h#2 (text+ko) ====

@@ -23,7 +23,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $FreeBSD: src/lib/libc/amd64/_fpmath.h,v 1.6 2005/03/07 04:55:21 das Exp $
+ * $FreeBSD: src/lib/libc/amd64/_fpmath.h,v 1.7 2008/01/17 16:39:06 bde Exp $
  */
 
 union IEEEl2bits {
@@ -36,6 +36,11 @@
 		unsigned int	junkl	:16;
 		unsigned int	junkh	:32;
 	} bits;
+	struct {
+		unsigned long	man	:64;
+		unsigned int	expsign	:16;
+		unsigned long	junk	:48;
+	} xbits;
 };
 
 #define	LDBL_NBIT	0x80000000
@@ -47,4 +52,4 @@
 #define	LDBL_TO_ARRAY32(u, a) do {			\
 	(a)[0] = (uint32_t)(u).bits.manl;		\
 	(a)[1] = (uint32_t)(u).bits.manh;		\
-} while(0)
+} while (0)

==== //depot/projects/toehead/lib/libc/i386/_fpmath.h#2 (text+ko) ====

@@ -23,7 +23,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $FreeBSD: src/lib/libc/i386/_fpmath.h,v 1.5 2005/03/07 04:55:22 das Exp $
+ * $FreeBSD: src/lib/libc/i386/_fpmath.h,v 1.6 2008/01/17 16:39:06 bde Exp $
  */
 
 union IEEEl2bits {
@@ -35,6 +35,11 @@
 		unsigned int	sign	:1;
 		unsigned int	junk	:16;
 	} bits;
+	struct {
+		unsigned long long man	:64;
+		unsigned int 	expsign	:16;
+		unsigned int	junk	:16;
+	} xbits;
 };
 
 #define	LDBL_NBIT	0x80000000
@@ -46,4 +51,4 @@
 #define	LDBL_TO_ARRAY32(u, a) do {			\
 	(a)[0] = (uint32_t)(u).bits.manl;		\
 	(a)[1] = (uint32_t)(u).bits.manh;		\
-} while(0)
+} while (0)

==== //depot/projects/toehead/lib/libc/ia64/_fpmath.h#2 (text+ko) ====

@@ -24,7 +24,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $FreeBSD: src/lib/libc/ia64/_fpmath.h,v 1.6 2005/03/07 04:55:40 das Exp $
+ * $FreeBSD: src/lib/libc/ia64/_fpmath.h,v 1.7 2008/01/17 16:39:07 bde Exp $
  */
 
 #include <sys/endian.h>
@@ -46,6 +46,17 @@
 		unsigned int	manl	:32;
 #endif
 	} bits;
+	struct {
+#if _BYTE_ORDER == _LITTLE_ENDIAN
+		unsigned long	man	:64;
+		unsigned int	expsign	:16;
+		unsigned long	junk	:48;
+#else /* _BIG_ENDIAN */
+		unsigned long	junk	:48;
+		unsigned int	expsign	:16;
+		unsigned long	man	:64;
+#endif
+	} xbits;
 };
 
 #if _BYTE_ORDER == _LITTLE_ENDIAN
@@ -68,4 +79,4 @@
 #define	LDBL_TO_ARRAY32(u, a) do {			\
 	(a)[0] = (uint32_t)(u).bits.manl;		\
 	(a)[1] = (uint32_t)(u).bits.manh;		\
-} while(0)
+} while (0)

==== //depot/projects/toehead/lib/libc/sys/access.2#2 (text+ko) ====

@@ -26,9 +26,9 @@
 .\" SUCH DAMAGE.
 .\"
 .\"     @(#)access.2	8.2 (Berkeley) 4/1/94
-.\" $FreeBSD: src/lib/libc/sys/access.2,v 1.20 2007/12/08 22:50:35 remko Exp $
+.\" $FreeBSD: src/lib/libc/sys/access.2,v 1.21 2008/01/16 19:36:21 remko Exp $
 .\"
-.Dd December 8, 2007
+.Dd January 16, 2007
 .Dt ACCESS 2
 .Os
 .Sh NAME
@@ -146,9 +146,9 @@
 make sense for particular filesystem objects (e.g. 'delete' menu
 item only highlighted in a writable folder ... avoiding interpretation
 of the st_mode bits that the application might not understand --
-e.g. in the case of AFS).  It also allows a cheaper file existance
-test than
-.Ns Xr stat 2 .
+e.g. in the case of AFS).
+It also allows a cheaper file existance test than
+.Xr stat 2 .
 .Sh SEE ALSO
 .Xr chmod 2 ,
 .Xr intro 2 ,

==== //depot/projects/toehead/lib/msun/src/math_private.h#3 (text+ko) ====

@@ -11,7 +11,7 @@
 
 /*
  * from: @(#)fdlibm.h 5.1 93/09/24
- * $FreeBSD: src/lib/msun/src/math_private.h,v 1.21 2007/12/18 23:46:32 das Exp $
+ * $FreeBSD: src/lib/msun/src/math_private.h,v 1.22 2008/01/17 17:02:11 bde Exp $
  */
 
 #ifndef _MATH_PRIVATE_H_
@@ -154,6 +154,22 @@
   (d) = sf_u.value;						\
 } while (0)
 
+#ifdef FLT_EVAL_METHOD
+/*
+ * Attempt to get strict C99 semantics for assignment with non-C99 compilers.
+ */
+#if FLT_EVAL_METHOD == 0 || __GNUC__ == 0
+#define	STRICT_ASSIGN(type, lval, rval)	((lval) = (rval))
+#else
+#define	STRICT_ASSIGN(type, lval, rval) do {	\
+	volatile type __lval;			\
+						\
+	__lval = (rval);			\
+	(lval) = __lval;			\
+} while (0)
+#endif
+#endif
+
 /*
  * Common routine to process the arguments to nan(), nanf(), and nanl().
  */

==== //depot/projects/toehead/share/man/man4/mfi.4#2 (text) ====

@@ -22,9 +22,9 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/share/man/man4/mfi.4,v 1.6 2007/08/13 19:29:16 jhb Exp $
+.\" $FreeBSD: src/share/man/man4/mfi.4,v 1.7 2008/01/17 19:36:13 ambrisko Exp $
 .\"
-.Dd April 3, 2006
+.Dd January 17, 2008
 .Dt MFI 4
 .Os
 .Sh NAME
@@ -83,7 +83,11 @@
 .It
 LSI MegaRAID SAS 8480E
 .It
-Dell PERC5/i
+LSI MegaRAID SAS 1078
+.It
+Dell PERC5
+.It
+Dell PERC6
 .El
 .Sh FILES
 .Bl -tag -width ".Pa /dev/mfid?" -compact

==== //depot/projects/toehead/share/misc/pci_vendors#2 (text+ko) ====

@@ -1,4 +1,4 @@
-; $FreeBSD: src/share/misc/pci_vendors,v 1.36 2007/10/29 00:31:09 benjsc Exp $
+; $FreeBSD: src/share/misc/pci_vendors,v 1.37 2008/01/17 19:29:01 ambrisko Exp $
 ;
 ; Automatically generated by src/tools/tools/pciid/mk_pci_vendors.pl
 ; (with the -l option), using the following source lists:
@@ -218,7 +218,7 @@
 	005A	SAS 3000 series, 6-port with 1066E -StorPort
 	005C	SAS1064A PCI-X Fusion-MPT SAS
 	005E	SAS 3000 series, 6-port with 1066 -StorPort
-	0060	SAS1078 PCI-X Fusion-MPT SAS
+	0060	MegaRAID SAS 1078
 	0062	LSISAS1078 PCI-Express Fusion-MPT SAS
 	008F	53C810 LSI 53C8xx SCSI host adapter chip
 	0407	MegaRAID

==== //depot/projects/toehead/sys/amd64/amd64/pmap.c#3 (text+ko) ====

@@ -77,7 +77,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.604 2008/01/14 21:25:06 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.605 2008/01/17 18:25:51 alc Exp $");
 
 /*
  *	Manages physical address maps.
@@ -149,11 +149,7 @@
 #define PMAP_SHPGPERPROC 200
 #endif
 
-#if defined(DIAGNOSTIC)
-#define PMAP_DIAGNOSTIC
-#endif
-
-#if !defined(PMAP_DIAGNOSTIC)
+#if !defined(DIAGNOSTIC)
 #define PMAP_INLINE	__gnu89_inline
 #else
 #define PMAP_INLINE
@@ -2249,12 +2245,9 @@
 	boolean_t invlva;
 
 	va = trunc_page(va);
-#ifdef PMAP_DIAGNOSTIC
-	if (va > VM_MAX_KERNEL_ADDRESS)
-		panic("pmap_enter: toobig");
-	if ((va >= UPT_MIN_ADDRESS) && (va < UPT_MAX_ADDRESS))
-		panic("pmap_enter: invalid to pmap_enter page table pages (va: 0x%lx)", va);
-#endif
+	KASSERT(va <= VM_MAX_KERNEL_ADDRESS, ("pmap_enter: toobig"));
+	KASSERT(va < UPT_MIN_ADDRESS || va >= UPT_MAX_ADDRESS,
+	    ("pmap_enter: invalid to pmap_enter page table pages (va: 0x%lx)", va));
 
 	mpte = NULL;
 
@@ -2268,19 +2261,9 @@
 	if (va < VM_MAXUSER_ADDRESS) {
 		mpte = pmap_allocpte(pmap, va, M_WAITOK);
 	}
-#if 0 && defined(PMAP_DIAGNOSTIC)
-	else {
-		pd_entry_t *pdeaddr = pmap_pde(pmap, va);
-		origpte = *pdeaddr;
-		if ((origpte & PG_V) == 0) { 
-			panic("pmap_enter: invalid kernel page table page, pde=%p, va=%p\n",
-				origpte, va);
-		}
-	}
-#endif
 
 	pde = pmap_pde(pmap, va);
-	if (pde != NULL) {
+	if (pde != NULL && (*pde & PG_V) != 0) {
 		if ((*pde & PG_PS) != 0)
 			panic("pmap_enter: attempted pmap_enter on 2MB page");
 		pte = pmap_pde_to_pte(pde, va);
@@ -2291,7 +2274,7 @@
 	 * Page Directory table entry not valid, we need a new PT page
 	 */
 	if (pte == NULL)
-		panic("pmap_enter: invalid page directory va=%#lx\n", va);
+		panic("pmap_enter: invalid page directory va=%#lx", va);
 
 	pa = VM_PAGE_TO_PHYS(m);
 	om = NULL;
@@ -2745,8 +2728,8 @@
 		pdp_entry_t *pdpe;
 		pd_entry_t srcptepaddr, *pde;
 
-		if (addr >= UPT_MIN_ADDRESS)
-			panic("pmap_copy: invalid to pmap_copy page tables");
+		KASSERT(addr < UPT_MIN_ADDRESS,
+		    ("pmap_copy: invalid to pmap_copy page tables"));
 
 		pml4e = pmap_pml4e(src_pmap, addr);
 		if ((*pml4e & PG_V) == 0) {
@@ -2784,8 +2767,8 @@
 		}
 
 		srcmpte = PHYS_TO_VM_PAGE(srcptepaddr & PG_FRAME);
-		if (srcmpte->wire_count == 0)
-			panic("pmap_copy: source page table page is unused");
+		KASSERT(srcmpte->wire_count > 0,
+		    ("pmap_copy: source page table page is unused"));
 
 		if (va_next > end_addr)
 			va_next = end_addr;

==== //depot/projects/toehead/sys/amd64/include/_types.h#2 (text+ko) ====

@@ -33,7 +33,7 @@
  *
  *	From: @(#)ansi.h	8.2 (Berkeley) 1/4/94
  *	From: @(#)types.h	8.3 (Berkeley) 1/5/94
- * $FreeBSD: src/sys/amd64/include/_types.h,v 1.11 2006/01/09 06:05:56 imp Exp $
+ * $FreeBSD: src/sys/amd64/include/_types.h,v 1.12 2008/01/17 13:12:46 bde Exp $
  */
 
 #ifndef _MACHINE__TYPES_H_
@@ -64,7 +64,7 @@
 typedef	unsigned int	__cpumask_t;
 typedef	__int64_t	__critical_t;
 typedef	double		__double_t;
-typedef	double		__float_t;
+typedef	float		__float_t;
 typedef	__int64_t	__intfptr_t;
 typedef	__int64_t	__intmax_t;
 typedef	__int64_t	__intptr_t;

==== //depot/projects/toehead/sys/amd64/include/float.h#2 (text+ko) ====

@@ -27,7 +27,7 @@
  * SUCH DAMAGE.
  *
  *	from: @(#)float.h	7.1 (Berkeley) 5/8/90
- * $FreeBSD: src/sys/amd64/include/float.h,v 1.15 2005/01/05 20:17:20 imp Exp $
+ * $FreeBSD: src/sys/amd64/include/float.h,v 1.16 2008/01/17 13:12:46 bde Exp $
  */
 
 #ifndef _MACHINE_FLOAT_H_
@@ -42,7 +42,7 @@
 #define FLT_RADIX	2		/* b */
 #define FLT_ROUNDS	__flt_rounds()
 #if __ISO_C_VISIBLE >= 1999
-#define	FLT_EVAL_METHOD	(-1)		/* i387 semantics are...interesting */
+#define	FLT_EVAL_METHOD	0		/* no promotions */
 #define	DECIMAL_DIG	21		/* max precision in decimal digits */
 #endif
 

==== //depot/projects/toehead/sys/amd64/isa/clock.c#2 (text+ko) ====

@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/isa/clock.c,v 1.235 2007/10/26 03:23:53 peter Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/isa/clock.c,v 1.236 2008/01/17 18:59:38 jhb Exp $");
 
 /*
  * Routines to handle clock hardware.
@@ -286,6 +286,7 @@
 		start = rdtsc();
 		end = start + (tsc_freq * n) / 1000000;
 		do {
+			cpu_spinwait();
 			now = rdtsc();
 		} while (now < end || (now > start && end < start));
 		sched_unpin();

==== //depot/projects/toehead/sys/arm/arm/pmap.c#4 (text+ko) ====

@@ -147,7 +147,7 @@
 #include "opt_vm.h"
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/arm/arm/pmap.c,v 1.96 2008/01/03 07:34:33 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/arm/arm/pmap.c,v 1.97 2008/01/17 12:41:59 cognet Exp $");
 #include <sys/param.h>
 #include <sys/systm.h>
 #include <sys/kernel.h>
@@ -3828,7 +3828,8 @@
 	bzero(&pmap->pm_stats, sizeof pmap->pm_stats);
 	pmap->pm_stats.resident_count = 1;
 	if (vector_page < KERNBASE) {
-		pmap_enter(pmap, vector_page, PHYS_TO_VM_PAGE(systempage.pv_pa),
+		pmap_enter(pmap, vector_page, 
+		    VM_PROT_READ, PHYS_TO_VM_PAGE(systempage.pv_pa),
 		    VM_PROT_READ, 1);
 	} 
 	return (1);

==== //depot/projects/toehead/sys/boot/forth/loader.conf.5#2 (text+ko) ====

@@ -22,8 +22,8 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/sys/boot/forth/loader.conf.5,v 1.26 2005/11/18 10:34:24 ru Exp $
-.Dd November 15, 2005
+.\" $FreeBSD: src/sys/boot/forth/loader.conf.5,v 1.28 2008/01/16 07:00:55 keramida Exp $
+.Dd January 16, 2008
 .Dt LOADER.CONF 5
 .Os
 .Sh NAME
@@ -238,6 +238,16 @@
 .Xr boot 8 ,
 .Xr loader 8 ,
 .Xr loader.4th 8
+.Sh BUGS
+The
+.Xr loader 8
+stops reading
+.Nm
+when it encounters a syntax error, so any options which are vital for
+booting a particular system (i.e.\& 
+.Dq Va hw.ata.ata_dma Ns "=0" )
+should precede any experimental additions to
+.Nm .
 .Sh HISTORY
 The file
 .Nm

==== //depot/projects/toehead/sys/dev/acpica/acpi_hpet.c#3 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_hpet.c,v 1.13 2008/01/15 18:50:47 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_hpet.c,v 1.14 2008/01/16 18:47:07 jhb Exp $");
 
 #include "opt_acpi.h"
 #include <sys/param.h>
@@ -38,6 +38,7 @@
 
 #include <contrib/dev/acpica/acpi.h>
 #include <dev/acpica/acpivar.h>
+#include <dev/acpica/acpi_hpet.h>
 
 ACPI_SERIAL_DECL(hpet, "ACPI HPET support");
 
@@ -58,12 +59,6 @@
 
 static char *hpet_ids[] = { "PNP0103", NULL };
 
-#define HPET_MEM_WIDTH		0x400	/* Expected memory region size */
-#define HPET_OFFSET_INFO	0	/* Location of info in region */
-#define HPET_OFFSET_PERIOD	4	/* Location of period (1/hz) */
-#define HPET_OFFSET_ENABLE	0x10	/* Location of enable word */
-#define HPET_OFFSET_VALUE	0xf0	/* Location of actual timer value */
-
 #define DEV_HPET(x)	(acpi_get_magic(x) == (uintptr_t)&acpi_hpet_devclass)
 
 struct timecounter hpet_timecounter = {
@@ -79,25 +74,25 @@
 	struct acpi_hpet_softc *sc;
 
 	sc = tc->tc_priv;
-	return (bus_read_4(sc->mem_res, HPET_OFFSET_VALUE));
+	return (bus_read_4(sc->mem_res, HPET_MAIN_COUNTER));
 }
 
 static void
 hpet_enable(struct acpi_hpet_softc *sc)
 {
 	uint32_t val;
-	
-	val = bus_read_4(sc->mem_res, HPET_OFFSET_ENABLE);
-	bus_write_4(sc->mem_res, HPET_OFFSET_ENABLE, val | 1);
+
+	val = bus_read_4(sc->mem_res, HPET_CONFIG);
+	bus_write_4(sc->mem_res, HPET_CONFIG, val | HPET_CNF_ENABLE);
 }
 
 static void
 hpet_disable(struct acpi_hpet_softc *sc)
 {
 	uint32_t val;
-	
-	val = bus_read_4(sc->mem_res, HPET_OFFSET_ENABLE);
-	bus_write_4(sc->mem_res, HPET_OFFSET_ENABLE, val & ~1);
+
+	val = bus_read_4(sc->mem_res, HPET_CONFIG);
+	bus_write_4(sc->mem_res, HPET_CONFIG, val & ~HPET_CNF_ENABLE);
 }
 
 /* Discover the HPET via the ACPI table of the same name. */
@@ -187,7 +182,7 @@
 	hpet_enable(sc);
 
 	/* Read basic statistics about the timer. */
-	val = bus_read_4(sc->mem_res, HPET_OFFSET_PERIOD);
+	val = bus_read_4(sc->mem_res, HPET_PERIOD);
 	if (val == 0) {
 		device_printf(dev, "invalid period\n");
 		hpet_disable(sc);
@@ -197,12 +192,13 @@
 
 	freq = (1000000000000000LL + val / 2) / val;
 	if (bootverbose) {
-		val = bus_read_4(sc->mem_res, HPET_OFFSET_INFO);
+		val = bus_read_4(sc->mem_res, HPET_CAPABILITIES);
 		device_printf(dev,
 		    "vend: 0x%x rev: 0x%x num: %d hz: %jd opts:%s%s\n",
-		    val >> 16, val & 0xff, (val >> 18) & 0xf, freq,
-		    ((val >> 15) & 1) ? " leg_route" : "",
-		    ((val >> 13) & 1) ? " count_size" : "");
+		    val >> 16, val & HPET_CAP_REV_ID,
+		    (val & HPET_CAP_NUM_TIM) >> 8, freq,
+		    (val & HPET_CAP_LEG_RT) ? " legacy_route" : "",
+		    (val & HPET_CAP_COUNT_SIZE) ? " 64-bit" : "");
 	}
 
 	if (testenv("debug.acpi.hpet_test"))
@@ -212,9 +208,9 @@
 	 * Don't attach if the timer never increments.  Since the spec
 	 * requires it to be at least 10 MHz, it has to change in 1 us.
 	 */
-	val = bus_read_4(sc->mem_res, HPET_OFFSET_VALUE);
+	val = bus_read_4(sc->mem_res, HPET_MAIN_COUNTER);
 	DELAY(1);
-	val2 = bus_read_4(sc->mem_res, HPET_OFFSET_VALUE);
+	val2 = bus_read_4(sc->mem_res, HPET_MAIN_COUNTER);
 	if (val == val2) {
 		device_printf(dev, "HPET never increments, disabling\n");
 		hpet_disable(sc);
@@ -278,11 +274,11 @@
 	binuptime(&b0);
 	binuptime(&b0);
 	binuptime(&b1);
-	u1 = bus_read_4(sc->mem_res, HPET_OFFSET_VALUE);
+	u1 = bus_read_4(sc->mem_res, HPET_MAIN_COUNTER);
 	for (i = 1; i < 1000; i++)
-		u2 = bus_read_4(sc->mem_res, HPET_OFFSET_VALUE);
+		u2 = bus_read_4(sc->mem_res, HPET_MAIN_COUNTER);
 	binuptime(&b2);
-	u2 = bus_read_4(sc->mem_res, HPET_OFFSET_VALUE);
+	u2 = bus_read_4(sc->mem_res, HPET_MAIN_COUNTER);
 
 	bintime_sub(&b2, &b1);
 	bintime_sub(&b1, &b0);

==== //depot/projects/toehead/sys/dev/cxgb/cxgb_main.c#4 (text+ko) ====

@@ -28,7 +28,7 @@
 ***************************************************************************/
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/cxgb/cxgb_main.c,v 1.46 2008/01/15 03:27:41 kmacy Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/cxgb/cxgb_main.c,v 1.47 2008/01/16 21:33:34 kmacy Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1772,15 +1772,15 @@
 		break;
 	case SIOCSIFADDR:
 	case SIOCGIFADDR:
-		PORT_LOCK(p);
 		if (ifa->ifa_addr->sa_family == AF_INET) {
+			PORT_LOCK(p);
 			ifp->if_flags |= IFF_UP;
 			if (!(ifp->if_drv_flags & IFF_DRV_RUNNING)) 
 				cxgb_init_locked(p);
 			arp_ifinit(ifp, ifa);
+			PORT_UNLOCK(p);
 		} else
 			error = ether_ioctl(ifp, command, data);
-		PORT_UNLOCK(p);
 		break;
 	case SIOCSIFFLAGS:
 		callout_drain(&p->adapter->cxgb_tick_ch);

==== //depot/projects/toehead/sys/dev/drm/drm_drv.c#2 (text+ko) ====

@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/drm/drm_drv.c,v 1.6 2006/09/07 23:04:47 anholt Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/drm/drm_drv.c,v 1.7 2008/01/16 13:54:40 remko Exp $");
 
 #include "dev/drm/drmP.h"
 #include "dev/drm/drm.h"
@@ -711,6 +711,9 @@
 		return EINVAL;
 	}
 
+	if (--priv->refs != 0)
+		goto done;
+
 	if (dev->driver.preclose != NULL)
 		dev->driver.preclose(dev, filp);
 
@@ -786,17 +789,17 @@
 	dev->buf_pgid = 0;
 #endif /* __NetBSD__  || __OpenBSD__ */
 
-	if (--priv->refs == 0) {
-		if (dev->driver.postclose != NULL)
-			dev->driver.postclose(dev, priv);
-		TAILQ_REMOVE(&dev->files, priv, link);
-		free(priv, M_DRM);
-	}
+	if (dev->driver.postclose != NULL)
+		dev->driver.postclose(dev, priv);
+
+	TAILQ_REMOVE(&dev->files, priv, link);
+	free(priv, M_DRM);
 
 	/* ========================================================
 	 * End inline drm_release
 	 */
 
+	done:
 	atomic_inc( &dev->counts[_DRM_STAT_CLOSES] );
 #ifdef __FreeBSD__
 	device_unbusy(dev->device);

==== //depot/projects/toehead/sys/dev/if_ndis/if_ndis.c#2 (text+ko) ====

@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/if_ndis/if_ndis.c,v 1.130 2007/12/09 20:14:01 thompsa Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/if_ndis/if_ndis.c,v 1.131 2008/01/17 20:11:58 jhb Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -3264,7 +3264,7 @@
 		return;
 	}
 
-	tsleep(&error, PWAIT, "ssidscan", hz * 3);
+	pause("ssidscan", hz * 3);
 	if (!NDIS_INITIALIZED(sc))
 		/* The interface was downed while we were sleeping */
 		return;

==== //depot/projects/toehead/sys/i386/i386/pmap.c#3 (text+ko) ====

@@ -75,7 +75,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/i386/pmap.c,v 1.607 2008/01/14 22:51:43 peter Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/i386/pmap.c,v 1.608 2008/01/17 18:25:52 alc Exp $");
 
 /*
  *	Manages physical address maps.
@@ -158,11 +158,7 @@
 #define PMAP_SHPGPERPROC 200
 #endif
 
-#if defined(DIAGNOSTIC)
-#define PMAP_DIAGNOSTIC
-#endif
-
-#if !defined(PMAP_DIAGNOSTIC)
+#if !defined(DIAGNOSTIC)
 #define PMAP_INLINE	__gnu89_inline
 #else
 #define PMAP_INLINE
@@ -2308,12 +2304,9 @@
 	boolean_t invlva;
 
 	va = trunc_page(va);
-#ifdef PMAP_DIAGNOSTIC
-	if (va > VM_MAX_KERNEL_ADDRESS)
-		panic("pmap_enter: toobig");
-	if ((va >= UPT_MIN_ADDRESS) && (va < UPT_MAX_ADDRESS))
-		panic("pmap_enter: invalid to pmap_enter page table pages (va: 0x%x)", va);
-#endif
+	KASSERT(va <= VM_MAX_KERNEL_ADDRESS, ("pmap_enter: toobig"));
+	KASSERT(va < UPT_MIN_ADDRESS || va >= UPT_MAX_ADDRESS,
+	    ("pmap_enter: invalid to pmap_enter page table pages (va: 0x%x)", va));
 
 	mpte = NULL;
 
@@ -2328,16 +2321,6 @@
 	if (va < VM_MAXUSER_ADDRESS) {
 		mpte = pmap_allocpte(pmap, va, M_WAITOK);
 	}
-#if 0 && defined(PMAP_DIAGNOSTIC)
-	else {
-		pd_entry_t *pdeaddr = pmap_pde(pmap, va);
-		origpte = *pdeaddr;
-		if ((origpte & PG_V) == 0) { 
-			panic("pmap_enter: invalid kernel page table page, pdir=%p, pde=%p, va=%p\n",
-				pmap->pm_pdir[PTDPTDI], origpte, va);
-		}
-	}
-#endif
 
 	pde = pmap_pde(pmap, va);
 	if ((*pde & PG_PS) != 0)
@@ -2348,7 +2331,7 @@
 	 * Page Directory table entry not valid, we need a new PT page
 	 */
 	if (pte == NULL) {
-		panic("pmap_enter: invalid page directory pdir=%#jx, va=%#x\n",
+		panic("pmap_enter: invalid page directory pdir=%#jx, va=%#x",
 			(uintmax_t)pmap->pm_pdir[PTDPTDI], va);
 	}
 
@@ -2795,8 +2778,8 @@
 		pd_entry_t srcptepaddr;
 		unsigned ptepindex;
 
-		if (addr >= UPT_MIN_ADDRESS)
-			panic("pmap_copy: invalid to pmap_copy page tables");
+		KASSERT(addr < UPT_MIN_ADDRESS,
+		    ("pmap_copy: invalid to pmap_copy page tables"));
 
 		pdnxt = (addr + NBPDR) & ~PDRMASK;
 		ptepindex = addr >> PDRSHIFT;
@@ -2816,8 +2799,8 @@
 		}
 
 		srcmpte = PHYS_TO_VM_PAGE(srcptepaddr & PG_FRAME);
-		if (srcmpte->wire_count == 0)
-			panic("pmap_copy: source page table page is unused");
+		KASSERT(srcmpte->wire_count > 0,
+		    ("pmap_copy: source page table page is unused"));
 
 		if (pdnxt > end_addr)
 			pdnxt = end_addr;

==== //depot/projects/toehead/sys/i386/isa/clock.c#2 (text+ko) ====

@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/isa/clock.c,v 1.240 2007/10/26 03:23:54 peter Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/isa/clock.c,v 1.241 2008/01/17 18:59:38 jhb Exp $");
 
 /*
  * Routines to handle clock hardware.
@@ -291,6 +291,7 @@
 		start = rdtsc();
 		end = start + (tsc_freq * n) / 1000000;
 		do {
+			cpu_spinwait();
 			now = rdtsc();
 		} while (now < end || (now > start && end < start));
 		sched_unpin();

==== //depot/projects/toehead/sys/kern/kern_rwlock.c#3 (text+ko) ====

@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/kern_rwlock.c,v 1.33 2007/12/15 23:13:31 jeff Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/kern_rwlock.c,v 1.34 2008/01/17 20:15:15 jhb Exp $");
 
 #include "opt_ddb.h"
 #include "opt_no_adaptive_rwlocks.h"
@@ -806,7 +806,7 @@
 	    (v & RW_LOCK_WRITE_WAITERS));
 	if (v & RW_LOCK_READ_WAITERS)
 		turnstile_unpend(ts, TS_EXCLUSIVE_LOCK);
-	else if (ts)
+	else
 		turnstile_disown(ts);
 	turnstile_chain_unlock(&rw->lock_object);
 out:

==== //depot/projects/toehead/sys/kern/uipc_shm.c#2 (text+ko) ====

@@ -31,9 +31,6 @@
  *
  * TODO:
  *
- * (1) Convert test utilities into regression tests and import them into
- *     src/tools/regression.
- *
  * (2) Need to export data to a userland tool via a sysctl.  Should ipcs(1)
  *     and ipcrm(1) be expanded or should new tools to manage both POSIX
  *     kernel semaphores and POSIX shared memory be written?
@@ -52,7 +49,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/uipc_shm.c,v 1.1 2008/01/08 21:58:15 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/uipc_shm.c,v 1.2 2008/01/16 15:51:23 jhb Exp $");
 
 #include "opt_mac.h"
 

==== //depot/projects/toehead/sys/net/if_bridge.c#3 (text+ko) ====

@@ -47,11 +47,6 @@
  * 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 Jason L. Wright
- * 4. 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 ``AS IS'' AND ANY EXPRESS OR
  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
@@ -80,7 +75,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/net/if_bridge.c,v 1.109 2007/12/18 09:13:04 thompsa Exp $");
+__FBSDID("$FreeBSD: src/sys/net/if_bridge.c,v 1.110 2008/01/17 09:46:16 thompsa Exp $");
 
 #include "opt_inet.h"
 #include "opt_inet6.h"

==== //depot/projects/toehead/tools/tools/aac/aac_checkq.c#2 (text+ko) ====

@@ -24,7 +24,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/tools/tools/aac/aac_checkq.c,v 1.3 2005/11/06 15:47:06 maxim Exp $");
+__FBSDID("$FreeBSD: src/tools/tools/aac/aac_checkq.c,v 1.4 2008/01/17 18:59:59 emaste Exp $");
 
 #include <sys/types.h>
 #include <sys/fcntl.h>
@@ -33,6 +33,8 @@
 
 #include <errno.h>
 #include <stdio.h>
+#include <stdlib.h>
+#include <strings.h>
 
 /*
  * Simple program to print out the queue stats on the given queue index.

==== //depot/projects/toehead/usr.bin/systat/cmds.c#2 (text+ko) ====

@@ -33,7 +33,7 @@
 
 #include <sys/cdefs.h>
 
-__FBSDID("$FreeBSD: src/usr.bin/systat/cmds.c,v 1.5 2003/01/04 21:58:25 phk Exp $");
+__FBSDID("$FreeBSD: src/usr.bin/systat/cmds.c,v 1.6 2008/01/16 19:27:42 delphij Exp $");
 
 #ifdef lint
 static const char sccsid[] = "@(#)cmds.c	8.2 (Berkeley) 4/29/95";
@@ -49,8 +49,7 @@
 #include "extern.h"
 
 void
-command(cmd)
-        const char *cmd;
+command(const char *cmd)
 {
         struct cmdtab *p;
         char *cp, *tmpstr, *tmpstr1;
@@ -150,8 +149,7 @@
 }
 
 struct cmdtab *
-lookup(name)
-	const char *name;
+lookup(const char *name)
 {
 	const char *p, *q;
 	struct cmdtab *ct, *found;
@@ -179,7 +177,7 @@
 }
 
 void
-status()
+status(void)
 {
 
         error("Showing %s, refresh every %d seconds.",
@@ -187,8 +185,7 @@
 }
 
 int
-prefix(s1, s2)
-        const char *s1, *s2;
+prefix(const char *s1, const char *s2)
 {
 
         while (*s1 == *s2) {

==== //depot/projects/toehead/usr.bin/systat/convtbl.c#2 (text+ko) ====

@@ -25,7 +25,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $FreeBSD: src/usr.bin/systat/convtbl.c,v 1.12 2007/01/18 09:24:08 ru Exp $
+ * $FreeBSD: src/usr.bin/systat/convtbl.c,v 1.13 2008/01/16 19:27:42 delphij Exp $
  */
 
 #include <sys/types.h>
@@ -126,7 +126,7 @@
 }
 
 const char *
-get_helplist()
+get_helplist(void)
 {
 	int i;
 	size_t len;

==== //depot/projects/toehead/usr.bin/systat/devs.c#2 (text+ko) ====

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



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