CVS commit: src/sys/ufs

2014-05-26 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Mon May 26 18:52:50 UTC 2014

Modified Files:
src/sys/ufs/chfs: chfs_inode.h
src/sys/ufs/ufs: inode.h

Log Message:
Remove lfs-only inode flags.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/ufs/chfs/chfs_inode.h
cvs rdiff -u -r1.68 -r1.69 src/sys/ufs/ufs/inode.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/ufs/chfs/chfs_inode.h
diff -u src/sys/ufs/chfs/chfs_inode.h:1.7 src/sys/ufs/chfs/chfs_inode.h:1.8
--- src/sys/ufs/chfs/chfs_inode.h:1.7	Tue Jan 22 09:39:15 2013
+++ src/sys/ufs/chfs/chfs_inode.h	Mon May 26 18:52:50 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: chfs_inode.h,v 1.7 2013/01/22 09:39:15 dholland Exp $	*/
+/*	$NetBSD: chfs_inode.h,v 1.8 2014/05/26 18:52:50 dholland Exp $	*/
 
 /*-
  * Copyright (c) 2010 Department of Software Engineering,
@@ -121,13 +121,13 @@ struct chfs_inode
 #define	IN_MODIFY	0x2000		/* Modification time update request. */
 #define	IN_MODIFIED	0x0008		/* Inode has been modified. */
 #define	IN_ACCESSED	0x0010		/* Inode has been accessed. */
-#define	IN_RENAME	0x0020		/* Inode is being renamed. */
+/*	   unused	0x0020		/* was IN_RENAME */
 #define	IN_SHLOCK	0x0040		/* File has shared lock. */
 #define	IN_EXLOCK	0x0080		/* File has exclusive lock. */
-#define	IN_CLEANING	0x0100		/* LFS: file is being cleaned */
-#define	IN_ADIROP	0x0200		/* LFS: dirop in progress */
+/*	   unused	0x0100		/* was LFS-only IN_CLEANING */
+/*	   unused	0x0200		/* was LFS-only IN_ADIROP */
 #define	IN_SPACECOUNTED	0x0400		/* Blocks to be freed in free count. */
-#define	IN_PAGING   0x1000		/* LFS: file is on paging queue */
+/*	   unused   0x1000		/* was LFS-only IN_PAGING */
 
 
 #ifdef VTOI

Index: src/sys/ufs/ufs/inode.h
diff -u src/sys/ufs/ufs/inode.h:1.68 src/sys/ufs/ufs/inode.h:1.69
--- src/sys/ufs/ufs/inode.h:1.68	Sat May 17 19:11:40 2014
+++ src/sys/ufs/ufs/inode.h	Mon May 26 18:52:50 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: inode.h,v 1.68 2014/05/17 19:11:40 martin Exp $	*/
+/*	$NetBSD: inode.h,v 1.69 2014/05/26 18:52:50 dholland Exp $	*/
 
 /*
  * Copyright (c) 1982, 1989, 1993
@@ -238,14 +238,14 @@ struct inode {
 #define	IN_MODIFY	0x2000		/* Modification time update request. */
 #define	IN_MODIFIED	0x0008		/* Inode has been modified. */
 #define	IN_ACCESSED	0x0010		/* Inode has been accessed. */
-/* #define	IN_UNUSED	0x0020 */	/* unused, was IN_RENAME */
+/* 	   unused	0x0020 */	/* was IN_RENAME */
 #define	IN_SHLOCK	0x0040		/* File has shared lock. */
 #define	IN_EXLOCK	0x0080		/* File has exclusive lock. */
-#define	IN_CLEANING	0x0100		/* LFS: file is being cleaned */
-#define	IN_ADIROP	0x0200		/* LFS: dirop in progress */
+#define	   unused	0x0100		/* was LFS-only IN_CLEANING */
+/*	   unused	0x0200		/* was LFS-only IN_ADIROP */
 #define	IN_SPACECOUNTED	0x0400		/* Blocks to be freed in free count. */
