Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Oct 2010 20:02:18 +0000 (UTC)
From:      Dimitry Andric <dim@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r214220 - in projects/binutils-2.17: . contrib/top lib/libc/gen lib/libc/include lib/libc/stdlib lib/libc/sys lib/libgeom lib/libthr lib/libthr/thread libexec/rtld-elf libexec/rtld-elf/...
Message-ID:  <201010222002.o9MK2I2b064696@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dim
Date: Fri Oct 22 20:02:18 2010
New Revision: 214220
URL: http://svn.freebsd.org/changeset/base/214220

Log:
  Sync: merge r214077 through r214219 from ^/head.

Added:
  projects/binutils-2.17/share/man/man9/vm_page_sleep_if_busy.9
     - copied unchanged from r214219, head/share/man/man9/vm_page_sleep_if_busy.9
  projects/binutils-2.17/sys/dev/xen/control/
     - copied from r214219, head/sys/dev/xen/control/
  projects/binutils-2.17/sys/xen/blkif.h
     - copied unchanged from r214219, head/sys/xen/blkif.h
  projects/binutils-2.17/sys/xen/xenbus/xenbus.c
     - copied unchanged from r214219, head/sys/xen/xenbus/xenbus.c
  projects/binutils-2.17/sys/xen/xenbus/xenbusb.c
     - copied unchanged from r214219, head/sys/xen/xenbus/xenbusb.c
  projects/binutils-2.17/sys/xen/xenbus/xenbusb.h
     - copied unchanged from r214219, head/sys/xen/xenbus/xenbusb.h
  projects/binutils-2.17/sys/xen/xenbus/xenbusb_back.c
     - copied unchanged from r214219, head/sys/xen/xenbus/xenbusb_back.c
  projects/binutils-2.17/sys/xen/xenbus/xenbusb_front.c
     - copied unchanged from r214219, head/sys/xen/xenbus/xenbusb_front.c
  projects/binutils-2.17/sys/xen/xenbus/xenbusb_if.m
     - copied unchanged from r214219, head/sys/xen/xenbus/xenbusb_if.m
  projects/binutils-2.17/sys/xen/xenstore/
     - copied from r214219, head/sys/xen/xenstore/
Deleted:
  projects/binutils-2.17/share/man/man9/vm_page_sleep_busy.9
  projects/binutils-2.17/sys/xen/reboot.c
  projects/binutils-2.17/sys/xen/xenbus/init.txt
  projects/binutils-2.17/sys/xen/xenbus/xenbus_client.c
  projects/binutils-2.17/sys/xen/xenbus/xenbus_comms.c
  projects/binutils-2.17/sys/xen/xenbus/xenbus_comms.h
  projects/binutils-2.17/sys/xen/xenbus/xenbus_dev.c
  projects/binutils-2.17/sys/xen/xenbus/xenbus_probe.c
  projects/binutils-2.17/sys/xen/xenbus/xenbus_probe_backend.c
  projects/binutils-2.17/sys/xen/xenbus/xenbus_xs.c
Modified:
  projects/binutils-2.17/ObsoleteFiles.inc
  projects/binutils-2.17/lib/libc/gen/pututxline.c
  projects/binutils-2.17/lib/libc/include/namespace.h
  projects/binutils-2.17/lib/libc/include/un-namespace.h
  projects/binutils-2.17/lib/libc/stdlib/strtonum.3
  projects/binutils-2.17/lib/libc/sys/getpriority.2
  projects/binutils-2.17/lib/libc/sys/pathconf.2
  projects/binutils-2.17/lib/libc/sys/stat.2
  projects/binutils-2.17/lib/libgeom/geom_ctl.c
  projects/binutils-2.17/lib/libthr/pthread.map
  projects/binutils-2.17/lib/libthr/thread/thr_private.h
  projects/binutils-2.17/lib/libthr/thread/thr_rwlock.c
  projects/binutils-2.17/lib/libthr/thread/thr_rwlockattr.c
  projects/binutils-2.17/libexec/rtld-elf/Makefile
  projects/binutils-2.17/libexec/rtld-elf/ia64/reloc.c
  projects/binutils-2.17/sbin/fsirand/fsirand.8
  projects/binutils-2.17/sbin/geom/class/eli/geli.8
  projects/binutils-2.17/sbin/geom/class/eli/geom_eli.c
  projects/binutils-2.17/sbin/hastd/hooks.c
  projects/binutils-2.17/sbin/ipfw/ipfw.8
  projects/binutils-2.17/sbin/restore/restore.8
  projects/binutils-2.17/share/man/man4/iscsi_initiator.4
  projects/binutils-2.17/share/man/man5/device.hints.5
  projects/binutils-2.17/share/man/man5/elf.5
  projects/binutils-2.17/share/man/man9/Makefile
  projects/binutils-2.17/share/man/man9/VOP_GETPAGES.9
  projects/binutils-2.17/share/man/man9/sysctl_add_oid.9
  projects/binutils-2.17/share/man/man9/vm_page_io.9
  projects/binutils-2.17/share/man/man9/vm_page_wakeup.9
  projects/binutils-2.17/sys/boot/common/gpt.c
  projects/binutils-2.17/sys/boot/i386/boot2/boot2.c
  projects/binutils-2.17/sys/conf/files
  projects/binutils-2.17/sys/dev/acpica/acpi_pci.c
  projects/binutils-2.17/sys/dev/bge/if_bge.c
  projects/binutils-2.17/sys/dev/bge/if_bgereg.h
  projects/binutils-2.17/sys/dev/iwi/if_iwi.c
  projects/binutils-2.17/sys/dev/mfi/mfireg.h
  projects/binutils-2.17/sys/dev/mvs/mvs.c
  projects/binutils-2.17/sys/dev/mvs/mvs_pci.c
  projects/binutils-2.17/sys/dev/mvs/mvs_soc.c
  projects/binutils-2.17/sys/dev/pci/pci.c
  projects/binutils-2.17/sys/dev/pci/pci_pci.c
  projects/binutils-2.17/sys/dev/pci/pci_private.h
  projects/binutils-2.17/sys/dev/pci/pcireg.h
  projects/binutils-2.17/sys/dev/pci/pcivar.h
  projects/binutils-2.17/sys/dev/sis/if_sis.c
  projects/binutils-2.17/sys/dev/xen/balloon/balloon.c
  projects/binutils-2.17/sys/dev/xen/blkback/blkback.c
  projects/binutils-2.17/sys/dev/xen/blkfront/blkfront.c
  projects/binutils-2.17/sys/dev/xen/blkfront/block.h
  projects/binutils-2.17/sys/dev/xen/netfront/netfront.c
  projects/binutils-2.17/sys/dev/xen/xenpci/evtchn.c
  projects/binutils-2.17/sys/dev/xen/xenpci/xenpci.c
  projects/binutils-2.17/sys/fs/nfsserver/nfs_nfsdport.c
  projects/binutils-2.17/sys/geom/eli/g_eli.c
  projects/binutils-2.17/sys/geom/eli/g_eli.h
  projects/binutils-2.17/sys/geom/eli/g_eli_ctl.c
  projects/binutils-2.17/sys/geom/eli/g_eli_integrity.c
  projects/binutils-2.17/sys/geom/eli/g_eli_privacy.c
  projects/binutils-2.17/sys/i386/xen/xen_machdep.c
  projects/binutils-2.17/sys/kern/kern_exec.c
  projects/binutils-2.17/sys/kern/kern_exit.c
  projects/binutils-2.17/sys/kern/kern_fork.c
  projects/binutils-2.17/sys/kern/kern_ktrace.c
  projects/binutils-2.17/sys/kern/kern_syscalls.c
  projects/binutils-2.17/sys/kern/kern_thr.c
  projects/binutils-2.17/sys/mips/rmi/board.c
  projects/binutils-2.17/sys/mips/rmi/dev/nlge/if_nlge.c
  projects/binutils-2.17/sys/mips/rmi/xlr_machdep.c
  projects/binutils-2.17/sys/net/if.c
  projects/binutils-2.17/sys/net/if.h
  projects/binutils-2.17/sys/sys/ktrace.h
  projects/binutils-2.17/sys/sys/sockio.h
  projects/binutils-2.17/sys/vm/swap_pager.c
  projects/binutils-2.17/sys/vm/vm_map.c
  projects/binutils-2.17/sys/vm/vm_map.h
  projects/binutils-2.17/sys/xen/evtchn/evtchn.c
  projects/binutils-2.17/sys/xen/gnttab.c
  projects/binutils-2.17/sys/xen/gnttab.h
  projects/binutils-2.17/sys/xen/interface/grant_table.h
  projects/binutils-2.17/sys/xen/interface/hvm/params.h
  projects/binutils-2.17/sys/xen/interface/io/blkif.h
  projects/binutils-2.17/sys/xen/interface/io/protocols.h
  projects/binutils-2.17/sys/xen/interface/io/ring.h
  projects/binutils-2.17/sys/xen/interface/io/xenbus.h
  projects/binutils-2.17/sys/xen/xen_intr.h
  projects/binutils-2.17/sys/xen/xenbus/xenbus_if.m
  projects/binutils-2.17/sys/xen/xenbus/xenbusvar.h
  projects/binutils-2.17/tools/tools/syscall_timing/syscall_timing.c
  projects/binutils-2.17/usr.bin/login/login.c
  projects/binutils-2.17/usr.bin/mesg/mesg.1
  projects/binutils-2.17/usr.bin/truss/setup.c
  projects/binutils-2.17/usr.bin/unzip/unzip.1
  projects/binutils-2.17/usr.bin/unzip/unzip.c
  projects/binutils-2.17/usr.sbin/lpr/lpr/lpr.c
  projects/binutils-2.17/usr.sbin/mfiutil/mfi_drive.c
  projects/binutils-2.17/usr.sbin/mtest/mtest.8
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend-query/disk-info.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend-query/list-components.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend-query/query-langs.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend-query/test-live.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend/functions-bsdlabel.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend/functions-cleanup.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend/functions-disk.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend/functions-extractimage.sh
  projects/binutils-2.17/usr.sbin/pc-sysinstall/backend/functions.sh
