Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 11 May 2012 09:34:40 +0000 (UTC)
From:      Grzegorz Bernacki <gber@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r235263 - in projects/nand: . cddl/contrib/opensolaris/cmd/zdb cddl/contrib/opensolaris/cmd/zfs cddl/contrib/opensolaris/cmd/zstreamdump cddl/contrib/opensolaris/lib/libzfs/common cddl/...
Message-ID:  <201205110934.q4B9Ye51075542@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gber
Date: Fri May 11 09:34:39 2012
New Revision: 235263
URL: http://svn.freebsd.org/changeset/base/235263

Log:
  IFC @235262

Added:
  projects/nand/share/syscons/keymaps/spanish.dvorak.kbd
     - copied unchanged from r235262, head/share/syscons/keymaps/spanish.dvorak.kbd
  projects/nand/sys/arm/conf/genboardid.awk
     - copied unchanged from r235262, head/sys/arm/conf/genboardid.awk
  projects/nand/sys/arm/conf/mach-types
     - copied unchanged from r235262, head/sys/arm/conf/mach-types
  projects/nand/sys/boot/i386/cdboot/cdboot.S
     - copied unchanged from r235262, head/sys/boot/i386/cdboot/cdboot.S
  projects/nand/sys/dev/ral/rt2860.c
     - copied unchanged from r235262, head/sys/dev/ral/rt2860.c
  projects/nand/sys/dev/ral/rt2860reg.h
     - copied unchanged from r235262, head/sys/dev/ral/rt2860reg.h
  projects/nand/sys/dev/ral/rt2860var.h
     - copied unchanged from r235262, head/sys/dev/ral/rt2860var.h
Deleted:
  projects/nand/sys/boot/i386/cdboot/cdboot.s
Modified:
  projects/nand/Makefile.inc1
  projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.8
  projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.c
  projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs.8
  projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c
  projects/nand/cddl/contrib/opensolaris/cmd/zstreamdump/zstreamdump.1
  projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs.h
  projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c
  projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c
  projects/nand/cddl/contrib/opensolaris/lib/libzpool/common/sys/zfs_context.h
  projects/nand/contrib/jemalloc/ChangeLog
  projects/nand/contrib/jemalloc/FREEBSD-Xlist
  projects/nand/contrib/jemalloc/FREEBSD-diffs
  projects/nand/contrib/jemalloc/VERSION
  projects/nand/contrib/jemalloc/doc/jemalloc.3
  projects/nand/contrib/jemalloc/include/jemalloc/internal/arena.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/atomic.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/ctl.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/mutex.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/private_namespace.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/prof.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/tcache.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/tsd.h
  projects/nand/contrib/jemalloc/include/jemalloc/internal/util.h
  projects/nand/contrib/jemalloc/include/jemalloc/jemalloc.h
  projects/nand/contrib/jemalloc/include/jemalloc/jemalloc_defs.h
  projects/nand/contrib/jemalloc/src/arena.c
  projects/nand/contrib/jemalloc/src/chunk.c
  projects/nand/contrib/jemalloc/src/chunk_mmap.c
  projects/nand/contrib/jemalloc/src/ctl.c
  projects/nand/contrib/jemalloc/src/huge.c
  projects/nand/contrib/jemalloc/src/jemalloc.c
  projects/nand/contrib/jemalloc/src/mutex.c
  projects/nand/contrib/jemalloc/src/prof.c
  projects/nand/contrib/jemalloc/src/quarantine.c
  projects/nand/contrib/jemalloc/src/stats.c
  projects/nand/contrib/jemalloc/src/tcache.c
  projects/nand/contrib/jemalloc/src/tsd.c
  projects/nand/contrib/jemalloc/src/util.c
  projects/nand/etc/mtree/BSD.usr.dist
  projects/nand/games/fortune/datfiles/freebsd-tips
  projects/nand/gnu/usr.bin/binutils/addr2line/addr2line.1
  projects/nand/gnu/usr.bin/binutils/ranlib/ranlib.1
  projects/nand/gnu/usr.bin/binutils/size/size.1
  projects/nand/gnu/usr.bin/binutils/strip/strip.1
  projects/nand/gnu/usr.bin/gdb/gdb/gdb.1
  projects/nand/lib/libc/locale/toupper.c
  projects/nand/lib/libc/stdio/fgets.3
  projects/nand/lib/libthr/thread/thr_sleepq.c
  projects/nand/sbin/geom/class/eli/geli.8
  projects/nand/sbin/md5/md5.1
  projects/nand/sbin/md5/md5.c
  projects/nand/share/man/man4/ral.4
  projects/nand/share/syscons/keymaps/Makefile
  projects/nand/sys/amd64/conf/GENERIC
  projects/nand/sys/boot/fdt/fdt_loader_cmd.c
  projects/nand/sys/boot/i386/cdboot/Makefile
  projects/nand/sys/boot/i386/loader/main.c
  projects/nand/sys/boot/i386/pxeldr/Makefile
  projects/nand/sys/boot/i386/pxeldr/pxeldr.S
  projects/nand/sys/boot/sparc64/boot1/Makefile
  projects/nand/sys/boot/sparc64/zfsboot/Makefile
  projects/nand/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c
  projects/nand/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c
  projects/nand/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu.h
  projects/nand/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_impl.h
  projects/nand/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dsl_dataset.h
  projects/nand/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c
  projects/nand/sys/cddl/contrib/opensolaris/uts/common/sys/fs/zfs.h
  projects/nand/sys/conf/files
  projects/nand/sys/conf/files.arm
  projects/nand/sys/dev/ath/ath_hal/ar5210/ar5210.h
  projects/nand/sys/dev/ath/ath_hal/ar5210/ar5210_attach.c
  projects/nand/sys/dev/ath/ath_hal/ar5210/ar5210_misc.c
  projects/nand/sys/dev/ath/ath_hal/ar5211/ar5211.h
  projects/nand/sys/dev/ath/ath_hal/ar5211/ar5211_attach.c
  projects/nand/sys/dev/ath/ath_hal/ar5211/ar5211_misc.c
  projects/nand/sys/dev/dc/if_dc.c
  projects/nand/sys/dev/e1000/if_em.c
  projects/nand/sys/dev/e1000/if_igb.c
  projects/nand/sys/dev/fxp/if_fxp.c
  projects/nand/sys/dev/hwpmc/hwpmc_intel.c
  projects/nand/sys/dev/ral/if_ral_pci.c
  projects/nand/sys/dev/re/if_re.c
  projects/nand/sys/dev/sf/if_sf.c
  projects/nand/sys/dev/usb/net/if_rue.c
  projects/nand/sys/dev/xl/if_xl.c
  projects/nand/sys/fs/ext2fs/ext2_vfsops.c
  projects/nand/sys/geom/eli/g_eli_integrity.c
  projects/nand/sys/i386/conf/GENERIC
  projects/nand/sys/modules/ral/Makefile
  projects/nand/sys/nfsclient/nfs_subs.c
  projects/nand/sys/sparc64/include/intr_machdep.h
  projects/nand/sys/sparc64/sparc64/intr_machdep.c
  projects/nand/sys/vm/vm_fault.c
  projects/nand/sys/vm/vm_map.c
  projects/nand/sys/vm/vm_map.h
  projects/nand/tools/build/mk/OptionalObsoleteFiles.inc
  projects/nand/usr.bin/calendar/calendar.1
  projects/nand/usr.bin/clang/clang/clang.1
  projects/nand/usr.bin/clang/tblgen/tblgen.1
  projects/nand/usr.bin/csup/csup.1
  projects/nand/usr.bin/fetch/fetch.1
  projects/nand/usr.bin/gprof/gprof.1
  projects/nand/usr.bin/ipcrm/ipcrm.1
  projects/nand/usr.bin/join/join.1
  projects/nand/usr.bin/limits/limits.1
  projects/nand/usr.bin/ncplogin/ncplogout.1
  projects/nand/usr.bin/tftp/tftp.1
  projects/nand/usr.bin/unzip/unzip.1
  projects/nand/usr.bin/who/who.1
  projects/nand/usr.bin/whois/whois.1
  projects/nand/usr.sbin/bsdinstall/scripts/mirrorselect
  projects/nand/usr.sbin/pkg_install/updating/pkg_updating.1
  projects/nand/usr.sbin/portsnap/portsnap/portsnap.sh