-#define	IN_PAGING   0x1000		/* LFS: file is on paging queue */
-#define IN_CDIROP   0x4000  /* LFS: dirop completed pending i/o */
+/*	   unused   0x1000		/* was LFS-only IN_PAGING */
+/*	   unused	0x4000  /* was LFS-only IN_CDIROP */
 #if defined(_KERNEL)
 
 /*



CVS commit: src/sys/ufs/lfs

2014-05-26 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Mon May 26 18:58:32 UTC 2014

Modified Files:
src/sys/ufs/lfs: lfs_inode.h

Log Message:
remove ffs-only IN_SPACECOUNTED


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/sys/ufs/lfs/lfs_inode.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/ufs/lfs/lfs_inode.h
diff -u src/sys/ufs/lfs/lfs_inode.h:1.5 src/sys/ufs/lfs/lfs_inode.h:1.6
--- src/sys/ufs/lfs/lfs_inode.h:1.5	Tue Jun 18 08:01:00 2013
+++ src/sys/ufs/lfs/lfs_inode.h	Mon May 26 18:58:32 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: lfs_inode.h,v 1.5 2013/06/18 08:01:00 dholland Exp $	*/
+/*	$NetBSD: lfs_inode.h,v 1.6 2014/05/26 18:58:32 dholland Exp $	*/
 /*  from NetBSD: ulfs_inode.h,v 1.5 2013/06/06 00:51:50 dholland Exp  */
 /*  from NetBSD: inode.h,v 1.64 2012/11/19 00:36:21 jakllsch Exp  */
 