Directory Properties:
  projects/binutils-2.17/   (props changed)
  projects/binutils-2.17/cddl/contrib/opensolaris/   (props changed)
  projects/binutils-2.17/contrib/bind9/   (props changed)
  projects/binutils-2.17/contrib/binutils/   (props changed)
  projects/binutils-2.17/contrib/bzip2/   (props changed)
  projects/binutils-2.17/contrib/ee/   (props changed)
  projects/binutils-2.17/contrib/expat/   (props changed)
  projects/binutils-2.17/contrib/file/   (props changed)
  projects/binutils-2.17/contrib/gdb/   (props changed)
  projects/binutils-2.17/contrib/gdtoa/   (props changed)
  projects/binutils-2.17/contrib/gnu-sort/   (props changed)
  projects/binutils-2.17/contrib/groff/   (props changed)
  projects/binutils-2.17/contrib/less/   (props changed)
  projects/binutils-2.17/contrib/libpcap/   (props changed)
  projects/binutils-2.17/contrib/llvm/   (props changed)
  projects/binutils-2.17/contrib/llvm/tools/clang/   (props changed)
  projects/binutils-2.17/contrib/ncurses/   (props changed)
  projects/binutils-2.17/contrib/netcat/   (props changed)
  projects/binutils-2.17/contrib/ntp/   (props changed)
  projects/binutils-2.17/contrib/one-true-awk/   (props changed)
  projects/binutils-2.17/contrib/openbsm/   (props changed)
  projects/binutils-2.17/contrib/openpam/   (props changed)
  projects/binutils-2.17/contrib/pf/   (props changed)
  projects/binutils-2.17/contrib/sendmail/   (props changed)
  projects/binutils-2.17/contrib/tcpdump/   (props changed)
  projects/binutils-2.17/contrib/tcsh/   (props changed)
  projects/binutils-2.17/contrib/top/   (props changed)
  projects/binutils-2.17/contrib/top/install-sh   (props changed)
  projects/binutils-2.17/contrib/tzcode/stdtime/   (props changed)
  projects/binutils-2.17/contrib/tzcode/zic/   (props changed)
  projects/binutils-2.17/contrib/tzdata/   (props changed)
  projects/binutils-2.17/contrib/wpa/   (props changed)
  projects/binutils-2.17/contrib/xz/   (props changed)
  projects/binutils-2.17/crypto/openssh/   (props changed)
  projects/binutils-2.17/crypto/openssl/   (props changed)
  projects/binutils-2.17/lib/libc/   (props changed)
  projects/binutils-2.17/lib/libc/stdtime/   (props changed)
  projects/binutils-2.17/lib/libutil/   (props changed)
  projects/binutils-2.17/lib/libz/   (props changed)
  projects/binutils-2.17/sbin/   (props changed)
  projects/binutils-2.17/sbin/ipfw/   (props changed)
  projects/binutils-2.17/share/mk/bsd.arch.inc.mk   (props changed)
  projects/binutils-2.17/share/zoneinfo/   (props changed)
  projects/binutils-2.17/sys/   (props changed)
  projects/binutils-2.17/sys/amd64/include/xen/   (props changed)
  projects/binutils-2.17/sys/cddl/contrib/opensolaris/   (props changed)
  projects/binutils-2.17/sys/contrib/dev/acpica/   (props changed)
  projects/binutils-2.17/sys/contrib/pf/   (props changed)
  projects/binutils-2.17/sys/contrib/x86emu/   (props changed)
  projects/binutils-2.17/sys/dev/xen/xenpci/   (props changed)
  projects/binutils-2.17/usr.bin/calendar/   (props changed)
  projects/binutils-2.17/usr.bin/csup/   (props changed)
  projects/binutils-2.17/usr.bin/procstat/   (props changed)
  projects/binutils-2.17/usr.sbin/zic/   (props changed)