Directory Properties:
  projects/nand/   (props changed)
  projects/nand/MAINTAINERS   (props changed)
  projects/nand/cddl/contrib/opensolaris/   (props changed)
  projects/nand/contrib/bind9/   (props changed)
  projects/nand/contrib/binutils/   (props changed)
  projects/nand/contrib/bzip2/   (props changed)
  projects/nand/contrib/com_err/   (props changed)
  projects/nand/contrib/compiler-rt/   (props changed)
  projects/nand/contrib/dialog/   (props changed)
  projects/nand/contrib/ee/   (props changed)
  projects/nand/contrib/expat/   (props changed)
  projects/nand/contrib/file/   (props changed)
  projects/nand/contrib/gcc/   (props changed)
  projects/nand/contrib/gdb/   (props changed)
  projects/nand/contrib/gdtoa/   (props changed)
  projects/nand/contrib/gnu-sort/   (props changed)
  projects/nand/contrib/groff/   (props changed)
  projects/nand/contrib/less/   (props changed)
  projects/nand/contrib/libarchive/   (props changed)
  projects/nand/contrib/libarchive/cpio/   (props changed)
  projects/nand/contrib/libarchive/libarchive/   (props changed)
  projects/nand/contrib/libarchive/libarchive_fe/   (props changed)
  projects/nand/contrib/libarchive/tar/   (props changed)
  projects/nand/contrib/libc++/   (props changed)
  projects/nand/contrib/libcxxrt/   (props changed)
  projects/nand/contrib/libpcap/   (props changed)
  projects/nand/contrib/libstdc++/   (props changed)
  projects/nand/contrib/llvm/   (props changed)
  projects/nand/contrib/llvm/tools/clang/   (props changed)
  projects/nand/contrib/ncurses/   (props changed)
  projects/nand/contrib/netcat/   (props changed)
  projects/nand/contrib/ntp/   (props changed)
  projects/nand/contrib/one-true-awk/   (props changed)
  projects/nand/contrib/openbsm/   (props changed)
  projects/nand/contrib/openpam/   (props changed)
  projects/nand/contrib/openresolv/   (props changed)
  projects/nand/contrib/pf/   (props changed)
  projects/nand/contrib/sendmail/   (props changed)
  projects/nand/contrib/tcpdump/   (props changed)
  projects/nand/contrib/tcsh/   (props changed)
  projects/nand/contrib/tnftp/   (props changed)
  projects/nand/contrib/top/   (props changed)
  projects/nand/contrib/top/install-sh   (props changed)
  projects/nand/contrib/tzcode/stdtime/   (props changed)
  projects/nand/contrib/tzcode/zic/   (props changed)
  projects/nand/contrib/tzdata/   (props changed)
  projects/nand/contrib/wpa/   (props changed)
  projects/nand/contrib/xz/   (props changed)
  projects/nand/crypto/heimdal/   (props changed)
  projects/nand/crypto/openssh/   (props changed)
  projects/nand/crypto/openssl/   (props changed)
  projects/nand/gnu/lib/   (props changed)
  projects/nand/gnu/usr.bin/binutils/   (props changed)
  projects/nand/gnu/usr.bin/cc/cc_tools/   (props changed)
  projects/nand/gnu/usr.bin/gdb/   (props changed)
  projects/nand/lib/libc/   (props changed)
  projects/nand/lib/libc/stdtime/   (props changed)
  projects/nand/lib/libutil/   (props changed)
  projects/nand/lib/libz/   (props changed)
  projects/nand/sbin/   (props changed)
  projects/nand/sbin/ipfw/   (props changed)
  projects/nand/share/man/man4/   (props changed)
  projects/nand/share/mk/bsd.arch.inc.mk   (props changed)
  projects/nand/share/zoneinfo/   (props changed)
  projects/nand/sys/   (props changed)
  projects/nand/sys/amd64/include/xen/   (props changed)
  projects/nand/sys/boot/   (props changed)
  projects/nand/sys/boot/i386/efi/   (props changed)
  projects/nand/sys/boot/ia64/efi/   (props changed)
  projects/nand/sys/boot/ia64/ski/   (props changed)
  projects/nand/sys/boot/powerpc/boot1.chrp/   (props changed)
  projects/nand/sys/boot/powerpc/ofw/   (props changed)
  projects/nand/sys/cddl/contrib/opensolaris/   (props changed)
  projects/nand/sys/conf/   (props changed)
  projects/nand/sys/contrib/dev/acpica/   (props changed)
  projects/nand/sys/contrib/dev/acpica/changes.txt   (props changed)
  projects/nand/sys/contrib/dev/acpica/common/   (props changed)
  projects/nand/sys/contrib/dev/acpica/compiler/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/debugger/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/disassembler/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/dispatcher/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/events/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/executer/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/hardware/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/namespace/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/parser/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/resources/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/tables/   (props changed)
  projects/nand/sys/contrib/dev/acpica/components/utilities/   (props changed)
  projects/nand/sys/contrib/dev/acpica/include/   (props changed)
  projects/nand/sys/contrib/dev/acpica/os_specific/   (props changed)
  projects/nand/sys/contrib/octeon-sdk/   (props changed)
  projects/nand/sys/contrib/pf/   (props changed)
  projects/nand/sys/contrib/x86emu/   (props changed)
  projects/nand/sys/i386/conf/XENHVM   (props changed)
  projects/nand/usr.bin/calendar/   (props changed)
  projects/nand/usr.bin/csup/   (props changed)
  projects/nand/usr.bin/procstat/   (props changed)
  projects/nand/usr.sbin/jail/   (props changed)
  projects/nand/usr.sbin/ndiscvt/   (props changed)
  projects/nand/usr.sbin/rtadvctl/   (props changed)
  projects/nand/usr.sbin/rtadvd/   (props changed)
  projects/nand/usr.sbin/rtsold/   (props changed)
  projects/nand/usr.sbin/zic/   (props changed)