@@ -207,12 +207,12 @@ struct inode {
 #define	IN_MODIFY	0x2000		/* Modification time update request. */
 #define	IN_MODIFIED	0x0008		/* Inode has been modified. */
 #define	IN_ACCESSED	0x0010		/* Inode has been accessed. */
-/* #define	IN_UNUSED	0x0020 */	/* unused, was IN_RENAME */
+/* 	   unused	0x0020 */	/* was IN_RENAME */
 #define	IN_SHLOCK	0x0040		/* File has shared lock. */
 #define	IN_EXLOCK	0x0080		/* File has exclusive lock. */
 #define	IN_CLEANING	0x0100		/* LFS: file is being cleaned */
 #define	IN_ADIROP	0x0200		/* LFS: dirop in progress */
-#define	IN_SPACECOUNTED	0x0400		/* Blocks to be freed in free count. */
+/* 	   unused	0x0400		/* was FFS-only IN_SPACECOUNTED */
 #define	IN_PAGING   0x1000		/* LFS: file is on paging queue */
 #define IN_CDIROP   0x4000  /* LFS: dirop completed pending i/o */
 



CVS commit: src/sys/fs/tmpfs

2014-05-26 Thread Mindaugas Rasiukevicius
Module Name:src
Committed By:   rmind
Date:   Mon May 26 19:12:07 UTC 2014

Modified Files:
src/sys/fs/tmpfs: tmpfs_vnops.c

Log Message:
tmpfs_mknod: it is not our responsibility to call vput() on the directory
vnode, so remove it (and ensure *vpp is NULL while here).


To generate a diff of this commit:
cvs rdiff -u -r1.118 -r1.119 src/sys/fs/tmpfs/tmpfs_vnops.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/fs/tmpfs/tmpfs_vnops.c
diff -u src/sys/fs/tmpfs/tmpfs_vnops.c:1.118 src/sys/fs/tmpfs/tmpfs_vnops.c:1.119
--- src/sys/fs/tmpfs/tmpfs_vnops.c:1.118	Thu Feb 27 16:51:38 2014
+++ src/sys/fs/tmpfs/tmpfs_vnops.c	Mon May 26 19:12:07 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: tmpfs_vnops.c,v 1.118 2014/02/27 16:51:38 hannken Exp $	*/
+/*	$NetBSD: tmpfs_vnops.c,v 1.119 2014/05/26 19:12:07 rmind Exp $	*/
 
 /*
  * Copyright (c) 2005, 2006, 2007 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: tmpfs_vnops.c,v 1.118 2014/02/27 16:51:38 hannken Exp $);
+__KERNEL_RCSID(0, $NetBSD: tmpfs_vnops.c,v 1.119 2014/05/26 19:12:07 rmind Exp $);
 
 #include sys/param.h
 #include sys/dirent.h
@@ -343,7 +343,7 @@ tmpfs_mknod(void *v)
 	enum vtype vt = vap-va_type;
 
 	if (vt != VBLK  vt != VCHR  vt != VFIFO) {
-		vput(dvp);
+		*vpp = NULL;
 		return EINVAL;
 	}
 	return tmpfs_construct_node(dvp, vpp, vap, cnp, NULL);



CVS commit: src/sys/ufs

2014-05-26 Thread Ryo ONODERA
Module Name:src
Committed By:   ryoon
Date:   Mon May 26 19:12:43 UTC 2014

Modified Files:
src/sys/ufs/lfs: lfs_inode.h
src/sys/ufs/ufs: inode.h

Log Message:
Close comments


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/ufs/lfs/lfs_inode.h
cvs rdiff -u -r1.69 -r1.70 src/sys/ufs/ufs/inode.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/ufs/lfs/lfs_inode.h
diff -u src/sys/ufs/lfs/lfs_inode.h:1.6 src/sys/ufs/lfs/lfs_inode.h:1.7
--- src/sys/ufs/lfs/lfs_inode.h:1.6	Mon May 26 18:58:32 2014
+++ src/sys/ufs/lfs/lfs_inode.h	Mon May 26 19:12:43 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: lfs_inode.h,v 1.6 2014/05/26 18:58:32 dholland Exp $	*/
+/*	$NetBSD: lfs_inode.h,v 1.7 2014/05/26 19:12:43 ryoon Exp $	*/
 /*  from NetBSD: ulfs_inode.h,v 1.5 2013/06/06 00:51:50 dholland Exp  */
 /*  from NetBSD: inode.h,v 1.64 2012/11/19 00:36:21 jakllsch Exp  */
 
@@ -212,7 +212,7 @@ struct inode {
 #define	IN_EXLOCK	0x0080		/* File has exclusive lock. */
 #define	IN_CLEANING	0x0100		/* LFS: file is being cleaned */
 #define	IN_ADIROP	0x0200		/* LFS: dirop in progress */
-/* 	   unused	0x0400		/* was FFS-only IN_SPACECOUNTED */
+/* 	   unused	0x0400 */	/* was FFS-only IN_SPACECOUNTED */
 #define	IN_PAGING   0x1000		/* LFS: file is on paging queue */
 #define IN_CDIROP   0x4000  /* LFS: dirop completed pending i/o */
 

Index: src/sys/ufs/ufs/inode.h
diff -u src/sys/ufs/ufs/inode.h:1.69 src/sys/ufs/ufs/inode.h:1.70
--- src/sys/ufs/ufs/inode.h:1.69	Mon May 26 18:52:50 2014
+++ src/sys/ufs/ufs/inode.h	Mon May 26 19:12:43 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: inode.h,v 1.69 2014/05/26 18:52:50 dholland Exp $	*/
+/*	$NetBSD: inode.h,v 1.70 2014/05/26 19:12:43 ryoon Exp $	*/
 
 /*
  * Copyright (c) 1982, 1989, 1993
@@ -242,10 +242,10 @@ struct inode {
 #define	IN_SHLOCK	0x0040		/* File has shared lock. */
 #define	IN_EXLOCK	0x0080		/* File has exclusive lock. */
 #define	   unused	0x0100		/* was LFS-only IN_CLEANING */
-/*	   unused	0x0200		/* was LFS-only IN_ADIROP */
+/*	   unused	0x0200 */	/* was LFS-only IN_ADIROP */
 #define	IN_SPACECOUNTED	0x0400		/* Blocks to be freed in free count. */
-/*	   unused   0x1000		/* was LFS-only IN_PAGING */
-/*	   unused	0x4000  /* was LFS-only IN_CDIROP */
+/*	   unused   0x1000 */	/* was LFS-only IN_PAGING */
+/*	   unused	0x4000 */   /* was LFS-only IN_CDIROP */
 #if defined(_KERNEL)
 
 /*



CVS commit: src/sys/dev/pci

2014-05-26 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon May 26 19:13:20 UTC 2014

Modified Files:
src/sys/dev/pci: agp_i810.c

Log Message:
Avoid xcall(9) while cold.


To generate a diff of this commit:
cvs rdiff -u -r1.76 -r1.77 src/sys/dev/pci/agp_i810.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pci/agp_i810.c
diff -u src/sys/dev/pci/agp_i810.c:1.76 src/sys/dev/pci/agp_i810.c:1.77
--- src/sys/dev/pci/agp_i810.c:1.76	Sat May 24 14:17:29 2014
+++ src/sys/dev/pci/agp_i810.c	Mon May 26 19:13:20 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: agp_i810.c,v 1.76 2014/05/24 14:17:29 riastradh Exp $	*/
+/*	$NetBSD: agp_i810.c,v 1.77 2014/05/26 19:13:20 riastradh Exp $	*/
 
 /*-
  * Copyright (c) 2000 Doug Rabson
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: agp_i810.c,v 1.76 2014/05/24 14:17:29 riastradh Exp $);
+__KERNEL_RCSID(0, $NetBSD: agp_i810.c,v 1.77 2014/05/26 19:13:20 riastradh Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -203,7 +203,19 @@ agp_i810_chipset_flush(struct agp_i810_s
 		break;
 	case CHIP_I830:
 	case CHIP_I855:
-		xc_wait(xc_broadcast(0, agp_flush_cache_xc, NULL, NULL));
+		/*
+		 * Flush all CPU caches.  If we're cold, we can't run
+		 * xcalls, but there should be only one CPU up, so
+		 * flushing only the local CPU's cache should suffice.
+		 *
+		 * XXX Come to think of it, do these chipsets appear in
+		 * any multi-CPU systems?
+		 */
+		if (cold)
+			agp_flush_cache();
+		else
+			xc_wait(xc_broadcast(0, agp_flush_cache_xc,
+NULL, NULL));
 		WRITE4(AGP_I830_HIC, READ4(AGP_I830_HIC) | __BIT(31));
 		while (ISSET(READ4(AGP_I830_HIC), __BIT(31))) {
 			if (timo-- == 0)



CVS commit: src/sys/dev/pci

2014-05-26 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Mon May 26 19:15:39 UTC 2014

Modified Files:
src/sys/dev/pci: agp_i810.c

Log Message:
Use correct address for 64-bit flush page config register.


To generate a diff of this commit:
cvs rdiff -u -r1.77 -r1.78 src/sys/dev/pci/agp_i810.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pci/agp_i810.c
diff -u src/sys/dev/pci/agp_i810.c:1.77 src/sys/dev/pci/agp_i810.c:1.78
--- src/sys/dev/pci/agp_i810.c:1.77	Mon May 26 19:13:20 2014
+++ src/sys/dev/pci/agp_i810.c	Mon May 26 19:15:39 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: agp_i810.c,v 1.77 2014/05/26 19:13:20 riastradh Exp $	*/
+/*	$NetBSD: agp_i810.c,v 1.78 2014/05/26 19:15:39 riastradh Exp $	*/
 
 /*-
  * Copyright (c) 2000 Doug Rabson
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: agp_i810.c,v 1.77 2014/05/26 19:13:20 riastradh Exp $);
+__KERNEL_RCSID(0, $NetBSD: agp_i810.c,v 1.78 2014/05/26 19:15:39 riastradh Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -868,9 +868,9 @@ agp_i810_detach(struct agp_softc *sc)
 AGP_I915_IFPADDR, 0);
 			} else {
 pci_conf_write(sc-as_pc, sc-as_tag,
-AGP_I915_IFPADDR, 0);
+AGP_I965_IFPADDR, 0);
 pci_conf_write(sc-as_pc, sc-as_tag,
-AGP_I915_IFPADDR + 4, 0);
+AGP_I965_IFPADDR + 4, 0);
 			}
 			isc-flush_addr = 0;
 			bus_space_free(isc-flush_bst, isc-flush_bsh,



CVS commit: src/sys/ufs

2014-05-26 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Mon May 26 19:16:39 UTC 2014

Modified Files:
src/sys/ufs/chfs: chfs_inode.h
src/sys/ufs/ufs: inode.h

Log Message:
Fix previous. Anyone have a brown paper bag?


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/ufs/chfs/chfs_inode.h
cvs rdiff -u -r1.70 -r1.71 src/sys/ufs/ufs/inode.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/ufs/chfs/chfs_inode.h
diff -u src/sys/ufs/chfs/chfs_inode.h:1.8 src/sys/ufs/chfs/chfs_inode.h:1.9
--- src/sys/ufs/chfs/chfs_inode.h:1.8	Mon May 26 18:52:50 2014
+++ src/sys/ufs/chfs/chfs_inode.h	Mon May 26 19:16:39 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: chfs_inode.h,v 1.8 2014/05/26 18:52:50 dholland Exp $	*/
+/*	$NetBSD: chfs_inode.h,v 1.9 2014/05/26 19:16:39 dholland Exp $	*/
 
 /*-
  * Copyright (c) 2010 Department of Software Engineering,
@@ -121,13 +121,13 @@ struct chfs_inode
 #define	IN_MODIFY	0x2000		/* Modification time update request. */
 #define	IN_MODIFIED	0x0008		/* Inode has been modified. */
 #define	IN_ACCESSED	0x0010		/* Inode has been accessed. */
-/*	   unused	0x0020		/* was IN_RENAME */
+/*	   unused	0x0020 */	/* was IN_RENAME */
 #define	IN_SHLOCK	0x0040		/* File has shared lock. */
 #define	IN_EXLOCK	0x0080		/* File has exclusive lock. */
-/*	   unused	0x0100		/* was LFS-only IN_CLEANING */
-/*	   unused	0x0200		/* was LFS-only IN_ADIROP */
+/*	   unused	0x0100 */	/* was LFS-only IN_CLEANING */
+/*	   unused	0x0200 */	/* was LFS-only IN_ADIROP */
 #define	IN_SPACECOUNTED	0x0400		/* Blocks to be freed in free count. */
-/*	   unused   0x1000		/* was LFS-only IN_PAGING */
+/*	   unused   0x1000 */	/* was LFS-only IN_PAGING */
 
 
 #ifdef VTOI

Index: src/sys/ufs/ufs/inode.h
diff -u src/sys/ufs/ufs/inode.h:1.70 src/sys/ufs/ufs/inode.h:1.71
--- src/sys/ufs/ufs/inode.h:1.70	Mon May 26 19:12:43 2014
+++ src/sys/ufs/ufs/inode.h	Mon May 26 19:16:39 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: inode.h,v 1.70 2014/05/26 19:12:43 ryoon Exp $	*/
+/*	$NetBSD: inode.h,v 1.71 2014/05/26 19:16:39 dholland Exp $	*/
 
 /*
  * Copyright (c) 1982, 1989, 1993
@@ -241,11 +241,11 @@ struct inode {
 /* 	   unused	0x0020 */	/* was IN_RENAME */
 #define	IN_SHLOCK	0x0040		/* File has shared lock. */
 #define	IN_EXLOCK	0x0080		/* File has exclusive lock. */
-#define	   unused	0x0100		/* was LFS-only IN_CLEANING */
+/*	   unused	0x0100 */	/* was LFS-only IN_CLEANING */
 /*	   unused	0x0200 */	/* was LFS-only IN_ADIROP */
 #define	IN_SPACECOUNTED	0x0400		/* Blocks to be freed in free count. */
 /*	   unused   0x1000 */	/* was LFS-only IN_PAGING */
-/*	   unused	0x4000 */   /* was LFS-only IN_CDIROP */
+/*	   unused	0x4000 */	/* was LFS-only IN_CDIROP */
 #if defined(_KERNEL)
 
 /*



CVS commit: src/sys/rump/dev/lib/libmiiphy

2014-05-26 Thread Antti Kantee
Module Name:src
Committed By:   pooka
Date:   Mon May 26 19:55:53 UTC 2014

Modified Files:
src/sys/rump/dev/lib/libmiiphy: Makefile

Log Message:
mvphy is not configured, so don't try to build it


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/rump/dev/lib/libmiiphy/Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/rump/dev/lib/libmiiphy/Makefile
diff -u src/sys/rump/dev/lib/libmiiphy/Makefile:1.1 src/sys/rump/dev/lib/libmiiphy/Makefile:1.2
--- src/sys/rump/dev/lib/libmiiphy/Makefile:1.1	Fri Apr  4 14:18:19 2014
+++ src/sys/rump/dev/lib/libmiiphy/Makefile	Mon May 26 19:55:53 2014
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.1 2014/04/04 14:18:19 pooka Exp $
+#	$NetBSD: Makefile,v 1.2 2014/05/26 19:55:53 pooka Exp $
 #
 
 RUMPTOP=${TOPRUMP}
@@ -13,7 +13,7 @@ SRCS=	phy_at_mii.c
 SRCS+= mii.c mii_ethersubr.c mii_physubr.c ukphy.c ukphy_subr.c
 SRCS+= acphy.c amhphy.c atphy.c bmtphy.c brgphy.c ciphy.c dmphy.c etphy.c \
 exphy.c gentbi.c glxtphy.c gphyter.c icsphy.c igphy.c ihphy.c ikphy.c \
-inphy.c iophy.c lxtphy.c makphy.c mvphy.c nsphy.c nsphyter.c pnaphy.c \
+inphy.c iophy.c lxtphy.c makphy.c nsphy.c nsphyter.c pnaphy.c \
 qsphy.c rdcphy.c rgephy.c rlphy.c sqphy.c tlphy.c tqphy.c urlphy.c
 
 CPPFLAGS+= -I${RUMPTOP}/librump/rumpkern -I${.CURDIR}/opt



CVS commit: src/usr.sbin/pstat

2014-05-26 Thread David A. Holland
Module Name:src
Committed By:   dholland
Date:   Mon May 26 20:07:25 UTC 2014

Modified Files:
src/usr.sbin/pstat: pstat.c

Log Message:
Don't check lfs flags on ffs vnodes.


To generate a diff of this commit:
cvs rdiff -u -r1.123 -r1.124 src/usr.sbin/pstat/pstat.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.sbin/pstat/pstat.c
diff -u src/usr.sbin/pstat/pstat.c:1.123 src/usr.sbin/pstat/pstat.c:1.124
--- src/usr.sbin/pstat/pstat.c:1.123	Mon Mar 24 13:42:41 2014
+++ src/usr.sbin/pstat/pstat.c	Mon May 26 20:07:25 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: pstat.c,v 1.123 2014/03/24 13:42:41 hannken Exp $	*/
+/*	$NetBSD: pstat.c,v 1.124 2014/05/26 20:07:25 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1980, 1991, 1993, 1994
@@ -39,7 +39,7 @@ __COPYRIGHT(@(#) Copyright (c) 1980, 19
 #if 0
 static char sccsid[] = @(#)pstat.c	8.16 (Berkeley) 5/9/95;
 #else
-__RCSID($NetBSD: pstat.c,v 1.123 2014/03/24 13:42:41 hannken Exp $);
+__RCSID($NetBSD: pstat.c,v 1.124 2014/05/26 20:07:25 dholland Exp $);
 #endif
 #endif /* not lint */
 
@@ -330,6 +330,9 @@ vnodemode(void)
 			maddr = vp-v_mount;
 			mount_print(mp);
 			vnode_header();
+			/*
+			 * XXX do this in a more fs-independent way
+			 */
 			if (FSTYPE_IS(mp, MOUNT_FFS) ||
 			FSTYPE_IS(mp, MOUNT_MFS)) {
 ufs_header();
@@ -455,8 +458,6 @@ const struct flagbit_desc ufs_flags[] = 
 	{ IN_ACCESSED,	'a' },
 	{ IN_SHLOCK,	'S' },
 	{ IN_EXLOCK,	'E' },
-	{ IN_CLEANING,	'c' },
-	{ IN_ADIROP,	'D' },
 	{ IN_SPACECOUNTED, 's' },
 	{ 0,		'\0' },
 };



CVS commit: src/sys/dev/pci

2014-05-26 Thread Thor Lancelot Simon
Module Name:src
Committed By:   tls
Date:   Tue May 27 02:21:29 UTC 2014

Modified Files:
src/sys/dev/pci: if_wm.c

Log Message:
From dyoung@ -- bump max TX DMA size to avoid pathological condition with TSO.


To generate a diff of this commit:
cvs rdiff -u -r1.268 -r1.269 src/sys/dev/pci/if_wm.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pci/if_wm.c
diff -u src/sys/dev/pci/if_wm.c:1.268 src/sys/dev/pci/if_wm.c:1.269
--- src/sys/dev/pci/if_wm.c:1.268	Sat Mar 29 19:28:25 2014
+++ src/sys/dev/pci/if_wm.c	Tue May 27 02:21:29 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_wm.c,v 1.268 2014/03/29 19:28:25 christos Exp $	*/
+/*	$NetBSD: if_wm.c,v 1.269 2014/05/27 02:21:29 tls Exp $	*/
 
 /*
  * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc.
@@ -76,7 +76,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: if_wm.c,v 1.268 2014/03/29 19:28:25 christos Exp $);
+__KERNEL_RCSID(0, $NetBSD: if_wm.c,v 1.269 2014/05/27 02:21:29 tls Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -167,7 +167,7 @@ int	wm_debug = WM_DEBUG_TX | WM_DEBUG_RX
 #define	WM_NEXTTX(sc, x)	(((x) + 1)  WM_NTXDESC_MASK(sc))
 #define	WM_NEXTTXS(sc, x)	(((x) + 1)  WM_TXQUEUELEN_MASK(sc))
 
-#define	WM_MAXTXDMA		round_page(IP_MAXPACKET) /* for TSO */
+#define	WM_MAXTXDMA		 (2 * round_page(IP_MAXPACKET)) /* for TSO */
 
 /*
  * Receive descriptor list size.  We have one Rx buffer for normal



CVS commit: src/sys/dev/pci

2014-05-26 Thread Taylor R Campbell
Module Name:src
Committed By:   riastradh
Date:   Tue May 27 03:17:33 UTC 2014

Modified Files:
src/sys/dev/pci: agp_i810.c agp_i810var.h

Log Message:
Rework agp_i810 attachment code a little.

- Fix up error branches in agp_i810_attach.

- Use a separate bus space handle for the GTT, whether it is in a
separate BAR or a subregion of the MMIO device registers, so that

(a) agp_i810_write_gtt_entry and agp_i810_post_gtt_entry are easier to
follow, and

(b) we can map the GTT prefetchable eventually.


To generate a diff of this commit:
cvs rdiff -u -r1.78 -r1.79 src/sys/dev/pci/agp_i810.c
cvs rdiff -u -r1.3 -r1.4 src/sys/dev/pci/agp_i810var.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pci/agp_i810.c
diff -u src/sys/dev/pci/agp_i810.c:1.78 src/sys/dev/pci/agp_i810.c:1.79
--- src/sys/dev/pci/agp_i810.c:1.78	Mon May 26 19:15:39 2014
+++ src/sys/dev/pci/agp_i810.c	Tue May 27 03:17:33 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: agp_i810.c,v 1.78 2014/05/26 19:15:39 riastradh Exp $	*/
+/*	$NetBSD: agp_i810.c,v 1.79 2014/05/27 03:17:33 riastradh Exp $	*/
 
 /*-
  * Copyright (c) 2000 Doug Rabson
@@ -30,7 +30,7 @@
  */
 
 #include sys/cdefs.h
-__KERNEL_RCSID(0, $NetBSD: agp_i810.c,v 1.78 2014/05/26 19:15:39 riastradh Exp $);
+__KERNEL_RCSID(0, $NetBSD: agp_i810.c,v 1.79 2014/05/27 03:17:33 riastradh Exp $);
 
 #include sys/param.h
 #include sys/systm.h
@@ -88,6 +88,7 @@ static bool agp_i810_resume(device_t, co
 static int agp_i810_init(struct agp_softc *);
 
 static int agp_i810_setup_chipset_flush_page(struct agp_softc *);
+static void agp_i810_teardown_chipset_flush_page(struct agp_softc *);
 static int agp_i810_init(struct agp_softc *);
 
 static struct agp_methods agp_i810_methods = {
@@ -107,7 +108,6 @@ int
 agp_i810_write_gtt_entry(struct agp_i810_softc *isc, off_t off, bus_addr_t v)
 {
 	u_int32_t pte;
-	bus_size_t base_off, wroff;
 
 	/* Bits 11:4 (physical start address extension) should be zero. */
 	if ((v  0xff0) != 0)
@@ -132,58 +132,18 @@ agp_i810_write_gtt_entry(struct agp_i810
 		}
 	}
 
-	base_off = 0;
-	wroff = (off  AGP_PAGE_SHIFT) * 4;
+	bus_space_write_4(isc-gtt_bst, isc-gtt_bsh,
+	4*(off  AGP_PAGE_SHIFT), pte);
 
-	switch (isc-chiptype) {
-	case CHIP_I810:
-	case CHIP_I830:
-	case CHIP_I855:
-		base_off = AGP_I810_GTT;
-		break;
-	case CHIP_I965:
-		base_off = AGP_I965_GTT;
-		break;
-	case CHIP_G4X:
-		base_off = AGP_G4X_GTT;
-		break;
-	case CHIP_I915:
-	case CHIP_G33:
-		bus_space_write_4(isc-gtt_bst, isc-gtt_bsh, wroff, pte);
-		return 0;
-	}
-
-	WRITE4(base_off + wroff, pte);
 	return 0;
 }
 
 void
 agp_i810_post_gtt_entry(struct agp_i810_softc *isc, off_t off)
 {
-	bus_size_t base_off, wroff;
-
-	base_off = 0;
-	wroff = (off  AGP_PAGE_SHIFT) * 4;
-
-	switch (isc-chiptype) {
-	case CHIP_I810:
-	case CHIP_I830:
-	case CHIP_I855:
-		base_off = AGP_I810_GTT;
-		break;
-	case CHIP_I965:
-		base_off = AGP_I965_GTT;
-		break;
-	case CHIP_G4X:
-		base_off = AGP_G4X_GTT;
-		break;
-	case CHIP_I915:
-	case CHIP_G33:
-		(void)bus_space_read_4(isc-gtt_bst, isc-gtt_bsh, wroff);
-		return;
-	}
 
-	(void)READ4(base_off + wroff);
+	(void)bus_space_read_4(isc-gtt_bst, isc-gtt_bsh,
+	4*(off  AGP_PAGE_SHIFT));
 }
 
 static void
@@ -313,14 +273,17 @@ agp_i810_attach(device_t parent, device_
 	struct agp_softc *sc = device_private(self);
 	struct agp_i810_softc *isc;
 	struct agp_gatt *gatt;
-	int error, apbase;
-	bus_addr_t mmadr;
-	bus_size_t mmadrsize;
+	int apbase, mmadr_bar, gtt_bar;
+	int mmadr_type, mmadr_flags;
+	bus_addr_t mmadr, gtt_off;
+	bus_size_t mmadr_size;
+	int error;
 
 	isc = malloc(sizeof *isc, M_AGP, M_NOWAIT|M_ZERO);
 	if (isc == NULL) {
 		aprint_error(: can't allocate chipset-specific softc\n);
-		return ENOMEM;
+		error = ENOMEM;
+		goto fail0;
 	}
 	sc-as_chipc = isc;
 	sc-as_methods = agp_i810_methods;
@@ -335,12 +298,13 @@ agp_i810_attach(device_t parent, device_
 		case PCI_PRODUCT_INTEL_82845G_DRAM:
 		case PCI_PRODUCT_INTEL_82815_FULL_HUB:
 		case PCI_PRODUCT_INTEL_82855GM_MCH:
+			free(isc, M_AGP);
 			return agp_intel_attach(parent, self, aux);
 		}
 #endif
 		aprint_error(: can't find internal VGA device config space\n);
-		free(isc, M_AGP);
-		return ENOENT;
+		error = ENOENT;
+		goto fail1;
 	}
 
 	/* XXXfvdl */
@@ -405,80 +369,129 @@ agp_i810_attach(device_t parent, device_
 		break;
 	}
 
+	mmadr_type = PCI_MAPREG_TYPE_MEM;
 	switch (isc-chiptype) {
 	case CHIP_I915:
 	case CHIP_G33:
 		apbase = AGP_I915_GMADR;
+		mmadr_bar = AGP_I915_MMADR;
+		gtt_bar = AGP_I915_GTTADR;
 		break;
 	case CHIP_I965:
+		apbase = AGP_I965_GMADR;
+		mmadr_bar = AGP_I965_MMADR;
+		mmadr_type |= PCI_MAPREG_MEM_TYPE_64BIT;
+		gtt_bar = 0;
+		gtt_off = AGP_I965_GTT;
+		break;
 	case CHIP_G4X:
 		apbase = AGP_I965_GMADR;
+		mmadr_bar = AGP_I965_MMADR;
+		mmadr_type |= PCI_MAPREG_MEM_TYPE_64BIT;
+		gtt_bar = 0;
+		gtt_off = AGP_G4X_GTT;
 		break;
 	default:
 		apbase = 

CVS commit: src/usr.sbin/cpuctl/arch

2014-05-26 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Tue May 27 04:18:01 UTC 2014

Modified Files:
src/usr.sbin/cpuctl/arch: i386.c

Log Message:
If -v is set and unknown cacheinfo desc is found, print it.


To generate a diff of this commit:
cvs rdiff -u -r1.54 -r1.55 src/usr.sbin/cpuctl/arch/i386.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.sbin/cpuctl/arch/i386.c
diff -u src/usr.sbin/cpuctl/arch/i386.c:1.54 src/usr.sbin/cpuctl/arch/i386.c:1.55
--- src/usr.sbin/cpuctl/arch/i386.c:1.54	Sat Jan  4 18:13:48 2014
+++ src/usr.sbin/cpuctl/arch/i386.c	Tue May 27 04:18:00 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: i386.c,v 1.54 2014/01/04 18:13:48 msaitoh Exp $	*/
+/*	$NetBSD: i386.c,v 1.55 2014/05/27 04:18:00 msaitoh Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2001, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -57,7 +57,7 @@
 
 #include sys/cdefs.h
 #ifndef lint
-__RCSID($NetBSD: i386.c,v 1.54 2014/01/04 18:13:48 msaitoh Exp $);
+__RCSID($NetBSD: i386.c,v 1.55 2014/05/27 04:18:00 msaitoh Exp $);
 #endif /* not lint */
 
 #include sys/types.h
@@ -997,6 +997,9 @@ intel_cpu_cacheinfo(struct cpu_info *ci)
 desc);
 if (cai != NULL)
 	ci-ci_cinfo[cai-cai_index] = *cai;
+else if (verbose)
+	printf(Unknown cacheinfo desc %02x\n,
+	desc);
 			}
 		}
 		x86_cpuid(2, descs);