Modified: projects/binutils-2.17/ObsoleteFiles.inc
==============================================================================
--- projects/binutils-2.17/ObsoleteFiles.inc	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/ObsoleteFiles.inc	Fri Oct 22 20:02:18 2010	(r214220)
@@ -14,6 +14,8 @@
 # The file is partitioned: OLD_FILES first, then OLD_LIBS and OLD_DIRS last.
 #
 
+# 20101020: catch up with vm_page_sleep_if_busy rename
+OLD_FILES+=usr/share/man/man9/vm_page_sleep_busy.9.gz
 # 20101011: removed subblock.h from liblzma
 OLD_FILES+=usr/include/lzma/subblock.h
 # 20101002: removed manpath.config

Modified: projects/binutils-2.17/lib/libc/gen/pututxline.c
==============================================================================
--- projects/binutils-2.17/lib/libc/gen/pututxline.c	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libc/gen/pututxline.c	Fri Oct 22 20:02:18 2010	(r214220)
@@ -65,7 +65,7 @@ futx_open(const char *file)
 	return (fp);
 }
 
-static void
+static int
 utx_active_add(const struct futx *fu)
 {
 	FILE *fp;
@@ -78,7 +78,7 @@ utx_active_add(const struct futx *fu)
 	 */
 	fp = futx_open(_PATH_UTX_ACTIVE);
 	if (fp == NULL)
-		return;
+		return (1);
 	while (fread(&fe, sizeof fe, 1, fp) == 1) {
 		switch (fe.fu_type) {
 		case USER_PROCESS:
@@ -110,6 +110,7 @@ utx_active_add(const struct futx *fu)
 exact:
 	fwrite(fu, sizeof *fu, 1, fp);
 	fclose(fp);
+	return (0);
 }
 
 static int
@@ -123,7 +124,7 @@ utx_active_remove(struct futx *fu)
 	 */
 	fp = futx_open(_PATH_UTX_ACTIVE);
 	if (fp == NULL)
-		return (0);
+		return (1);
 	while (fread(&fe, sizeof fe, 1, fp) == 1) {
 		switch (fe.fu_type) {
 		case USER_PROCESS:
@@ -151,7 +152,7 @@ utx_active_purge(void)
 	truncate(_PATH_UTX_ACTIVE, 0);
 }
 
-static void
+static int
 utx_lastlogin_add(const struct futx *fu)
 {
 	FILE *fp;
@@ -164,7 +165,7 @@ utx_lastlogin_add(const struct futx *fu)
 	 */
 	fp = futx_open(_PATH_UTX_LASTLOGIN);
 	if (fp == NULL)
-		return;
+		return (1);
 	while (fread(&fe, sizeof fe, 1, fp) == 1) {
 		if (strncmp(fu->fu_user, fe.fu_user, sizeof fe.fu_user) != 0)
 			continue;
@@ -175,6 +176,7 @@ utx_lastlogin_add(const struct futx *fu)
 	}
 	fwrite(fu, sizeof *fu, 1, fp);
 	fclose(fp);
+	return (0);
 }
 
 static void
@@ -197,7 +199,7 @@ utx_lastlogin_upgrade(void)
 	_close(fd);
 }
 
-static void
+static int
 utx_log_add(const struct futx *fu)
 {
 	int fd;
@@ -219,15 +221,17 @@ utx_log_add(const struct futx *fu)
 
 	fd = _open(_PATH_UTX_LOG, O_CREAT|O_WRONLY|O_APPEND, 0644);
 	if (fd < 0)
-		return;
+		return (1);
 	_writev(fd, vec, 2);
 	_close(fd);
+	return (0);
 }
 
 struct utmpx *
 pututxline(const struct utmpx *utmpx)
 {
 	struct futx fu;
+	int bad = 0;
 
 	utx_to_futx(utmpx, &fu);
 	
@@ -241,16 +245,21 @@ pututxline(const struct utmpx *utmpx)
 	case NEW_TIME:
 		break;
 	case USER_PROCESS:
-		utx_active_add(&fu);
-		utx_lastlogin_add(&fu);
+		bad |= utx_active_add(&fu);
+		bad |= utx_lastlogin_add(&fu);
 		break;
 #if 0 /* XXX: Are these records of any use to us? */
 	case INIT_PROCESS:
 	case LOGIN_PROCESS:
-		utx_active_add(&fu);
+		bad |= utx_active_add(&fu);
 		break;
 #endif
 	case DEAD_PROCESS:
+		/*
+		 * In case writing a logout entry fails, never attempt
+		 * to write it to utx.log.  The logout entry's ut_id
+		 * might be invalid.
+		 */
 		if (utx_active_remove(&fu) != 0)
 			return (NULL);
 		break;
@@ -258,6 +267,6 @@ pututxline(const struct utmpx *utmpx)
 		return (NULL);
 	}
 
-	utx_log_add(&fu);
-	return (futx_to_utx(&fu));
+	bad |= utx_log_add(&fu);
+	return (bad ? NULL : futx_to_utx(&fu));
 }

Modified: projects/binutils-2.17/lib/libc/include/namespace.h
==============================================================================
--- projects/binutils-2.17/lib/libc/include/namespace.h	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libc/include/namespace.h	Fri Oct 22 20:02:18 2010	(r214220)
@@ -177,10 +177,8 @@
 #define		pthread_rwlock_unlock		_pthread_rwlock_unlock
 #define		pthread_rwlock_wrlock		_pthread_rwlock_wrlock
 #define		pthread_rwlockattr_destroy	_pthread_rwlockattr_destroy
-#define		pthread_rwlockattr_getkind_np	_pthread_rwlockattr_getkind_np
 #define		pthread_rwlockattr_getpshared	_pthread_rwlockattr_getpshared
 #define		pthread_rwlockattr_init		_pthread_rwlockattr_init
-#define		pthread_rwlockattr_setkind_np	_pthread_rwlockattr_setkind_np
 #define		pthread_rwlockattr_setpshared	_pthread_rwlockattr_setpshared
 #define		pthread_self			_pthread_self
 #define		pthread_set_name_np		_pthread_set_name_np

Modified: projects/binutils-2.17/lib/libc/include/un-namespace.h
==============================================================================
--- projects/binutils-2.17/lib/libc/include/un-namespace.h	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libc/include/un-namespace.h	Fri Oct 22 20:02:18 2010	(r214220)
@@ -158,10 +158,8 @@
 #undef		pthread_rwlock_unlock
 #undef		pthread_rwlock_wrlock
 #undef		pthread_rwlockattr_destroy
-#undef		pthread_rwlockattr_getkind_np
 #undef		pthread_rwlockattr_getpshared
 #undef		pthread_rwlockattr_init
-#undef		pthread_rwlockattr_setkind_np
 #undef		pthread_rwlockattr_setpshared
 #undef		pthread_self
 #undef		pthread_set_name_np

Modified: projects/binutils-2.17/lib/libc/stdlib/strtonum.3
==============================================================================
--- projects/binutils-2.17/lib/libc/stdlib/strtonum.3	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libc/stdlib/strtonum.3	Fri Oct 22 20:02:18 2010	(r214220)
@@ -12,7 +12,7 @@
 .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 .\"
-.\" $OpenBSD: strtonum.3,v 1.12 2005/10/26 11:37:58 jmc Exp $
+.\" $OpenBSD: strtonum.3,v 1.13 2006/04/25 05:15:42 tedu Exp $
 .\" $FreeBSD$
 .\"
 .Dd April 29, 2004
@@ -23,7 +23,6 @@
 .Nd "reliably convert string value to an integer"
 .Sh SYNOPSIS
 .In stdlib.h
-.In limits.h
 .Ft long long
 .Fo strtonum
 .Fa "const char *nptr"

Modified: projects/binutils-2.17/lib/libc/sys/getpriority.2
==============================================================================
--- projects/binutils-2.17/lib/libc/sys/getpriority.2	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libc/sys/getpriority.2	Fri Oct 22 20:02:18 2010	(r214220)
@@ -129,10 +129,10 @@ or
 .Dv PRIO_USER .
 .El
 .Pp
-.Bl -tag -width Er
 In addition to the errors indicated above,
 .Fn setpriority
 will fail if:
+.Bl -tag -width Er
 .It Bq Er EPERM
 A process was located, but neither its effective nor real user
 ID matched the effective user ID of the caller.

Modified: projects/binutils-2.17/lib/libc/sys/pathconf.2
==============================================================================
--- projects/binutils-2.17/lib/libc/sys/pathconf.2	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libc/sys/pathconf.2	Fri Oct 22 20:02:18 2010	(r214220)
@@ -89,7 +89,6 @@ returns information about the file the l
 The available values are as follows:
 .Pp
 .Bl -tag -width 6n
-.Pp
 .It Li _PC_LINK_MAX
 The maximum file link count.
 .It Li _PC_MAX_CANON
@@ -234,11 +233,11 @@ Too many symbolic links were encountered
 An I/O error occurred while reading from or writing to the file system.
 .El
 .Pp
-.Bl -tag -width Er
 The
 .Fn fpathconf
 system call
 will fail if:
+.Bl -tag -width Er
 .It Bq Er EBADF
 The
 .Fa fd

Modified: projects/binutils-2.17/lib/libc/sys/stat.2
==============================================================================
--- projects/binutils-2.17/lib/libc/sys/stat.2	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libc/sys/stat.2	Fri Oct 22 20:02:18 2010	(r214220)
@@ -345,10 +345,10 @@ represented correctly in the structure p
 .Fa sb .
 .El
 .Pp
-.Bl -tag -width Er
 The
 .Fn fstat
 system call will fail if:
+.Bl -tag -width Er
 .It Bq Er EBADF
 The
 .Fa fd

Modified: projects/binutils-2.17/lib/libgeom/geom_ctl.c
==============================================================================
--- projects/binutils-2.17/lib/libgeom/geom_ctl.c	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libgeom/geom_ctl.c	Fri Oct 22 20:02:18 2010	(r214220)
@@ -54,7 +54,7 @@ static char nomemmsg[] = "Could not allo
 void
 gctl_dump(struct gctl_req *req, FILE *f)
 {
-	u_int i;
+	unsigned int i;
 	int j;
 	struct gctl_req_arg *ap;
 
@@ -126,10 +126,8 @@ gctl_check_alloc(struct gctl_req *req, v
 struct gctl_req *
 gctl_get_handle(void)
 {
-	struct gctl_req *rp;
 
-	rp = calloc(1, sizeof *rp);
-	return (rp);
+	return (calloc(1, sizeof(struct gctl_req)));
 }
 
 /*
@@ -152,8 +150,9 @@ gctl_new_arg(struct gctl_req *req)
 	return (ap);
 }
 
-void
-gctl_ro_param(struct gctl_req *req, const char *name, int len, const void* value)
+static void
+gctl_param_add(struct gctl_req *req, const char *name, int len, void *value,
+    int flag)
 {
 	struct gctl_req_arg *ap;
 
@@ -167,8 +166,8 @@ gctl_ro_param(struct gctl_req *req, cons
 	if (ap->name == NULL)
 		return;
 	ap->nlen = strlen(ap->name) + 1;
-	ap->value = __DECONST(void *, value);
-	ap->flag = GCTL_PARAM_RD;
+	ap->value = value;
+	ap->flag = flag;
 	if (len >= 0)
 		ap->len = len;
 	else if (len < 0) {
@@ -178,26 +177,17 @@ gctl_ro_param(struct gctl_req *req, cons
 }
 
 void
-gctl_rw_param(struct gctl_req *req, const char *name, int len, void* value)
+gctl_ro_param(struct gctl_req *req, const char *name, int len, const void* value)
 {
-	struct gctl_req_arg *ap;
 
-	if (req == NULL || req->error != NULL)
-		return;
-	ap = gctl_new_arg(req);
-	if (ap == NULL)
-		return;
-	ap->name = strdup(name);
-	gctl_check_alloc(req, ap->name);
-	if (ap->name == NULL)
-		return;
-	ap->nlen = strlen(ap->name) + 1;
-	ap->value = value;
-	ap->flag = GCTL_PARAM_RW;
-	if (len >= 0)
-		ap->len = len;
-	else if (len < 0)
-		ap->len = strlen(value) + 1;	
+	gctl_param_add(req, name, len, __DECONST(void *, value), GCTL_PARAM_RD);
+}
+
+void
+gctl_rw_param(struct gctl_req *req, const char *name, int len, void *value)
+{
+
+	gctl_param_add(req, name, len, value, GCTL_PARAM_RW);
 }
 
 const char *
@@ -233,7 +223,7 @@ gctl_issue(struct gctl_req *req)
 void
 gctl_free(struct gctl_req *req)
 {
-	u_int i;
+	unsigned int i;
 
 	if (req == NULL)
 		return;

Modified: projects/binutils-2.17/lib/libthr/pthread.map
==============================================================================
--- projects/binutils-2.17/lib/libthr/pthread.map	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libthr/pthread.map	Fri Oct 22 20:02:18 2010	(r214220)
@@ -318,9 +318,7 @@ FBSDprivate_1.0 {
 	_pthread_rwlock_wrlock;
 	_pthread_rwlockattr_destroy;
 	_pthread_rwlockattr_getpshared;
-	_pthread_rwlockattr_getkind_np;
 	_pthread_rwlockattr_init;
-	_pthread_rwlockattr_setkind_np;
 	_pthread_rwlockattr_setpshared;
 	_pthread_self;
 	_pthread_set_name_np;
@@ -403,8 +401,6 @@ FBSD_1.1 {
 
 FBSD_1.2 {
 	openat;
-	pthread_rwlockattr_getkind_np;
-	pthread_rwlockattr_setkind_np;
 	setcontext;
 	swapcontext;
 };

Modified: projects/binutils-2.17/lib/libthr/thread/thr_private.h
==============================================================================
--- projects/binutils-2.17/lib/libthr/thread/thr_private.h	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libthr/thread/thr_private.h	Fri Oct 22 20:02:18 2010	(r214220)
@@ -285,14 +285,11 @@ struct pthread_prio {
 
 struct pthread_rwlockattr {
 	int		pshared;
-	int		kind;
 };
 
 struct pthread_rwlock {
 	struct urwlock 	lock;
 	struct pthread	*owner;
-	int	recurse;
-	int	kind;
 };
 
 /*

Modified: projects/binutils-2.17/lib/libthr/thread/thr_rwlock.c
==============================================================================
--- projects/binutils-2.17/lib/libthr/thread/thr_rwlock.c	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libthr/thread/thr_rwlock.c	Fri Oct 22 20:02:18 2010	(r214220)
@@ -63,19 +63,13 @@ __weak_reference(_pthread_rwlock_timedwr
  */
 
 static int
-rwlock_init(pthread_rwlock_t *rwlock, const pthread_rwlockattr_t *attr)
+rwlock_init(pthread_rwlock_t *rwlock, const pthread_rwlockattr_t *attr __unused)
 {
 	pthread_rwlock_t prwlock;
 
 	prwlock = (pthread_rwlock_t)calloc(1, sizeof(struct pthread_rwlock));
 	if (prwlock == NULL)
 		return (ENOMEM);
-	if (attr != NULL)
-		prwlock->kind = (*attr)->kind;
-	else
-		prwlock->kind = PTHREAD_RWLOCK_DEFAULT_NP;
-	if (prwlock->kind == PTHREAD_RWLOCK_PREFER_READER_NP)
-		prwlock->lock.rw_flags |= URWLOCK_PREFER_READER;
 	*rwlock = prwlock;
 	return (0);
 }
@@ -118,7 +112,7 @@ init_static(struct pthread *thread, pthr
 }
 
 int
-_pthread_rwlock_init(pthread_rwlock_t *rwlock, const pthread_rwlockattr_t *attr)
+_pthread_rwlock_init (pthread_rwlock_t *rwlock, const pthread_rwlockattr_t *attr)
 {
 	*rwlock = NULL;
 	return (rwlock_init(rwlock, attr));
@@ -266,14 +260,6 @@ rwlock_wrlock_common (pthread_rwlock_t *
 
 	CHECK_AND_INIT_RWLOCK
 
-	if (__predict_false(prwlock->owner == curthread)) {
-		if (__predict_false(
-			prwlock->kind == PTHREAD_RWLOCK_PREFER_WRITER_NP)) {
-			prwlock->recurse++;
-			return (0);
-		}
-	}
-
 	/*
 	 * POSIX said the validity of the abstimeout parameter need
 	 * not be checked if the lock can be immediately acquired.
@@ -349,13 +335,6 @@ _pthread_rwlock_unlock (pthread_rwlock_t
 	if (state & URWLOCK_WRITE_OWNER) {
 		if (__predict_false(prwlock->owner != curthread))
 			return (EPERM);
-		if (__predict_false(
-			prwlock->kind == PTHREAD_RWLOCK_PREFER_WRITER_NP)) {
-			if (prwlock->recurse > 0) {
-				prwlock->recurse--;
-				return (0);
-			}
-		}
 		prwlock->owner = NULL;
 	}
 

Modified: projects/binutils-2.17/lib/libthr/thread/thr_rwlockattr.c
==============================================================================
--- projects/binutils-2.17/lib/libthr/thread/thr_rwlockattr.c	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/lib/libthr/thread/thr_rwlockattr.c	Fri Oct 22 20:02:18 2010	(r214220)
@@ -36,10 +36,8 @@
 
 __weak_reference(_pthread_rwlockattr_destroy, pthread_rwlockattr_destroy);
 __weak_reference(_pthread_rwlockattr_getpshared, pthread_rwlockattr_getpshared);
-__weak_reference(_pthread_rwlockattr_getkind_np, pthread_rwlockattr_getkind_np);
 __weak_reference(_pthread_rwlockattr_init, pthread_rwlockattr_init);
 __weak_reference(_pthread_rwlockattr_setpshared, pthread_rwlockattr_setpshared);
-__weak_reference(_pthread_rwlockattr_setkind_np, pthread_rwlockattr_setkind_np);
 
 int
 _pthread_rwlockattr_destroy(pthread_rwlockattr_t *rwlockattr)
@@ -83,7 +81,6 @@ _pthread_rwlockattr_init(pthread_rwlocka
 		return(ENOMEM);
 
 	prwlockattr->pshared 	= PTHREAD_PROCESS_PRIVATE;
-	prwlockattr->kind	= PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP;
 	*rwlockattr		= prwlockattr;
 
 	return(0);
@@ -100,22 +97,3 @@ _pthread_rwlockattr_setpshared(pthread_r
 
 	return(0);
 }
-
-int
-_pthread_rwlockattr_setkind_np(pthread_rwlockattr_t *attr, int kind)
-{
-	if (kind != PTHREAD_RWLOCK_PREFER_READER_NP &&
-	    kind != PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP &&
-	    kind != PTHREAD_RWLOCK_PREFER_WRITER_NP) {
-		return (EINVAL);
-	}
-	(*attr)->kind = kind;
-	return (0);
-}
-
-int
-_pthread_rwlockattr_getkind_np(const pthread_rwlockattr_t *attr, int *kind)
-{
-	*kind = (*attr)->kind;
-	return (0);
-}

Modified: projects/binutils-2.17/libexec/rtld-elf/Makefile
==============================================================================
--- projects/binutils-2.17/libexec/rtld-elf/Makefile	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/libexec/rtld-elf/Makefile	Fri Oct 22 20:02:18 2010	(r214220)
@@ -34,7 +34,6 @@ LDFLAGS+=	-shared -Wl,-Bsymbolic
 DPADD=		${LIBC_PIC}
 LDADD=		-lc_pic -lssp_nonshared
 
-.if ${MACHINE_CPUARCH} != "ia64"
 .if ${MK_SYMVER} == "yes"
 LIBCDIR=	${.CURDIR}/../../lib/libc
 VERSION_DEF=	${LIBCDIR}/Versions.def
@@ -48,7 +47,6 @@ ${PROG}:	${VERSION_MAP}
 SYMBOL_MAPS+=	${.CURDIR}/${RTLD_ARCH}/Symbol.map
 .endif
 .endif
-.endif
 
 .sinclude "${.CURDIR}/${RTLD_ARCH}/Makefile.inc"
 

Modified: projects/binutils-2.17/libexec/rtld-elf/ia64/reloc.c
==============================================================================
--- projects/binutils-2.17/libexec/rtld-elf/ia64/reloc.c	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/libexec/rtld-elf/ia64/reloc.c	Fri Oct 22 20:02:18 2010	(r214220)
@@ -195,9 +195,22 @@ reloc_non_plt_obj(Obj_Entry *obj_rtld, O
 		int sym_index;
 
 		def = find_symdef(ELF_R_SYM(rela->r_info), obj, &defobj,
-				  false, cache);
-		if (def == NULL)
-			return -1;
+				  true, cache);
+		if (def == NULL) {
+			/*
+			 * XXX r_debug_state is problematic and find_symdef()
+			 * returns NULL for it. This probably has something to
+			 * do with symbol versioning (r_debug_state is in the
+			 * symbol map). If we return -1 in that case we abort
+			 * relocating rtld, which typically is fatal. So, for
+			 * now just skip the symbol when we're relocating
+			 * rtld. We don't care about r_debug_state unless we
+			 * are being debugged.
+			 */
+			if (obj != obj_rtld)
+				return -1;
+			break;
+		}
 
 		if (def->st_shndx != SHN_UNDEF) {
 			target = (Elf_Addr)(defobj->relocbase + def->st_value);

Modified: projects/binutils-2.17/sbin/fsirand/fsirand.8
==============================================================================
--- projects/binutils-2.17/sbin/fsirand/fsirand.8	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/sbin/fsirand/fsirand.8	Fri Oct 22 20:02:18 2010	(r214220)
@@ -73,8 +73,8 @@ The
 utility may be used on the root file system in single-user mode
 but the system should be rebooted via ``reboot -n'' afterwards.
 .Sh OPTIONS
-.Bl -tag -width indent
 The available options are as follows:
+.Bl -tag -width indent
 .It Fl b
 Use the default block size (usually 512 bytes) instead
 of the value gleaned from the disklabel.

Modified: projects/binutils-2.17/sbin/geom/class/eli/geli.8
==============================================================================
--- projects/binutils-2.17/sbin/geom/class/eli/geli.8	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/sbin/geom/class/eli/geli.8	Fri Oct 22 20:02:18 2010	(r214220)
@@ -24,7 +24,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd September 25, 2010
+.Dd October 20, 2010
 .Dt GELI 8
 .Os
 .Sh NAME
@@ -119,6 +119,16 @@ utility:
 .Ar file
 .Ar prov
 .Nm
+.Cm suspend
+.Op Fl v
+.Fl a | Ar prov ...
+.Nm
+.Cm resume
+.Op Fl pv
+.Op Fl j Ar passfile
+.Op Fl k Ar keyfile
+.Ar prov
+.Nm
 .Cm resize
 .Op Fl v
 .Fl s Ar oldsize
@@ -207,6 +217,8 @@ Allows to attach a provider with a rando
 partitions and temporary file systems.
 .It
 Allows to verify data integrity (data authentication).
+.It
+Allows to suspend and resume encrypted devices.
 .El
 .Pp
 The first argument to
@@ -458,6 +470,8 @@ will not be detached even if all keys wi
 It can be even rescued with the
 .Cm setkey
 subcommand.
+.Pp
+Additional options include:
 .Bl -tag -width ".Fl a Ar keyno"
 .It Fl a
 Destroy all keys (does not need
@@ -482,6 +496,8 @@ backup, your data is gone for good.
 In case the provider was attached with the
 .Fl r
 flag, the keys will not be destroyed, only the provider will be detached.
+.Pp
+Additional options include:
 .Bl -tag -width ".Fl a"
 .It Fl a
 If specified, all currently attached providers will be killed.
@@ -490,6 +506,8 @@ If specified, all currently attached pro
 Backup metadata from the given provider to the given file.
 .It Cm restore
 Restore metadata from the given file to the given provider.
+.Pp
+Additional options include:
 .Bl -tag -width ".Fl f"
 .It Fl f
 Metadata contains the size of the provider to ensure that the correct
@@ -508,12 +526,73 @@ through
 and
 .Cm restore .
 .El
+.It Cm suspend
+Suspend device by waiting for all inflight request to finish, clearing all
+sensitive informations (like keys) from the kernel memory and blocking all
+further I/O requests until the
+.Cm resume
+subcommand is executed.
+This functionality is useful for eg. laptops - when one wants to suspend a
+laptop, one does not want to leave encrypted device attached.
+Instead of closing all files and directories opened from a file system placed
+on an encrypted device, unmounting the file system and detaching the device,
+the
+.Cm suspend
+subcommand can be used.
+Any access to the encrypted device will be blocked until the keys are
+recovered through
+.Cm resume
+subcommand, thus there is no need to close nor unmount anything.
+The
+.Cm suspend
+subcommand does not work with devices created with the
+.Cm onetime
+subcommand.
+Please note that sensitive data might still be present in memory after
+suspending encrypted device, because of file system cache, etc.
+.Pp
+Additional options include:
+.Bl -tag -width ".Fl a"
+.It Fl a
+Suspend all
+.Nm
+devices.
+.El
+.It Cm resume
+Resume previously suspended device.
+The caller must ensure that executing this subcommand won't try to access
+suspended device, which will lead to a deadlock.
+For example suspending device, which contains file system where the
+.Nm
+utility is stored is bad idea.
+.Pp
+Additional options include:
+.Bl -tag -width ".Fl j Ar passfile"
+.It Fl j Ar passfile
+Specifies a file which contains the passphrase or its part.
+For more information see the description of the
+.Fl J
+option for the
+.Cm init
+subcommand.
+.It Fl k Ar keyfile
+Specifies a file which contains part of the key.
+For more information see the description of the
+.Fl K
+option for the
+.Cm init
+subcommand.
+.It Fl p
+Do not use passphrase as the key component.
+.El
 .It Cm resize
 Inform
 .Nm
 that the provider has been resized.
 The old metadata block is relocated to the correct position at the end of the
 provider and the provider size is updated.
+.Pp
+Additional options include:
 .Bl -tag -width ".Fl s Ar oldsize"
 .It Fl s Ar oldsize
 The size of the provider before it was resized.
@@ -746,6 +825,19 @@ prompt:
 # geli attach da0
 Enter passphrase: foobar
 .Ed
+.Pp
+Suspend all
+.Nm
+devices, suspend a laptop, then resume devices one by one after resuming a
+laptop:
+.Bd -literal -offset indent
+# geli suspend -a
+# zzz
+<resume your laptop>
+# geli resume -p -k keyfile gpt/secret
+# geli resume gpt/private
+Enter passphrase:
+.Ed
 .Sh ENCRYPTION MODES
 .Nm
 supports two encryption modes:

Modified: projects/binutils-2.17/sbin/geom/class/eli/geom_eli.c
==============================================================================
--- projects/binutils-2.17/sbin/geom/class/eli/geom_eli.c	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/sbin/geom/class/eli/geom_eli.c	Fri Oct 22 20:02:18 2010	(r214220)
@@ -67,6 +67,7 @@ static void eli_attach(struct gctl_req *
 static void eli_configure(struct gctl_req *req);
 static void eli_setkey(struct gctl_req *req);
 static void eli_delkey(struct gctl_req *req);
+static void eli_resume(struct gctl_req *req);
 static void eli_kill(struct gctl_req *req);
 static void eli_backup(struct gctl_req *req);
 static void eli_restore(struct gctl_req *req);
@@ -89,6 +90,8 @@ static int eli_backup_create(struct gctl
  * configure [-bB] prov ...
  * setkey [-pPv] [-n keyno] [-j passfile] [-J newpassfile] [-k keyfile] [-K newkeyfile] prov
  * delkey [-afv] [-n keyno] prov
+ * suspend [-v] -a | prov ...
+ * resume [-pv] [-j passfile] [-k keyfile] prov
  * kill [-av] [prov ...]
  * backup [-v] prov file
  * restore [-fv] file prov
@@ -198,6 +201,22 @@ struct g_command class_commands[] = {
 	    },
 	    "[-afv] [-n keyno] prov"
 	},
+	{ "suspend", G_FLAG_VERBOSE, NULL,
+	    {
+		{ 'a', "all", NULL, G_TYPE_BOOL },
+		G_OPT_SENTINEL
+	    },
+	    "[-v] -a | prov ..."
+	},
+	{ "resume", G_FLAG_VERBOSE, eli_main,
+	    {
+		{ 'j', "passfile", G_VAL_OPTIONAL, G_TYPE_STRING | G_TYPE_MULTI },
+		{ 'k', "keyfile", G_VAL_OPTIONAL, G_TYPE_STRING | G_TYPE_MULTI },
+		{ 'p', "nopassphrase", NULL, G_TYPE_BOOL },
+		G_OPT_SENTINEL
+	    },
+	    "[-pv] [-j passfile] [-k keyfile] prov"
+	},
 	{ "kill", G_FLAG_VERBOSE, eli_main,
 	    {
 		{ 'a', "all", NULL, G_TYPE_BOOL },
@@ -280,6 +299,8 @@ eli_main(struct gctl_req *req, unsigned 
 		eli_setkey(req);
 	else if (strcmp(name, "delkey") == 0)
 		eli_delkey(req);
+	else if (strcmp(name, "resume") == 0)
+		eli_resume(req);
 	else if (strcmp(name, "kill") == 0)
 		eli_kill(req);
 	else if (strcmp(name, "backup") == 0)
@@ -1118,6 +1139,44 @@ eli_delkey(struct gctl_req *req)
 		eli_delkey_detached(req, prov);
 }
 
+static void
+eli_resume(struct gctl_req *req)
+{
+	struct g_eli_metadata md;
+	unsigned char key[G_ELI_USERKEYLEN];
+	const char *prov;
+	off_t mediasize;
+	int nargs;
+
+	nargs = gctl_get_int(req, "nargs");
+	if (nargs != 1) {
+		gctl_error(req, "Invalid number of arguments.");
+		return;
+	}
+	prov = gctl_get_ascii(req, "arg0");
+
+	if (eli_metadata_read(req, prov, &md) == -1)
+		return;
+
+	mediasize = g_get_mediasize(prov);
+	if (md.md_provsize != (uint64_t)mediasize) {
+		gctl_error(req, "Provider size mismatch.");
+		return;
+	}
+
+	if (eli_genkey(req, &md, key, false) == NULL) {
+		bzero(key, sizeof(key));
+		return;
+	}
+
+	gctl_ro_param(req, "key", sizeof(key), key);
+	if (gctl_issue(req) == NULL) {
+		if (verbose)
+			printf("Resumed %s.\n", prov);
+	}
+	bzero(key, sizeof(key));
+}
+
 static int
 eli_trash_metadata(struct gctl_req *req, const char *prov, int fd, off_t offset)
 {

Modified: projects/binutils-2.17/sbin/hastd/hooks.c
==============================================================================
--- projects/binutils-2.17/sbin/hastd/hooks.c	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/sbin/hastd/hooks.c	Fri Oct 22 20:02:18 2010	(r214220)
@@ -88,32 +88,19 @@ static void hook_free(struct hookproc *h
 static void
 descriptors(void)
 {
-	long maxfd;
 	int fd;
 
 	/*
-	 * Close all descriptors.
+	 * Close all (or almost all) descriptors.
 	 */
-	maxfd = sysconf(_SC_OPEN_MAX);
-	if (maxfd < 0) {
-		pjdlog_errno(LOG_WARNING, "sysconf(_SC_OPEN_MAX) failed");
-		maxfd = 1024;
-	}
-	for (fd = 0; fd <= maxfd; fd++) {
-		switch (fd) {
-		case STDIN_FILENO:
-		case STDOUT_FILENO:
-		case STDERR_FILENO:
-			if (pjdlog_mode_get() == PJDLOG_MODE_STD)
-				break;
-			/* FALLTHROUGH */
-		default:
-			close(fd);
-			break;
-		}
-	}
-	if (pjdlog_mode_get() == PJDLOG_MODE_STD)
+	if (pjdlog_mode_get() == PJDLOG_MODE_STD) {
+		closefrom(MAX(MAX(STDIN_FILENO, STDOUT_FILENO),
+		    STDERR_FILENO) + 1);
 		return;
+	}
+
+	closefrom(0);
+
 	/*
 	 * Redirect stdin, stdout and stderr to /dev/null.
 	 */

Modified: projects/binutils-2.17/sbin/ipfw/ipfw.8
==============================================================================
--- projects/binutils-2.17/sbin/ipfw/ipfw.8	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/sbin/ipfw/ipfw.8	Fri Oct 22 20:02:18 2010	(r214220)
@@ -1009,11 +1009,11 @@ The second format
 with multiple addresses) is provided for convenience only and
 its use is discouraged.
 .It Ar addr : Oo Cm not Oc Bro
-.Bl -tag -width indent
 .Cm any | me | me6 |
 .Cm table Ns Pq Ar number Ns Op , Ns Ar value
 .Ar | addr-list | addr-set
 .Brc
+.Bl -tag -width indent
 .It Cm any
 matches any IP address.
 .It Cm me
@@ -2176,7 +2176,6 @@ Finally, the following parameters can be
 pipes and queues:
 .Pp
 .Bl -tag -width XXXX -compact
-.Pp
 .It Cm buckets Ar hash-table-size
 Specifies the size of the hash table used for storing the
 various queues.

Modified: projects/binutils-2.17/sbin/restore/restore.8
==============================================================================
--- projects/binutils-2.17/sbin/restore/restore.8	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/sbin/restore/restore.8	Fri Oct 22 20:02:18 2010	(r214220)
@@ -412,7 +412,6 @@ Most checks are self-explanatory or can 
 Common errors are given below.
 .Pp
 .Bl -tag -width Ds -compact
-.Pp
 .It <filename>: not found on tape
 The specified file name was listed in the tape directory,
 but was not found on the tape.

Modified: projects/binutils-2.17/share/man/man4/iscsi_initiator.4
==============================================================================
--- projects/binutils-2.17/share/man/man4/iscsi_initiator.4	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/share/man/man4/iscsi_initiator.4	Fri Oct 22 20:02:18 2010	(r214220)
@@ -90,8 +90,8 @@ see
 The 
 .Nm
 driver creates the following:
-.Bl -tag -width ".Pa /dev/iscsi%dxx" -compact
 .Pp
+.Bl -tag -width ".Pa /dev/iscsi%dxx" -compact
 .It Pa /dev/iscsi
 used to create new sessions.
 .It Pa /dev/iscsi%d

Modified: projects/binutils-2.17/share/man/man5/device.hints.5
==============================================================================
--- projects/binutils-2.17/share/man/man5/device.hints.5	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/share/man/man5/device.hints.5	Fri Oct 22 20:02:18 2010	(r214220)
@@ -161,7 +161,7 @@ hint.acpi.0.disabled="1"
 .Sh SEE ALSO
 .Xr kenv 1 ,
 .Xr loader.conf 5 ,
-.Xr loader 8,
+.Xr loader 8 ,
 .Xr resource_int_value 9 .
 .Sh HISTORY
 The

Modified: projects/binutils-2.17/share/man/man5/elf.5
==============================================================================
--- projects/binutils-2.17/share/man/man5/elf.5	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/share/man/man5/elf.5	Fri Oct 22 20:02:18 2010	(r214220)
@@ -462,8 +462,8 @@ member in the total struct.
 .It Dv p_type
 This member of the Phdr struct tells what kind of segment this array
 element describes or how to interpret the array element's information.
-.Bl -tag -width "PT_DYNAMIC" -compact
 .Pp
+.Bl -tag -width "PT_DYNAMIC" -compact
 .It Dv PT_NULL
 The array element is unused and the other members' values are undefined.
 This lets the program header have ignored entries.

Modified: projects/binutils-2.17/share/man/man9/Makefile
==============================================================================
--- projects/binutils-2.17/share/man/man9/Makefile	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/share/man/man9/Makefile	Fri Oct 22 20:02:18 2010	(r214220)
@@ -324,7 +324,7 @@ MAN=	accept_filter.9 \
 	vm_page_lookup.9 \
 	vm_page_protect.9 \
 	vm_page_rename.9 \
-	vm_page_sleep_busy.9 \
+	vm_page_sleep_if_busy.9 \
 	vm_page_wakeup.9 \
 	vm_page_wire.9 \
 	vm_page_zero_fill.9 \

Modified: projects/binutils-2.17/share/man/man9/VOP_GETPAGES.9
==============================================================================
--- projects/binutils-2.17/share/man/man9/VOP_GETPAGES.9	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/share/man/man9/VOP_GETPAGES.9	Fri Oct 22 20:02:18 2010	(r214220)
@@ -41,9 +41,9 @@
 .In sys/vnode.h
 .In vm/vm.h
 .Ft int
-.Fn VOP_GETPAGES "struct vnode *vp" "vm_page_t *m" "int count" "int reqpage" "vm_ooffset_t offset"
+.Fn VOP_GETPAGES "struct vnode *vp" "vm_page_t *ma" "int count" "int reqpage" "vm_ooffset_t offset"
 .Ft int
-.Fn VOP_PUTPAGES "struct vnode *vp" "vm_page_t *m" "int count" "int sync" "int *rtvals" "vm_ooffset_t offset"
+.Fn VOP_PUTPAGES "struct vnode *vp" "vm_page_t *ma" "int count" "int sync" "int *rtvals" "vm_ooffset_t offset"
 .Sh DESCRIPTION
 The
 .Fn VOP_GETPAGES
@@ -66,11 +66,11 @@ The arguments are:
 .Bl -tag -width reqpage
 .It Fa vp
 The file to access.
-.It Fa m
-Pointer to the first element of an array of contiguous pages representing a
+.It Fa ma
+Pointer to the first element of an array of pages representing a
 contiguous region of the file to be read or written.
 .It Fa count
-The number of pages in the array.
+The number of bytes that should be read into the pages of the array.
 .It Fa sync
 .Dv VM_PAGER_PUT_SYNC
 if the write should be synchronous.
@@ -123,22 +123,27 @@ The page was not handled by this request
 The
 .Fn VOP_GETPAGES
 method is expected to release any pages in
-.Fa m
+.Fa ma
 that it does not successfully handle, by calling
 .Xr vm_page_free 9 .
 When it succeeds,
 .Fn VOP_GETPAGES
-must set the valid bits appropriately, clear the dirty bit
-(using
-.Xr vm_page_undirty 9 ) ,
-either activate the page (if its wanted bit is set)
+must set the valid bits appropriately.
+.Fn VOP_GETPAGES
+must keep
+.Fa reqpage
+busy.
+It must unbusy all other successfully handled pages and put them
+on appropriate page queue(s).
+For example,
+.Fn VOP_GETPAGES
+may either activate a page (if its wanted bit is set)
 or deactivate it (otherwise), and finally call
 .Xr vm_page_wakeup 9
-to arouse any threads currently waiting for the page to be faulted in,
-for each page read.
+to arouse any threads currently waiting for the page to be faulted in.
 .Sh RETURN VALUES
 If it successfully reads
-.Fa m[reqpage] ,
+.Fa ma[reqpage] ,
 .Fn VOP_GETPAGES
 returns
 .Dv VM_PAGER_OK ;

Modified: projects/binutils-2.17/share/man/man9/sysctl_add_oid.9
==============================================================================
--- projects/binutils-2.17/share/man/man9/sysctl_add_oid.9	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/share/man/man9/sysctl_add_oid.9	Fri Oct 22 20:02:18 2010	(r214220)
@@ -411,8 +411,8 @@ and to delete them later in orderly fash
 .Pp
 There is a set of macros defined
 that helps to create oids of given type.
-.Bl -tag -width SYSCTL_ADD_STRINGXX
 They are as follows:
+.Bl -tag -width SYSCTL_ADD_STRINGXX
 .It Fn SYSCTL_ADD_OID
 creates a raw oid.
 This macro is functionally equivalent to the

Modified: projects/binutils-2.17/share/man/man9/vm_page_io.9
==============================================================================
--- projects/binutils-2.17/share/man/man9/vm_page_io.9	Fri Oct 22 19:30:56 2010	(r214219)
+++ projects/binutils-2.17/share/man/man9/vm_page_io.9	Fri Oct 22 20:02:18 2010	(r214220)
@@ -52,9 +52,9 @@ function lowers the busy count on the pa
 count is zero, a
 .Xr wakeup 9
 will be issued if the page has been marked
-.Dv PG_WANTED .
+.Dv VPO_WANTED .
 A page is typically marked
-.Dv PG_WANTED
+.Dv VPO_WANTED
 by a thread to register its interest in
 the page to either complete I/O or becoming available for general use.
 .Sh AUTHORS

Copied: projects/binutils-2.17/share/man/man9/vm_page_sleep_if_busy.9 (from r214219, head/share/man/man9/vm_page_sleep_if_busy.9)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ projects/binutils-2.17/share/man/man9/vm_page_sleep_if_busy.9	Fri Oct 22 20:02:18 2010	(r214220, copy of r214219, head/share/man/man9/vm_page_sleep_if_busy.9)
@@ -0,0 +1,68 @@
+.\"
+.\" Copyright (C) 2001 Chad David <davidc@acns.ab.ca>. All rights reserved.
+.\"
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***



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