Modified: projects/nand/Makefile.inc1
==============================================================================
--- projects/nand/Makefile.inc1	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/Makefile.inc1	Fri May 11 09:34:39 2012	(r235263)
@@ -223,9 +223,6 @@ CROSSENV=	MAKEOBJDIRPREFIX=${OBJTREE} \
 		MACHINE_ARCH=${TARGET_ARCH} \
 		MACHINE=${TARGET} \
 		CPUTYPE=${TARGET_CPUTYPE}
-.if ${OSRELDATE} < 700044
-CROSSENV+=	AR=gnu-ar RANLIB=gnu-ranlib
-.endif
 .if ${MK_GROFF} != "no"
 CROSSENV+=	GROFF_BIN_PATH=${WORLDTMP}/legacy/usr/bin \
 		GROFF_FONT_PATH=${WORLDTMP}/legacy/usr/share/groff_font \
@@ -981,8 +978,8 @@ update:
 # legacy: Build compatibility shims for the next three targets
 #
 legacy:
-.if ${BOOTSTRAPPING} < 600034 && ${BOOTSTRAPPING} != 0
-	@echo "ERROR: Source upgrades from versions prior to 6.0 not supported."; \
+.if ${BOOTSTRAPPING} < 800107 && ${BOOTSTRAPPING} != 0
+	@echo "ERROR: Source upgrades from versions prior to 8.0 not supported."; \
 	false
 .endif
 .for _tool in tools/build
@@ -1010,14 +1007,6 @@ _gperf=		gnu/usr.bin/gperf
 _groff=		gnu/usr.bin/groff
 .endif
 
-.if ${BOOTSTRAPPING} >= 700044 && ${BOOTSTRAPPING} < 800022
-_ar=		usr.bin/ar
-.endif
-
-.if ${BOOTSTRAPPING} < 800013
-_mklocale=	usr.bin/mklocale
-.endif
-
 .if ${BOOTSTRAPPING} < 900002
 _sed=		usr.bin/sed
 .endif
@@ -1031,16 +1020,10 @@ _yacc=		usr.bin/yacc
 _awk=		usr.bin/awk
 .endif
 
-.if ${MK_BSNMP} != "no" && \
-    (${BOOTSTRAPPING} < 700018 || !exists(/usr/sbin/gensnmptree))
+.if ${MK_BSNMP} != "no" &&  !exists(/usr/sbin/gensnmptree)
 _gensnmptree=	usr.sbin/bsnmpd/gensnmptree
 .endif
 
-.if ${MK_RESCUE} != "no" && \
-    ${BOOTSTRAPPING} < 700026
-_crunchgen=	usr.sbin/crunch/crunchgen
-.endif
-
 .if ${MK_CLANG} != "no"
 _clang_tblgen= \
 	lib/clang/libllvmsupport \
@@ -1051,9 +1034,7 @@ _clang_tblgen= \
 
 # dtrace tools are required for older bootstrap env and cross-build
 .if ${MK_CDDL} != "no" && \
-    ((${BOOTSTRAPPING} < 800038 && \
-          !(${BOOTSTRAPPING} >= 700112 && ${BOOTSTRAPPING} < 799999)) \
-      || (${MACHINE} != ${TARGET} || ${MACHINE_ARCH} != ${TARGET_ARCH}))
+    (${MACHINE} != ${TARGET} || ${MACHINE_ARCH} != ${TARGET_ARCH})
 _dtrace_tools= cddl/usr.bin/sgsmsg cddl/lib/libctf lib/libelf \
     lib/libdwarf cddl/usr.bin/ctfconvert cddl/usr.bin/ctfmerge
 .endif
@@ -1082,20 +1063,17 @@ bootstrap-tools:
     ${_strfile} \
     ${_gperf} \
     ${_groff} \
-    ${_ar} \
     ${_dtc} \
     ${_awk} \
     usr.bin/lorder \
     usr.bin/makewhatis \
-    ${_mklocale} \
     usr.bin/rpcgen \
     ${_sed} \
     ${_lex} \
     ${_yacc} \
     usr.bin/xinstall \
     ${_gensnmptree} \
-    usr.sbin/config \
-    ${_crunchgen}
+    usr.sbin/config
 	${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all,install)"; \
 		cd ${.CURDIR}/${_tool}; \
 		${MAKE} DIRPRFX=${_tool}/ obj; \
@@ -1154,7 +1132,7 @@ build-tools:
 #
 # cross-tools: Build cross-building tools
 #
-.if ${TARGET_ARCH} != ${MACHINE_ARCH} || ${BOOTSTRAPPING} < 800035
+.if ${TARGET_ARCH} != ${MACHINE_ARCH}
 .if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386"
 _btxld=		usr.sbin/btxld
 .endif

Modified: projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.8
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.8	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.8	Fri May 11 09:34:39 2012	(r235263)
@@ -1,61 +1,286 @@
 '\" te
-.\" Copyright (c) 2011, Martin Matuska <mm@FreeBSD.org>.
+.\" Copyright (c) 2012, Martin Matuska <mm@FreeBSD.org>.
 .\" All Rights Reserved.
 .\"
-.\" The contents of this file are subject to the terms of the
-.\" Common Development and Distribution License (the "License").
-.\" You may not use this file except in compliance with the License.
-.\"
-.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
-.\" or http://www.opensolaris.org/os/licensing.
-.\" See the License for the specific language governing permissions
-.\" and limitations under the License.
-.\"
-.\" When distributing Covered Code, include this CDDL HEADER in each
-.\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
-.\" If applicable, add the following below this CDDL HEADER, with the
-.\" fields enclosed by brackets "[]" replaced with your own identifying
-.\" information: Portions Copyright [yyyy] [name of copyright owner]
+.\" This file and its contents are supplied under the terms of the
+.\" Common Development and Distribution License ("CDDL"), version 1.0.
+.\" You may only use this file in accordance with the terms of version
+.\" 1.0 of the CDDL.
 .\"
-.\" Copyright (c) 2004, Sun Microsystems, Inc. All Rights Reserved.
+.\" A full copy of the text of the CDDL should have accompanied this
+.\" source.  A copy of the CDDL is also available via the Internet at
+.\" http://www.illumos.org/license/CDDL.
+.\"
+.\"
+.\" Copyright 2012, Richard Lowe.
+.\" Copyright (c) 2012, Marcelo Araujo <araujo@FreeBSD.org>.
+.\" All Rights Reserved.
 .\"
 .\" $FreeBSD$
 .\"
-.Dd November 26, 2011
+.Dd May 10, 2012
 .Dt ZDB 8
 .Os
 .Sh NAME
 .Nm zdb
-.Nd ZFS debugger
+.Nd Display zpool debugging and consistency information
 .Sh SYNOPSIS
 .Nm
-.Ar pool
+.Op Fl CumdibcsDvhLXFPA
+.Op Fl e Op Fl p Ar path...
+.Op Fl t Ar txg
+.Ar poolname
+.Op Ar object ...
+.Nm
+.Op Fl divPA
+.Op Fl e Op Fl p Ar path...
+.Ar dataset
+.Op Ar object ...
+.Nm
+.Fl m Op Fl LXFPA
+.Op Fl t Ar txg
+.Op Fl e Op Fl p Ar path...
+.Ar poolname
+.Nm
+.Fl R Op Fl A
+.Op Fl e Op Fl p Ar path...
+.Ar poolname
+.Ar vdev Ns : Ns Ar offset Ns : Ns Ar size Ns Op Ns : Ns Ar flags
+.Nm
+.Fl S
+.Op Fl AP
+.Op Fl e Op Fl p Ar path...
+.Ar poolname
+.Nm
+.Fl l
+.Op Fl uA
+.Ar device
+.Nm
+.Fl C
+.Op Fl A
+.Op Fl U Ar cache
 .Sh DESCRIPTION
 The
 .Nm
-command is used by support engineers to diagnose failures and
-gather statistics. Since the
-.Tn ZFS
-file system is always consistent on disk and is self-repairing,
-.Nm
-should only be run under the direction by a support engineer.
-.Pp
-If no arguments are specified,
-.Nm
-performs basic consistency checks on the pool and associated datasets, and
-report any problems detected.
-.Nm
-Any options supported by this command are internal to Sun and subject to change
-at any time.
-.Sh EXIT STATUS
-The following exit values are returned:
-.Bl -tag -offset 2n -width 2n
-.It 0
-The pool is consistent.
-.It 1
-An error was detected.
-.It 2
-Invalid command line options were specified.
+utility displays information about a ZFS pool useful for debugging and
+performs some amount of consistency checking.
+It is a not a general purpose tool and options (and facilities) may change.
+This is neither a
+.Xr fsck 8
+nor a
+.Xr fsdb 8
+utility.
+.Pp
+The output of this command in general reflects the on-disk structure of a ZFS
+pool, and is inherently unstable.
+The precise output of most invocations is not documented, a knowledge of ZFS
+internals is assumed.
+.Pp
+When operating on an imported and active pool it is possible, though unlikely,
+that zdb may interpret inconsistent pool data and behave erratically.
+.Sh OPTIONS
+Display options:
+.Bl -tag -width indent
+.It Fl b
+Display statistics regarding the number, size (logical, physical and
+allocated) and deduplication of blocks.
+.It Fl c
+Verify the checksum of all metadata blocks while printing block statistics
+(see
+.Fl b Ns ).
+.Pp
+If specified multiple times, verify the checksums of all blocks.
+.It Fl C
+Display information about the configuration. If specified with no other
+options, instead display information about the cache file
+.Ns ( Pa /etc/zfs/zpool.cache Ns ).
+To specify the cache file to display, see
+.Fl U
+.Pp
+If specified multiple times, and a pool name is also specified display both
+the cached configuration and the on-disk configuration.
+If specified multiple times with
+.FL e
+also display the configuration that would be used were the pool to be
+imported.
+.It Fl d
+Display information about datasets. Specified once, displays basic dataset
+information: ID, create transaction, size, and object count.
+.Pp
+If specified multiple times provides greater and greater verbosity.
+.Pp
+If object IDs are specified, display information about those specific objects only.
+.It Fl D
+Display deduplication statistics, including the deduplication ratio (dedup),
+compression ratio (compress), inflation due to the zfs copies property
+(copies), and an overall effective ratio (dedup * compress / copies).
+.Pp
+If specified twice, display a histogram of deduplication statistics, showing
+the allocated (physically present on disk) and referenced (logically
+referenced in the pool) block counts and sizes by reference count.
+.It Fl h
+Display pool history similar to
+.Cm zpool history ,
+but include internal changes, transaction, and dataset information.
+.It Fl i
+Display information about intent log (ZIL) entries relating to each
+dataset.
+If specified multiple times, display counts of each intent log transaction
+type.
+.It Fl l Ar device
+Display the vdev labels from the specified device.
+If the
+.Fl u
+option is also specified, also display the uberblocks on this device.
+.It Fl L
+Disable leak tracing and the loading of space maps.
+By default,
+.Nm 
+verifies that all non-free blocks are referenced, which can be very expensive.
+.It Fl m
+Display the offset, spacemap, and free space of each metaslab.
+When specified twice, also display information about the maximum contiguous
+free space and the percentage of free space in each space map.
+When specified three times display every spacemap record.
+.It Xo
+.Fl R Ar poolname
+.Ar vdev Ns : Ns Ar offset Ns : Ns Ar size Ns Op Ns : Ns Ar flags
+.Xc
+Read and display a block from the specified device. By default the block is
+displayed as a hex dump, but see the description of the
+.Fl r
+flag, below.
+.Pp
+The block is specified in terms of a colon-separated tuple
+.Ar vdev
+(an integer vdev identifier)
+.Ar offset
+(the offset within the vdev)
+.Ar size
+(the size of the block to read) and, optionally,
+.Ar flags
+(a set of flags, described below).
+.Bl -tag -width indent
+.It Sy b offset
+Print block pointer
+.It Sy d
+Decompress the block
+.It Sy e
+Byte swap the block
+.It Sy g
+Dump gang block header
+.It Sy i
+Dump indirect block
+.It Sy r
+Dump raw uninterpreted block data
+.El
+.It Fl s
+Report statistics on
+.Nm Ns 's
+I/O.
+Display operation counts, bandwidth, and error counts of I/O to the pool from
+.Nm .
+.It Fl S
+Simulate the effects of deduplication, constructing a DDT and then display
+that DDT as with \fB-DD\fR.
+.It Fl u
+Display the current uberblock.
+.El
+.Pp
+Other options:
+.Bl -tag -width indent
+.It Fl A
+Do not abort should any assertion fail.
+.It Fl AA
+Enable panic recovery, certain errors which would otherwise be fatal are
+demoted to warnings.
+.It Fl AAA
+Do not abort if asserts fail and also enable panic recovery.
+.It Fl e Op Fl p Ar path...
+Operate on an exported pool, not present in
+.Pa /etc/zfs/zpool.cache .
+The
+.Fl p
+flag specifies the path under which devices are to be searched.
+.It Fl F
+Attempt to make an unreadable pool readable by trying progressively older
+transactions.
+.It Fl P
+Print numbers in an unscaled form more amenable to parsing, eg. 1000000 rather
+than 1M.
+.It Fl t Ar transaction
+Specify the highest transaction to use when searching for uberblocks.
+See also the
+.Fl u
+and
+.Fl l
+options for a means to see the available uberblocks and their associated
+transaction numbers.
+.It Fl U Ar cachefile
+Use a cache file other than
+.Pa /etc/zfs/zpool.cache .
+This option is only valid with
+.Fl C
+.It Fl v
+Enable verbosity.
+Specify multiple times for increased verbosity.
+.It Fl X
+Attempt
+.Ql extreme
+transaction rewind, that is attempt the same recovery as
+.Fl F
+but read transactions otherwise deemed too old.
+.El
+.Pp
+Specifying a display option more than once enables verbosity for only that
+option, with more occurrences enabling more verbosity.
+.Pp
+If no options are specified, all information about the named pool will be
+displayed at default verbosity.
+.Sh EXAMPLES
+.Bl -tag -width 0n
+.It Sy Example 1 Display the configuration of imported pool 'rpool'
+.Bd -literal -offset 2n
+.Li # Ic zdb -C rpool
+
+MOS Configuration:
+        version: 28
+        name: 'rpool'
+ ...
+.Ed
+.It Sy Example 2 Display basic dataset information about 'rpool'
+.Bd -literal -offset 2n
+.Li # Ic zdb -d rpool
+Dataset mos [META], ID 0, cr_txg 4, 26.9M, 1051 objects
+Dataset rpool/swap [ZVOL], ID 59, cr_txg 356, 486M, 2 objects
+...
+.Ed
+.It Xo Sy Example 3 Display basic information about object 0 in
+.Sy 'rpool/export/home'
+.Xc
+.Bd -literal -offset 2n
+.Li # Ic zdb -d rpool/export/home 0
+Dataset rpool/export/home [ZPL], ID 137, cr_txg 1546, 32K, 8 objects
+
+    Object  lvl   iblk   dblk  dsize  lsize   %full  type
+         0    7    16K    16K  15.0K    16K   25.00  DMU dnode
+.Ed
+.It Xo Sy Example 4 Display the predicted effect of enabling deduplication on
+.Sy 'rpool'
+.Xc
+.Bd -literal -offset 2n
+.Li # Ic zdb -S rpool
+Simulated DDT histogram:
+
+bucket             allocated                      referenced          
+______  ______________________________  ______________________________
+refcnt  blocks   LSIZE   PSIZE   DSIZE  blocks   LSIZE   PSIZE   DSIZE
+------  ------   -----   -----   -----  ------   -----   -----   -----
+     1    694K   27.1G   15.0G   15.0G    694K   27.1G   15.0G   15.0G
+     2   35.0K   1.33G    699M    699M   74.7K   2.79G   1.45G   1.45G
+ ...
+dedup = 1.11, compress = 1.80, copies = 1.00, dedup * compress / copies = 2.00
+.Ed
 .El
 .Sh SEE ALSO
 .Xr zfs 8 ,
@@ -64,16 +289,18 @@ Invalid command line options were specif
 This manual page is a
 .Xr mdoc 7
 reimplementation of the
-.Tn OpenSolaris
+.Tn illumos
 manual page
 .Em zdb(1M) ,
 modified and customized for
 .Fx
 and licensed under the
-.Tn Common Development and Distribution License
+Common Development and Distribution License
 .Pq Tn CDDL .
 .Pp
 The
 .Xr mdoc 7
 implementation of this manual page was initially written by
-.An Martin Matuska Aq mm@FreeBSD.org .
+.An Martin Matuska Aq mm@FreeBSD.org
+and
+.An Marcelo Araujo Aq araujo@FreeBSD.org .

Modified: projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.c
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.c	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/cmd/zdb/zdb.c	Fri May 11 09:34:39 2012	(r235263)
@@ -102,13 +102,16 @@ static void
 usage(void)
 {
 	(void) fprintf(stderr,
-	    "Usage: %s [-CumdibcsDvhL] poolname [object...]\n"
-	    "       %s [-div] dataset [object...]\n"
-	    "       %s -m [-L] poolname [vdev [metaslab...]]\n"
-	    "       %s -R poolname vdev:offset:size[:flags]\n"
-	    "       %s -S poolname\n"
-	    "       %s -l [-u] device\n"
-	    "       %s -C\n\n",
+            "Usage: %s [-CumdibcsDvhLXFPA] [-t txg] [-e [-p path...]]"
+            "poolname [object...]\n"
+            "       %s [-divPA] [-e -p path...] dataset [object...]\n"
+            "       %s -m [-LXFPA] [-t txg] [-e [-p path...]]"
+            "poolname [vdev [metaslab...]]\n"
+            "       %s -R [-A] [-e [-p path...]] poolname "
+            "vdev:offset:size[:flags]\n"
+            "       %s -S [-PA] [-e [-p path...]] poolname\n"
+            "       %s -l [-uA] device\n"
+            "       %s -C [-A] [-U config]\n\n",
 	    cmdname, cmdname, cmdname, cmdname, cmdname, cmdname, cmdname);
 
 	(void) fprintf(stderr, "    Dataset name must include at least one "
@@ -150,7 +153,7 @@ usage(void)
 	    "has altroot/not in a cachefile\n");
 	(void) fprintf(stderr, "        -p <path> -- use one or more with "
 	    "-e to specify path to vdev dir\n");
-	(void) fprintf(stderr, "	-P print numbers parsable\n");
+	(void) fprintf(stderr, "	-P print numbers in parseable form\n");
 	(void) fprintf(stderr, "        -t <txg> -- highest txg to use when "
 	    "searching for uberblocks\n");
 	(void) fprintf(stderr, "Specify an option more than once (e.g. -bb) "

Modified: projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs.8
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs.8	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs.8	Fri May 11 09:34:39 2012	(r235263)
@@ -18,8 +18,9 @@
 .\" information: Portions Copyright [yyyy] [name of copyright owner]
 .\"
 .\" Copyright (c) 2010, Sun Microsystems, Inc. All Rights Reserved.
-.\" Copyright (c) 2011 by Delphix. All rights reserved.
+.\" Copyright (c) 2012 by Delphix. All rights reserved.
 .\" Copyright (c) 2012 Nexenta Systems, Inc. All Rights Reserved.
+.\" Copyright (c) 2012, Joyent, Inc. All rights reserved.
 .\" Copyright (c) 2011, Pawel Jakub Dawidek <pjd@FreeBSD.org>
 .\"
 .\" $FreeBSD$
@@ -77,10 +78,12 @@
 .Ar clone-filesystem
 .Nm
 .Cm rename
+.Op Fl f
 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
 .Nm
 .Cm rename
+.Op Fl f
 .Fl p
 .Ar filesystem Ns | Ns Ar volume
 .Ar filesystem Ns | Ns Ar volume
@@ -1646,12 +1649,14 @@ subcommand can be used to rename any con
 .It Xo
 .Nm
 .Cm rename
+.Op Fl f
 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
 .Xc
 .It Xo
 .Nm
 .Cm rename
+.Op Fl f
 .Fl p
 .Ar filesystem Ns | Ns Ar volume
 .Ar filesystem Ns | Ns Ar volume
@@ -1685,6 +1690,11 @@ property is set to
 or
 .Cm none ,
 file system is not unmounted even if this option is not given.
+.It Fl f
+Force unmount any filesystems that need to be unmounted in the process.
+This flag has no effect if used together with the
+.Fl u
+flag.
 .El
 .It Xo
 .Nm
@@ -2271,6 +2281,7 @@ flags to determine what data will be sen
 Print machine-parsable verbose information about the stream package generated.
 .It Fl v
 Print verbose information about the stream package generated.
+This information includes a per-second report of how much data has been sent.
 .El
 .Pp
 The format of the stream is committed. You will be able to receive your streams

Modified: projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c	Fri May 11 09:34:39 2012	(r235263)
@@ -22,10 +22,12 @@
 /*
  * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
  * Copyright 2012 Nexenta Systems, Inc. All rights reserved.
- * Copyright (c) 2011 by Delphix. All rights reserved.
+ * Copyright (c) 2012 by Delphix. All rights reserved.
+ * Copyright 2012 Milan Jurik. All rights reserved.
+ * Copyright (c) 2012, Joyent, Inc. All rights reserved.
  * Copyright (c) 2011-2012 Pawel Jakub Dawidek <pawel@dawidek.net>.
  * All rights reserved.
- * Copyright (c) 2011 Martin Matuska <mm@FreeBSD.org>. All rights reserved.
+ * Copyright (c) 2012 Martin Matuska <mm@FreeBSD.org>. All rights reserved.
  */
 
 #include <assert.h>
@@ -256,9 +258,10 @@ get_usage(zfs_help_t idx)
 		"snapshot>\n"
 		"\treceive [-vnFu] [-d | -e] <filesystem>\n"));
 	case HELP_RENAME:
-		return (gettext("\trename <filesystem|volume|snapshot> "
+		return (gettext("\trename [-f] <filesystem|volume|snapshot> "
 		    "<filesystem|volume|snapshot>\n"
-		    "\trename -p <filesystem|volume> <filesystem|volume>\n"
+		    "\trename [-f] -p <filesystem|volume> "
+		    "<filesystem|volume>\n"
 		    "\trename -r <snapshot> <snapshot>\n"
 		    "\trename -u [-p] <filesystem> <filesystem>"));
 	case HELP_ROLLBACK:
@@ -764,7 +767,6 @@ zfs_do_create(int argc, char **argv)
 			(void) fprintf(stderr, gettext("missing size "
 			    "argument\n"));
 			goto badusage;
-			break;
 		case '?':
 			(void) fprintf(stderr, gettext("invalid option '%c'\n"),
 			    optopt);
@@ -3091,8 +3093,8 @@ zfs_do_list(int argc, char **argv)
 }
 
 /*
- * zfs rename <fs | snap | vol> <fs | snap | vol>
- * zfs rename -p <fs | vol> <fs | vol>
+ * zfs rename [-f] <fs | snap | vol> <fs | snap | vol>
+ * zfs rename [-f] -p <fs | vol> <fs | vol>
  * zfs rename -r <snap> <snap>
  * zfs rename -u [-p] <fs> <fs>
  *
@@ -3112,7 +3114,7 @@ zfs_do_rename(int argc, char **argv)
 	boolean_t parents = B_FALSE;
 
 	/* check options */
-	while ((c = getopt(argc, argv, "pru")) != -1) {
+	while ((c = getopt(argc, argv, "fpru")) != -1) {
 		switch (c) {
 		case 'p':
 			parents = B_TRUE;
@@ -3123,6 +3125,9 @@ zfs_do_rename(int argc, char **argv)
 		case 'u':
 			flags.nounmount = B_TRUE;
 			break;
+		case 'f':
+			flags.forceunmount = B_TRUE;
+			break;
 		case '?':
 		default:
 			(void) fprintf(stderr, gettext("invalid option '%c'\n"),
@@ -3586,6 +3591,7 @@ zfs_do_send(int argc, char **argv)
 			if (flags.verbose)
 				extraverbose = B_TRUE;
 			flags.verbose = B_TRUE;
+			flags.progress = B_TRUE;
 			break;
 		case 'D':
 			flags.dedup = B_TRUE;

Modified: projects/nand/cddl/contrib/opensolaris/cmd/zstreamdump/zstreamdump.1
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/cmd/zstreamdump/zstreamdump.1	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/cmd/zstreamdump/zstreamdump.1	Fri May 11 09:34:39 2012	(r235263)
@@ -25,7 +25,7 @@
 .Dt ZSTREAMDUMP 8
 .Os
 .Sh NAME
-.Nm zdb
+.Nm zstreamdump
 .Nd filter data in zfs send stream
 .Sh SYNOPSIS
 .Nm

Modified: projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs.h
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs.h	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs.h	Fri May 11 09:34:39 2012	(r235263)
@@ -25,7 +25,8 @@
  * Copyright (c) 2011 Pawel Jakub Dawidek <pawel@dawidek.net>.
  * All rights reserved.
  * Copyright (c) 2011 by Delphix. All rights reserved.
- * All rights reserved.
+ * Copyright (c) 2012, Joyent, Inc. All rights reserved.
+ * Copyright (c) 2012 Martin Matuska <mm@FreeBSD.org>. All rights reserved.
  */
 
 #ifndef	_LIBZFS_H
@@ -541,6 +542,9 @@ typedef struct renameflags {
 
 	/* don't unmount file systems */
 	int nounmount : 1;
+
+	/* force unmount file systems */
+	int forceunmount : 1;
 } renameflags_t;
 
 extern int zfs_rename(zfs_handle_t *, const char *, renameflags_t flags);
@@ -569,6 +573,9 @@ typedef struct sendflags {
 
 	/* parsable verbose output (ie. -P) */
 	boolean_t parsable;
+
+	/* show progress (ie. -v) */
+	boolean_t progress;
 } sendflags_t;
 
 typedef boolean_t (snapfilter_cb_t)(zfs_handle_t *, void *);

Modified: projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c	Fri May 11 09:34:39 2012	(r235263)
@@ -25,6 +25,7 @@
  * Copyright (c) 2011 by Delphix. All rights reserved.
  * Copyright (c) 2011-2012 Pawel Jakub Dawidek <pawel@dawidek.net>.
  * All rights reserved.
+ * Copyright (c) 2012 Martin Matuska <mm@FreeBSD.org>. All rights reserved.
  */
 
 #include <ctype.h>
@@ -3721,7 +3722,8 @@ zfs_rename(zfs_handle_t *zhp, const char
 
 	} else {
 		if ((cl = changelist_gather(zhp, ZFS_PROP_NAME,
-		    flags.nounmount ? CL_GATHER_DONT_UNMOUNT : 0, 0)) == NULL) {
+		    flags.nounmount ? CL_GATHER_DONT_UNMOUNT : 0,
+		    flags.forceunmount ? MS_FORCE : 0)) == NULL) {
 			return (-1);
 		}
 

Modified: projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c	Fri May 11 09:34:39 2012	(r235263)
@@ -22,6 +22,7 @@
 /*
  * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
  * Copyright (c) 2011 by Delphix. All rights reserved.
+ * Copyright (c) 2012, Joyent, Inc. All rights reserved.
  * Copyright (c) 2012 Pawel Jakub Dawidek <pawel@dawidek.net>.
  * All rights reserved.
  */
@@ -40,6 +41,7 @@
 #include <sys/mount.h>
 #include <pthread.h>
 #include <umem.h>
+#include <time.h>
 
 #include <libzfs.h>
 
@@ -67,6 +69,12 @@ typedef struct dedup_arg {
 	libzfs_handle_t  *dedup_hdl;
 } dedup_arg_t;
 
+typedef struct progress_arg {
+	zfs_handle_t *pa_zhp;
+	int pa_fd;
+	boolean_t pa_parsable;
+} progress_arg_t;
+
 typedef struct dataref {
 	uint64_t ref_guid;
 	uint64_t ref_object;
@@ -786,7 +794,7 @@ typedef struct send_dump_data {
 	char prevsnap[ZFS_MAXNAMELEN];
 	uint64_t prevsnap_obj;
 	boolean_t seenfrom, seento, replicate, doall, fromorigin;
-	boolean_t verbose, dryrun, parsable;
+	boolean_t verbose, dryrun, parsable, progress;
 	int outfd;
 	boolean_t err;
 	nvlist_t *fss;
@@ -979,10 +987,60 @@ hold_for_send(zfs_handle_t *zhp, send_du
 	return (error);
 }
 
+static void *
+send_progress_thread(void *arg)
+{
+	progress_arg_t *pa = arg;
+
+	zfs_cmd_t zc = { 0 };
+	zfs_handle_t *zhp = pa->pa_zhp;
+	libzfs_handle_t *hdl = zhp->zfs_hdl;
+	unsigned long long bytes;
+	char buf[16];
+
+	time_t t;
+	struct tm *tm;
+
+	assert(zhp->zfs_type == ZFS_TYPE_SNAPSHOT);
+	(void) strlcpy(zc.zc_name, zhp->zfs_name, sizeof (zc.zc_name));
+
+	if (!pa->pa_parsable)
+		(void) fprintf(stderr, "TIME        SENT   SNAPSHOT\n");
+
+	/*
+	 * Print the progress from ZFS_IOC_SEND_PROGRESS every second.
+	 */
+	for (;;) {
+		(void) sleep(1);
+
+		zc.zc_cookie = pa->pa_fd;
+		if (zfs_ioctl(hdl, ZFS_IOC_SEND_PROGRESS, &zc) != 0)
+			return ((void *)-1);
+
+		(void) time(&t);
+		tm = localtime(&t);
+		bytes = zc.zc_cookie;
+
+		if (pa->pa_parsable) {
+			(void) fprintf(stderr, "%02d:%02d:%02d\t%llu\t%s\n",
+			    tm->tm_hour, tm->tm_min, tm->tm_sec,
+			    bytes, zhp->zfs_name);
+		} else {
+			zfs_nicenum(bytes, buf, sizeof (buf));
+			(void) fprintf(stderr, "%02d:%02d:%02d   %5s   %s\n",
+			    tm->tm_hour, tm->tm_min, tm->tm_sec,
+			    buf, zhp->zfs_name);
+		}
+	}
+}
+
 static int
 dump_snapshot(zfs_handle_t *zhp, void *arg)
 {
 	send_dump_data_t *sdd = arg;
+	progress_arg_t pa = { 0 };
+	pthread_t tid;
+
 	char *thissnap;
 	int err;
 	boolean_t isfromsnap, istosnap, fromorigin;
@@ -1100,8 +1158,29 @@ dump_snapshot(zfs_handle_t *zhp, void *a
 	}
 
 	if (!sdd->dryrun) {
+		/*
+		 * If progress reporting is requested, spawn a new thread to
+		 * poll ZFS_IOC_SEND_PROGRESS at a regular interval.
+		 */
+		if (sdd->progress) {
+			pa.pa_zhp = zhp;
+			pa.pa_fd = sdd->outfd;
+			pa.pa_parsable = sdd->parsable;
+
+			if (err = pthread_create(&tid, NULL,
+			    send_progress_thread, &pa)) {
+				zfs_close(zhp);
+				return (err);
+			}
+		}
+
 		err = dump_ioctl(zhp, sdd->prevsnap, sdd->prevsnap_obj,
 		    fromorigin, sdd->outfd, sdd->debugnv);
+
+		if (sdd->progress) {
+			(void) pthread_cancel(tid);
+			(void) pthread_join(tid, NULL);
+		}
 	}
 
 	(void) strcpy(sdd->prevsnap, thissnap);
@@ -1451,12 +1530,13 @@ zfs_send(zfs_handle_t *zhp, const char *
 	sdd.fsavl = fsavl;
 	sdd.verbose = flags->verbose;
 	sdd.parsable = flags->parsable;
+	sdd.progress = flags->progress;
 	sdd.dryrun = flags->dryrun;
 	sdd.filter_cb = filter_func;
 	sdd.filter_cb_arg = cb_arg;
 	if (debugnvp)
 		sdd.debugnv = *debugnvp;
-	if (holdsnaps) {
+	if (holdsnaps || flags->progress) {
 		++holdseq;
 		(void) snprintf(sdd.holdtag, sizeof (sdd.holdtag),
 		    ".send-%d-%llu", getpid(), (u_longlong_t)holdseq);

Modified: projects/nand/cddl/contrib/opensolaris/lib/libzpool/common/sys/zfs_context.h
==============================================================================
--- projects/nand/cddl/contrib/opensolaris/lib/libzpool/common/sys/zfs_context.h	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/cddl/contrib/opensolaris/lib/libzpool/common/sys/zfs_context.h	Fri May 11 09:34:39 2012	(r235263)
@@ -20,6 +20,7 @@
  */
 /*
  * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, Joyent, Inc. All rights reserved.
  */
 
 #ifndef _SYS_ZFS_CONTEXT_H
@@ -228,6 +229,7 @@ struct proc {
 };
 
 extern struct proc p0;
+#define	curproc		(&p0)
 
 #define	PS_NONE		-1
 

Modified: projects/nand/contrib/jemalloc/ChangeLog
==============================================================================
--- projects/nand/contrib/jemalloc/ChangeLog	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/contrib/jemalloc/ChangeLog	Fri May 11 09:34:39 2012	(r235263)
@@ -19,9 +19,10 @@ found in the git revision history:
 
   New features:
   - Implement Valgrind support, redzones, and quarantine.
-  - Add support for additional operating systems:
+  - Add support for additional platforms:
     + FreeBSD
     + Mac OS X Lion
+    + MinGW
   - Add support for additional architectures:
     + MIPS
     + SH4
@@ -64,18 +65,24 @@ found in the git revision history:
   - Remove the --enable-sysv configure option.
 
   Bug fixes:
-  - Fix fork-related bugs that could cause deadlock in children between fork
-    and exec.
   - Fix a statistics-related bug in the "thread.arena" mallctl that could cause
     invalid statistics and crashes.
-  - Work around TLS dallocation via free() on Linux.  This bug could cause
+  - Work around TLS deallocation via free() on Linux.  This bug could cause
     write-after-free memory corruption.
+  - Fix a potential deadlock that could occur during interval- and
+    growth-triggered heap profile dumps.
   - Fix chunk_alloc_dss() to stop claiming memory is zeroed.  This bug could
     cause memory corruption and crashes with --enable-dss specified.
+  - Fix fork-related bugs that could cause deadlock in children between fork
+    and exec.
   - Fix malloc_stats_print() to honor 'b' and 'l' in the opts parameter.
   - Fix realloc(p, 0) to act like free(p).
   - Do not enforce minimum alignment in memalign().
   - Check for NULL pointer in malloc_usable_size().
+  - Fix an off-by-one heap profile statistics bug that could be observed in
+    interval- and growth-triggered heap profiles.
+  - Fix the "epoch" mallctl to update cached stats even if the passed in epoch
+    is 0.
   - Fix bin->runcur management to fix a layout policy bug.  This bug did not
     affect correctness.
   - Fix a bug in choose_arena_hard() that potentially caused more arenas to be

Modified: projects/nand/contrib/jemalloc/FREEBSD-Xlist
==============================================================================
--- projects/nand/contrib/jemalloc/FREEBSD-Xlist	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/contrib/jemalloc/FREEBSD-Xlist	Fri May 11 09:34:39 2012	(r235263)
@@ -18,6 +18,7 @@ include/jemalloc/internal/jemalloc_inter
 include/jemalloc/internal/size_classes.sh
 include/jemalloc/jemalloc.h.in
 include/jemalloc/jemalloc_defs.h.in
+include/msvc_compat/
 install-sh
 src/zone.c
 test/

Modified: projects/nand/contrib/jemalloc/FREEBSD-diffs
==============================================================================
--- projects/nand/contrib/jemalloc/FREEBSD-diffs	Fri May 11 07:12:18 2012	(r235262)
+++ projects/nand/contrib/jemalloc/FREEBSD-diffs	Fri May 11 09:34:39 2012	(r235263)
@@ -1,5 +1,5 @@
 diff --git a/doc/jemalloc.xml.in b/doc/jemalloc.xml.in
-index e8a5722..cec85b5 100644
+index 93c16dc..b5c5595 100644
 --- a/doc/jemalloc.xml.in
 +++ b/doc/jemalloc.xml.in
 @@ -51,12 +51,23 @@
@@ -27,7 +27,7 @@ index e8a5722..cec85b5 100644
        <refsect2>
          <title>Standard API</title>
          <funcprototype>
-@@ -2091,4 +2102,16 @@ malloc_conf = "lg_chunk:24";]]></programlisting></para>
+@@ -2101,4 +2112,16 @@ malloc_conf = "lg_chunk:24";]]></programlisting></para>
      <para>The <function>posix_memalign<parameter/></function> function conforms
      to IEEE Std 1003.1-2001 (&ldquo;POSIX.1&rdquo;).</para>
    </refsect1>
@@ -45,7 +45,7 @@ index e8a5722..cec85b5 100644
 +  </refsect1>
  </refentry>
 diff --git a/include/jemalloc/internal/jemalloc_internal.h.in b/include/jemalloc/internal/jemalloc_internal.h.in
-index b61abe8..edbb437 100644
+index 268cd14..cfb1fb9 100644
 --- a/include/jemalloc/internal/jemalloc_internal.h.in
 +++ b/include/jemalloc/internal/jemalloc_internal.h.in
 @@ -1,5 +1,8 @@
@@ -54,12 +54,12 @@ index b61abe8..edbb437 100644
 +#include "libc_private.h"
 +#include "namespace.h"
 +
- #include <sys/mman.h>
- #include <sys/param.h>
- #include <sys/syscall.h>
-@@ -35,6 +38,9 @@
- #include <pthread.h>
  #include <math.h>
+ #ifdef _WIN32
+ #  include <windows.h>
+@@ -54,6 +57,9 @@ typedef intptr_t ssize_t;
+ #endif
+ #include <fcntl.h>
  
 +#include "un-namespace.h"
 +#include "libc_private.h"
@@ -68,10 +68,10 @@ index b61abe8..edbb437 100644
  #include "../jemalloc@install_suffix@.h"
  
 diff --git a/include/jemalloc/internal/mutex.h b/include/jemalloc/internal/mutex.h
-index 8837ef5..d7133f4 100644
+index de44e14..564d604 100644
 --- a/include/jemalloc/internal/mutex.h
 +++ b/include/jemalloc/internal/mutex.h
-@@ -39,9 +39,6 @@ struct malloc_mutex_s {
+@@ -43,9 +43,6 @@ struct malloc_mutex_s {
  
  #ifdef JEMALLOC_LAZY_LOCK
  extern bool isthreaded;
@@ -82,10 +82,10 @@ index 8837ef5..d7133f4 100644
  
  bool	malloc_mutex_init(malloc_mutex_t *mutex);
 diff --git a/include/jemalloc/internal/private_namespace.h b/include/jemalloc/internal/private_namespace.h
-index bb1b63e..00eb169 100644
+index b816647..b8ce6b1 100644
 --- a/include/jemalloc/internal/private_namespace.h
 +++ b/include/jemalloc/internal/private_namespace.h
-@@ -165,7 +165,6 @@
+@@ -186,7 +186,6 @@
  #define	iqalloc JEMALLOC_N(iqalloc)
  #define	iralloc JEMALLOC_N(iralloc)
  #define	isalloc JEMALLOC_N(isalloc)
@@ -94,7 +94,7 @@ index bb1b63e..00eb169 100644
  #define	jemalloc_postfork_child JEMALLOC_N(jemalloc_postfork_child)
  #define	jemalloc_postfork_parent JEMALLOC_N(jemalloc_postfork_parent)
 diff --git a/include/jemalloc/jemalloc.h.in b/include/jemalloc/jemalloc.h.in
-index f0581db..f26d8bc 100644
+index ad06948..505dd38 100644
 --- a/include/jemalloc/jemalloc.h.in
 +++ b/include/jemalloc/jemalloc.h.in
 @@ -15,6 +15,7 @@ extern "C" {
@@ -107,10 +107,10 @@ index f0581db..f26d8bc 100644
  #define	ALLOCM_LG_ALIGN(la)	(la)
 diff --git a/include/jemalloc/jemalloc_FreeBSD.h b/include/jemalloc/jemalloc_FreeBSD.h
 new file mode 100644
-index 0000000..2c5797f
+index 0000000..9efab93
 --- /dev/null
 +++ b/include/jemalloc/jemalloc_FreeBSD.h
-@@ -0,0 +1,76 @@
+@@ -0,0 +1,80 @@
 +/*
 + * Override settings that were generated in jemalloc_defs.h as necessary.
 + */
@@ -154,8 +154,12 @@ index 0000000..2c5797f
 +#  define LG_SIZEOF_PTR		2
 +#endif
 +#ifdef __mips__
++#ifdef __mips_n64

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



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