aboutsummaryrefslogtreecommitdiff
path: root/cddl
diff options
context:
space:
mode:
Diffstat (limited to 'cddl')
-rw-r--r--cddl/Makefile1
-rw-r--r--cddl/Makefile.inc1
-rw-r--r--cddl/compat/opensolaris/include/alloca.h2
-rw-r--r--cddl/compat/opensolaris/include/assert.h2
-rw-r--r--cddl/compat/opensolaris/include/devid.h2
-rw-r--r--cddl/compat/opensolaris/include/dtrace.h2
-rw-r--r--cddl/compat/opensolaris/include/fcntl.h2
-rw-r--r--cddl/compat/opensolaris/include/fsshare.h2
-rw-r--r--cddl/compat/opensolaris/include/libintl.h1
-rw-r--r--cddl/compat/opensolaris/include/libproc.h5
-rw-r--r--cddl/compat/opensolaris/include/libshare.h2
-rw-r--r--cddl/compat/opensolaris/include/priv.h1
-rw-r--r--cddl/compat/opensolaris/include/sha2.h2
-rw-r--r--cddl/compat/opensolaris/include/solaris.h1
-rw-r--r--cddl/compat/opensolaris/include/stdio.h2
-rw-r--r--cddl/compat/opensolaris/include/stdlib.h37
-rw-r--r--cddl/compat/opensolaris/include/strings.h2
-rw-r--r--cddl/compat/opensolaris/include/thread_pool.h1
-rw-r--r--cddl/compat/opensolaris/include/unistd.h2
-rw-r--r--cddl/compat/opensolaris/include/zone.h1
-rw-r--r--cddl/compat/opensolaris/lib/libumem/umem.c2
-rw-r--r--cddl/compat/opensolaris/lib/libumem/umem.h2
-rw-r--r--cddl/contrib/opensolaris/cmd/dtrace/dtrace.120
-rw-r--r--cddl/contrib/opensolaris/cmd/dtrace/dtrace.c9
-rw-r--r--cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/kinst/tst.basic.ksh48
-rw-r--r--cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh2
-rw-r--r--cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/translators/tst.OutputAliasTrans.d12
-rw-r--r--cddl/contrib/opensolaris/cmd/lockstat/lockstat.c6
-rw-r--r--cddl/contrib/opensolaris/cmd/lockstat/sym.c21
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_cc.c16
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h1
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.c142
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c30
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c14
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_parser.c2
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c3
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c295
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.h6
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_provider.c29
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dtrace.h3
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/mips/dt_isadep.c75
-rw-r--r--cddl/contrib/opensolaris/tools/ctf/common/memory.c14
-rw-r--r--cddl/contrib/opensolaris/tools/ctf/common/memory.h1
-rw-r--r--cddl/contrib/opensolaris/tools/ctf/common/utils.c24
-rw-r--r--cddl/contrib/opensolaris/tools/ctf/common/utils.h2
-rw-r--r--cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c13
-rw-r--r--cddl/contrib/opensolaris/tools/ctf/dump/dump.c2
-rw-r--r--cddl/lib/Makefile50
-rw-r--r--cddl/lib/Makefile.inc1
-rw-r--r--cddl/lib/drti/Makefile1
-rw-r--r--cddl/lib/drti/Makefile.depend1
-rw-r--r--cddl/lib/libavl/Makefile3
-rw-r--r--cddl/lib/libavl/Makefile.depend3
-rw-r--r--cddl/lib/libctf/Makefile1
-rw-r--r--cddl/lib/libctf/Makefile.depend2
-rw-r--r--cddl/lib/libdtrace/Makefile28
-rw-r--r--cddl/lib/libdtrace/Makefile.depend4
-rw-r--r--cddl/lib/libdtrace/errno.d2
-rw-r--r--cddl/lib/libdtrace/io.d2
-rw-r--r--cddl/lib/libdtrace/ip.d2
-rw-r--r--cddl/lib/libdtrace/libproc_compat.h4
-rw-r--r--cddl/lib/libdtrace/net.d2
-rw-r--r--cddl/lib/libdtrace/nfs.d2
-rw-r--r--cddl/lib/libdtrace/nfssrv.d2
-rw-r--r--cddl/lib/libdtrace/psinfo.d2
-rw-r--r--cddl/lib/libdtrace/regs_aarch64.d74
-rw-r--r--cddl/lib/libdtrace/regs_riscv.d74
-rw-r--r--cddl/lib/libdtrace/regs_x86.d8
-rw-r--r--cddl/lib/libdtrace/sched.d2
-rw-r--r--cddl/lib/libdtrace/sctp.d2
-rw-r--r--cddl/lib/libdtrace/siftr.d55
-rw-r--r--cddl/lib/libdtrace/signal.d2
-rw-r--r--cddl/lib/libdtrace/socket.d2
-rw-r--r--cddl/lib/libdtrace/tcp.d24
-rw-r--r--cddl/lib/libdtrace/udp.d2
-rw-r--r--cddl/lib/libdtrace/udplite.d2
-rw-r--r--cddl/lib/libdtrace/unistd.d2
-rw-r--r--cddl/lib/libicp/Makefile78
-rw-r--r--cddl/lib/libicp/Makefile.depend0
-rw-r--r--cddl/lib/libicp_rescue/Makefile72
-rw-r--r--cddl/lib/libicp_rescue/Makefile.depend0
-rw-r--r--cddl/lib/libnvpair/Makefile5
-rw-r--r--cddl/lib/libnvpair/Makefile.depend3
-rw-r--r--cddl/lib/libspl/Makefile3
-rw-r--r--cddl/lib/libspl/Makefile.depend0
-rw-r--r--cddl/lib/libtpool/Makefile3
-rw-r--r--cddl/lib/libtpool/Makefile.depend0
-rw-r--r--cddl/lib/libumem/Makefile3
-rw-r--r--cddl/lib/libumem/Makefile.depend1
-rw-r--r--cddl/lib/libuutil/Makefile4
-rw-r--r--cddl/lib/libuutil/Makefile.depend3
-rw-r--r--cddl/lib/libzfs/Makefile7
-rw-r--r--cddl/lib/libzfs/Makefile.depend4
-rw-r--r--cddl/lib/libzfs_core/Makefile3
-rw-r--r--cddl/lib/libzfs_core/Makefile.depend4
-rw-r--r--cddl/lib/libzfsbootenv/Makefile3
-rw-r--r--cddl/lib/libzfsbootenv/Makefile.depend0
-rw-r--r--cddl/lib/libzpool/Makefile15
-rw-r--r--cddl/lib/libzpool/Makefile.depend4
-rw-r--r--cddl/lib/libzutil/Makefile3
-rw-r--r--cddl/lib/libzutil/Makefile.depend0
-rw-r--r--cddl/lib/pam_zfs_key/Makefile2
-rw-r--r--cddl/lib/tests/Makefile1
-rw-r--r--cddl/lib/tests/Makefile.depend1
-rw-r--r--cddl/sbin/Makefile10
-rw-r--r--cddl/sbin/Makefile.inc1
-rw-r--r--cddl/sbin/tests/Makefile1
-rw-r--r--cddl/sbin/tests/Makefile.depend1
-rw-r--r--cddl/sbin/zfs/Makefile5
-rw-r--r--cddl/sbin/zfs/Makefile.depend12
-rw-r--r--cddl/sbin/zpool/Makefile4
-rw-r--r--cddl/sbin/zpool/Makefile.depend11
-rw-r--r--cddl/share/Makefile7
-rw-r--r--cddl/share/zfs/Makefile1
-rw-r--r--cddl/share/zfs/compatibility.d/Makefile11
-rw-r--r--cddl/tests/Makefile1
-rw-r--r--cddl/tests/Makefile.depend1
-rw-r--r--cddl/usr.bin/Makefile17
-rw-r--r--cddl/usr.bin/Makefile.inc1
-rw-r--r--cddl/usr.bin/ctfconvert/Makefile2
-rw-r--r--cddl/usr.bin/ctfconvert/Makefile.depend4
-rw-r--r--cddl/usr.bin/ctfconvert/ctfconvert.12
-rw-r--r--cddl/usr.bin/ctfconvert/tests/Makefile1
-rw-r--r--cddl/usr.bin/ctfconvert/tests/ctfconvert_test.sh1
-rw-r--r--cddl/usr.bin/ctfdump/Makefile2
-rw-r--r--cddl/usr.bin/ctfdump/Makefile.depend2
-rw-r--r--cddl/usr.bin/ctfdump/ctfdump.12
-rw-r--r--cddl/usr.bin/ctfmerge/Makefile2
-rw-r--r--cddl/usr.bin/ctfmerge/Makefile.depend3
-rw-r--r--cddl/usr.bin/ctfmerge/ctfmerge.12
-rw-r--r--cddl/usr.bin/tests/Makefile1
-rw-r--r--cddl/usr.bin/tests/Makefile.depend1
-rw-r--r--cddl/usr.bin/zinject/Makefile2
-rw-r--r--cddl/usr.bin/zinject/Makefile.depend10
-rw-r--r--cddl/usr.bin/zstream/Makefile4
-rw-r--r--cddl/usr.bin/ztest/Makefile2
-rw-r--r--cddl/usr.bin/ztest/Makefile.depend10
-rw-r--r--cddl/usr.bin/ztest/tests/Makefile1
-rwxr-xr-xcddl/usr.bin/ztest/tests/ztest.sh1
-rw-r--r--cddl/usr.libexec/Makefile9
-rw-r--r--cddl/usr.libexec/zfs_prepare_disk/Makefile20
-rw-r--r--cddl/usr.libexec/zpool_influxdb/Makefile1
-rw-r--r--cddl/usr.libexec/zpool_influxdb/Makefile.depend1
-rw-r--r--cddl/usr.sbin/Makefile25
-rw-r--r--cddl/usr.sbin/Makefile.inc1
-rw-r--r--cddl/usr.sbin/dtrace/Makefile6
-rw-r--r--cddl/usr.sbin/dtrace/Makefile.depend9
-rw-r--r--cddl/usr.sbin/dtrace/tests/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/amd64/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/amd64/arrays/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/Makefile2
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/aggs/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/aggs/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/arrays/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/arrays/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/assocs/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/assocs/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/begin/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/begin/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/buffering/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/buffering/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/cg/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/cg/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/clauses/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/clauses/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/cpc/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/cpc/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/decls/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/decls/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/drops/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/drops/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/end/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/end/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/enum/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/enum/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/env/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/error/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/error/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/exit/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/exit/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/funcs/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/funcs/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/grammar/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/grammar/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/include/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/include/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/inline/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/inline/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/io/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/io/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/ip/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/ip/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/java_api/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/java_api/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/json/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/json/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/kinst/Makefile18
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/lexer/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/lexer/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/mdb/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/mdb/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/mib/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/mib/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/misc/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/misc/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/nfs/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/operators/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/operators/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/pid/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/pid/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/pointers/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/pointers/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/pragma/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/pragma/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/predicates/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/predicates/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/print/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/print/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/printa/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/printa/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/printf/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/printf/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/privs/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/privs/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/probes/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/probes/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/proc/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/proc/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/providers/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/providers/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/raise/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/raise/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/rates/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/rates/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/safety/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/safety/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/scalars/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/scalars/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sched/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sched/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/scripting/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/scripting/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sdt/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sdt/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/speculation/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/speculation/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stability/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stability/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stack/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stack/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stop/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/stop/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/strlen/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/strlen/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/struct/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/struct/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sugar/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sugar/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/syscall/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/syscall/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/sysevent/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/trace/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/trace/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/translators/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/translators/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/typedef/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/typedef/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/types/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/types/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/uctf/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/uctf/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/union/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/union/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/usdt/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/usdt/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/ustack/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/ustack/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/vars/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/vars/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/version/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/common/version/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/tests/dtrace.test.mk1
-rw-r--r--cddl/usr.sbin/dtrace/tests/i386/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/i386/arrays/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/i386/funcs/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/i386/pid/Makefile1
-rw-r--r--cddl/usr.sbin/dtrace/tests/i386/ustack/Makefile1
-rwxr-xr-xcddl/usr.sbin/dtrace/tests/tools/dtest.sh2
-rwxr-xr-xcddl/usr.sbin/dtrace/tests/tools/exclude.sh1
-rwxr-xr-xcddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh3
-rwxr-xr-xcddl/usr.sbin/dtrace/tests/tools/gentest.sh1
-rw-r--r--cddl/usr.sbin/dwatch/Makefile1
-rwxr-xr-xcddl/usr.sbin/dwatch/dwatch1
-rw-r--r--cddl/usr.sbin/dwatch/dwatch.14
-rw-r--r--cddl/usr.sbin/dwatch/examples/Makefile1
-rw-r--r--cddl/usr.sbin/dwatch/examples/profile_template1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/Makefile2
-rw-r--r--cddl/usr.sbin/dwatch/libexec/chmod1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/errno1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/io1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/ip1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/kill1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/nanosleep1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/open1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/proc1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/rw1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/sched1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/sendrecv1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/systop1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/tcp1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/udp1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/udplite1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/vop_create1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/vop_readdir1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/vop_rename1
-rw-r--r--cddl/usr.sbin/dwatch/libexec/vop_symlink1
-rw-r--r--cddl/usr.sbin/lockstat/Makefile8
-rw-r--r--cddl/usr.sbin/lockstat/Makefile.depend9
-rw-r--r--cddl/usr.sbin/plockstat/Makefile8
-rw-r--r--cddl/usr.sbin/plockstat/Makefile.depend9
-rw-r--r--cddl/usr.sbin/plockstat/plockstat.12
-rw-r--r--cddl/usr.sbin/tests/Makefile1
-rw-r--r--cddl/usr.sbin/tests/Makefile.depend1
-rw-r--r--cddl/usr.sbin/zdb/Makefile4
-rw-r--r--cddl/usr.sbin/zdb/Makefile.depend14
-rw-r--r--cddl/usr.sbin/zfsd/Makefile2
-rw-r--r--cddl/usr.sbin/zfsd/Makefile.common3
-rw-r--r--cddl/usr.sbin/zfsd/Makefile.depend8
-rw-r--r--cddl/usr.sbin/zfsd/callout.cc2
-rw-r--r--cddl/usr.sbin/zfsd/callout.h2
-rw-r--r--cddl/usr.sbin/zfsd/case_file.cc49
-rw-r--r--cddl/usr.sbin/zfsd/case_file.h21
-rw-r--r--cddl/usr.sbin/zfsd/tests/Makefile1
-rw-r--r--cddl/usr.sbin/zfsd/tests/libmocks.c2
-rw-r--r--cddl/usr.sbin/zfsd/tests/libmocks.h2
-rw-r--r--cddl/usr.sbin/zfsd/tests/zfsd_unittest.cc46
-rw-r--r--cddl/usr.sbin/zfsd/tests/zfsd_unittest.supp1
-rw-r--r--cddl/usr.sbin/zfsd/vdev.cc8
-rw-r--r--cddl/usr.sbin/zfsd/vdev.h2
-rw-r--r--cddl/usr.sbin/zfsd/vdev_iterator.cc16
-rw-r--r--cddl/usr.sbin/zfsd/vdev_iterator.h2
-rw-r--r--cddl/usr.sbin/zfsd/zfsd.82
-rw-r--r--cddl/usr.sbin/zfsd/zfsd.cc7
-rw-r--r--cddl/usr.sbin/zfsd/zfsd.h2
-rw-r--r--cddl/usr.sbin/zfsd/zfsd_event.cc26
-rw-r--r--cddl/usr.sbin/zfsd/zfsd_event.h2
-rw-r--r--cddl/usr.sbin/zfsd/zfsd_exception.cc4
-rw-r--r--cddl/usr.sbin/zfsd/zfsd_exception.h2
-rw-r--r--cddl/usr.sbin/zfsd/zfsd_main.cc3
-rw-r--r--cddl/usr.sbin/zfsd/zpool_list.cc2
-rw-r--r--cddl/usr.sbin/zfsd/zpool_list.h4
-rw-r--r--cddl/usr.sbin/zhack/Makefile2
-rw-r--r--cddl/usr.sbin/zhack/Makefile.depend16
389 files changed, 968 insertions, 1216 deletions
diff --git a/cddl/Makefile b/cddl/Makefile
index 284a370c0167..c83acca43119 100644
--- a/cddl/Makefile
+++ b/cddl/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <src.opts.mk>
diff --git a/cddl/Makefile.inc b/cddl/Makefile.inc
index 687068d599e8..b306a28b5c84 100644
--- a/cddl/Makefile.inc
+++ b/cddl/Makefile.inc
@@ -1,4 +1,3 @@
-# $FreeBSD$
OPENSOLARIS_USR_DISTDIR= ${.CURDIR}/../../../cddl/contrib/opensolaris
OPENSOLARIS_SYS_DISTDIR= ${.CURDIR}/../../../sys/cddl/contrib/opensolaris
diff --git a/cddl/compat/opensolaris/include/alloca.h b/cddl/compat/opensolaris/include/alloca.h
index b8433c100dc2..723115ea2af1 100644
--- a/cddl/compat/opensolaris/include/alloca.h
+++ b/cddl/compat/opensolaris/include/alloca.h
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
*/
#ifndef _COMPAT_OPENSOLARIS_ALLOCA_H_
diff --git a/cddl/compat/opensolaris/include/assert.h b/cddl/compat/opensolaris/include/assert.h
index 0887093d5d64..5afaae7166bf 100644
--- a/cddl/compat/opensolaris/include/assert.h
+++ b/cddl/compat/opensolaris/include/assert.h
@@ -22,8 +22,6 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $FreeBSD$
*/
#undef assert
diff --git a/cddl/compat/opensolaris/include/devid.h b/cddl/compat/opensolaris/include/devid.h
index 205e461f8956..6718ce2b9fbc 100644
--- a/cddl/compat/opensolaris/include/devid.h
+++ b/cddl/compat/opensolaris/include/devid.h
@@ -18,8 +18,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright 2006 Sun Microsystems, Inc. All rights reserved.
diff --git a/cddl/compat/opensolaris/include/dtrace.h b/cddl/compat/opensolaris/include/dtrace.h
index 9630f9e74f58..7696d74a1414 100644
--- a/cddl/compat/opensolaris/include/dtrace.h
+++ b/cddl/compat/opensolaris/include/dtrace.h
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
*/
#ifndef _COMPAT_OPENSOLARIS_DTRACE_H_
diff --git a/cddl/compat/opensolaris/include/fcntl.h b/cddl/compat/opensolaris/include/fcntl.h
index b962bb4855ee..dd1a66cbbcae 100644
--- a/cddl/compat/opensolaris/include/fcntl.h
+++ b/cddl/compat/opensolaris/include/fcntl.h
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
*/
#ifndef _COMPAT_OPENSOLARIS_FCNTL_H_
diff --git a/cddl/compat/opensolaris/include/fsshare.h b/cddl/compat/opensolaris/include/fsshare.h
index 11a8dbf0b04d..0492006892f1 100644
--- a/cddl/compat/opensolaris/include/fsshare.h
+++ b/cddl/compat/opensolaris/include/fsshare.h
@@ -22,8 +22,6 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $FreeBSD$
*/
#ifndef _OPENSOLARIS_FSSHARE_H_
diff --git a/cddl/compat/opensolaris/include/libintl.h b/cddl/compat/opensolaris/include/libintl.h
index da13f4749081..5dbc06a75b2f 100644
--- a/cddl/compat/opensolaris/include/libintl.h
+++ b/cddl/compat/opensolaris/include/libintl.h
@@ -1,4 +1,3 @@
-/* $FreeBSD$ */
#ifndef _LIBINTL_H_
#define _LIBINTL_H_
diff --git a/cddl/compat/opensolaris/include/libproc.h b/cddl/compat/opensolaris/include/libproc.h
index 428fa6cf53fe..9c153cd817e9 100644
--- a/cddl/compat/opensolaris/include/libproc.h
+++ b/cddl/compat/opensolaris/include/libproc.h
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
*/
#ifndef _COMPAT_OPENSOLARIS_LIBPROC_H_
@@ -35,9 +33,6 @@
#define ps_prochandle proc_handle
#define Lmid_t int
-#define PR_RLC 0x0001
-#define PR_KLC 0x0002
-
#include_next <libproc.h>
#endif
diff --git a/cddl/compat/opensolaris/include/libshare.h b/cddl/compat/opensolaris/include/libshare.h
index 82aacadd93a9..eb93933ed901 100644
--- a/cddl/compat/opensolaris/include/libshare.h
+++ b/cddl/compat/opensolaris/include/libshare.h
@@ -22,8 +22,6 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $FreeBSD$
*/
#ifndef _OPENSOLARIS_LIBSHARE_H_
diff --git a/cddl/compat/opensolaris/include/priv.h b/cddl/compat/opensolaris/include/priv.h
index 2fee5b0d40c8..182921a02b3f 100644
--- a/cddl/compat/opensolaris/include/priv.h
+++ b/cddl/compat/opensolaris/include/priv.h
@@ -1,4 +1,3 @@
-/* $FreeBSD$ */
#ifndef _OPENSOLARIS_PRIV_H_
#define _OPENSOLARIS_PRIV_H_
diff --git a/cddl/compat/opensolaris/include/sha2.h b/cddl/compat/opensolaris/include/sha2.h
index 488f2dbd8b47..1add5365da21 100644
--- a/cddl/compat/opensolaris/include/sha2.h
+++ b/cddl/compat/opensolaris/include/sha2.h
@@ -22,8 +22,6 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $FreeBSD$
*/
#ifndef _OPENSOLARIS_SHA2_H_
diff --git a/cddl/compat/opensolaris/include/solaris.h b/cddl/compat/opensolaris/include/solaris.h
index 9bead018bcec..b4fb71be92a6 100644
--- a/cddl/compat/opensolaris/include/solaris.h
+++ b/cddl/compat/opensolaris/include/solaris.h
@@ -1,4 +1,3 @@
-/* $FreeBSD$ */
#ifndef _SOLARIS_H_
#define _SOLARIS_H_
diff --git a/cddl/compat/opensolaris/include/stdio.h b/cddl/compat/opensolaris/include/stdio.h
index eba348744475..3c4f323c355f 100644
--- a/cddl/compat/opensolaris/include/stdio.h
+++ b/cddl/compat/opensolaris/include/stdio.h
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
*/
#ifndef _COMPAT_OPENSOLARIS_STDIO_H_
diff --git a/cddl/compat/opensolaris/include/stdlib.h b/cddl/compat/opensolaris/include/stdlib.h
deleted file mode 100644
index 9ba32322c03b..000000000000
--- a/cddl/compat/opensolaris/include/stdlib.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 John Birrell <jb@freebsd.org>
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- * $FreeBSD$
- *
- */
-
-#include_next <stdlib.h>
-
-#ifndef _COMPAT_OPENSOLARIS_STDLIB_H_
-#define _COMPAT_OPENSOLARIS_STDLIB_H_
-
-#define getexecname getprogname
-
-#endif
diff --git a/cddl/compat/opensolaris/include/strings.h b/cddl/compat/opensolaris/include/strings.h
index a62bbc845e15..913f0214febc 100644
--- a/cddl/compat/opensolaris/include/strings.h
+++ b/cddl/compat/opensolaris/include/strings.h
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
*/
#ifndef _COMPAT_OPENSOLARIS_STRINGS_H_
diff --git a/cddl/compat/opensolaris/include/thread_pool.h b/cddl/compat/opensolaris/include/thread_pool.h
index 3bd23a6dd2aa..3f4f74212d78 100644
--- a/cddl/compat/opensolaris/include/thread_pool.h
+++ b/cddl/compat/opensolaris/include/thread_pool.h
@@ -25,7 +25,6 @@
*/
/*
- * $FreeBSD$
*/
#ifndef _THREAD_POOL_H_
diff --git a/cddl/compat/opensolaris/include/unistd.h b/cddl/compat/opensolaris/include/unistd.h
index e1a1bc81e60f..48c284cfb45c 100644
--- a/cddl/compat/opensolaris/include/unistd.h
+++ b/cddl/compat/opensolaris/include/unistd.h
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
*/
#ifndef _COMPAT_OPENSOLARIS_UNISTD_H_
diff --git a/cddl/compat/opensolaris/include/zone.h b/cddl/compat/opensolaris/include/zone.h
index 8c377cf6574d..66a041772963 100644
--- a/cddl/compat/opensolaris/include/zone.h
+++ b/cddl/compat/opensolaris/include/zone.h
@@ -1,4 +1,3 @@
-/* $FreeBSD$ */
#ifndef _ZONE_H_
#define _ZONE_H_
diff --git a/cddl/compat/opensolaris/lib/libumem/umem.c b/cddl/compat/opensolaris/lib/libumem/umem.c
index 9dc101f2e65f..e9662ce3c1e8 100644
--- a/cddl/compat/opensolaris/lib/libumem/umem.c
+++ b/cddl/compat/opensolaris/lib/libumem/umem.c
@@ -17,8 +17,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright 2006 Ricardo Correia. All rights reserved.
diff --git a/cddl/compat/opensolaris/lib/libumem/umem.h b/cddl/compat/opensolaris/lib/libumem/umem.h
index da4b32fa551e..971cde36e1b2 100644
--- a/cddl/compat/opensolaris/lib/libumem/umem.h
+++ b/cddl/compat/opensolaris/lib/libumem/umem.h
@@ -18,8 +18,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
diff --git a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1 b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1
index 8724b27f4cbb..42367b99b786 100644
--- a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1
+++ b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.1
@@ -20,7 +20,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd September 7, 2021
+.Dd February 24, 2023
.Dt DTRACE 1
.Os
.Sh NAME
@@ -29,7 +29,7 @@
.Sh SYNOPSIS
.Nm
.Op Fl 32 | Fl 64
-.Op Fl aACeFGhHlqSvVwZ
+.Op Fl aACdeFGhHlqSvVwZ
.Op Fl b Ar bufsz
.Op Fl c Ar cmd
.Op Fl D Ar name Op Ns = Ns value
@@ -195,6 +195,12 @@ option.
For a description of the set of tokens defined by the D compiler when invoking
the C preprocessor, see
.Fl X .
+.It Fl d
+Dump the D script to standard output, after syntactic transformations have been
+applied.
+For example, if-statements in D are implemented using such transformations: a
+conditional clause in a probe body is replaced at compile-time by a separate
+probe predicated on the original condition.
.It Fl D Ar name Op Ns = Ns value
Define
.Ar name
@@ -803,11 +809,6 @@ failed or that the specified request could not be satisfied.
.It 2
Invalid command line options or arguments were specified.
.El
-.Sh HISTORY
-The
-.Nm
-utility first appeared in
-.Fx 7.1 .
.Sh SEE ALSO
.Xr cpp 1 ,
.Xr elf 5 ,
@@ -815,3 +816,8 @@ utility first appeared in
.Rs
.%T Solaris Dynamic Tracing Guide
.Re
+.Sh HISTORY
+The
+.Nm
+utility first appeared in
+.Fx 7.1 .
diff --git a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c
index 06eff2055c17..cdc476a43b08 100644
--- a/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c
+++ b/cddl/contrib/opensolaris/cmd/dtrace/dtrace.c
@@ -77,7 +77,7 @@ typedef struct dtrace_cmd {
#define E_USAGE 2
static const char DTRACE_OPTSTR[] =
- "3:6:aAb:Bc:CD:ef:FGhHi:I:lL:m:n:o:p:P:qs:SU:vVwx:X:Z";
+ "3:6:aAb:Bc:CdD:ef:FGhHi:I:lL:m:n:o:p:P:qs:SU:vVwx:X:Z";
static char **g_argv;
static int g_argc;
@@ -130,7 +130,7 @@ usage(FILE *fp)
{
static const char predact[] = "[[ predicate ] action ]";
- (void) fprintf(fp, "Usage: %s [-32|-64] [-aACeFGhHlqSvVwZ] "
+ (void) fprintf(fp, "Usage: %s [-32|-64] [-aACdeFGhHlqSvVwZ] "
"[-b bufsz] [-c cmd] [-D name[=def]]\n\t[-I path] [-L path] "
"[-o output] [-p pid] [-s script] [-U name]\n\t"
"[-x opt[=val]] [-X a|c|s|t]\n\n"
@@ -152,6 +152,7 @@ usage(FILE *fp)
"\t-b set trace buffer size\n"
"\t-c run specified command and exit upon its completion\n"
"\t-C run cpp(1) preprocessor on script files\n"
+ "\t-d dump script after syntactic transformations\n"
"\t-D define symbol when invoking preprocessor\n"
"\t-e exit after compiling request but prior to enabling probes\n"
"\t-f enable or list probes matching the specified function name\n"
@@ -1559,6 +1560,10 @@ main(int argc, char *argv[])
g_cflags |= DTRACE_C_CPP;
break;
+ case 'd':
+ g_cflags |= DTRACE_C_SUGAR;
+ break;
+
case 'D':
if (dtrace_setopt(g_dtp, "define", optarg) != 0)
dfatal("failed to set -D %s", optarg);
diff --git a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/kinst/tst.basic.ksh b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/kinst/tst.basic.ksh
new file mode 100644
index 000000000000..3005da74c895
--- /dev/null
+++ b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/kinst/tst.basic.ksh
@@ -0,0 +1,48 @@
+#!/usr/bin/ksh
+#
+# 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.
+#
+# 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 (c) 2022 Mark Johnston <markj@FreeBSD.org>
+#
+
+script()
+{
+ $dtrace -q -s /dev/stdin <<__EOF__
+kinst::vm_fault: {}
+kinst::amd64_syscall: {}
+kinst::exit1: {}
+kinst::spinlock_enter: {}
+kinst::memcpy: {}
+
+tick-10s {exit(0);}
+__EOF__
+}
+
+spin()
+{
+ while true; do
+ ls -la / >/dev/null 2>&1
+ done
+}
+
+if [ $# != 1 ]; then
+ echo expected one argument: '<'dtrace-path'>'
+ exit 2
+fi
+
+dtrace=$1
+
+spin &
+child=$!
+
+script
+exit $?
diff --git a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh
index 59094e3da37f..1c23b2a0b9e0 100644
--- a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh
+++ b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh
@@ -61,7 +61,7 @@ EOF
sleeper()
{
while true; do
- $longsleep &
+ limits -c unlimited $longsleep &
/bin/sleep 1
kill -SEGV $!
done
diff --git a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/translators/tst.OutputAliasTrans.d b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/translators/tst.OutputAliasTrans.d
index cd4715319913..c6bfff2181e6 100644
--- a/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/translators/tst.OutputAliasTrans.d
+++ b/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/translators/tst.OutputAliasTrans.d
@@ -37,23 +37,23 @@
#pragma D option quiet
-struct input_struct {
+struct dtrace_input_struct {
int ii;
char ic;
};
-struct output_struct {
+struct dtrace_output_struct {
int oi;
char oc;
};
-typedef struct output_struct output_t;
+typedef struct dtrace_output_struct dtrace_output_t;
-translator output_t < struct input_struct *ivar >
+translator dtrace_output_t < struct dtrace_input_struct *ivar >
{
- oi = ((struct input_struct *) ivar)->ii;
- oc = ((struct input_struct *) ivar)->ic;
+ oi = ((struct dtrace_input_struct *) ivar)->ii;
+ oc = ((struct dtrace_input_struct *) ivar)->ic;
};
BEGIN
diff --git a/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c b/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c
index a7378980bc56..2cbad3442efb 100644
--- a/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c
+++ b/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c
@@ -606,14 +606,14 @@ predicate_add(char **pred, char *what, char *cmp, uintptr_t value)
if (*pred[0] != '\0') {
if (cmp != NULL) {
- (void) sprintf(new, "(%s) && (%s %s 0x%p)",
+ (void) sprintf(new, "(%s) && (%s %s %p)",
*pred, what, cmp, (void *)value);
} else {
(void) sprintf(new, "(%s) && (%s)", *pred, what);
}
} else {
if (cmp != NULL) {
- (void) sprintf(new, "%s %s 0x%p",
+ (void) sprintf(new, "%s %s %p",
what, cmp, (void *)value);
} else {
(void) sprintf(new, "%s", what);
@@ -632,7 +632,7 @@ predicate_destroy(char **pred)
}
static void
-filter_add(char **filt, char *what, uintptr_t base, uintptr_t size)
+filter_add(char **filt, char *what, uintptr_t base, size_t size)
{
char buf[256], *c = buf, *new;
int len, newlen;
diff --git a/cddl/contrib/opensolaris/cmd/lockstat/sym.c b/cddl/contrib/opensolaris/cmd/lockstat/sym.c
index b5366c566857..7516e7d435f4 100644
--- a/cddl/contrib/opensolaris/cmd/lockstat/sym.c
+++ b/cddl/contrib/opensolaris/cmd/lockstat/sym.c
@@ -42,6 +42,7 @@
#include <libelf.h>
#include <link.h>
#include <elf.h>
+#include <gelf.h>
#ifdef illumos
#include <sys/machelf.h>
@@ -54,7 +55,6 @@
#endif
#include <sys/cpuvar.h>
-
typedef struct syment {
uintptr_t addr;
char *name;
@@ -73,11 +73,6 @@ static char maxsymname[64];
#endif
#endif
-#define __sElfN(x) typedef __CONCAT(__CONCAT(__CONCAT(Elf,__ELF_WORD_SIZE),_),x) x
-__sElfN(Sym);
-__sElfN(Shdr);
-#define elf_getshdr __elfN(getshdr)
-
static void
add_symbol(char *name, uintptr_t addr, size_t size)
{
@@ -174,7 +169,7 @@ symtab_init(void)
{
Elf *elf;
Elf_Scn *scn = NULL;
- Sym *symtab, *symp, *lastsym;
+ GElf_Sym *symtab, *symp, *lastsym;
char *strtab;
uint_t cnt;
int fd;
@@ -198,13 +193,13 @@ symtab_init(void)
(void) elf_version(EV_CURRENT);
elf = elf_begin(fd, ELF_C_READ, NULL);
-
for (cnt = 1; (scn = elf_nextscn(elf, scn)) != NULL; cnt++) {
- Shdr *shdr = elf_getshdr(scn);
- if (shdr->sh_type == SHT_SYMTAB) {
- symtab = (Sym *)elf_getdata(scn, NULL)->d_buf;
- nsyms = shdr->sh_size / shdr->sh_entsize;
- strindex = shdr->sh_link;
+ GElf_Shdr shdr;
+ (void) gelf_getshdr(scn, &shdr);
+ if (shdr.sh_type == SHT_SYMTAB) {
+ symtab = (GElf_Sym *)elf_getdata(scn, NULL)->d_buf;
+ nsyms = shdr.sh_size / shdr.sh_entsize;
+ strindex = shdr.sh_link;
}
}
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_cc.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_cc.c
index e63771c91e08..f3fda4af834e 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_cc.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_cc.c
@@ -2478,10 +2478,7 @@ dt_compile(dtrace_hdl_t *dtp, int context, dtrace_probespec_t pspec, void *arg,
"not referenced)\n", yypcb->pcb_sargv[argc - 1], argc - 1);
}
- /*
- * Perform sugar transformations (for "if" / "else") and replace the
- * existing clause chain with the new one.
- */
+ /* Perform sugar transformations. */
if (context == DT_CTX_DPROG) {
dt_node_t *dnp, *next_dnp;
dt_node_t *new_list = NULL;
@@ -2492,8 +2489,17 @@ dt_compile(dtrace_hdl_t *dtp, int context, dtrace_probespec_t pspec, void *arg,
next_dnp = dnp->dn_list;
dnp->dn_list = NULL;
- if (dnp->dn_kind == DT_NODE_CLAUSE)
+ if (dnp->dn_kind == DT_NODE_CLAUSE) {
dnp = dt_compile_sugar(dtp, dnp);
+ if (cflags & DTRACE_C_SUGAR) {
+ dt_node_t *p;
+
+ dt_printd(dnp, stdout, 0);
+ for (p = dnp->dn_list; p != NULL;
+ p = p->dn_list)
+ dt_printd(p, stdout, 0);
+ }
+ }
/* append node to the new list */
new_list = dt_node_link(new_list, dnp);
}
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h
index b3f69bb6329d..1e62bd6b21db 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h
@@ -323,6 +323,7 @@ struct dtrace_hdl {
#endif
int dt_fd; /* file descriptor for dtrace pseudo-device */
int dt_ftfd; /* file descriptor for fasttrap pseudo-device */
+ int dt_kinstfd; /* file descriptor for kinst pseudo-device */
int dt_fterr; /* saved errno from failed open of dt_ftfd */
int dt_cdefs_fd; /* file descriptor for C CTF debugging cache */
int dt_ddefs_fd; /* file descriptor for D CTF debugging cache */
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.c
index 0b3dac0224f9..442c6f940733 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_link.c
@@ -215,10 +215,6 @@ prepare_elf32(dtrace_hdl_t *dtp, const dof_hdr_t *dof, dof_elf32_t *dep)
dofr[j].dofr_offset;
rel->r_info = ELF32_R_INFO(count + dep->de_global,
R_386_PC32);
-#elif defined(__mips__)
-/* XXX */
- printf("%s:%s(%d): MIPS not implemented\n",
- __FUNCTION__, __FILE__, __LINE__);
#elif defined(__powerpc__)
/*
* Add 4 bytes to hit the low half of this 64-bit
@@ -229,9 +225,9 @@ prepare_elf32(dtrace_hdl_t *dtp, const dof_hdr_t *dof, dof_elf32_t *dep)
rel->r_info = ELF32_R_INFO(count + dep->de_global,
R_PPC_REL32);
#elif defined(__riscv)
-/* XXX */
- printf("%s:%s(%d): RISC-V not implemented\n",
- __FUNCTION__, __FILE__, __LINE__);
+ rel->r_offset = s->dofs_offset + dofr[j].dofr_offset;
+ rel->r_info = ELF32_R_INFO(count + dep->de_global,
+ R_RISCV_32_PCREL);
#else
#error unknown ISA
#endif
@@ -401,15 +397,15 @@ prepare_elf64(dtrace_hdl_t *dtp, const dof_hdr_t *dof, dof_elf64_t *dep)
R_AARCH64_PREL64);
#elif defined(__arm__)
/* XXX */
-#elif defined(__mips__)
-/* XXX */
#elif defined(__powerpc__)
rel->r_offset = s->dofs_offset +
dofr[j].dofr_offset;
rel->r_info = ELF64_R_INFO(count + dep->de_global,
R_PPC64_REL64);
#elif defined(__riscv)
-/* XXX */
+ rel->r_offset = s->dofs_offset + dofr[j].dofr_offset;
+ rel->r_info = ELF64_R_INFO(count + dep->de_global,
+ R_RISCV_32_PCREL);
#elif defined(__i386) || defined(__amd64)
rel->r_offset = s->dofs_offset +
dofr[j].dofr_offset;
@@ -504,14 +500,28 @@ dump_elf32(dtrace_hdl_t *dtp, const dof_hdr_t *dof, int fd)
elf_file.ehdr.e_type = ET_REL;
#if defined(__arm__)
elf_file.ehdr.e_machine = EM_ARM;
-#elif defined(__mips__)
- elf_file.ehdr.e_machine = EM_MIPS;
#elif defined(__powerpc__)
elf_file.ehdr.e_machine = EM_PPC;
#elif defined(__i386) || defined(__amd64)
elf_file.ehdr.e_machine = EM_386;
#elif defined(__aarch64__)
elf_file.ehdr.e_machine = EM_AARCH64;
+#elif defined(__riscv)
+ elf_file.ehdr.e_machine = EM_RISCV;
+
+ /* Set the ELF flags according to our current ABI */
+#if defined(__riscv_compressed)
+ elf_file.ehdr.e_flags |= EF_RISCV_RVC;
+#endif
+#if defined(__riscv_float_abi_soft)
+ elf_file.ehdr.e_flags |= EF_RISCV_FLOAT_ABI_SOFT;
+#endif
+#if defined(__riscv_float_abi_single)
+ elf_file.ehdr.e_flags |= EF_RISCV_FLOAT_ABI_SINGLE;
+#endif
+#if defined(__riscv_float_abi_double)
+ elf_file.ehdr.e_flags |= EF_RISCV_FLOAT_ABI_DOUBLE;
+#endif
#endif
elf_file.ehdr.e_version = EV_CURRENT;
elf_file.ehdr.e_shoff = sizeof (Elf32_Ehdr);
@@ -572,7 +582,7 @@ dump_elf32(dtrace_hdl_t *dtp, const dof_hdr_t *dof, int fd)
} else {
shp = &elf_file.shdr[ESHDR_REL];
shp->sh_name = 37; /* DTRACE_SHSTRTAB32[37] = ".rel.SUNW_dof" */
- shp->sh_flags = SHF_ALLOC;
+ shp->sh_flags = 0;
shp->sh_type = SHT_REL;
shp->sh_entsize = sizeof (de.de_rel[0]);
shp->sh_link = ESHDR_SYMTAB;
@@ -644,8 +654,6 @@ dump_elf64(dtrace_hdl_t *dtp, const dof_hdr_t *dof, int fd)
elf_file.ehdr.e_type = ET_REL;
#if defined(__arm__)
elf_file.ehdr.e_machine = EM_ARM;
-#elif defined(__mips__)
- elf_file.ehdr.e_machine = EM_MIPS;
#elif defined(__powerpc64__)
#if defined(_CALL_ELF) && _CALL_ELF == 2
elf_file.ehdr.e_flags = 2;
@@ -655,6 +663,22 @@ dump_elf64(dtrace_hdl_t *dtp, const dof_hdr_t *dof, int fd)
elf_file.ehdr.e_machine = EM_AMD64;
#elif defined(__aarch64__)
elf_file.ehdr.e_machine = EM_AARCH64;
+#elif defined(__riscv)
+ elf_file.ehdr.e_machine = EM_RISCV;
+
+ /* Set the ELF flags according to our current ABI */
+#if defined(__riscv_compressed)
+ elf_file.ehdr.e_flags |= EF_RISCV_RVC;
+#endif
+#if defined(__riscv_float_abi_soft)
+ elf_file.ehdr.e_flags |= EF_RISCV_FLOAT_ABI_SOFT;
+#endif
+#if defined(__riscv_float_abi_single)
+ elf_file.ehdr.e_flags |= EF_RISCV_FLOAT_ABI_SINGLE;
+#endif
+#if defined(__riscv_float_abi_double)
+ elf_file.ehdr.e_flags |= EF_RISCV_FLOAT_ABI_DOUBLE;
+#endif
#endif
elf_file.ehdr.e_version = EV_CURRENT;
elf_file.ehdr.e_shoff = sizeof (Elf64_Ehdr);
@@ -715,7 +739,7 @@ dump_elf64(dtrace_hdl_t *dtp, const dof_hdr_t *dof, int fd)
} else {
shp = &elf_file.shdr[ESHDR_REL];
shp->sh_name = 37; /* DTRACE_SHSTRTAB64[37] = ".rel.SUNW_dof" */
- shp->sh_flags = SHF_ALLOC;
+ shp->sh_flags = 0;
shp->sh_type = SHT_RELA;
shp->sh_entsize = sizeof (de.de_rel[0]);
shp->sh_link = ESHDR_SYMTAB;
@@ -843,17 +867,6 @@ dt_modtext(dtrace_hdl_t *dtp, char *p, int isenabled, GElf_Rela *rela,
__LINE__);
return (-1);
}
-#elif defined(__mips__)
-#define DT_REL_NONE R_MIPS_NONE
-
-static int
-dt_modtext(dtrace_hdl_t *dtp, char *p, int isenabled, GElf_Rela *rela,
- uint32_t *off)
-{
- printf("%s:%s(%d): MIPS not implemented\n", __FUNCTION__, __FILE__,
- __LINE__);
- return (-1);
-}
#elif defined(__powerpc__)
/* The sentinel is 'xor r3,r3,r3'. */
#define DT_OP_XOR_R3 0x7c631a78
@@ -938,14 +951,74 @@ dt_modtext(dtrace_hdl_t *dtp, char *p, int isenabled, GElf_Rela *rela,
return (0);
}
#elif defined(__riscv)
+#define DT_OP_NOP 0x00000013 /* addi x0, x0, 0 */
+#define DT_OP_RET 0x00008067 /* jalr x0, x1, 0 */
+#define DT_OP_IS_AUIPC(op) (((op) & 0x7f) == 0x17)
+#define DT_OP_IS_JALR(op) (((op) & 0x707f) == 0x67)
+#define DT_OP_JALR_CALL 0x000080e7 /* jalr x1, x1, 0 */
+#define DT_OP_JALR_TAIL 0x00030067 /* jalr x0, x6, 0 */
#define DT_REL_NONE R_RISCV_NONE
+
static int
dt_modtext(dtrace_hdl_t *dtp, char *p, int isenabled, GElf_Rela *rela,
uint32_t *off)
{
- printf("%s:%s(%d): RISC-V implementation required\n", __FUNCTION__,
- __FILE__, __LINE__);
- return (-1);
+ uint32_t *ip;
+
+ /*
+ * XXX: this implementation is untested, but should serve as a decent
+ * starting point.
+ */
+
+ /*
+ * Ensure that the offset is aligned on a compressed-instruction
+ * boundary.
+ */
+ if ((rela->r_offset & (sizeof (uint16_t) - 1)) != 0)
+ return (-1);
+
+ /*
+ * We only know about some specific relocation types.
+ * We also recognize relocation type NONE, since that gets used for
+ * relocations of USDT probes, and we might be re-processing a file.
+ */
+ if (GELF_R_TYPE(rela->r_info) != R_RISCV_CALL &&
+ GELF_R_TYPE(rela->r_info) != R_RISCV_CALL_PLT &&
+ GELF_R_TYPE(rela->r_info) != R_RISCV_NONE)
+ return (-1);
+
+ ip = (uint32_t *)(p + rela->r_offset);
+
+ /*
+ * We may have already processed this object file in an earlier linker
+ * invocation. Check to see if the present instruction sequence matches
+ * the one we would install below.
+ */
+ if (ip[0] == DT_OP_NOP && (ip[1] == DT_OP_NOP || ip[1] == DT_OP_RET))
+ return (0);
+
+ /*
+ * We expect a auipc+jalr pair, either from a call or a tail.
+ * - call: auipc x1 0; jalr x1, x1, 0
+ * - tail: auipc x6 0; jalr x0, x6, 0
+ */
+ if (!DT_OP_IS_AUIPC(ip[0]) || !DT_OP_IS_JALR(ip[1]))
+ return (-1);
+
+ /*
+ * On riscv, we do not have to differentiate between regular probes and
+ * is-enabled probes. Calls are to be converted into a no-op whereas
+ * tail calls should become a return.
+ */
+ if (ip[1] == DT_OP_JALR_CALL) {
+ ip[0] = DT_OP_NOP;
+ ip[1] = DT_OP_NOP;
+ } else {
+ ip[0] = DT_OP_NOP;
+ ip[1] = DT_OP_RET;
+ }
+
+ return (0);
}
#elif defined(__i386) || defined(__amd64)
@@ -1167,9 +1240,7 @@ process_obj(dtrace_hdl_t *dtp, const char *obj, int *eprobesp)
if (dtp->dt_oflags & DTRACE_O_LP64) {
eclass = ELFCLASS64;
-#if defined(__mips__)
- emachine1 = emachine2 = EM_MIPS;
-#elif defined(__powerpc__)
+#if defined(__powerpc__)
emachine1 = emachine2 = EM_PPC64;
#if !defined(_CALL_ELF) || _CALL_ELF == 1
uses_funcdesc = 1;
@@ -1178,14 +1249,14 @@ process_obj(dtrace_hdl_t *dtp, const char *obj, int *eprobesp)
emachine1 = emachine2 = EM_AMD64;
#elif defined(__aarch64__)
emachine1 = emachine2 = EM_AARCH64;
+#elif defined(__riscv)
+ emachine1 = emachine2 = EM_RISCV;
#endif
symsize = sizeof (Elf64_Sym);
} else {
eclass = ELFCLASS32;
#if defined(__arm__)
emachine1 = emachine2 = EM_ARM;
-#elif defined(__mips__)
- emachine1 = emachine2 = EM_MIPS;
#elif defined(__powerpc__)
emachine1 = emachine2 = EM_PPC;
#elif defined(__i386) || defined(__amd64)
@@ -1612,6 +1683,7 @@ process_obj(dtrace_hdl_t *dtp, const char *obj, int *eprobesp)
* invocation.
*/
if (rsym.st_shndx != SHN_ABS) {
+ rsym.st_info = GELF_ST_INFO(STB_WEAK, STT_FUNC);
rsym.st_shndx = SHN_ABS;
(void) gelf_update_sym(data_sym, ndx, &rsym);
}
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c
index b9408944f8c5..281c787de533 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c
@@ -1129,33 +1129,21 @@ dt_module_getctflib(dtrace_hdl_t *dtp, dt_module_t *dmp, const char *name)
* including the path.
*/
static void
-#ifdef illumos
-dt_module_update(dtrace_hdl_t *dtp, const char *name)
-#else
dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
-#endif
{
char fname[MAXPATHLEN];
struct stat64 st;
int fd, err, bits;
-#ifdef __FreeBSD__
struct module_stat ms;
dt_kmodule_t *dkmp;
uint_t h;
int modid;
-#endif
-
dt_module_t *dmp;
const char *s;
size_t shstrs;
GElf_Shdr sh;
Elf_Data *dp;
Elf_Scn *sp;
-
-#ifdef illumos
- (void) snprintf(fname, sizeof (fname),
- "%s/%s/object", OBJFS_ROOT, name);
-#else
GElf_Ehdr ehdr;
GElf_Phdr ph;
char name[MAXPATHLEN];
@@ -1165,7 +1153,6 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
(void) strlcpy(name, k_stat->name, sizeof(name));
(void) strlcpy(fname, k_stat->pathname, sizeof(fname));
-#endif
if ((fd = open(fname, O_RDONLY)) == -1 || fstat64(fd, &st) == -1 ||
(dmp = dt_module_create(dtp, name)) == NULL) {
@@ -1174,6 +1161,9 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
return;
}
+ (void) strlcpy(dmp->dm_file, fname, sizeof(dmp->dm_file));
+ dmp->dm_modid = k_stat->id;
+
/*
* Since the module can unload out from under us (and /system/object
* will return ENOENT), tell libelf to cook the entire file now and
@@ -1206,7 +1196,6 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
dt_module_destroy(dtp, dmp);
return;
}
-#if defined(__FreeBSD__)
mapbase = (uintptr_t)k_stat->address;
gelf_getehdr(dmp->dm_elf, &ehdr);
is_elf_obj = (ehdr.e_type == ET_REL);
@@ -1219,7 +1208,6 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
return;
}
}
-#endif
/*
* Iterate over the section headers locating various sections of
* interest and use their attributes to flesh out the dt_module_t.
@@ -1228,7 +1216,6 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
if (gelf_getshdr(sp, &sh) == NULL || sh.sh_type == SHT_NULL ||
(s = elf_strptr(dmp->dm_elf, shstrs, sh.sh_name)) == NULL)
continue; /* skip any malformed sections */
-#if defined(__FreeBSD__)
if (sh.sh_size == 0)
continue;
if (sh.sh_type == SHT_PROGBITS || sh.sh_type == SHT_NOBITS) {
@@ -1240,7 +1227,6 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
dmp->dm_sec_offsets[elf_ndxscn(sp)] = sh.sh_addr;
mapbase += sh.sh_size;
}
-#endif
if (strcmp(s, ".text") == 0) {
dmp->dm_text_size = sh.sh_size;
dmp->dm_text_va = sh.sh_addr;
@@ -1254,17 +1240,10 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
(dp = elf_getdata(sp, NULL)) != NULL) {
bcopy(dp->d_buf, &dmp->dm_info,
MIN(sh.sh_size, sizeof (dmp->dm_info)));
- } else if (strcmp(s, ".filename") == 0 &&
- (dp = elf_getdata(sp, NULL)) != NULL) {
- (void) strlcpy(dmp->dm_file,
- dp->d_buf, sizeof (dmp->dm_file));
}
}
dmp->dm_flags |= DT_DM_KERNEL;
-#ifdef illumos
- dmp->dm_modid = (int)OBJFS_MODID(st.st_ino);
-#else
/*
* Include .rodata and special sections into .text.
* This depends on default section layout produced by GNU ld
@@ -1285,12 +1264,10 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
}
}
#endif
-#endif /* illumos */
if (dmp->dm_info.objfs_info_primary)
dmp->dm_flags |= DT_DM_PRIMARY;
-#ifdef __FreeBSD__
ms.version = sizeof(ms);
for (modid = kldfirstmod(k_stat->id); modid > 0;
modid = modnext(modid)) {
@@ -1315,7 +1292,6 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
dkmp->dkm_module = dmp;
dtp->dt_kmods[h] = dkmp;
}
-#endif
dt_dprintf("opened %d-bit module %s (%s) [%d]\n",
bits, dmp->dm_name, dmp->dm_file, dmp->dm_modid);
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c
index f55d488f4d91..fd770e180b47 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c
@@ -416,6 +416,8 @@ static const dt_ident_t _dtrace_globals[] = {
&dt_idops_func, "void(int)" },
{ "rand", DT_IDENT_FUNC, 0, DIF_SUBR_RAND, DT_ATTR_STABCMN, DT_VERS_1_0,
&dt_idops_func, "int()" },
+{ "regs", DT_IDENT_ARRAY, 0, DIF_VAR_REGS, DT_ATTR_STABCMN, DT_VERS_1_13,
+ &dt_idops_regs, NULL },
{ "rindex", DT_IDENT_FUNC, 0, DIF_SUBR_RINDEX, DT_ATTR_STABCMN, DT_VERS_1_1,
&dt_idops_func, "int(const char *, const char *, [int])" },
#ifdef illumos
@@ -1113,6 +1115,15 @@ dt_vopen(int version, int flags, int *errp,
*/
if (err == ENOENT && modfind("dtraceall") < 0) {
kldload("dtraceall"); /* ignore the error */
+#if __SIZEOF_LONG__ == 8
+ if (modfind("linux64elf") >= 0)
+ kldload("systrace_linux");
+ if (modfind("linuxelf") >= 0)
+ kldload("systrace_linux32");
+#else
+ if (modfind("linuxelf") >= 0)
+ kldload("systrace_linux");
+#endif
dtfd = open("/dev/dtrace/dtrace", O_RDWR | O_CLOEXEC);
err = errno;
}
@@ -1171,6 +1182,7 @@ alloc:
dtp->dt_version = version;
dtp->dt_fd = dtfd;
dtp->dt_ftfd = ftfd;
+ dtp->dt_kinstfd = -1;
dtp->dt_fterr = fterr;
dtp->dt_cdefs_fd = -1;
dtp->dt_ddefs_fd = -1;
@@ -1679,6 +1691,8 @@ dtrace_close(dtrace_hdl_t *dtp)
(void) close(dtp->dt_fd);
if (dtp->dt_ftfd != -1)
(void) close(dtp->dt_ftfd);
+ if (dtp->dt_kinstfd != -1)
+ (void) close(dtp->dt_kinstfd);
if (dtp->dt_cdefs_fd != -1)
(void) close(dtp->dt_cdefs_fd);
if (dtp->dt_ddefs_fd != -1)
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_parser.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_parser.c
index f028f99ccf64..2b85dd2b26b6 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_parser.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_parser.c
@@ -4767,8 +4767,8 @@ dt_printd(dt_node_t *dnp, FILE *fp, int depth)
dt_printd(dnp->dn_pred, fp, 0);
(void) fprintf(fp, "/\n");
}
- (void) fprintf(fp, "{\n");
+ (void) fprintf(fp, "{\n");
for (arg = dnp->dn_acts; arg != NULL; arg = arg->dn_list)
dt_printd(arg, fp, depth + 1);
(void) fprintf(fp, "}\n");
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
index 57a7db4ad0fd..c33ae955ba61 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
@@ -317,8 +317,7 @@ pfprint_fp(dtrace_hdl_t *dtp, FILE *fp, const char *format,
case sizeof (double):
return (dt_printf(dtp, fp, format,
*((double *)addr) / n));
-#if !defined(__arm__) && !defined(__powerpc__) && \
- !defined(__mips__) && !defined(__riscv)
+#if !defined(__arm__) && !defined(__powerpc__) && !defined(__riscv)
case sizeof (long double):
return (dt_printf(dtp, fp, format,
*((long double *)addr) / ldn));
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c
index 34bcc15b9ac7..b32dcea1f8ba 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c
@@ -80,10 +80,8 @@
* up using this condition and will then call the client handler as necessary.
*/
+#include <sys/syscall.h>
#include <sys/wait.h>
-#ifdef illumos
-#include <sys/lwp.h>
-#endif
#include <strings.h>
#include <signal.h>
#include <assert.h>
@@ -93,14 +91,10 @@
#include <dt_pid.h>
#include <dt_impl.h>
-#ifndef illumos
-#include <sys/syscall.h>
#include <libproc_compat.h>
-#define SYS_forksys SYS_fork
-#endif
#define IS_SYS_EXEC(w) (w == SYS_execve)
-#define IS_SYS_FORK(w) (w == SYS_vfork || w == SYS_forksys)
+#define IS_SYS_FORK(w) (w == SYS_vfork || w == SYS_fork)
static dt_bkpt_t *
dt_proc_bpcreate(dt_proc_t *dpr, uintptr_t addr, dt_bkpt_f *func, void *data)
@@ -147,38 +141,23 @@ dt_proc_bpdestroy(dt_proc_t *dpr, int delbkpts)
static void
dt_proc_bpmatch(dtrace_hdl_t *dtp, dt_proc_t *dpr)
{
-#ifdef illumos
- const lwpstatus_t *psp = &Pstatus(dpr->dpr_proc)->pr_lwp;
-#else
unsigned long pc;
-#endif
dt_bkpt_t *dbp;
assert(DT_MUTEX_HELD(&dpr->dpr_lock));
-#ifndef illumos
proc_regget(dpr->dpr_proc, REG_PC, &pc);
proc_bkptregadj(&pc);
-#endif
for (dbp = dt_list_next(&dpr->dpr_bps);
dbp != NULL; dbp = dt_list_next(dbp)) {
-#ifdef illumos
- if (psp->pr_reg[R_PC] == dbp->dbp_addr)
- break;
-#else
if (pc == dbp->dbp_addr)
break;
-#endif
}
if (dbp == NULL) {
dt_dprintf("pid %d: spurious breakpoint wakeup for %lx\n",
-#ifdef illumos
- (int)dpr->dpr_pid, (ulong_t)psp->pr_reg[R_PC]);
-#else
(int)dpr->dpr_pid, pc);
-#endif
return;
}
@@ -346,12 +325,8 @@ dt_proc_rdwatch(dt_proc_t *dpr, rd_event_e event, const char *evname)
}
(void) dt_proc_bpcreate(dpr, rdn.u.bptaddr,
-#ifdef illumos
- (dt_bkpt_f *)dt_proc_rdevent, (void *)evname);
-#else
/* XXX ugly */
(dt_bkpt_f *)dt_proc_rdevent, __DECONST(void *, evname));
-#endif
}
/*
@@ -361,34 +336,18 @@ dt_proc_rdwatch(dt_proc_t *dpr, rd_event_e event, const char *evname)
static void
dt_proc_attach(dt_proc_t *dpr, int exec)
{
-#ifdef illumos
- const pstatus_t *psp = Pstatus(dpr->dpr_proc);
-#endif
rd_err_e err;
GElf_Sym sym;
assert(DT_MUTEX_HELD(&dpr->dpr_lock));
if (exec) {
-#ifdef illumos
- if (psp->pr_lwp.pr_errno != 0)
- return; /* exec failed: nothing needs to be done */
-#endif
dt_proc_bpdestroy(dpr, B_FALSE);
-#ifdef illumos
- Preset_maps(dpr->dpr_proc);
-#endif
}
if ((dpr->dpr_rtld = Prd_agent(dpr->dpr_proc)) != NULL &&
(err = rd_event_enable(dpr->dpr_rtld, B_TRUE)) == RD_OK) {
-#ifdef illumos
- dt_proc_rdwatch(dpr, RD_PREINIT, "RD_PREINIT");
-#endif
dt_proc_rdwatch(dpr, RD_POSTINIT, "RD_POSTINIT");
-#ifdef illumos
- dt_proc_rdwatch(dpr, RD_DLACTIVITY, "RD_DLACTIVITY");
-#endif
} else {
dt_dprintf("pid %d: failed to enable rtld events: %s\n",
(int)dpr->dpr_pid, dpr->dpr_rtld ? rd_errstr(err) :
@@ -407,84 +366,6 @@ dt_proc_attach(dt_proc_t *dpr, int exec)
}
}
-/*
- * Wait for a stopped process to be set running again by some other debugger.
- * This is typically not required by /proc-based debuggers, since the usual
- * model is that one debugger controls one victim. But DTrace, as usual, has
- * its own needs: the stop() action assumes that prun(1) or some other tool
- * will be applied to resume the victim process. This could be solved by
- * adding a PCWRUN directive to /proc, but that seems like overkill unless
- * other debuggers end up needing this functionality, so we implement a cheap
- * equivalent to PCWRUN using the set of existing kernel mechanisms.
- *
- * Our intent is really not just to wait for the victim to run, but rather to
- * wait for it to run and then stop again for a reason other than the current
- * PR_REQUESTED stop. Since PCWSTOP/Pstopstatus() can be applied repeatedly
- * to a stopped process and will return the same result without affecting the
- * victim, we can just perform these operations repeatedly until Pstate()
- * changes, the representative LWP ID changes, or the stop timestamp advances.
- * dt_proc_control() will then rediscover the new state and continue as usual.
- * When the process is still stopped in the same exact state, we sleep for a
- * brief interval before waiting again so as not to spin consuming CPU cycles.
- */
-static void
-dt_proc_waitrun(dt_proc_t *dpr)
-{
- printf("%s:%s(%d): not implemented\n", __FUNCTION__, __FILE__,
- __LINE__);
-#ifdef DOODAD
- struct ps_prochandle *P = dpr->dpr_proc;
- const lwpstatus_t *psp = &Pstatus(P)->pr_lwp;
-
- int krflag = psp->pr_flags & (PR_KLC | PR_RLC);
- timestruc_t tstamp = psp->pr_tstamp;
- lwpid_t lwpid = psp->pr_lwpid;
-
- const long wstop = PCWSTOP;
- int pfd = Pctlfd(P);
-
- assert(DT_MUTEX_HELD(&dpr->dpr_lock));
- assert(psp->pr_flags & PR_STOPPED);
- assert(Pstate(P) == PS_STOP);
-
- /*
- * While we are waiting for the victim to run, clear PR_KLC and PR_RLC
- * so that if the libdtrace client is killed, the victim stays stopped.
- * dt_proc_destroy() will also observe this and perform PRELEASE_HANG.
- */
- (void) Punsetflags(P, krflag);
- Psync(P);
-
- (void) pthread_mutex_unlock(&dpr->dpr_lock);
-
- while (!dpr->dpr_quit) {
- if (write(pfd, &wstop, sizeof (wstop)) == -1 && errno == EINTR)
- continue; /* check dpr_quit and continue waiting */
-
- (void) pthread_mutex_lock(&dpr->dpr_lock);
- (void) Pstopstatus(P, PCNULL, 0);
- psp = &Pstatus(P)->pr_lwp;
-
- /*
- * If we've reached a new state, found a new representative, or
- * the stop timestamp has changed, restore PR_KLC/PR_RLC to its
- * original setting and then return with dpr_lock held.
- */
- if (Pstate(P) != PS_STOP || psp->pr_lwpid != lwpid ||
- bcmp(&psp->pr_tstamp, &tstamp, sizeof (tstamp)) != 0) {
- (void) Psetflags(P, krflag);
- Psync(P);
- return;
- }
-
- (void) pthread_mutex_unlock(&dpr->dpr_lock);
- (void) poll(NULL, 0, MILLISEC / 2);
- }
-
- (void) pthread_mutex_lock(&dpr->dpr_lock);
-#endif
-}
-
typedef struct dt_proc_control_data {
dtrace_hdl_t *dpcd_hdl; /* DTrace handle */
dt_proc_t *dpcd_proc; /* proccess to control */
@@ -511,12 +392,6 @@ dt_proc_control(void *arg)
dt_proc_hash_t *dph = dtp->dt_procs;
struct ps_prochandle *P = dpr->dpr_proc;
int pid = dpr->dpr_pid;
-
-#ifdef illumos
- int pfd = Pctlfd(P);
-
- const long wstop = PCWSTOP;
-#endif
int notify = B_FALSE;
/*
@@ -534,44 +409,14 @@ dt_proc_control(void *arg)
*/
(void) pthread_mutex_lock(&dpr->dpr_lock);
-#ifdef illumos
- (void) Punsetflags(P, PR_ASYNC); /* require synchronous mode */
- (void) Psetflags(P, PR_BPTADJ); /* always adjust eip on x86 */
- (void) Punsetflags(P, PR_FORK); /* do not inherit on fork */
-
- (void) Pfault(P, FLTBPT, B_TRUE); /* always trace breakpoints */
- (void) Pfault(P, FLTTRACE, B_TRUE); /* always trace single-step */
-
- /*
- * We must trace exit from exec() system calls so that if the exec is
- * successful, we can reset our breakpoints and re-initialize libproc.
- */
- (void) Psysexit(P, SYS_execve, B_TRUE);
-
- /*
- * We must trace entry and exit for fork() system calls in order to
- * disable our breakpoints temporarily during the fork. We do not set
- * the PR_FORK flag, so if fork succeeds the child begins executing and
- * does not inherit any other tracing behaviors or a control thread.
- */
- (void) Psysentry(P, SYS_vfork, B_TRUE);
- (void) Psysexit(P, SYS_vfork, B_TRUE);
- (void) Psysentry(P, SYS_forksys, B_TRUE);
- (void) Psysexit(P, SYS_forksys, B_TRUE);
-
- Psync(P); /* enable all /proc changes */
-#endif
dt_proc_attach(dpr, B_FALSE); /* enable rtld breakpoints */
/*
- * If PR_KLC is set, we created the process; otherwise we grabbed it.
- * Check for an appropriate stop request and wait for dt_proc_continue.
+ * If DT_CLOSE_KILL is set, we created the process; otherwise we
+ * grabbed it. Check for an appropriate stop request and wait for
+ * dt_proc_continue.
*/
-#ifdef illumos
- if (Pstatus(P)->pr_flags & PR_KLC)
-#else
- if (proc_getflags(P) & PR_KLC)
-#endif
+ if (dpr->dpr_close == DT_CLOSE_KILL)
dt_proc_stop(dpr, DT_PROC_STOP_CREATE);
else
dt_proc_stop(dpr, DT_PROC_STOP_GRAB);
@@ -595,55 +440,21 @@ dt_proc_control(void *arg)
while (!dpr->dpr_quit) {
const lwpstatus_t *psp;
-#ifdef illumos
- if (write(pfd, &wstop, sizeof (wstop)) == -1 && errno == EINTR)
- continue; /* check dpr_quit and continue waiting */
-#else
/* Wait for the process to report status. */
proc_wstatus(P);
if (errno == EINTR)
continue; /* check dpr_quit and continue waiting */
-#endif
(void) pthread_mutex_lock(&dpr->dpr_lock);
-#ifdef illumos
-pwait_locked:
- if (Pstopstatus(P, PCNULL, 0) == -1 && errno == EINTR) {
- (void) pthread_mutex_unlock(&dpr->dpr_lock);
- continue; /* check dpr_quit and continue waiting */
- }
-#endif
-
switch (Pstate(P)) {
case PS_STOP:
-#ifdef illumos
- psp = &Pstatus(P)->pr_lwp;
-#else
psp = proc_getlwpstatus(P);
-#endif
dt_dprintf("pid %d: proc stopped showing %d/%d\n",
pid, psp->pr_why, psp->pr_what);
/*
- * If the process stops showing PR_REQUESTED, then the
- * DTrace stop() action was applied to it or another
- * debugging utility (e.g. pstop(1)) asked it to stop.
- * In either case, the user's intention is for the
- * process to remain stopped until another external
- * mechanism (e.g. prun(1)) is applied. So instead of
- * setting the process running ourself, we wait for
- * someone else to do so. Once that happens, we return
- * to our normal loop waiting for an event of interest.
- */
- if (psp->pr_why == PR_REQUESTED) {
- dt_proc_waitrun(dpr);
- (void) pthread_mutex_unlock(&dpr->dpr_lock);
- continue;
- }
-
- /*
* If the process stops showing one of the events that
* we are tracing, perform the appropriate response.
* Note that we ignore PR_SUSPENDED, PR_CHECKPOINT, and
@@ -666,11 +477,6 @@ pwait_locked:
break;
case PS_LOST:
-#ifdef illumos
- if (Preopen(P) == 0)
- goto pwait_locked;
-#endif
-
dt_dprintf("pid %d: proc lost: %s\n",
pid, strerror(errno));
@@ -685,9 +491,19 @@ pwait_locked:
break;
}
- if (Pstate(P) != PS_UNDEAD && Psetrun(P, 0, 0) == -1) {
- dt_dprintf("pid %d: failed to set running: %s\n",
- (int)dpr->dpr_pid, strerror(errno));
+ if (Pstate(P) != PS_UNDEAD) {
+ if (dpr->dpr_quit && dpr->dpr_close == DT_CLOSE_KILL) {
+ /*
+ * We're about to kill the child, so don't
+ * bother resuming it. In some cases, such as
+ * an initialization error, we shouldn't have
+ * started it in the first place, so letting it
+ * run could be harmful.
+ */
+ } else if (Psetrun(P, 0, 0) == -1) {
+ dt_dprintf("pid %d: failed to set running: "
+ "%s\n", (int)dpr->dpr_pid, strerror(errno));
+ }
}
(void) pthread_mutex_unlock(&dpr->dpr_lock);
@@ -739,11 +555,7 @@ dt_proc_t *
dt_proc_lookup(dtrace_hdl_t *dtp, struct ps_prochandle *P, int remove)
{
dt_proc_hash_t *dph = dtp->dt_procs;
-#ifdef illumos
- pid_t pid = Pstatus(P)->pr_pid;
-#else
pid_t pid = proc_getpid(P);
-#endif
dt_proc_t *dpr, **dpp = &dph->dph_hash[pid & (dph->dph_hashlen - 1)];
for (dpr = *dpp; dpr != NULL; dpr = dpr->dpr_hash) {
@@ -772,28 +584,15 @@ dt_proc_destroy(dtrace_hdl_t *dtp, struct ps_prochandle *P)
assert(dpr != NULL);
- /*
- * If neither PR_KLC nor PR_RLC is set, then the process is stopped by
- * an external debugger and we were waiting in dt_proc_waitrun().
- * Leave the process in this condition using PRELEASE_HANG.
- */
-#ifdef illumos
- if (!(Pstatus(dpr->dpr_proc)->pr_flags & (PR_KLC | PR_RLC))) {
-#else
- if (!(proc_getflags(dpr->dpr_proc) & (PR_KLC | PR_RLC))) {
-#endif
- dt_dprintf("abandoning pid %d\n", (int)dpr->dpr_pid);
- rflag = PRELEASE_HANG;
-#ifdef illumos
- } else if (Pstatus(dpr->dpr_proc)->pr_flags & PR_KLC) {
-#else
- } else if (proc_getflags(dpr->dpr_proc) & PR_KLC) {
-#endif
+ switch (dpr->dpr_close) {
+ case DT_CLOSE_KILL:
dt_dprintf("killing pid %d\n", (int)dpr->dpr_pid);
- rflag = PRELEASE_KILL; /* apply kill-on-last-close */
- } else {
+ rflag = PRELEASE_KILL;
+ break;
+ case DT_CLOSE_RUN:
dt_dprintf("releasing pid %d\n", (int)dpr->dpr_pid);
- rflag = 0; /* apply run-on-last-close */
+ rflag = 0;
+ break;
}
if (dpr->dpr_tid) {
@@ -813,11 +612,7 @@ dt_proc_destroy(dtrace_hdl_t *dtp, struct ps_prochandle *P)
*/
(void) pthread_mutex_lock(&dpr->dpr_lock);
dpr->dpr_quit = B_TRUE;
-#ifdef illumos
- (void) _lwp_kill(dpr->dpr_tid, SIGCANCEL);
-#else
pthread_kill(dpr->dpr_tid, SIGTHR);
-#endif
/*
* If the process is currently idling in dt_proc_stop(), re-
@@ -885,11 +680,7 @@ dt_proc_create_thread(dtrace_hdl_t *dtp, dt_proc_t *dpr, uint_t stop)
(void) sigfillset(&nset);
(void) sigdelset(&nset, SIGABRT); /* unblocked for assert() */
-#ifdef illumos
- (void) sigdelset(&nset, SIGCANCEL); /* see dt_proc_destroy() */
-#else
(void) sigdelset(&nset, SIGUSR1); /* see dt_proc_destroy() */
-#endif
data.dpcd_hdl = dtp;
data.dpcd_proc = dpr;
@@ -917,14 +708,8 @@ dt_proc_create_thread(dtrace_hdl_t *dtp, dt_proc_t *dpr, uint_t stop)
* small amount of useful information to help figure it out.
*/
if (dpr->dpr_done) {
-#ifdef illumos
- const psinfo_t *prp = Ppsinfo(dpr->dpr_proc);
- int stat = prp ? prp->pr_wstat : 0;
- int pid = dpr->dpr_pid;
-#else
int stat = proc_getwstat(dpr->dpr_proc);
int pid = proc_getpid(dpr->dpr_proc);
-#endif
if (proc_state(dpr->dpr_proc) == PS_LOST) {
(void) dt_proc_error(dpr->dpr_hdl, dpr,
"failed to control pid %d: process exec'd "
@@ -968,29 +753,15 @@ dt_proc_create(dtrace_hdl_t *dtp, const char *file, char *const *argv,
(void) pthread_mutex_init(&dpr->dpr_lock, NULL);
(void) pthread_cond_init(&dpr->dpr_cv, NULL);
-#ifdef illumos
- dpr->dpr_proc = Pxcreate(file, argv, dtp->dt_proc_env, &err, NULL, 0);
- if (dpr->dpr_proc == NULL) {
- return (dt_proc_error(dtp, dpr,
- "failed to execute %s: %s\n", file, Pcreate_error(err)));
- }
-#else
if ((err = proc_create(file, argv, dtp->dt_proc_env, pcf, child_arg,
&dpr->dpr_proc)) != 0) {
return (dt_proc_error(dtp, dpr,
"failed to execute %s: %s\n", file, Pcreate_error(err)));
}
-#endif
dpr->dpr_hdl = dtp;
-#ifdef illumos
- dpr->dpr_pid = Pstatus(dpr->dpr_proc)->pr_pid;
-#else
dpr->dpr_pid = proc_getpid(dpr->dpr_proc);
-#endif
-
- (void) Punsetflags(dpr->dpr_proc, PR_RLC);
- (void) Psetflags(dpr->dpr_proc, PR_KLC);
+ dpr->dpr_close = DT_CLOSE_KILL;
if (dt_proc_create_thread(dtp, dpr, dtp->dt_prcmode) != 0)
return (NULL); /* dt_proc_error() has been called for us */
@@ -1048,20 +819,14 @@ dt_proc_grab(dtrace_hdl_t *dtp, pid_t pid, int flags, int nomonitor)
(void) pthread_mutex_init(&dpr->dpr_lock, NULL);
(void) pthread_cond_init(&dpr->dpr_cv, NULL);
-#ifdef illumos
- if ((dpr->dpr_proc = Pgrab(pid, flags, &err)) == NULL) {
-#else
if ((err = proc_attach(pid, flags, &dpr->dpr_proc)) != 0) {
-#endif
return (dt_proc_error(dtp, dpr,
"failed to grab pid %d: %s\n", (int)pid, Pgrab_error(err)));
}
dpr->dpr_hdl = dtp;
dpr->dpr_pid = pid;
-
- (void) Punsetflags(dpr->dpr_proc, PR_KLC);
- (void) Psetflags(dpr->dpr_proc, PR_RLC);
+ dpr->dpr_close = DT_CLOSE_RUN;
/*
* If we are attempting to grab the process without a monitor
@@ -1227,11 +992,7 @@ dtrace_proc_create(dtrace_hdl_t *dtp, const char *file, char *const *argv,
struct ps_prochandle *P = dt_proc_create(dtp, file, argv, pcf, child_arg);
if (P != NULL && idp != NULL && idp->di_id == 0) {
-#ifdef illumos
- idp->di_id = Pstatus(P)->pr_pid; /* $target = created pid */
-#else
idp->di_id = proc_getpid(P); /* $target = created pid */
-#endif
}
return (P);
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.h b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.h
index beae6f6d5cda..458e9902881f 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.h
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.h
@@ -40,6 +40,11 @@
extern "C" {
#endif
+enum dt_close_action {
+ DT_CLOSE_RUN,
+ DT_CLOSE_KILL,
+};
+
typedef struct dt_proc {
dt_list_t dpr_list; /* prev/next pointers for lru chain */
struct dt_proc *dpr_hash; /* next pointer for pid hash chain */
@@ -60,6 +65,7 @@ typedef struct dt_proc {
uint8_t dpr_rdonly; /* proc flag: opened read-only */
pthread_t dpr_tid; /* control thread (or zero if none) */
dt_list_t dpr_bps; /* list of dt_bkpt_t structures */
+ enum dt_close_action dpr_close; /* do this to child when exiting */
} dt_proc_t;
typedef struct dt_proc_notify {
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_provider.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_provider.c
index 7cf352d4d505..2391690afc0b 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_provider.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_provider.c
@@ -48,6 +48,7 @@
#include <dt_list.h>
#include <dt_pid.h>
#include <dtrace.h>
+#include <kinst.h>
static dt_provider_t *
dt_provider_insert(dtrace_hdl_t *dtp, dt_provider_t *pvp, uint_t h)
@@ -699,6 +700,34 @@ dt_probe_info(dtrace_hdl_t *dtp,
prp = idp->di_data;
else if (pdp->dtpd_id != DTRACE_IDNONE)
prp = dt_probe_discover(pvp, pdp);
+
+ if (strcmp(pvp->pv_desc.dtvd_name, "kinst") == 0) {
+ dtrace_kinst_probedesc_t pd;
+
+ if (dtp->dt_kinstfd == -1) {
+ int fd;
+
+ fd = open("/dev/dtrace/kinst", O_WRONLY);
+ if (fd < 0) {
+ (void) dt_set_errno(dtp, errno);
+ return (NULL);
+ }
+ dtp->dt_kinstfd = fd;
+ }
+ memset(&pd, 0, sizeof(pd));
+ strlcpy(pd.kpd_func, pdp->dtpd_func,
+ sizeof (pd.kpd_func));
+
+ if (n_is_glob)
+ pd.kpd_off = -1;
+ else
+ pd.kpd_off = strtol(pdp->dtpd_name, NULL, 10);
+ if (ioctl(dtp->dt_kinstfd, KINSTIOC_MAKEPROBE, &pd) !=
+ 0) {
+ (void) dt_set_errno(dtp, errno);
+ return (NULL);
+ }
+ }
}
/*
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dtrace.h b/cddl/contrib/opensolaris/lib/libdtrace/common/dtrace.h
index f0bc83a7fc7b..af0213695f32 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dtrace.h
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dtrace.h
@@ -119,10 +119,11 @@ typedef struct dtrace_proginfo {
#define DTRACE_C_PSPEC 0x0080 /* Interpret ambiguous specifiers as probes */
#define DTRACE_C_ETAGS 0x0100 /* Prefix error messages with error tags */
#define DTRACE_C_ARGREF 0x0200 /* Do not require all macro args to be used */
+#define DTRACE_C_SUGAR 0x0400 /* Dump D script post-dt_sugar */
#define DTRACE_C_DEFARG 0x0800 /* Use 0/"" as value for unspecified args */
#define DTRACE_C_NOLIBS 0x1000 /* Do not process D system libraries */
#define DTRACE_C_CTL 0x2000 /* Only process control directives */
-#define DTRACE_C_MASK 0x3bff /* mask of all valid flags to dtrace_*compile */
+#define DTRACE_C_MASK 0x3fff /* mask of all valid flags to dtrace_*compile */
extern dtrace_prog_t *dtrace_program_strcompile(dtrace_hdl_t *,
const char *, dtrace_probespec_t, uint_t, int, char *const []);
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/mips/dt_isadep.c b/cddl/contrib/opensolaris/lib/libdtrace/mips/dt_isadep.c
deleted file mode 100644
index 1aeb95f3dfd7..000000000000
--- a/cddl/contrib/opensolaris/lib/libdtrace/mips/dt_isadep.c
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * CDDL HEADER START
- *
- * The contents of this file are subject to the terms of the
- * Common Development and Distribution License, Version 1.0 only
- * (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]
- *
- * CDDL HEADER END
- */
-/*
- * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
- * Use is subject to license terms.
- */
-
-#pragma ident "%Z%%M% %I% %E% SMI"
-
-#include <stdlib.h>
-#include <assert.h>
-#include <errno.h>
-#include <string.h>
-#include <libgen.h>
-
-#include <dt_impl.h>
-#include <dt_pid.h>
-
-/*ARGSUSED*/
-int
-dt_pid_create_entry_probe(struct ps_prochandle *P, dtrace_hdl_t *dtp,
- fasttrap_probe_spec_t *ftp, const GElf_Sym *symp)
-{
-
- dt_dprintf("%s: unimplemented\n", __func__);
- return (DT_PROC_ERR);
-}
-
-int
-dt_pid_create_return_probe(struct ps_prochandle *P, dtrace_hdl_t *dtp,
- fasttrap_probe_spec_t *ftp, const GElf_Sym *symp, uint64_t *stret)
-{
-
- dt_dprintf("%s: unimplemented\n", __func__);
- return (DT_PROC_ERR);
-}
-
-/*ARGSUSED*/
-int
-dt_pid_create_offset_probe(struct ps_prochandle *P, dtrace_hdl_t *dtp,
- fasttrap_probe_spec_t *ftp, const GElf_Sym *symp, ulong_t off)
-{
-
- dt_dprintf("%s: unimplemented\n", __func__);
- return (DT_PROC_ERR);
-}
-
-/*ARGSUSED*/
-int
-dt_pid_create_glob_offset_probes(struct ps_prochandle *P, dtrace_hdl_t *dtp,
- fasttrap_probe_spec_t *ftp, const GElf_Sym *symp, const char *pattern)
-{
-
- dt_dprintf("%s: unimplemented\n", __func__);
- return (DT_PROC_ERR);
-}
diff --git a/cddl/contrib/opensolaris/tools/ctf/common/memory.c b/cddl/contrib/opensolaris/tools/ctf/common/memory.c
index e16044a8b672..66296c5b114d 100644
--- a/cddl/contrib/opensolaris/tools/ctf/common/memory.c
+++ b/cddl/contrib/opensolaris/tools/ctf/common/memory.c
@@ -44,6 +44,20 @@ memory_bailout(void)
exit(1);
}
+int
+xasprintf(char **s, const char *fmt, ...)
+{
+ va_list ap;
+ int ret;
+
+ va_start(ap, fmt);
+ ret = vasprintf(s, fmt, ap);
+ va_end(ap);
+ if (ret == -1)
+ memory_bailout();
+ return (ret);
+}
+
void *
xmalloc(size_t size)
{
diff --git a/cddl/contrib/opensolaris/tools/ctf/common/memory.h b/cddl/contrib/opensolaris/tools/ctf/common/memory.h
index 88ca31bec65a..72706b5f7fdb 100644
--- a/cddl/contrib/opensolaris/tools/ctf/common/memory.h
+++ b/cddl/contrib/opensolaris/tools/ctf/common/memory.h
@@ -39,6 +39,7 @@
extern "C" {
#endif
+int xasprintf(char **, const char *, ...);
void *xmalloc(size_t);
void *xcalloc(size_t);
char *xstrdup(const char *);
diff --git a/cddl/contrib/opensolaris/tools/ctf/common/utils.c b/cddl/contrib/opensolaris/tools/ctf/common/utils.c
index f74eb8de40fa..fda29486d94b 100644
--- a/cddl/contrib/opensolaris/tools/ctf/common/utils.c
+++ b/cddl/contrib/opensolaris/tools/ctf/common/utils.c
@@ -35,30 +35,6 @@
/*LINTLIBRARY*/
-static const char *pname;
-
-#pragma init(getpname)
-const char *
-getpname(void)
-{
- const char *p, *q;
-
- if (pname != NULL)
- return (pname);
-
- if ((p = getexecname()) != NULL)
- q = strrchr(p, '/');
- else
- q = NULL;
-
- if (q == NULL)
- pname = p;
- else
- pname = q + 1;
-
- return (pname);
-}
-
void
vdie(const char *format, va_list alist)
{
diff --git a/cddl/contrib/opensolaris/tools/ctf/common/utils.h b/cddl/contrib/opensolaris/tools/ctf/common/utils.h
index 99378bb4f251..6918bdab89aa 100644
--- a/cddl/contrib/opensolaris/tools/ctf/common/utils.h
+++ b/cddl/contrib/opensolaris/tools/ctf/common/utils.h
@@ -42,8 +42,6 @@ extern "C" {
extern void vdie(const char *, va_list);
extern void die(const char *, ...);
-extern const char *getpname(void);
-
#ifdef __cplusplus
}
#endif
diff --git a/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c b/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c
index 2d686e53fed1..ec5a3c58856d 100644
--- a/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c
+++ b/cddl/contrib/opensolaris/tools/ctf/cvt/dwarf.c
@@ -618,7 +618,7 @@ tdesc_intr_long(dwarf_t *dw)
* caller can then use the copy as the type for a bitfield structure member.
*/
static tdesc_t *
-tdesc_intr_clone(dwarf_t *dw, tdesc_t *old, size_t bitsz)
+tdesc_intr_clone(dwarf_t *dw, tdesc_t *old, size_t bitsz, const char *suffix)
{
tdesc_t *new = xcalloc(sizeof (tdesc_t));
@@ -627,7 +627,7 @@ tdesc_intr_clone(dwarf_t *dw, tdesc_t *old, size_t bitsz)
"unresolved type\n", old->t_id);
}
- new->t_name = xstrdup(old->t_name);
+ xasprintf(&new->t_name, "%s %s", old->t_name, suffix);
new->t_size = old->t_size;
new->t_id = mfgtid_next(dw);
new->t_type = INTRINSIC;
@@ -1158,7 +1158,8 @@ die_sou_resolve(tdesc_t *tdp, tdesc_t **tdpp __unused, void *private)
debug(3, "tdp %u: creating bitfield for %d bits\n",
tdp->t_id, ml->ml_size);
- ml->ml_type = tdesc_intr_clone(dw, mt, ml->ml_size);
+ ml->ml_type = tdesc_intr_clone(dw, mt, ml->ml_size,
+ "bitfield");
}
}
@@ -1366,7 +1367,7 @@ static const fp_size_map_t fp_encodings[] = {
};
static uint_t
-die_base_type2enc(dwarf_t *dw, Dwarf_Off off, Dwarf_Signed enc, size_t sz)
+die_base_type2enc(dwarf_t *dw, Dwarf_Off off, Dwarf_Unsigned enc, size_t sz)
{
const fp_size_map_t *map = fp_encodings;
uint_t szidx = dw->dw_ptrsz == sizeof (uint64_t);
@@ -1397,9 +1398,9 @@ static intr_t *
die_base_from_dwarf(dwarf_t *dw, Dwarf_Die base, Dwarf_Off off, size_t sz)
{
intr_t *intr = xcalloc(sizeof (intr_t));
- Dwarf_Signed enc;
+ Dwarf_Unsigned enc;
- (void) die_signed(dw, base, DW_AT_encoding, &enc, DW_ATTR_REQ);
+ (void) die_unsigned(dw, base, DW_AT_encoding, &enc, DW_ATTR_REQ);
switch (enc) {
case DW_ATE_unsigned:
diff --git a/cddl/contrib/opensolaris/tools/ctf/dump/dump.c b/cddl/contrib/opensolaris/tools/ctf/dump/dump.c
index 06c00a7b0e7f..5cbf46af1b73 100644
--- a/cddl/contrib/opensolaris/tools/ctf/dump/dump.c
+++ b/cddl/contrib/opensolaris/tools/ctf/dump/dump.c
@@ -856,7 +856,7 @@ print_stats(void)
static int
print_usage(FILE *fp, int verbose)
{
- (void) fprintf(fp, "Usage: %s [-dfhlsSt] [-u file] file\n", getpname());
+ (void) fprintf(fp, "Usage: %s [-dfhlsSt] [-u file] file\n", getprogname());
if (verbose) {
(void) fprintf(fp,
diff --git a/cddl/lib/Makefile b/cddl/lib/Makefile
index 5ca0d56b291a..68250c8300b1 100644
--- a/cddl/lib/Makefile
+++ b/cddl/lib/Makefile
@@ -1,40 +1,32 @@
-# $FreeBSD$
.include <src.opts.mk>
-SUBDIR= drti \
- libavl \
+.if ${MK_DTRACE} == yes || ${MK_ZFS} == yes
+SUBDIR= libspl
+.endif
+
+SUBDIR.${MK_DTRACE}+= \
+ drti \
libctf \
- libdtrace \
- ${_libicp} \
- ${_libicp_rescue} \
+ libdtrace
+
+SUBDIR.${MK_TESTS}+= tests
+
+SUBDIR.${MK_ZFS}+= \
+ libavl \
+ libicp \
+ libicp_rescue \
libnvpair \
- libspl \
- ${_libtpool} \
+ libtpool \
libumem \
libuutil \
- ${_libzfs_core} \
- ${_libzfs} \
- ${_libzfsbootenv} \
- ${_libzpool} \
- ${_libzutil} \
- ${_pam_zfs_key}
-
-SUBDIR.${MK_TESTS}+= tests
+ libzfs \
+ libzfs_core \
+ libzfsbootenv \
+ libzpool \
+ libzutil
-.if ${MK_ZFS} != "no"
-_libzfs_core= libzfs_core
-_libicp= libicp
-_libicp_rescue= libicp_rescue
-_libzfs= libzfs
-_libzutil= libzutil
-_libzfsbootenv= libzfsbootenv
-_libzpool= libzpool
-_libtpool= libtpool
-.if ${MK_OPENSSL} != "no"
-_pam_zfs_key= pam_zfs_key
-.endif
-.endif
+SUBDIR.${MK_ZFS}.${MK_OPENSSL} = pam_zfs_key
SUBDIR_DEPEND_libavl= libspl
SUBDIR_DEPEND_libctf= libspl
diff --git a/cddl/lib/Makefile.inc b/cddl/lib/Makefile.inc
index 8f9af1d17e9d..3e83ba423f35 100644
--- a/cddl/lib/Makefile.inc
+++ b/cddl/lib/Makefile.inc
@@ -1,4 +1,3 @@
-# $FreeBSD$
SHLIBDIR?= /lib
SHLIB_MAJOR?= 2
diff --git a/cddl/lib/drti/Makefile b/cddl/lib/drti/Makefile
index 321352c7100c..b9023202f0fb 100644
--- a/cddl/lib/drti/Makefile
+++ b/cddl/lib/drti/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/lib/libdtrace/common
diff --git a/cddl/lib/drti/Makefile.depend b/cddl/lib/drti/Makefile.depend
index 422dbea77a29..2c564fe515ff 100644
--- a/cddl/lib/drti/Makefile.depend
+++ b/cddl/lib/drti/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libavl/Makefile b/cddl/lib/libavl/Makefile
index b5e3b458f982..5b47d42d7575 100644
--- a/cddl/lib/libavl/Makefile
+++ b/cddl/lib/libavl/Makefile
@@ -1,8 +1,7 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/avl
-PACKAGE= runtime
+PACKAGE= zfs
LIB= avl
LIBADD= spl
SRCS= avl.c
diff --git a/cddl/lib/libavl/Makefile.depend b/cddl/lib/libavl/Makefile.depend
index 1c1a9bee1d67..409c3c86cc20 100644
--- a/cddl/lib/libavl/Makefile.depend
+++ b/cddl/lib/libavl/Makefile.depend
@@ -1,8 +1,9 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
+ cddl/lib/libspl \
include \
+ include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
diff --git a/cddl/lib/libctf/Makefile b/cddl/lib/libctf/Makefile
index 860b327ca768..3b91a97bc3ee 100644
--- a/cddl/lib/libctf/Makefile
+++ b/cddl/lib/libctf/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/common/ctf
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/lib/libctf/common
diff --git a/cddl/lib/libctf/Makefile.depend b/cddl/lib/libctf/Makefile.depend
index ec3b871042c4..7cbc01413fbc 100644
--- a/cddl/lib/libctf/Makefile.depend
+++ b/cddl/lib/libctf/Makefile.depend
@@ -1,7 +1,7 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
+ cddl/lib/libspl \
include \
include/xlocale \
lib/${CSU_DIR} \
diff --git a/cddl/lib/libdtrace/Makefile b/cddl/lib/libdtrace/Makefile
index 05b183215f4c..0b12410fbb47 100644
--- a/cddl/lib/libdtrace/Makefile
+++ b/cddl/lib/libdtrace/Makefile
@@ -1,10 +1,14 @@
-# $FreeBSD$
+
+SHLIBDIR?= /lib
+
+.include <src.opts.mk>
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/lib/libdtrace/common
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/lib/libgen/common
PACKAGE= dtrace
LIB= dtrace
+
SRCS= dt_aggregate.c \
dt_as.c \
dt_buf.c \
@@ -84,6 +88,7 @@ CFLAGS+= -DHAVE_ISSETUGID
CFLAGS+= -I${.OBJDIR} -I${.CURDIR} \
-I${SRCTOP}/sys/cddl/dev/dtrace/${MACHINE_ARCH} \
+ -I${SRCTOP}/sys/cddl/dev/kinst \
-I${SRCTOP}/sys/cddl/compat/opensolaris \
-I${SRCTOP}/cddl/compat/opensolaris/include \
-I${OPENSOLARIS_USR_DISTDIR}/head \
@@ -107,10 +112,6 @@ CFLAGS+= -I${OPENSOLARIS_SYS_DISTDIR}/uts/intel -DDIS_MEM
CFLAGS+= -I${OPENSOLARIS_SYS_DISTDIR}/uts/arm
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/lib/libdtrace/arm
.PATH: ${SRCTOP}/sys/cddl/dev/dtrace/arm
-.elif ${MACHINE_CPUARCH} == "mips"
-CFLAGS+= -I${OPENSOLARIS_SYS_DISTDIR}/uts/mips
-.PATH: ${SRCTOP}/cddl/contrib/opensolaris/lib/libdtrace/mips
-.PATH: ${SRCTOP}/sys/cddl/dev/dtrace/mips
.elif ${MACHINE_CPUARCH} == "powerpc"
CFLAGS+= -I${OPENSOLARIS_SYS_DISTDIR}/uts/powerpc
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/lib/libdtrace/powerpc
@@ -125,12 +126,27 @@ CFLAGS+= -I${OPENSOLARIS_SYS_DISTDIR}/uts/intel
.endif
.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "amd64"
-SRCS+= dis_tables.c
+SRCS+= dis_tables.c instr_size.c
DSRCS+= regs_x86.d
.endif
+.if ${MACHINE_CPUARCH} == "riscv"
+SRCS+= instr_size.c
+DSRCS+= regs_riscv.d
+.endif
+
+.if ${MACHINE_CPUARCH} == "aarch64"
+SRCS+= instr_size.c
+DSRCS+= regs_aarch64.d
+.endif
+
YFLAGS+=-d
+.if ${MK_DTRACE_ASAN} != "no"
+CFLAGS+= -fsanitize=address -fsanitize=undefined
+LDFLAGS+= -fsanitize=address -fsanitize=undefined
+.endif
+
LIBADD= ctf elf proc pthread rtld_db
CLEANFILES= dt_errtags.c dt_names.c
diff --git a/cddl/lib/libdtrace/Makefile.depend b/cddl/lib/libdtrace/Makefile.depend
index 68a8d3e9c520..92c6b0e658b5 100644
--- a/cddl/lib/libdtrace/Makefile.depend
+++ b/cddl/lib/libdtrace/Makefile.depend
@@ -1,9 +1,8 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
+ bin/sh.host \
cddl/lib/libctf \
- gnu/lib/csu \
include \
include/arpa \
include/xlocale \
@@ -14,6 +13,7 @@ DIRDEPS = \
lib/libproc \
lib/librtld_db \
lib/libthr \
+ usr.bin/awk.host \
usr.bin/yacc.host \
diff --git a/cddl/lib/libdtrace/errno.d b/cddl/lib/libdtrace/errno.d
index 426d882b0db1..2045e3a7433d 100644
--- a/cddl/lib/libdtrace/errno.d
+++ b/cddl/lib/libdtrace/errno.d
@@ -21,8 +21,6 @@
*
* Portions Copyright 2006-2008 John Birrell jb@freebsd.org
* Portions Copyright 2018 Devin Teske dteske@freebsd.org
- *
- * $FreeBSD$
*/
/*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
diff --git a/cddl/lib/libdtrace/io.d b/cddl/lib/libdtrace/io.d
index d643ad732a94..fbce09e2fcf7 100644
--- a/cddl/lib/libdtrace/io.d
+++ b/cddl/lib/libdtrace/io.d
@@ -19,8 +19,6 @@
* CDDL HEADER END
*
* Portions Copyright 2018 Devin Teske dteske@freebsd.org
- *
- * $FreeBSD$
*/
/*
* Copyright 2006 Sun Microsystems, Inc. All rights reserved.
diff --git a/cddl/lib/libdtrace/ip.d b/cddl/lib/libdtrace/ip.d
index f591a965af68..172d7d54bc36 100644
--- a/cddl/lib/libdtrace/ip.d
+++ b/cddl/lib/libdtrace/ip.d
@@ -17,8 +17,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
diff --git a/cddl/lib/libdtrace/libproc_compat.h b/cddl/lib/libdtrace/libproc_compat.h
index 14f32506bb8f..7cdc8af18b56 100644
--- a/cddl/lib/libdtrace/libproc_compat.h
+++ b/cddl/lib/libdtrace/libproc_compat.h
@@ -25,8 +25,6 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $FreeBSD$
*/
/*
@@ -58,10 +56,8 @@
#define Prd_agent proc_rdagent
#define Prelease proc_detach
#define Psetbkpt proc_bkptset
-#define Psetflags proc_setflags
#define Pstate proc_state
#define Psymbol_iter_by_addr proc_iter_symbyaddr
-#define Punsetflags proc_clearflags
#define Pupdate_maps proc_rdagent
#define Pupdate_syms proc_updatesyms
#define Pxecbkpt proc_bkptexec
diff --git a/cddl/lib/libdtrace/net.d b/cddl/lib/libdtrace/net.d
index ee22c8ffb0cc..fef61ea31f4b 100644
--- a/cddl/lib/libdtrace/net.d
+++ b/cddl/lib/libdtrace/net.d
@@ -19,8 +19,6 @@
* CDDL HEADER END
*
* Portions Copyright 2006-2008 John Birrell jb@freebsd.org
- *
- * $FreeBSD$
*/
/*
diff --git a/cddl/lib/libdtrace/nfs.d b/cddl/lib/libdtrace/nfs.d
index ae864ed363d2..4d55b39a809d 100644
--- a/cddl/lib/libdtrace/nfs.d
+++ b/cddl/lib/libdtrace/nfs.d
@@ -19,8 +19,6 @@
* CDDL HEADER END
*
* Portions Copyright 2006-2008 John Birrell jb@freebsd.org
- *
- * $FreeBSD$
*/
/*
diff --git a/cddl/lib/libdtrace/nfssrv.d b/cddl/lib/libdtrace/nfssrv.d
index 37842f7963a1..b5231bf7a2ec 100644
--- a/cddl/lib/libdtrace/nfssrv.d
+++ b/cddl/lib/libdtrace/nfssrv.d
@@ -19,8 +19,6 @@
* CDDL HEADER END
*
* Portions Copyright 2006-2008 John Birrell jb@freebsd.org
- *
- * $FreeBSD$
*/
/*
diff --git a/cddl/lib/libdtrace/psinfo.d b/cddl/lib/libdtrace/psinfo.d
index 0f5ca63c39a4..c0cd5b121064 100644
--- a/cddl/lib/libdtrace/psinfo.d
+++ b/cddl/lib/libdtrace/psinfo.d
@@ -20,8 +20,6 @@
* CDDL HEADER END
*
* Portions Copyright 2006 John Birrell jb@freebsd.org
- *
- * $FreeBSD$
*/
/*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
diff --git a/cddl/lib/libdtrace/regs_aarch64.d b/cddl/lib/libdtrace/regs_aarch64.d
new file mode 100644
index 000000000000..7d20b5c546c5
--- /dev/null
+++ b/cddl/lib/libdtrace/regs_aarch64.d
@@ -0,0 +1,74 @@
+/*
+ * SPDX-License-Identifier: CDDL 1.0
+ *
+ * Copyright 2023 Christos Margiolis <christos@FreeBSD.org>
+ */
+
+inline int R_X0 = 0;
+#pragma D binding "1.13" R_X0
+inline int R_X1 = 1;
+#pragma D binding "1.13" R_X1
+inline int R_X2 = 2;
+#pragma D binding "1.13" R_X2
+inline int R_X3 = 3;
+#pragma D binding "1.13" R_X3
+inline int R_X4 = 4;
+#pragma D binding "1.13" R_X4
+inline int R_X5 = 5;
+#pragma D binding "1.13" R_X5
+inline int R_X6 = 6;
+#pragma D binding "1.13" R_X6
+inline int R_X7 = 7;
+#pragma D binding "1.13" R_X7
+inline int R_X8 = 8;
+#pragma D binding "1.13" R_X8
+inline int R_X9 = 9;
+#pragma D binding "1.13" R_X9
+inline int R_X10 = 10;
+#pragma D binding "1.13" R_X10
+inline int R_X11 = 11;
+#pragma D binding "1.13" R_X11
+inline int R_X12 = 12;
+#pragma D binding "1.13" R_X12
+inline int R_X13 = 13;
+#pragma D binding "1.13" R_X13
+inline int R_X14 = 14;
+#pragma D binding "1.13" R_X14
+inline int R_X15 = 15;
+#pragma D binding "1.13" R_X15
+inline int R_X16 = 16;
+#pragma D binding "1.13" R_X16
+inline int R_X17 = 17;
+#pragma D binding "1.13" R_X17
+inline int R_X18 = 18;
+#pragma D binding "1.13" R_X18
+inline int R_X19 = 19;
+#pragma D binding "1.13" R_X19
+inline int R_X20 = 20;
+#pragma D binding "1.13" R_X20
+inline int R_X21 = 21;
+#pragma D binding "1.13" R_X21
+inline int R_X22 = 22;
+#pragma D binding "1.13" R_X22
+inline int R_X23 = 23;
+#pragma D binding "1.13" R_X23
+inline int R_X24 = 24;
+#pragma D binding "1.13" R_X24
+inline int R_X25 = 25;
+#pragma D binding "1.13" R_X25
+inline int R_X26 = 26;
+#pragma D binding "1.13" R_X26
+inline int R_X27 = 27;
+#pragma D binding "1.13" R_X27
+inline int R_X28 = 28;
+#pragma D binding "1.13" R_X28
+inline int R_X29 = 29;
+#pragma D binding "1.13" R_X29
+inline int R_FP= 29;
+#pragma D binding "1.13" R_FP
+inline int R_LR = 30;
+#pragma D binding "1.13" R_LR
+inline int R_SP = 31;
+#pragma D binding "1.13" R_SP
+inline int R_PC = 32;
+#pragma D binding "1.13" R_PC
diff --git a/cddl/lib/libdtrace/regs_riscv.d b/cddl/lib/libdtrace/regs_riscv.d
new file mode 100644
index 000000000000..e8a9667d2efd
--- /dev/null
+++ b/cddl/lib/libdtrace/regs_riscv.d
@@ -0,0 +1,74 @@
+/*
+ * SPDX-License-Identifier: CDDL 1.0
+ *
+ * Copyright 2023 Christos Margiolis <christos@FreeBSD.org>
+ */
+
+inline int R_ZERO = 0;
+#pragma D binding "1.13" R_ZERO
+inline int R_RA = 1;
+#pragma D binding "1.13" R_RA
+inline int R_SP = 2;
+#pragma D binding "1.13" R_SP
+inline int R_GP = 3;
+#pragma D binding "1.13" R_GP
+inline int R_TP = 4;
+#pragma D binding "1.13" R_TP
+inline int R_T0 = 5;
+#pragma D binding "1.13" R_T0
+inline int R_T1 = 6;
+#pragma D binding "1.13" R_T1
+inline int R_T2 = 7;
+#pragma D binding "1.13" R_T2
+inline int R_S0 = 8;
+#pragma D binding "1.13" R_S0
+inline int R_FP = 8;
+#pragma D binding "1.13" R_FP
+inline int R_S1 = 9;
+#pragma D binding "1.13" R_S1
+inline int R_A0 = 10;
+#pragma D binding "1.13" R_A0
+inline int R_A1 = 11;
+#pragma D binding "1.13" R_A1
+inline int R_A2 = 12;
+#pragma D binding "1.13" R_A2
+inline int R_A3 = 13;
+#pragma D binding "1.13" R_A3
+inline int R_A4 = 14;
+#pragma D binding "1.13" R_A4
+inline int R_A5 = 15;
+#pragma D binding "1.13" R_A5
+inline int R_A6 = 16;
+#pragma D binding "1.13" R_A6
+inline int R_A7 = 17;
+#pragma D binding "1.13" R_A7
+inline int R_S2 = 18;
+#pragma D binding "1.13" R_S2
+inline int R_S3 = 19;
+#pragma D binding "1.13" R_S3
+inline int R_S4 = 20;
+#pragma D binding "1.13" R_S4
+inline int R_S5 = 21;
+#pragma D binding "1.13" R_S5
+inline int R_S6 = 22;
+#pragma D binding "1.13" R_S6
+inline int R_S7 = 23;
+#pragma D binding "1.13" R_S7
+inline int R_S8 = 24;
+#pragma D binding "1.13" R_S8
+inline int R_S9 = 25;
+#pragma D binding "1.13" R_S9
+inline int R_S10 = 26;
+#pragma D binding "1.13" R_S10
+inline int R_S11 = 27;
+#pragma D binding "1.13" R_S11
+inline int R_T3 = 28;
+#pragma D binding "1.13" R_T3
+inline int R_T4 = 29;
+#pragma D binding "1.13" R_T4
+inline int R_T5 = 30;
+#pragma D binding "1.13" R_T5
+inline int R_T6 = 31;
+#pragma D binding "1.13" R_T6
+inline int R_PC = 32;
+#pragma D binding "1.13" R_PC
diff --git a/cddl/lib/libdtrace/regs_x86.d b/cddl/lib/libdtrace/regs_x86.d
index 3f625f9f4445..2e31517fdd8d 100644
--- a/cddl/lib/libdtrace/regs_x86.d
+++ b/cddl/lib/libdtrace/regs_x86.d
@@ -20,8 +20,6 @@
* CDDL HEADER END
*
* Portions Copyright 2009 Stacey Son sson@FreeBSD.org
- *
- * $FreeBSD$
*/
/*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
@@ -80,11 +78,11 @@ inline int R_R0 = R_EAX;
inline int R_R1 = R_EBX;
#pragma D binding "1.0" R_R1
-inline int R_RSP = 18 + 1 + 20;
+inline int R_RSP = 18 + 1 + 24;
#pragma D binding "1.0" R_RSP
-inline int R_RFL = 18 + 1 + 19;
+inline int R_RFL = 18 + 1 + 23;
#pragma D binding "1.0" R_RFL
-inline int R_RIP = 18 + 1 + 17;
+inline int R_RIP = 18 + 1 + 21;
#pragma D binding "1.0" R_RIP
inline int R_RAX = 18 + 1 + 14;
#pragma D binding "1.0" R_RAX
diff --git a/cddl/lib/libdtrace/sched.d b/cddl/lib/libdtrace/sched.d
index 82fdf3ab0c05..7eca118fc428 100644
--- a/cddl/lib/libdtrace/sched.d
+++ b/cddl/lib/libdtrace/sched.d
@@ -19,8 +19,6 @@
* CDDL HEADER END
*
* Portions Copyright 2006-2008 John Birrell jb@freebsd.org
- *
- * $FreeBSD$
*/
/*
* Copyright 2006 Sun Microsystems, Inc. All rights reserved.
diff --git a/cddl/lib/libdtrace/sctp.d b/cddl/lib/libdtrace/sctp.d
index 5dc776bdb971..ef8c3bcc4a56 100644
--- a/cddl/lib/libdtrace/sctp.d
+++ b/cddl/lib/libdtrace/sctp.d
@@ -17,8 +17,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright (c) 2018 Michael Tuexen <tuexen@FreeBSD.org>
diff --git a/cddl/lib/libdtrace/siftr.d b/cddl/lib/libdtrace/siftr.d
index 37bc30ff3e06..bca3a0f0df7f 100644
--- a/cddl/lib/libdtrace/siftr.d
+++ b/cddl/lib/libdtrace/siftr.d
@@ -17,10 +17,9 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
+#pragma D depends_on library ip.d
#pragma D depends_on module kernel
#pragma D depends_on module siftr
#pragma D depends_on provider tcp
@@ -29,9 +28,9 @@
* Convert a SIFTR direction value to a string
*/
#pragma D binding "1.12.1" SIFTR_IN
-inline int SIFTR_IN = 1;
+inline int SIFTR_IN = 0;
#pragma D binding "1.12.1" SIFTR_OUT
-inline int SIFTR_OUT = 2;
+inline int SIFTR_OUT = 1;
/* SIFTR direction strings. */
#pragma D binding "1.12.1" siftr_dir_string
@@ -44,22 +43,23 @@ typedef struct siftrinfo {
struct timeval tval;
uint8_t direction;
uint8_t ipver;
- uint32_t hash;
- uint16_t tcp_localport;
- uint16_t tcp_foreignport;
- uint64_t snd_cwnd;
- u_long snd_wnd;
- u_long rcv_wnd;
- u_long snd_bwnd;
- u_long snd_ssthresh;
+ uint16_t lport;
+ uint16_t rport;
+ string laddr;
+ string raddr;
+ uint32_t snd_cwnd;
+ uint32_t snd_wnd;
+ uint32_t rcv_wnd;
+ uint32_t t_flags2;
+ uint32_t snd_ssthresh;
int conn_state;
- u_int max_seg_size;
- int smoothed_rtt;
+ uint32_t mss;
+ uint32_t srtt;
u_char sack_enabled;
u_char snd_scale;
u_char rcv_scale;
- u_int flags;
- int rxt_length;
+ u_int t_flags;
+ uint32_t rto;
u_int snd_buf_hiwater;
u_int snd_buf_cc;
u_int rcv_buf_hiwater;
@@ -74,22 +74,29 @@ typedef struct siftrinfo {
translator siftrinfo_t < struct pkt_node *p > {
direction = p == NULL ? 0 : p->direction;
ipver = p == NULL ? 0 : p->ipver;
- hash = p == NULL ? 0 : p->hash;
- tcp_localport = p == NULL ? 0 : ntohs(p->tcp_localport);
- tcp_foreignport = p == NULL ? 0 : ntohs(p->tcp_foreignport);
+ lport = p == NULL ? 0 : ntohs(p->lport);
+ rport = p == NULL ? 0 : ntohs(p->fport);
+ laddr = p == NULL ? "<unknown>" :
+ p->ipver == INP_IPV4 ?
+ inet_ntoa(&p->laddr.id46_addr.ia46_addr4.s_addr) :
+ inet_ntoa6(&p->laddr.id6_addr);
+ raddr = p == NULL ? "<unknown>" :
+ p->ipver == INP_IPV4 ?
+ inet_ntoa(&p->faddr.id46_addr.ia46_addr4.s_addr) :
+ inet_ntoa6(&p->faddr.id6_addr);
snd_cwnd = p == NULL ? 0 : p->snd_cwnd;
snd_wnd = p == NULL ? 0 : p->snd_wnd;
rcv_wnd = p == NULL ? 0 : p->rcv_wnd;
- snd_bwnd = p == NULL ? 0 : p->snd_bwnd;
+ t_flags2 = p == NULL ? 0 : p->t_flags2;
snd_ssthresh = p == NULL ? 0 : p->snd_ssthresh;
conn_state = p == NULL ? 0 : p->conn_state;
- max_seg_size = p == NULL ? 0 : p->max_seg_size;
- smoothed_rtt = p == NULL ? 0 : p->smoothed_rtt;
+ mss = p == NULL ? 0 : p->mss;
+ srtt = p == NULL ? 0 : p->srtt;
sack_enabled = p == NULL ? 0 : p->sack_enabled;
snd_scale = p == NULL ? 0 : p->snd_scale;
rcv_scale = p == NULL ? 0 : p->rcv_scale;
- flags = p == NULL ? 0 : p->flags;
- rxt_length = p == NULL ? 0 : p->rxt_length;
+ t_flags = p == NULL ? 0 : p->t_flags;
+ rto = p == NULL ? 0 : p->rto;
snd_buf_hiwater = p == NULL ? 0 : p->snd_buf_hiwater;
snd_buf_cc = p == NULL ? 0 : p->snd_buf_cc;
rcv_buf_hiwater = p == NULL ? 0 : p->rcv_buf_hiwater;
diff --git a/cddl/lib/libdtrace/signal.d b/cddl/lib/libdtrace/signal.d
index cdd433883397..0f9b2567cc0d 100644
--- a/cddl/lib/libdtrace/signal.d
+++ b/cddl/lib/libdtrace/signal.d
@@ -21,8 +21,6 @@
*
* Portions Copyright 2008 John Birrell jb@freebsd.org
* Portions Copyright 2018 Devin Teske dteske@freebsd.org
- *
- * $FreeBSD$
*/
inline int SIGHUP = 1;
diff --git a/cddl/lib/libdtrace/socket.d b/cddl/lib/libdtrace/socket.d
index da8f149b2d10..c8161f9b2d30 100644
--- a/cddl/lib/libdtrace/socket.d
+++ b/cddl/lib/libdtrace/socket.d
@@ -23,8 +23,6 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD$
- *
* Translators and flags for the socket structure. FreeBSD specific code.
*/
diff --git a/cddl/lib/libdtrace/tcp.d b/cddl/lib/libdtrace/tcp.d
index afcfdfadaf1e..ea3a553ebf53 100644
--- a/cddl/lib/libdtrace/tcp.d
+++ b/cddl/lib/libdtrace/tcp.d
@@ -17,8 +17,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
@@ -204,7 +202,7 @@ typedef struct tcpinfoh {
#pragma D binding "1.6.3" translator
translator csinfo_t < struct tcpcb *p > {
cs_addr = NULL;
- cs_cid = (uint64_t)(p == NULL ? 0 : p->t_inpcb);
+ cs_cid = (uint64_t)(p == NULL ? 0 : &p->t_inpcb);
cs_pid = 0;
cs_zoneid = 0;
};
@@ -214,16 +212,16 @@ translator tcpsinfo_t < struct tcpcb *p > {
tcps_addr = (uintptr_t)p;
tcps_local = -1; /* XXX */
tcps_active = -1; /* XXX */
- tcps_lport = p == NULL ? 0 : ntohs(p->t_inpcb->inp_inc.inc_ie.ie_lport);
- tcps_rport = p == NULL ? 0 : ntohs(p->t_inpcb->inp_inc.inc_ie.ie_fport);
+ tcps_lport = p == NULL ? 0 : ntohs(p->t_inpcb.inp_inc.inc_ie.ie_lport);
+ tcps_rport = p == NULL ? 0 : ntohs(p->t_inpcb.inp_inc.inc_ie.ie_fport);
tcps_laddr = p == NULL ? "<unknown>" :
- p->t_inpcb->inp_vflag == INP_IPV4 ?
- inet_ntoa(&p->t_inpcb->inp_inc.inc_ie.ie_dependladdr.id46_addr.ia46_addr4.s_addr) :
- inet_ntoa6(&p->t_inpcb->inp_inc.inc_ie.ie_dependladdr.id6_addr);
+ p->t_inpcb.inp_vflag == INP_IPV4 ?
+ inet_ntoa(&p->t_inpcb.inp_inc.inc_ie.ie_dependladdr.id46_addr.ia46_addr4.s_addr) :
+ inet_ntoa6(&p->t_inpcb.inp_inc.inc_ie.ie_dependladdr.id6_addr);
tcps_raddr = p == NULL ? "<unknown>" :
- p->t_inpcb->inp_vflag == INP_IPV4 ?
- inet_ntoa(&p->t_inpcb->inp_inc.inc_ie.ie_dependfaddr.id46_addr.ia46_addr4.s_addr) :
- inet_ntoa6(&p->t_inpcb->inp_inc.inc_ie.ie_dependfaddr.id6_addr);
+ p->t_inpcb.inp_vflag == INP_IPV4 ?
+ inet_ntoa(&p->t_inpcb.inp_inc.inc_ie.ie_dependfaddr.id46_addr.ia46_addr4.s_addr) :
+ inet_ntoa6(&p->t_inpcb.inp_inc.inc_ie.ie_dependfaddr.id6_addr);
tcps_state = p == NULL ? -1 : p->t_state;
tcps_iss = p == NULL ? 0 : p->iss;
tcps_irs = p == NULL ? 0 : p->irs;
@@ -250,9 +248,9 @@ translator tcpsinfo_t < struct tcpcb *p > {
tcps_retransmit = p == NULL ? -1 : p->t_rxtshift > 0 ? 1 : 0;
tcps_srtt = p == NULL ? -1 : p->t_srtt; /* smoothed RTT in units of (TCP_RTT_SCALE*hz) */
tcps_debug = p == NULL ? 0 :
- p->t_inpcb->inp_socket->so_options & 1;
+ p->t_inpcb.inp_socket->so_options & 1;
tcps_cookie = p == NULL ? -1 :
- p->t_inpcb->inp_socket->so_user_cookie;
+ p->t_inpcb.inp_socket->so_user_cookie;
tcps_dupacks = p == NULL ? -1 : p->t_dupacks;
tcps_rtttime = p == NULL ? -1 : p->t_rtttime;
tcps_rtseq = p == NULL ? -1 : p->t_rtseq;
diff --git a/cddl/lib/libdtrace/udp.d b/cddl/lib/libdtrace/udp.d
index 603bbbd29617..fd28f5e2e7e9 100644
--- a/cddl/lib/libdtrace/udp.d
+++ b/cddl/lib/libdtrace/udp.d
@@ -17,8 +17,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
diff --git a/cddl/lib/libdtrace/udplite.d b/cddl/lib/libdtrace/udplite.d
index e41a6faa36a8..88c1c8553ce5 100644
--- a/cddl/lib/libdtrace/udplite.d
+++ b/cddl/lib/libdtrace/udplite.d
@@ -17,8 +17,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
diff --git a/cddl/lib/libdtrace/unistd.d b/cddl/lib/libdtrace/unistd.d
index 1ceffef2b215..ead9d23ce670 100644
--- a/cddl/lib/libdtrace/unistd.d
+++ b/cddl/lib/libdtrace/unistd.d
@@ -17,8 +17,6 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
- *
- * $FreeBSD$
*/
/*
* Copyright 2007 Sun Microsystems, Inc. All rights reserved.
diff --git a/cddl/lib/libicp/Makefile b/cddl/lib/libicp/Makefile
index 6a8e979ea836..2d9bb3c67cb4 100644
--- a/cddl/lib/libicp/Makefile
+++ b/cddl/lib/libicp/Makefile
@@ -1,12 +1,10 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/icp
-PACKAGE= utilities
+PACKAGE= zfs
LIB= icp
LIBADD=
-
.if ${MACHINE_ARCH} == "amd64"
ASM_SOURCES_C = asm-x86_64/aes/aeskey.c
ASM_SOURCES_AS = \
@@ -15,16 +13,47 @@ ASM_SOURCES_AS = \
asm-x86_64/modes/gcm_pclmulqdq.S \
asm-x86_64/modes/aesni-gcm-x86_64.S \
asm-x86_64/modes/ghash-x86_64.S \
- asm-x86_64/sha2/sha256_impl.S \
- asm-x86_64/sha2/sha512_impl.S
+ asm-x86_64/sha2/sha256-x86_64.S \
+ asm-x86_64/sha2/sha512-x86_64.S \
+ asm-x86_64/blake3/blake3_avx2.S \
+ asm-x86_64/blake3/blake3_avx512.S \
+ asm-x86_64/blake3/blake3_sse2.S \
+ asm-x86_64/blake3/blake3_sse41.S
CFLAGS+= -D__amd64 -D_SYS_STACK_H -UHAVE_AES
+.elif ${MACHINE_ARCH} == "armv7"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-arm/sha2/sha256-armv7.S \
+ asm-arm/sha2/sha512-armv7.S
+.elif ${MACHINE_ARCH} == "aarch64"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-aarch64/blake3/b3_aarch64_sse2.S \
+ asm-aarch64/blake3/b3_aarch64_sse41.S \
+ asm-aarch64/sha2/sha256-armv8.S \
+ asm-aarch64/sha2/sha512-armv8.S
+.elif ${MACHINE_ARCH} == "powerpc64"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-ppc64/sha2/sha256-ppc.S \
+ asm-ppc64/sha2/sha512-ppc.S \
+ asm-ppc64/sha2/sha256-p8.S \
+ asm-ppc64/sha2/sha512-p8.S
+.elif ${MACHINE_ARCH} == "powerpc64le"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-ppc64/blake3/b3_ppc64le_sse2.S \
+ asm-ppc64/blake3/b3_ppc64le_sse41.S \
+ asm-ppc64/sha2/sha256-ppc.S \
+ asm-ppc64/sha2/sha512-ppc.S \
+ asm-ppc64/sha2/sha256-p8.S \
+ asm-ppc64/sha2/sha512-p8.S
.else
ASM_SOURCES_C =
ASM_SOURCES_AS =
.endif
-
KERNEL_C = \
spi/kcf_spi.c \
api/kcf_ctxops.c \
@@ -35,6 +64,9 @@ KERNEL_C = \
algs/aes/aes_impl_x86-64.c \
algs/aes/aes_impl.c \
algs/aes/aes_modes.c \
+ algs/blake3/blake3.c \
+ algs/blake3/blake3_generic.c \
+ algs/blake3/blake3_impl.c \
algs/edonr/edonr.c \
algs/modes/modes.c \
algs/modes/cbc.c \
@@ -44,7 +76,9 @@ KERNEL_C = \
algs/modes/ctr.c \
algs/modes/ccm.c \
algs/modes/ecb.c \
- algs/sha2/sha2.c \
+ algs/sha2/sha2_generic.c \
+ algs/sha2/sha256_impl.c \
+ algs/sha2/sha512_impl.c \
algs/skein/skein.c \
algs/skein/skein_block.c \
algs/skein/skein_iv.c \
@@ -59,10 +93,8 @@ KERNEL_C = \
core/kcf_prov_tabs.c \
$(ASM_SOURCES_C)
-
-
-
-
+.PATH: ${SRCTOP}/sys/contrib/openzfs/module/zfs
+KERNEL_C+= zfs_impl.c
SRCS= $(ASM_SOURCES_AS) $(KERNEL_C)
@@ -80,13 +112,31 @@ CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccomp
CFLAGS+= -DHAVE_ISSETUGID
CFLAGS+= -include ${SRCTOP}/sys/modules/zfs/zfs_config.h
-
CFLAGS.aes_amd64.S+= -DLOCORE
CFLAGS.aes_aesni.S+= -DLOCORE
CFLAGS.gcm_pclmulqdq.S+= -DLOCORE
CFLAGS.aesni-gcm-x86_64.S+= -DLOCORE
CFLAGS.ghash-x86_64.S+= -DLOCORE
-CFLAGS.sha256_impl.S+= -DLOCORE
-CFLAGS.sha512_impl.S+= -DLOCORE
+CFLAGS.sha256-x86_64.S+= -DLOCORE
+CFLAGS.sha512-x86_64.S+= -DLOCORE
+CFLAGS.blake3_avx2.S = -DLOCORE
+CFLAGS.blake3_avx512.S = -DLOCORE
+CFLAGS.blake3_sse2.S = -DLOCORE
+CFLAGS.blake3_sse41.S = -DLOCORE
+CFLAGS.b3_aarch64_sse2.S = -DLOCORE
+CFLAGS.b3_aarch64_sse41.S = -DLOCORE
+CFLAGS.sha256-armv7.S = -DLOCORE
+CFLAGS.sha256-armv8.S = -DLOCORE
+CFLAGS.sha512-armv7.S = -DLOCORE
+CFLAGS.sha512-armv8.S = -DLOCORE
+CFLAGS.b3_ppc64le_sse2.S = -DLOCORE
+CFLAGS.b3_ppc64le_sse41.S = -DLOCORE
+CFLAGS.sha256-p8.S = -DLOCORE
+CFLAGS.sha256-ppc.S = -DLOCORE
+CFLAGS.sha512-p8.S = -DLOCORE
+CFLAGS.sha512-ppc.S = -DLOCORE
+
+
+LDFLAGS.bfd+= -Wl,-znoexecstack
.include <bsd.lib.mk>
diff --git a/cddl/lib/libicp/Makefile.depend b/cddl/lib/libicp/Makefile.depend
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/cddl/lib/libicp/Makefile.depend
diff --git a/cddl/lib/libicp_rescue/Makefile b/cddl/lib/libicp_rescue/Makefile
index d3e69d276d17..e129a2f3e0f9 100644
--- a/cddl/lib/libicp_rescue/Makefile
+++ b/cddl/lib/libicp_rescue/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/icp
@@ -6,7 +5,6 @@ PACKAGE= utilities
LIB= icp_rescue
LIBADD=
-
.if ${MACHINE_ARCH} == "amd64"
ASM_SOURCES_C = asm-x86_64/aes/aeskey.c
ASM_SOURCES_AS = \
@@ -14,16 +12,47 @@ ASM_SOURCES_AS = \
asm-x86_64/aes/aes_aesni.S \
asm-x86_64/modes/gcm_pclmulqdq.S \
asm-x86_64/modes/aesni-gcm-x86_64.S \
- asm-x86_64/sha2/sha256_impl.S \
- asm-x86_64/sha2/sha512_impl.S
+ asm-x86_64/sha2/sha256-x86_64.S \
+ asm-x86_64/sha2/sha512-x86_64.S \
+ asm-x86_64/blake3/blake3_avx2.S \
+ asm-x86_64/blake3/blake3_avx512.S \
+ asm-x86_64/blake3/blake3_sse2.S \
+ asm-x86_64/blake3/blake3_sse41.S
CFLAGS+= -D__amd64 -D_SYS_STACK_H
+.elif ${MACHINE_ARCH} == "armv7"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-arm/sha2/sha256-armv7.S \
+ asm-arm/sha2/sha512-armv7.S
+.elif ${MACHINE_ARCH} == "aarch64"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-aarch64/blake3/b3_aarch64_sse2.S \
+ asm-aarch64/blake3/b3_aarch64_sse41.S \
+ asm-aarch64/sha2/sha256-armv8.S \
+ asm-aarch64/sha2/sha512-armv8.S
+.elif ${MACHINE_ARCH} == "powerpc64"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-ppc64/sha2/sha256-ppc.S \
+ asm-ppc64/sha2/sha512-ppc.S \
+ asm-ppc64/sha2/sha256-p8.S \
+ asm-ppc64/sha2/sha512-p8.S
+.elif ${MACHINE_ARCH} == "powerpc64le"
+ASM_SOURCES_C =
+ASM_SOURCES_AS = \
+ asm-ppc64/blake3/b3_ppc64le_sse2.S \
+ asm-ppc64/blake3/b3_ppc64le_sse41.S \
+ asm-ppc64/sha2/sha256-ppc.S \
+ asm-ppc64/sha2/sha512-ppc.S \
+ asm-ppc64/sha2/sha256-p8.S \
+ asm-ppc64/sha2/sha512-p8.S
.else
ASM_SOURCES_C =
ASM_SOURCES_AS =
.endif
-
KERNEL_C = \
spi/kcf_spi.c \
api/kcf_ctxops.c \
@@ -34,6 +63,9 @@ KERNEL_C = \
algs/aes/aes_impl_x86-64.c \
algs/aes/aes_impl.c \
algs/aes/aes_modes.c \
+ algs/blake3/blake3.c \
+ algs/blake3/blake3_generic.c \
+ algs/blake3/blake3_impl.c \
algs/edonr/edonr.c \
algs/modes/modes.c \
algs/modes/cbc.c \
@@ -43,7 +75,9 @@ KERNEL_C = \
algs/modes/ctr.c \
algs/modes/ccm.c \
algs/modes/ecb.c \
- algs/sha2/sha2.c \
+ algs/sha2/sha2_generic.c \
+ algs/sha2/sha256_impl.c \
+ algs/sha2/sha512_impl.c \
algs/skein/skein_block.c \
illumos-crypto.c \
io/aes.c \
@@ -56,6 +90,9 @@ KERNEL_C = \
core/kcf_prov_tabs.c \
$(ASM_SOURCES_C)
+.PATH: ${SRCTOP}/sys/contrib/openzfs/module/zfs
+KERNEL_C+= zfs_impl.c
+
SRCS= $(ASM_SOURCES_AS) $(KERNEL_C)
WARNS?= 2
@@ -72,14 +109,31 @@ CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccomp
CFLAGS+= -DHAVE_ISSETUGID -UHAVE_AVX -DRESCUE
CFLAGS+= -include ${SRCTOP}/sys/modules/zfs/zfs_config.h
-
CFLAGS.aes_amd64.S+= -DLOCORE
CFLAGS.aes_aesni.S+= -DLOCORE
CFLAGS.gcm_pclmulqdq.S+= -DLOCORE
CFLAGS.aesni-gcm-x86_64.S+= -DLOCORE
CFLAGS.ghash-x86_64.S+= -DLOCORE
-CFLAGS.sha256_impl.S+= -DLOCORE
-CFLAGS.sha512_impl.S+= -DLOCORE
+CFLAGS.sha256-x86_64.S+= -DLOCORE
+CFLAGS.sha512-x86_64.S+= -DLOCORE
CFLAGS.gcm.c+= -UCAN_USE_GCM_ASM
+CFLAGS.blake3_avx2.S = -DLOCORE
+CFLAGS.blake3_avx512.S = -DLOCORE
+CFLAGS.blake3_sse2.S = -DLOCORE
+CFLAGS.blake3_sse41.S = -DLOCORE
+CFLAGS.b3_aarch64_sse2.S = -DLOCORE
+CFLAGS.b3_aarch64_sse41.S = -DLOCORE
+CFLAGS.sha256-armv7.S = -DLOCORE
+CFLAGS.sha512-armv7.S = -DLOCORE
+CFLAGS.sha256-armv8.S = -DLOCORE
+CFLAGS.sha512-armv8.S = -DLOCORE
+CFLAGS.b3_ppc64le_sse2.S = -DLOCORE
+CFLAGS.b3_ppc64le_sse41.S = -DLOCORE
+CFLAGS.sha256-ppc.S = -DLOCORE
+CFLAGS.sha256-p8.S = -DLOCORE
+CFLAGS.sha512-ppc.S = -DLOCORE
+CFLAGS.sha512-p8.S = -DLOCORE
+
+LDFLAGS.bfd+= -Wl,-znoexecstack
.include <bsd.lib.mk>
diff --git a/cddl/lib/libicp_rescue/Makefile.depend b/cddl/lib/libicp_rescue/Makefile.depend
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/cddl/lib/libicp_rescue/Makefile.depend
diff --git a/cddl/lib/libnvpair/Makefile b/cddl/lib/libnvpair/Makefile
index aaf76ed3fb28..fb80d7c22ea5 100644
--- a/cddl/lib/libnvpair/Makefile
+++ b/cddl/lib/libnvpair/Makefile
@@ -1,13 +1,14 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/nvpair
.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libnvpair
+.PATH: ${SRCTOP}/sys/contrib/openzfs/include
LIB= nvpair
LIBADD= spl
-PACKAGE= runtime
+PACKAGE= zfs
# user
+INCS= libnvpair.h
SRCS= libnvpair.c \
libnvpair_json.c \
nvpair_alloc_system.c
diff --git a/cddl/lib/libnvpair/Makefile.depend b/cddl/lib/libnvpair/Makefile.depend
index 5f1a802404d8..409c3c86cc20 100644
--- a/cddl/lib/libnvpair/Makefile.depend
+++ b/cddl/lib/libnvpair/Makefile.depend
@@ -1,13 +1,12 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
+ cddl/lib/libspl \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/msun \
.include <dirdeps.mk>
diff --git a/cddl/lib/libspl/Makefile b/cddl/lib/libspl/Makefile
index 6a918c59e27e..e432b313d9d0 100644
--- a/cddl/lib/libspl/Makefile
+++ b/cddl/lib/libspl/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <bsd.init.mk>
.include <bsd.compiler.mk>
@@ -8,7 +7,7 @@
LIB= spl
LIBADD=
-PACKAGE= runtime
+PACKAGE= zfs
SRCS = \
assert.c \
diff --git a/cddl/lib/libspl/Makefile.depend b/cddl/lib/libspl/Makefile.depend
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/cddl/lib/libspl/Makefile.depend
diff --git a/cddl/lib/libtpool/Makefile b/cddl/lib/libtpool/Makefile
index 637385bc842e..6e85a8f82e9a 100644
--- a/cddl/lib/libtpool/Makefile
+++ b/cddl/lib/libtpool/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libtpool
.PATH: ${SRCTOP}/sys/contrib/openzfs/include
@@ -6,7 +5,7 @@
LIB= tpool
LIBADD= spl
-PACKAGE= runtime
+PACKAGE= zfs
INCS= thread_pool_impl.h
SRCS= thread_pool.c
diff --git a/cddl/lib/libtpool/Makefile.depend b/cddl/lib/libtpool/Makefile.depend
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/cddl/lib/libtpool/Makefile.depend
diff --git a/cddl/lib/libumem/Makefile b/cddl/lib/libumem/Makefile
index ca8f5e665920..1330ba0d94bd 100644
--- a/cddl/lib/libumem/Makefile
+++ b/cddl/lib/libumem/Makefile
@@ -1,8 +1,7 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/cddl/compat/opensolaris/lib/libumem
-PACKAGE= runtime
+PACKAGE= zfs
LIB= umem
SRCS= umem.c
WARNS?= 3
diff --git a/cddl/lib/libumem/Makefile.depend b/cddl/lib/libumem/Makefile.depend
index 1c1a9bee1d67..93249906da4f 100644
--- a/cddl/lib/libumem/Makefile.depend
+++ b/cddl/lib/libumem/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libuutil/Makefile b/cddl/lib/libuutil/Makefile
index 169b8d8afe01..333c581ccb90 100644
--- a/cddl/lib/libuutil/Makefile
+++ b/cddl/lib/libuutil/Makefile
@@ -1,8 +1,7 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libuutil
-PACKAGE= runtime
+PACKAGE= zfs
LIB= uutil
SRCS=\
uu_alloc.c \
@@ -10,7 +9,6 @@ SRCS=\
uu_ident.c \
uu_list.c \
uu_misc.c \
- uu_pname.c \
uu_string.c
WARNS?= 2
diff --git a/cddl/lib/libuutil/Makefile.depend b/cddl/lib/libuutil/Makefile.depend
index 8d409f5263ac..808980b1879e 100644
--- a/cddl/lib/libuutil/Makefile.depend
+++ b/cddl/lib/libuutil/Makefile.depend
@@ -1,7 +1,8 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
+ cddl/lib/libavl \
+ cddl/lib/libspl \
include \
include/xlocale \
lib/${CSU_DIR} \
diff --git a/cddl/lib/libzfs/Makefile b/cddl/lib/libzfs/Makefile
index 63bfcb39d4d8..ee57c30cc6ca 100644
--- a/cddl/lib/libzfs/Makefile
+++ b/cddl/lib/libzfs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/icp
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/zcommon
@@ -9,7 +8,7 @@
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/zstd
.PATH: ${SRCTOP}/sys/contrib/openzfs/module/zstd/lib
-PACKAGE= runtime
+PACKAGE= zfs
LIB= zfs
LIBADD= \
avl \
@@ -20,6 +19,7 @@ LIBADD= \
md \
nvpair \
pthread \
+ rt \
umem \
util \
uutil \
@@ -55,7 +55,6 @@ USER_C += \
os/freebsd/smb.c
KERNEL_C = \
- algs/sha2/sha2.c \
cityhash.c \
zfeature_common.c \
zfs_comutil.c \
@@ -103,6 +102,6 @@ CFLAGS+= -DHAVE_ISSETUGID
CFLAGS+= -include ${SRCTOP}/sys/modules/zfs/zfs_config.h
CFLAGS+= -DSYSCONFDIR=\"/etc\"
CFLAGS+= -DPKGDATADIR=\"/usr/share/zfs\"
-
+CFLAGS+= -DZFSEXECDIR=\"${LIBEXECDIR}/zfs\"
.include <bsd.lib.mk>
diff --git a/cddl/lib/libzfs/Makefile.depend b/cddl/lib/libzfs/Makefile.depend
index 54a7c43b42aa..1fead4b4f29d 100644
--- a/cddl/lib/libzfs/Makefile.depend
+++ b/cddl/lib/libzfs/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
@@ -7,6 +6,7 @@ DIRDEPS = \
cddl/lib/libumem \
cddl/lib/libuutil \
cddl/lib/libzfs_core \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
@@ -15,10 +15,12 @@ DIRDEPS = \
lib/libexpat \
lib/libgeom \
lib/libmd \
+ lib/librt \
lib/libthr \
lib/libutil \
lib/libz \
lib/msun \
+ secure/lib/libcrypto \
.include <dirdeps.mk>
diff --git a/cddl/lib/libzfs_core/Makefile b/cddl/lib/libzfs_core/Makefile
index 5a7475f55428..9797f004d10f 100644
--- a/cddl/lib/libzfs_core/Makefile
+++ b/cddl/lib/libzfs_core/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libzfs_core
.PATH: ${SRCTOP}/sys/contrib/openzfs/include
@@ -8,7 +7,7 @@
LIB= zfs_core
LIBADD= nvpair spl zutil
-PACKAGE= runtime
+PACKAGE= zfs
INCS= libzfs_core.h
SRCS= libzfs_core.c \
diff --git a/cddl/lib/libzfs_core/Makefile.depend b/cddl/lib/libzfs_core/Makefile.depend
index 26e3937b68fd..fd295d12904d 100644
--- a/cddl/lib/libzfs_core/Makefile.depend
+++ b/cddl/lib/libzfs_core/Makefile.depend
@@ -1,14 +1,14 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libnvpair \
+ cddl/lib/libspl \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/msun \
.include <dirdeps.mk>
diff --git a/cddl/lib/libzfsbootenv/Makefile b/cddl/lib/libzfsbootenv/Makefile
index be39af96124a..9579fb7dcf18 100644
--- a/cddl/lib/libzfsbootenv/Makefile
+++ b/cddl/lib/libzfsbootenv/Makefile
@@ -1,9 +1,8 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libzfsbootenv
.PATH: ${SRCTOP}/sys/contrib/openzfs/include
-PACKAGE= runtime
+PACKAGE= zfs
LIB= zfsbootenv
SHLIB_MAJOR= 1
diff --git a/cddl/lib/libzfsbootenv/Makefile.depend b/cddl/lib/libzfsbootenv/Makefile.depend
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/cddl/lib/libzfsbootenv/Makefile.depend
diff --git a/cddl/lib/libzpool/Makefile b/cddl/lib/libzpool/Makefile
index 69700ec51407..d05babdc26e0 100644
--- a/cddl/lib/libzpool/Makefile
+++ b/cddl/lib/libzpool/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
@@ -32,6 +31,7 @@ ATOMIC_SRCS= opensolaris_atomic.c
PICFLAG= -fPIC
.endif
+PACKAGE= zfs
LIB= zpool
USER_C = \
@@ -56,12 +56,14 @@ KERNEL_C = \
aggsum.c \
arc.c \
arc_os.c \
+ blake3_zfs.c \
blkptr.c \
bplist.c \
bpobj.c \
bptree.c \
- btree.c \
bqueue.c \
+ btree.c \
+ brt.c \
cityhash.c \
dbuf.c \
dbuf_stats.c \
@@ -115,10 +117,9 @@ KERNEL_C = \
refcount.c \
rrwlock.c \
sa.c \
- sha256.c \
+ sha2_zfs.c \
skein_zfs.c \
spa.c \
- spa_boot.c \
spa_checkpoint.c \
spa_config.c \
spa_errlog.c \
@@ -133,7 +134,6 @@ KERNEL_C = \
uberblock.c \
unique.c \
vdev.c \
- vdev_cache.c \
vdev_draid.c \
vdev_draid_rand.c \
vdev_file.c \
@@ -169,6 +169,7 @@ KERNEL_C = \
zcp_synctask.c \
zfeature.c \
zfs_byteswap.c \
+ zfs_chksum.c \
zfs_debug.c \
zfs_fm.c \
zfs_fuid.c \
@@ -285,6 +286,10 @@ CSTD= c99
CFLAGS+= -g -DDEBUG=1
+# Pointer values are used as debugging "tags" to mark reference count
+# ownerships and in some cases the tag reference is dropped after an
+# object is freed.
+CFLAGS.dbuf.c= ${NO_WUSE_AFTER_FREE}
CFLAGS.entropy_common.c= -fno-tree-vectorize
CFLAGS.entropy_common.c+= ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
CFLAGS.error_private.c= -fno-tree-vectorize
diff --git a/cddl/lib/libzpool/Makefile.depend b/cddl/lib/libzpool/Makefile.depend
index 06045f57b437..42b2995ff2d1 100644
--- a/cddl/lib/libzpool/Makefile.depend
+++ b/cddl/lib/libzpool/Makefile.depend
@@ -1,12 +1,11 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libavl \
cddl/lib/libicp \
cddl/lib/libnvpair \
+ cddl/lib/libspl \
cddl/lib/libumem \
- gnu/lib/csu \
include \
include/xlocale \
lib/${CSU_DIR} \
@@ -15,7 +14,6 @@ DIRDEPS = \
lib/libmd \
lib/libthr \
lib/libz \
- lib/msun \
.include <dirdeps.mk>
diff --git a/cddl/lib/libzutil/Makefile b/cddl/lib/libzutil/Makefile
index 2e6b53658b22..83f08960d533 100644
--- a/cddl/lib/libzutil/Makefile
+++ b/cddl/lib/libzutil/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libzutil
.PATH: ${SRCTOP}/sys/contrib/openzfs/lib/libzutil/os/freebsd
@@ -6,7 +5,7 @@
LIB= zutil
LIBADD= avl geom m tpool
-PACKAGE= runtime
+PACKAGE= zfs
INCS = zutil_import.h
diff --git a/cddl/lib/libzutil/Makefile.depend b/cddl/lib/libzutil/Makefile.depend
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/cddl/lib/libzutil/Makefile.depend
diff --git a/cddl/lib/pam_zfs_key/Makefile b/cddl/lib/pam_zfs_key/Makefile
index cf43802090dd..c35a8a6bd615 100644
--- a/cddl/lib/pam_zfs_key/Makefile
+++ b/cddl/lib/pam_zfs_key/Makefile
@@ -1,7 +1,7 @@
.PATH: ${SRCTOP}/sys/contrib/openzfs/contrib/pam_zfs_key
.PATH: ${SRCTOP}/sys/contrib/openzfs/include
-PACKAGE= utilities
+PACKAGE= zfs
LIB= pam_zfs_key
SHLIBDIR?= /usr/lib
diff --git a/cddl/lib/tests/Makefile b/cddl/lib/tests/Makefile
index 3b3078f8612a..b8996030aafc 100644
--- a/cddl/lib/tests/Makefile
+++ b/cddl/lib/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/tests
KYUAFILE= yes
diff --git a/cddl/lib/tests/Makefile.depend b/cddl/lib/tests/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/lib/tests/Makefile.depend
+++ b/cddl/lib/tests/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/sbin/Makefile b/cddl/sbin/Makefile
index 99c4a91a3e69..b0e1448c6455 100644
--- a/cddl/sbin/Makefile
+++ b/cddl/sbin/Makefile
@@ -1,15 +1,11 @@
-# $FreeBSD$
.include <src.opts.mk>
-SUBDIR= ${_zfs} ${_zpool}
-
SUBDIR.${MK_TESTS}+= tests
-.if ${MK_ZFS} != "no"
-_zfs= zfs
-_zpool= zpool
-.endif
+SUBDIR.${MK_ZFS}+= \
+ zfs \
+ zpool
SUBDIR_PARALLEL=
diff --git a/cddl/sbin/Makefile.inc b/cddl/sbin/Makefile.inc
index c5111d5cb286..9f2b933fcf06 100644
--- a/cddl/sbin/Makefile.inc
+++ b/cddl/sbin/Makefile.inc
@@ -1,4 +1,3 @@
-# $FreeBSD$
BINDIR?= /sbin
diff --git a/cddl/sbin/tests/Makefile b/cddl/sbin/tests/Makefile
index 3b3078f8612a..b8996030aafc 100644
--- a/cddl/sbin/tests/Makefile
+++ b/cddl/sbin/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/tests
KYUAFILE= yes
diff --git a/cddl/sbin/tests/Makefile.depend b/cddl/sbin/tests/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/sbin/tests/Makefile.depend
+++ b/cddl/sbin/tests/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/sbin/zfs/Makefile b/cddl/sbin/zfs/Makefile
index 6a6ef62e4fce..a47302c709d5 100644
--- a/cddl/sbin/zfs/Makefile
+++ b/cddl/sbin/zfs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
@@ -7,7 +6,7 @@ ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
.PATH: ${ZFSTOP}/man/man8
.PATH: ${ZFSTOP}/module/os/freebsd/spl
-PACKAGE= runtime
+PACKAGE= zfs
PROG= zfs
MAN= \
zfs.8 \
@@ -77,3 +76,5 @@ CFLAGS+= \
LIBADD= jail avl nvpair geom uutil zfs_core spl tpool zutil zfs m crypto
LDADD+= -pthread
.include <bsd.prog.mk>
+
+CWARNFLAGS.zfs_main.c+= -Wno-unused-variable
diff --git a/cddl/sbin/zfs/Makefile.depend b/cddl/sbin/zfs/Makefile.depend
index b22dd60b0ef8..41b9cb996621 100644
--- a/cddl/sbin/zfs/Makefile.depend
+++ b/cddl/sbin/zfs/Makefile.depend
@@ -1,28 +1,24 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libavl \
cddl/lib/libnvpair \
- cddl/lib/libumem \
+ cddl/lib/libspl \
+ cddl/lib/libtpool \
cddl/lib/libuutil \
cddl/lib/libzfs \
cddl/lib/libzfs_core \
- gnu/lib/csu \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libexpat \
lib/libgeom \
lib/libjail \
- lib/libmd \
- lib/libsbuf \
lib/libthr \
- lib/libutil \
- lib/libz \
lib/msun \
+ secure/lib/libcrypto \
.include <dirdeps.mk>
diff --git a/cddl/sbin/zpool/Makefile b/cddl/sbin/zpool/Makefile
index 4c2a8b94de19..5a47890e58f4 100644
--- a/cddl/sbin/zpool/Makefile
+++ b/cddl/sbin/zpool/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
@@ -10,10 +9,11 @@ ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
.PATH: ${ZFSTOP}/cmd/zpool/os/freebsd
-PACKAGE= runtime
+PACKAGE= zfs
PROG= zpool
MAN= \
spl.4 \
+ vdevprops.7 \
zfs.4 \
zpool.8 \
zpool-add.8 \
diff --git a/cddl/sbin/zpool/Makefile.depend b/cddl/sbin/zpool/Makefile.depend
index 53090da6e2fc..117ee30093fd 100644
--- a/cddl/sbin/zpool/Makefile.depend
+++ b/cddl/sbin/zpool/Makefile.depend
@@ -1,26 +1,21 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libavl \
cddl/lib/libnvpair \
- cddl/lib/libumem \
+ cddl/lib/libspl \
+ cddl/lib/libtpool \
cddl/lib/libuutil \
cddl/lib/libzfs \
cddl/lib/libzfs_core \
- gnu/lib/csu \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libexpat \
lib/libgeom \
- lib/libmd \
- lib/libsbuf \
lib/libthr \
- lib/libutil \
- lib/libz \
lib/msun \
diff --git a/cddl/share/Makefile b/cddl/share/Makefile
index 68670ffbe7e0..2e291b9425ed 100644
--- a/cddl/share/Makefile
+++ b/cddl/share/Makefile
@@ -1,12 +1,7 @@
-# $FreeBSD$
.include <src.opts.mk>
-SUBDIR= ${_zfs}
-
-.if ${MK_ZFS} != "no"
-_zfs= zfs
-.endif
+SUBDIR.${MK_ZFS}+= zfs
SUBDIR_PARALLEL=
diff --git a/cddl/share/zfs/Makefile b/cddl/share/zfs/Makefile
index 98e10b60aae6..a1fc04899b6e 100644
--- a/cddl/share/zfs/Makefile
+++ b/cddl/share/zfs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <src.opts.mk>
diff --git a/cddl/share/zfs/compatibility.d/Makefile b/cddl/share/zfs/compatibility.d/Makefile
index 255f4a3542b3..13d88fef184d 100644
--- a/cddl/share/zfs/compatibility.d/Makefile
+++ b/cddl/share/zfs/compatibility.d/Makefile
@@ -1,9 +1,10 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
.PATH: ${ZFSTOP}/cmd/zpool/compatibility.d
+PACKAGE= zfs
+
FILES= \
compat-2018 \
compat-2019 \
@@ -21,6 +22,7 @@ FILES= \
openzfs-2.0-linux \
openzfs-2.1-freebsd \
openzfs-2.1-linux \
+ openzfs-2.2 \
zol-0.6.1 \
zol-0.6.4 \
zol-0.6.5 \
@@ -41,12 +43,17 @@ LINKS= \
${FILESDIR}/freebsd-11.3 ${FILESDIR}/freebsd-12.0 \
${FILESDIR}/freebsd-11.3 ${FILESDIR}/freebsd-12.1 \
${FILESDIR}/freebsd-11.3 ${FILESDIR}/freebsd-12.2 \
+ ${FILESDIR}/freebsd-11.3 ${FILESDIR}/freebsd-12.3 \
+ ${FILESDIR}/freebsd-11.3 ${FILESDIR}/freebsd-12.4 \
${FILESDIR}/freebsd-11.3 ${FILESDIR}/freenas-11.3 \
${FILESDIR}/freenas-11.0 ${FILESDIR}/freenas-11.1 \
${FILESDIR}/openzfsonosx-1.9.3 ${FILESDIR}/openzfsonosx-1.9.4 \
${FILESDIR}/openzfs-2.0-freebsd ${FILESDIR}/truenas-12.0 \
${FILESDIR}/zol-0.7 ${FILESDIR}/ubuntu-18.04 \
- ${FILESDIR}/zol-0.8 ${FILESDIR}/ubuntu-20.04
+ ${FILESDIR}/zol-0.8 ${FILESDIR}/ubuntu-20.04 \
+ ${FILESDIR}/openzfs-2.1-linux ${FILESDIR}/ubuntu-22.04 \
+ ${FILESDIR}/openzfs-2.2 ${FILESDIR}/openzfs-2.2-linux \
+ ${FILESDIR}/openzfs-2.2 ${FILESDIR}/openzfs-2.2-freebsd
LINKMODE= ${NOBINMODE}
diff --git a/cddl/tests/Makefile b/cddl/tests/Makefile
index 3b3078f8612a..b8996030aafc 100644
--- a/cddl/tests/Makefile
+++ b/cddl/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/tests
KYUAFILE= yes
diff --git a/cddl/tests/Makefile.depend b/cddl/tests/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/tests/Makefile.depend
+++ b/cddl/tests/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.bin/Makefile b/cddl/usr.bin/Makefile
index 10d55215c0b3..ccf441cbabeb 100644
--- a/cddl/usr.bin/Makefile
+++ b/cddl/usr.bin/Makefile
@@ -1,22 +1,17 @@
-# $FreeBSD$
.include <src.opts.mk>
-SUBDIR= \
+SUBDIR.${MK_DTRACE}+= \
ctfconvert \
ctfdump \
- ctfmerge \
- ${_zinject} \
- ${_zstream} \
- ${_ztest}
+ ctfmerge
SUBDIR.${MK_TESTS}+= tests
-.if ${MK_ZFS} != "no"
-_zinject= zinject
-_ztest= ztest
-_zstream = zstream
-.endif
+SUBDIR.${MK_ZFS}+= \
+ zinject \
+ ztest \
+ zstream
SUBDIR_PARALLEL=
diff --git a/cddl/usr.bin/Makefile.inc b/cddl/usr.bin/Makefile.inc
index 4cec6fe01a45..78a3af23f3cc 100644
--- a/cddl/usr.bin/Makefile.inc
+++ b/cddl/usr.bin/Makefile.inc
@@ -1,4 +1,3 @@
-# $FreeBSD$
BINDIR?= /usr/bin
diff --git a/cddl/usr.bin/ctfconvert/Makefile b/cddl/usr.bin/ctfconvert/Makefile
index 78b65020452a..5dd38fbb5329 100644
--- a/cddl/usr.bin/ctfconvert/Makefile
+++ b/cddl/usr.bin/ctfconvert/Makefile
@@ -1,10 +1,10 @@
-# $FreeBSD$
.include <src.opts.mk>
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/tools/ctf/common
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/tools/ctf/cvt
+PACKAGE= ctf-tools
PROG= ctfconvert
SRCS= alist.c \
ctf.c \
diff --git a/cddl/usr.bin/ctfconvert/Makefile.depend b/cddl/usr.bin/ctfconvert/Makefile.depend
index eb40124b7c90..69aabda6c27e 100644
--- a/cddl/usr.bin/ctfconvert/Makefile.depend
+++ b/cddl/usr.bin/ctfconvert/Makefile.depend
@@ -1,11 +1,9 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
- gnu/lib/csu \
+ cddl/lib/libspl \
include \
include/xlocale \
- cddl/lib/libspl \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
diff --git a/cddl/usr.bin/ctfconvert/ctfconvert.1 b/cddl/usr.bin/ctfconvert/ctfconvert.1
index c7b01c9315ce..7697513d0740 100644
--- a/cddl/usr.bin/ctfconvert/ctfconvert.1
+++ b/cddl/usr.bin/ctfconvert/ctfconvert.1
@@ -26,8 +26,6 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $FreeBSD$
-.\"
.Dd April 21, 2022
.Dt CTFCONVERT 1
.Os
diff --git a/cddl/usr.bin/ctfconvert/tests/Makefile b/cddl/usr.bin/ctfconvert/tests/Makefile
index 431a1f25bd9f..101282261dd0 100644
--- a/cddl/usr.bin/ctfconvert/tests/Makefile
+++ b/cddl/usr.bin/ctfconvert/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
ATF_TESTS_SH+= ctfconvert_test
diff --git a/cddl/usr.bin/ctfconvert/tests/ctfconvert_test.sh b/cddl/usr.bin/ctfconvert/tests/ctfconvert_test.sh
index 04723fd08ad3..f19383cfbb4f 100644
--- a/cddl/usr.bin/ctfconvert/tests/ctfconvert_test.sh
+++ b/cddl/usr.bin/ctfconvert/tests/ctfconvert_test.sh
@@ -23,7 +23,6 @@
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
#
-# $FreeBSD$
#
usage_output='Usage: ctfconvert'
diff --git a/cddl/usr.bin/ctfdump/Makefile b/cddl/usr.bin/ctfdump/Makefile
index d7ddd45d9778..60ae9a0033b7 100644
--- a/cddl/usr.bin/ctfdump/Makefile
+++ b/cddl/usr.bin/ctfdump/Makefile
@@ -1,8 +1,8 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/tools/ctf/common
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/tools/ctf/dump
+PACKAGE= ctf-tools
PROG= ctfdump
SRCS= dump.c \
symbol.c \
diff --git a/cddl/usr.bin/ctfdump/Makefile.depend b/cddl/usr.bin/ctfdump/Makefile.depend
index ceebc6a83a34..edb476e399d9 100644
--- a/cddl/usr.bin/ctfdump/Makefile.depend
+++ b/cddl/usr.bin/ctfdump/Makefile.depend
@@ -1,8 +1,6 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
- gnu/lib/csu \
include \
include/xlocale \
lib/${CSU_DIR} \
diff --git a/cddl/usr.bin/ctfdump/ctfdump.1 b/cddl/usr.bin/ctfdump/ctfdump.1
index 68764d11b0f9..27dfe6563645 100644
--- a/cddl/usr.bin/ctfdump/ctfdump.1
+++ b/cddl/usr.bin/ctfdump/ctfdump.1
@@ -26,8 +26,6 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $FreeBSD$
-.\"
.Dd April 21, 2022
.Dt CTFDUMP 1
.Os
diff --git a/cddl/usr.bin/ctfmerge/Makefile b/cddl/usr.bin/ctfmerge/Makefile
index e9c8e505ed76..e7ad35ab097d 100644
--- a/cddl/usr.bin/ctfmerge/Makefile
+++ b/cddl/usr.bin/ctfmerge/Makefile
@@ -1,8 +1,8 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/tools/ctf/common
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/tools/ctf/cvt
+PACKAGE= ctf-tools
PROG= ctfmerge
SRCS= alist.c \
barrier.c \
diff --git a/cddl/usr.bin/ctfmerge/Makefile.depend b/cddl/usr.bin/ctfmerge/Makefile.depend
index 32a1985bd180..e724f22559ff 100644
--- a/cddl/usr.bin/ctfmerge/Makefile.depend
+++ b/cddl/usr.bin/ctfmerge/Makefile.depend
@@ -1,8 +1,7 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
- gnu/lib/csu \
+ cddl/lib/libspl \
include \
include/xlocale \
lib/${CSU_DIR} \
diff --git a/cddl/usr.bin/ctfmerge/ctfmerge.1 b/cddl/usr.bin/ctfmerge/ctfmerge.1
index b84bd8c84ead..2bc70db82dc9 100644
--- a/cddl/usr.bin/ctfmerge/ctfmerge.1
+++ b/cddl/usr.bin/ctfmerge/ctfmerge.1
@@ -26,8 +26,6 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $FreeBSD$
-.\"
.Dd April 21, 2022
.Dt CTFMERGE 1
.Os
diff --git a/cddl/usr.bin/tests/Makefile b/cddl/usr.bin/tests/Makefile
index 3b3078f8612a..b8996030aafc 100644
--- a/cddl/usr.bin/tests/Makefile
+++ b/cddl/usr.bin/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/tests
KYUAFILE= yes
diff --git a/cddl/usr.bin/tests/Makefile.depend b/cddl/usr.bin/tests/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.bin/tests/Makefile.depend
+++ b/cddl/usr.bin/tests/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.bin/zinject/Makefile b/cddl/usr.bin/zinject/Makefile
index fcc472c24214..71cd4776d339 100644
--- a/cddl/usr.bin/zinject/Makefile
+++ b/cddl/usr.bin/zinject/Makefile
@@ -1,10 +1,10 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
.PATH: ${ZFSTOP}/cmd/zinject
.PATH: ${ZFSTOP}/man/man8
+PACKAGE= zfs
PROG= zinject
INCS= zinject.h
SRCS= zinject.c translate.c
diff --git a/cddl/usr.bin/zinject/Makefile.depend b/cddl/usr.bin/zinject/Makefile.depend
index dfb2563fa7d1..c36e0e5ad2e7 100644
--- a/cddl/usr.bin/zinject/Makefile.depend
+++ b/cddl/usr.bin/zinject/Makefile.depend
@@ -1,27 +1,21 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libavl \
cddl/lib/libnvpair \
+ cddl/lib/libspl \
cddl/lib/libumem \
cddl/lib/libuutil \
cddl/lib/libzfs \
cddl/lib/libzfs_core \
cddl/lib/libzpool \
- gnu/lib/csu \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libexpat \
lib/libgeom \
- lib/libmd \
- lib/libsbuf \
- lib/libthr \
- lib/libutil \
- lib/libz \
lib/msun \
diff --git a/cddl/usr.bin/zstream/Makefile b/cddl/usr.bin/zstream/Makefile
index cfcff71a813f..4444973b2211 100644
--- a/cddl/usr.bin/zstream/Makefile
+++ b/cddl/usr.bin/zstream/Makefile
@@ -1,17 +1,19 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
.PATH: ${ZFSTOP}/cmd/zstream
.PATH: ${ZFSTOP}/man/man8
+PACKAGE= zfs
PROG= zstream
MAN= zstream.8
MLINKS= zstream.8 zstreamdump.8
INCS= zstream.h
SRCS= \
zstream.c \
+ zstream_decompress.c \
zstream_dump.c \
+ zstream_recompress.c \
zstream_redup.c \
zstream_token.c
diff --git a/cddl/usr.bin/ztest/Makefile b/cddl/usr.bin/ztest/Makefile
index 91118d13775d..2913349eccc1 100644
--- a/cddl/usr.bin/ztest/Makefile
+++ b/cddl/usr.bin/ztest/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <src.opts.mk>
@@ -7,6 +6,7 @@ ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
.PATH: ${ZFSTOP}/cmd
.PATH: ${ZFSTOP}/man/man1
+PACKAGE= zfs
PROG= ztest
MAN= ztest.1
diff --git a/cddl/usr.bin/ztest/Makefile.depend b/cddl/usr.bin/ztest/Makefile.depend
index dfb2563fa7d1..dd387951fe20 100644
--- a/cddl/usr.bin/ztest/Makefile.depend
+++ b/cddl/usr.bin/ztest/Makefile.depend
@@ -1,27 +1,23 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libavl \
+ cddl/lib/libicp \
cddl/lib/libnvpair \
+ cddl/lib/libspl \
cddl/lib/libumem \
cddl/lib/libuutil \
cddl/lib/libzfs \
cddl/lib/libzfs_core \
cddl/lib/libzpool \
- gnu/lib/csu \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libexpat \
lib/libgeom \
- lib/libmd \
- lib/libsbuf \
lib/libthr \
- lib/libutil \
- lib/libz \
lib/msun \
diff --git a/cddl/usr.bin/ztest/tests/Makefile b/cddl/usr.bin/ztest/tests/Makefile
index edf2a537dbe3..824497940b20 100644
--- a/cddl/usr.bin/ztest/tests/Makefile
+++ b/cddl/usr.bin/ztest/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <bsd.own.mk>
diff --git a/cddl/usr.bin/ztest/tests/ztest.sh b/cddl/usr.bin/ztest/tests/ztest.sh
index 9945d1a45aa9..8bc377917992 100755
--- a/cddl/usr.bin/ztest/tests/ztest.sh
+++ b/cddl/usr.bin/ztest/tests/ztest.sh
@@ -1,6 +1,5 @@
#
# Test Case: ztest
-# $FreeBSD$
#
atf_test_case ztest
ztest_head()
diff --git a/cddl/usr.libexec/Makefile b/cddl/usr.libexec/Makefile
index 6280cbab5766..9eb4872b69d5 100644
--- a/cddl/usr.libexec/Makefile
+++ b/cddl/usr.libexec/Makefile
@@ -1,12 +1,9 @@
-# $FreeBSD$
.include <src.opts.mk>
-SUBDIR= ${_zpool_influxdb}
-
-.if ${MK_ZFS} != "no"
-_zpool_influxdb= zpool_influxdb
-.endif
+SUBDIR.${MK_ZFS}+= \
+ zfs_prepare_disk \
+ zpool_influxdb
SUBDIR_PARALLEL=
diff --git a/cddl/usr.libexec/zfs_prepare_disk/Makefile b/cddl/usr.libexec/zfs_prepare_disk/Makefile
new file mode 100644
index 000000000000..e75484c6dc59
--- /dev/null
+++ b/cddl/usr.libexec/zfs_prepare_disk/Makefile
@@ -0,0 +1,20 @@
+
+ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
+
+.PATH: ${ZFSTOP}/scripts
+
+PACKAGE= zfs
+SCRIPTS= zfs_prepare_disk
+SCRIPTSDIR= ${LIBEXECDIR}/zfs
+
+.PATH: ${ZFSTOP}/man/man8
+MAN= zfs_prepare_disk.8
+
+CLEANFILES+= zfs_prepare_disk.8
+
+zfs_prepare_disk.8: zfs_prepare_disk.8.in
+ sed ${MAN_SUB} ${.ALLSRC} >${.TARGET}
+
+MAN_SUB+= -e 's|@zfsexecdir@|${LIBEXECDIR}/zfs|g'
+
+.include <bsd.prog.mk>
diff --git a/cddl/usr.libexec/zpool_influxdb/Makefile b/cddl/usr.libexec/zpool_influxdb/Makefile
index 2fb22f02ef32..7c0a245903a7 100644
--- a/cddl/usr.libexec/zpool_influxdb/Makefile
+++ b/cddl/usr.libexec/zpool_influxdb/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
diff --git a/cddl/usr.libexec/zpool_influxdb/Makefile.depend b/cddl/usr.libexec/zpool_influxdb/Makefile.depend
index 53090da6e2fc..50b043094969 100644
--- a/cddl/usr.libexec/zpool_influxdb/Makefile.depend
+++ b/cddl/usr.libexec/zpool_influxdb/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/Makefile b/cddl/usr.sbin/Makefile
index 42de5c96c53a..b3bf139feaef 100644
--- a/cddl/usr.sbin/Makefile
+++ b/cddl/usr.sbin/Makefile
@@ -1,24 +1,18 @@
-# $FreeBSD$
.include <src.opts.mk>
-SUBDIR= ${_dtrace} \
+SUBDIR.${MK_DTRACE}+= \
+ ${_dtrace} \
${_dwatch} \
${_lockstat} \
- ${_plockstat} \
- ${_zdb} \
- ${_zfsd} \
- ${_zhack}
+ ${_plockstat}
SUBDIR.${MK_TESTS}+= tests
-.if ${MK_ZFS} != "no"
-_zdb= zdb
-_zhack= zhack
-. if ${MK_CXX} != "no"
-_zfsd= zfsd
-. endif
-.endif
+SUBDIR.${MK_ZFS}+= \
+ zdb \
+ zhack \
+ zfsd
.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386"
_dtrace= dtrace
@@ -34,11 +28,6 @@ _dwatch= dwatch
_lockstat= lockstat
.endif
-.if ${MACHINE_CPUARCH} == "mips"
-_dtrace= dtrace
-_dwatch= dwatch
-.endif
-
.if ${MACHINE_CPUARCH} == "powerpc"
_dtrace= dtrace
_dwatch= dwatch
diff --git a/cddl/usr.sbin/Makefile.inc b/cddl/usr.sbin/Makefile.inc
index 282198ea8d8c..5c01baa093b7 100644
--- a/cddl/usr.sbin/Makefile.inc
+++ b/cddl/usr.sbin/Makefile.inc
@@ -1,4 +1,3 @@
-# $FreeBSD$
BINDIR?= /usr/sbin
diff --git a/cddl/usr.sbin/dtrace/Makefile b/cddl/usr.sbin/dtrace/Makefile
index d8510e62fb29..4dcfc0ebef7b 100644
--- a/cddl/usr.sbin/dtrace/Makefile
+++ b/cddl/usr.sbin/dtrace/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <src.opts.mk>
@@ -30,6 +29,11 @@ CFLAGS+= -DHAVE_ISSETUGID
#CFLAGS+= -DNEED_ERRLOC
#YFLAGS+= -d
+.if ${MK_DTRACE_ASAN} != "no"
+CFLAGS+= -fsanitize=address -fsanitize=undefined
+LDFLAGS+= -fsanitize=address -fsanitize=undefined
+.endif
+
LIBADD= dtrace ctf elf proc spl
.if ${MK_DTRACE_TESTS} != "no"
diff --git a/cddl/usr.sbin/dtrace/Makefile.depend b/cddl/usr.sbin/dtrace/Makefile.depend
index c37ef4acf01e..244baabbff3d 100644
--- a/cddl/usr.sbin/dtrace/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/Makefile.depend
@@ -1,24 +1,17 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libctf \
cddl/lib/libdtrace \
- gnu/lib/csu \
+ cddl/lib/libspl \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libcxxrt \
lib/libelf \
- lib/libkvm \
lib/libproc \
- lib/libprocstat \
lib/librtld_db \
- lib/libthr \
- lib/libutil \
- lib/libz \
.include <dirdeps.mk>
diff --git a/cddl/usr.sbin/dtrace/tests/Makefile b/cddl/usr.sbin/dtrace/tests/Makefile
index a311126f38b5..c7391dec2416 100644
--- a/cddl/usr.sbin/dtrace/tests/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <bsd.own.mk>
diff --git a/cddl/usr.sbin/dtrace/tests/Makefile.depend b/cddl/usr.sbin/dtrace/tests/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/amd64/Makefile b/cddl/usr.sbin/dtrace/tests/amd64/Makefile
index 39ccd333bedf..049692a46cd5 100644
--- a/cddl/usr.sbin/dtrace/tests/amd64/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/amd64/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
TESTSDIR= ${TESTSBASE}/cddl/usr.sbin/dtrace/amd64
TESTS_SUBDIRS+= arrays
diff --git a/cddl/usr.sbin/dtrace/tests/amd64/arrays/Makefile b/cddl/usr.sbin/dtrace/tests/amd64/arrays/Makefile
index 0308ba5083e1..60d6cdfd1f9f 100644
--- a/cddl/usr.sbin/dtrace/tests/amd64/arrays/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/amd64/arrays/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/Makefile b/cddl/usr.sbin/dtrace/tests/common/Makefile
index c395269e7aa9..cbcb41316094 100644
--- a/cddl/usr.sbin/dtrace/tests/common/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
# We exclude several subdirectories: nfs and sysevent do not compile on
# FreeBSD, and docsExamples doesn't seem amenable to automated testing.
@@ -32,6 +31,7 @@ TESTS_SUBDIRS+= aggs \
ip \
java_api \
json \
+ kinst \
lexer \
llquantize \
mdb \
diff --git a/cddl/usr.sbin/dtrace/tests/common/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile b/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile
index b5e95bc8fd67..a3c7736f20f7 100644
--- a/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/aggs/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile b/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile
index 2abee2f8598e..d573cb4b06c6 100644
--- a/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/arithmetic/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile b/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile
index abbc48322795..032f47461a92 100644
--- a/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/arrays/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile b/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile
index d7e64b8e4501..772b560bb516 100644
--- a/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/assocs/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/begin/Makefile b/cddl/usr.sbin/dtrace/tests/common/begin/Makefile
index 1c254bfe2958..c540a96cfaf4 100644
--- a/cddl/usr.sbin/dtrace/tests/common/begin/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/begin/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/begin/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/begin/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/begin/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/begin/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile b/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile
index 903e19262f73..2b3499fa092b 100644
--- a/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/bitfields/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile b/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile
index e9680e57088c..7f6223e3796e 100644
--- a/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/buffering/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile b/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile
index 962e8c9bddb8..b0cbc7961e9b 100644
--- a/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/builtinvar/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/cg/Makefile b/cddl/usr.sbin/dtrace/tests/common/cg/Makefile
index e98af5191aea..104dc2063a8c 100644
--- a/cddl/usr.sbin/dtrace/tests/common/cg/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/cg/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/cg/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/cg/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/cg/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/cg/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile b/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile
index 0e835239c35d..ecd84a68928d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/clauses/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile b/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile
index 7b8e85d904e7..75d5bebfaf93 100644
--- a/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/cpc/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/decls/Makefile b/cddl/usr.sbin/dtrace/tests/common/decls/Makefile
index bd3bf7716feb..1c0800355eff 100644
--- a/cddl/usr.sbin/dtrace/tests/common/decls/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/decls/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/decls/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/decls/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/decls/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/decls/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile b/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile
index 5ca7d0908fd7..4115176de9af 100644
--- a/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/docsExamples/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/drops/Makefile b/cddl/usr.sbin/dtrace/tests/common/drops/Makefile
index 4f1973c69b26..b7edb1177a78 100644
--- a/cddl/usr.sbin/dtrace/tests/common/drops/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/drops/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/drops/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/drops/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/drops/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/drops/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile b/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile
index dc77d8f0bc04..6d3815bbc80d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/dtraceUtil/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/end/Makefile b/cddl/usr.sbin/dtrace/tests/common/end/Makefile
index a05361ec4a39..8bc3ec2c65df 100644
--- a/cddl/usr.sbin/dtrace/tests/common/end/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/end/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/end/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/end/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/end/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/end/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/enum/Makefile b/cddl/usr.sbin/dtrace/tests/common/enum/Makefile
index 9b78801d4c2f..463824118757 100644
--- a/cddl/usr.sbin/dtrace/tests/common/enum/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/enum/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/enum/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/enum/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/enum/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/enum/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/env/Makefile b/cddl/usr.sbin/dtrace/tests/common/env/Makefile
index 9c37c28b448b..35eff477d4bb 100644
--- a/cddl/usr.sbin/dtrace/tests/common/env/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/env/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/error/Makefile b/cddl/usr.sbin/dtrace/tests/common/error/Makefile
index afd93dd222ee..372a8968585f 100644
--- a/cddl/usr.sbin/dtrace/tests/common/error/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/error/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/error/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/error/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/error/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/error/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/exit/Makefile b/cddl/usr.sbin/dtrace/tests/common/exit/Makefile
index 3732caa83335..ded0777e452b 100644
--- a/cddl/usr.sbin/dtrace/tests/common/exit/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/exit/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/exit/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/exit/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/exit/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/exit/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile b/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile
index c773b78ba795..4aaf2013d59f 100644
--- a/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/fbtprovider/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile b/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile
index 67d0b3cc4928..2fb59dc91f1d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/funcs/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile b/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile
index b9b94f2c6b35..0e07006bc116 100644
--- a/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/grammar/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/include/Makefile b/cddl/usr.sbin/dtrace/tests/common/include/Makefile
index d84f25bef30d..6d01872ad48c 100644
--- a/cddl/usr.sbin/dtrace/tests/common/include/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/include/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/include/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/include/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/include/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/include/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/inline/Makefile b/cddl/usr.sbin/dtrace/tests/common/inline/Makefile
index 3a30b97d3cb6..e3ff5a1e9a84 100644
--- a/cddl/usr.sbin/dtrace/tests/common/inline/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/inline/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/inline/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/inline/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/inline/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/inline/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/io/Makefile b/cddl/usr.sbin/dtrace/tests/common/io/Makefile
index 9075358230c4..58e1d3ed2745 100644
--- a/cddl/usr.sbin/dtrace/tests/common/io/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/io/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/io/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/io/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/io/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/io/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/ip/Makefile b/cddl/usr.sbin/dtrace/tests/common/ip/Makefile
index 25a214b7f37b..73cc3443d987 100644
--- a/cddl/usr.sbin/dtrace/tests/common/ip/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/ip/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/ip/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/ip/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/ip/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/ip/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile b/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile
index 7c7fdef9c008..08072d19e0ed 100644
--- a/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/java_api/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/json/Makefile b/cddl/usr.sbin/dtrace/tests/common/json/Makefile
index 24400027c1e4..c004df07d6ef 100644
--- a/cddl/usr.sbin/dtrace/tests/common/json/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/json/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/json/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/json/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/json/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/json/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/kinst/Makefile b/cddl/usr.sbin/dtrace/tests/common/kinst/Makefile
new file mode 100644
index 000000000000..f33a649010a5
--- /dev/null
+++ b/cddl/usr.sbin/dtrace/tests/common/kinst/Makefile
@@ -0,0 +1,18 @@
+
+#
+# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
+#
+
+PACKAGE= tests
+
+${PACKAGE}FILES= \
+ tst.basic.ksh \
+
+TESTEXES= \
+
+
+CFILES= \
+
+
+
+.include "../../dtrace.test.mk"
diff --git a/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile b/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile
index d53872a0361b..abeb9f04ea5d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/lexer/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile b/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile
index ed99dd1e116f..a73998387cc5 100644
--- a/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/llquantize/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile b/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile
index 26c26e7ba558..855582e677d7 100644
--- a/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/mdb/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/mib/Makefile b/cddl/usr.sbin/dtrace/tests/common/mib/Makefile
index ed799e68a879..573cc5ec1033 100644
--- a/cddl/usr.sbin/dtrace/tests/common/mib/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/mib/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/mib/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/mib/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/mib/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/mib/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/misc/Makefile b/cddl/usr.sbin/dtrace/tests/common/misc/Makefile
index 87084ab5d593..2bd6eb69a1d2 100644
--- a/cddl/usr.sbin/dtrace/tests/common/misc/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/misc/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/misc/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/misc/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/misc/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/misc/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile b/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile
index 2c0c4263a909..906d3e4bc4a7 100644
--- a/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/multiaggs/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/nfs/Makefile b/cddl/usr.sbin/dtrace/tests/common/nfs/Makefile
index b50285991374..ae820ee08c88 100644
--- a/cddl/usr.sbin/dtrace/tests/common/nfs/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/nfs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile b/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile
index 2f56b12a035c..6973488a7d28 100644
--- a/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/offsetof/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/operators/Makefile b/cddl/usr.sbin/dtrace/tests/common/operators/Makefile
index daf530b93b62..ccbbe083c13c 100644
--- a/cddl/usr.sbin/dtrace/tests/common/operators/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/operators/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/operators/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/operators/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/operators/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/operators/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/pid/Makefile b/cddl/usr.sbin/dtrace/tests/common/pid/Makefile
index 0b9fdeb8bb6e..0058a1100196 100644
--- a/cddl/usr.sbin/dtrace/tests/common/pid/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/pid/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/pid/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/pid/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/pid/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/pid/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile b/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile
index 57e30ed99036..ec40ac7ae151 100644
--- a/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/plockstat/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile b/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile
index af438aaaac2c..55921d888df8 100644
--- a/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/pointers/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile b/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile
index 26b6920d0b0c..b00a28915ea1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/pragma/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile b/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile
index bd14b43757f6..d0a983398dd6 100644
--- a/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/predicates/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile b/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile
index f8b8917be205..11ac3dc1107d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/preprocessor/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/print/Makefile b/cddl/usr.sbin/dtrace/tests/common/print/Makefile
index af4e20e30557..ecd2bee5d677 100644
--- a/cddl/usr.sbin/dtrace/tests/common/print/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/print/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/print/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/print/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/print/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/print/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/printa/Makefile b/cddl/usr.sbin/dtrace/tests/common/printa/Makefile
index 8f5ac3613dcb..895c00fc589f 100644
--- a/cddl/usr.sbin/dtrace/tests/common/printa/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/printa/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/printa/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/printa/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/printa/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/printa/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/printf/Makefile b/cddl/usr.sbin/dtrace/tests/common/printf/Makefile
index 86cfdbbd5d9b..97b9c89bc63c 100644
--- a/cddl/usr.sbin/dtrace/tests/common/printf/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/printf/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/printf/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/printf/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/printf/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/printf/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/privs/Makefile b/cddl/usr.sbin/dtrace/tests/common/privs/Makefile
index 36f6106f8f96..a53c8d87f70f 100644
--- a/cddl/usr.sbin/dtrace/tests/common/privs/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/privs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/privs/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/privs/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/privs/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/privs/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/probes/Makefile b/cddl/usr.sbin/dtrace/tests/common/probes/Makefile
index 7e02b9a73900..718afcbbc375 100644
--- a/cddl/usr.sbin/dtrace/tests/common/probes/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/probes/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/probes/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/probes/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/probes/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/probes/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/proc/Makefile b/cddl/usr.sbin/dtrace/tests/common/proc/Makefile
index 296634da3e38..92491ab55acf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/proc/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/proc/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/proc/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/proc/Makefile.depend
index 564eb51e0156..ab828d5334d8 100644
--- a/cddl/usr.sbin/dtrace/tests/common/proc/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/proc/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile b/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile
index 4e5a0157ecff..0e5439792b20 100644
--- a/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile.depend
index 03d33794d0e3..af9acf31579d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/profile-n/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/providers/Makefile b/cddl/usr.sbin/dtrace/tests/common/providers/Makefile
index 3972831ba5d5..31304c1bea7d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/providers/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/providers/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/providers/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/providers/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/providers/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/providers/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/raise/Makefile b/cddl/usr.sbin/dtrace/tests/common/raise/Makefile
index 83af0e40de1f..653d545eb5e0 100644
--- a/cddl/usr.sbin/dtrace/tests/common/raise/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/raise/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/raise/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/raise/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/raise/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/raise/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/rates/Makefile b/cddl/usr.sbin/dtrace/tests/common/rates/Makefile
index bc9ab0a9d446..4710339fe9ac 100644
--- a/cddl/usr.sbin/dtrace/tests/common/rates/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/rates/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/rates/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/rates/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/rates/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/rates/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/safety/Makefile b/cddl/usr.sbin/dtrace/tests/common/safety/Makefile
index 51b302fd3ad7..d3ce7c97abec 100644
--- a/cddl/usr.sbin/dtrace/tests/common/safety/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/safety/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/safety/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/safety/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/safety/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/safety/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile b/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile
index 9f019068da35..0d78e9b7117f 100644
--- a/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/scalars/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/sched/Makefile b/cddl/usr.sbin/dtrace/tests/common/sched/Makefile
index d1bf42553346..79791b6affb6 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sched/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/sched/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/sched/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/sched/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sched/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/sched/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile b/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile
index 1562629423ea..200668c94d50 100644
--- a/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/scripting/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile b/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile
index ad0a43e4047e..cc856e43924e 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/sdt/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile b/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile
index 021d0099b213..3dc50694e7b7 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/sizeof/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile b/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile
index 5afee0225e89..9726906660f9 100644
--- a/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/speculation/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/stability/Makefile b/cddl/usr.sbin/dtrace/tests/common/stability/Makefile
index 826202d4de3f..3eada9ad78ed 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stability/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/stability/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/stability/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/stability/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stability/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/stability/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/stack/Makefile b/cddl/usr.sbin/dtrace/tests/common/stack/Makefile
index 2fc1e8164dc6..350ab18e8a03 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stack/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/stack/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/stack/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/stack/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stack/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/stack/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile b/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile
index e7beb43fa827..3dc20ffa2f16 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/stackdepth/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/stop/Makefile b/cddl/usr.sbin/dtrace/tests/common/stop/Makefile
index 50a44bbd0a98..8583c29bf1a5 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stop/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/stop/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/stop/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/stop/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/stop/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/stop/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile b/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile
index 19937d3055eb..4eea0b538b16 100644
--- a/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/strlen/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile b/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile
index 0ccc037d8bf3..a45315d01e33 100644
--- a/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/strtoll/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/struct/Makefile b/cddl/usr.sbin/dtrace/tests/common/struct/Makefile
index 35dd51a8067c..e35235dc2b6d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/struct/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/struct/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/struct/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/struct/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/struct/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/struct/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile b/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile
index 40fc86a45ce0..4c9621e6c3c7 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/sugar/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile b/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile
index f759b6bd398f..2d3aaf1236cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/syscall/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/sysevent/Makefile b/cddl/usr.sbin/dtrace/tests/common/sysevent/Makefile
index d87b2bbaf042..2c6b909acfaf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/sysevent/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/sysevent/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile b/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile
index 1800635351d7..76e8f4282813 100644
--- a/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/tick-n/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/trace/Makefile b/cddl/usr.sbin/dtrace/tests/common/trace/Makefile
index 19ff8e44230b..be7c86bca876 100644
--- a/cddl/usr.sbin/dtrace/tests/common/trace/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/trace/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/trace/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/trace/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/trace/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/trace/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile b/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile
index 29b0ea26e691..3006ec1ff4a5 100644
--- a/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/tracemem/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/translators/Makefile b/cddl/usr.sbin/dtrace/tests/common/translators/Makefile
index 6d38d1d63e36..57cedb2cbcce 100644
--- a/cddl/usr.sbin/dtrace/tests/common/translators/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/translators/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/translators/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/translators/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/translators/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/translators/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile b/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile
index d3edcfd071ed..3bbc8fa3344d 100644
--- a/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/typedef/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/types/Makefile b/cddl/usr.sbin/dtrace/tests/common/types/Makefile
index 89c2947f2632..553037dd91d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/types/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/types/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/types/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/types/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/types/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/types/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile b/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile
index 945a853b69df..0a50173d3a84 100644
--- a/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/uctf/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/union/Makefile b/cddl/usr.sbin/dtrace/tests/common/union/Makefile
index 855869f05f04..4bb51f899a16 100644
--- a/cddl/usr.sbin/dtrace/tests/common/union/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/union/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/union/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/union/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/union/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/union/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile b/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile
index dd5571980d1d..edf3c451e9cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/usdt/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile b/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile
index 6ea0621a0c29..75931649250b 100644
--- a/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile.depend
index cae7e645ef6a..d80b3a4991d1 100644
--- a/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/ustack/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/vars/Makefile b/cddl/usr.sbin/dtrace/tests/common/vars/Makefile
index bced0bf6da53..29cf09bd1a49 100644
--- a/cddl/usr.sbin/dtrace/tests/common/vars/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/vars/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/vars/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/vars/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/vars/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/vars/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/common/version/Makefile b/cddl/usr.sbin/dtrace/tests/common/version/Makefile
index 3f1589f4249c..ccce43d023fa 100644
--- a/cddl/usr.sbin/dtrace/tests/common/version/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/common/version/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/common/version/Makefile.depend b/cddl/usr.sbin/dtrace/tests/common/version/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/dtrace/tests/common/version/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/tests/common/version/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/tests/dtrace.test.mk b/cddl/usr.sbin/dtrace/tests/dtrace.test.mk
index 0da134c0cbc2..c0d66aac3382 100644
--- a/cddl/usr.sbin/dtrace/tests/dtrace.test.mk
+++ b/cddl/usr.sbin/dtrace/tests/dtrace.test.mk
@@ -1,4 +1,3 @@
-# $FreeBSD$
TESTGROUP= ${.CURDIR:H:T}/${.CURDIR:T}
TESTBASE= ${SRCTOP}/cddl/contrib/opensolaris/cmd/dtrace/test/tst
diff --git a/cddl/usr.sbin/dtrace/tests/i386/Makefile b/cddl/usr.sbin/dtrace/tests/i386/Makefile
index bd6f7cf5ad5c..9501fd7f3cc2 100644
--- a/cddl/usr.sbin/dtrace/tests/i386/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/i386/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
TESTSDIR= ${TESTSBASE}/cddl/usr.sbin/dtrace/i386
TESTS_SUBDIRS+= arrays \
diff --git a/cddl/usr.sbin/dtrace/tests/i386/arrays/Makefile b/cddl/usr.sbin/dtrace/tests/i386/arrays/Makefile
index e97c9c64fbba..1cf9fdac093a 100644
--- a/cddl/usr.sbin/dtrace/tests/i386/arrays/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/i386/arrays/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/i386/funcs/Makefile b/cddl/usr.sbin/dtrace/tests/i386/funcs/Makefile
index 64a00fa57d8b..231db7bb146d 100644
--- a/cddl/usr.sbin/dtrace/tests/i386/funcs/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/i386/funcs/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/i386/pid/Makefile b/cddl/usr.sbin/dtrace/tests/i386/pid/Makefile
index 61fb328cbc7b..41f31d287fbb 100644
--- a/cddl/usr.sbin/dtrace/tests/i386/pid/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/i386/pid/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/i386/ustack/Makefile b/cddl/usr.sbin/dtrace/tests/i386/ustack/Makefile
index bc7c6a2d34c0..0df96490d438 100644
--- a/cddl/usr.sbin/dtrace/tests/i386/ustack/Makefile
+++ b/cddl/usr.sbin/dtrace/tests/i386/ustack/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
#
# This Makefile was generated by $srcdir/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh.
diff --git a/cddl/usr.sbin/dtrace/tests/tools/dtest.sh b/cddl/usr.sbin/dtrace/tests/tools/dtest.sh
index dc1f0244739c..e87562d2fe45 100755
--- a/cddl/usr.sbin/dtrace/tests/tools/dtest.sh
+++ b/cddl/usr.sbin/dtrace/tests/tools/dtest.sh
@@ -1,7 +1,5 @@
#!/bin/sh
-# $FreeBSD$
-
usage()
{
cat >&2 <<__EOF__
diff --git a/cddl/usr.sbin/dtrace/tests/tools/exclude.sh b/cddl/usr.sbin/dtrace/tests/tools/exclude.sh
index 26e875073edd..dce5a843b605 100755
--- a/cddl/usr.sbin/dtrace/tests/tools/exclude.sh
+++ b/cddl/usr.sbin/dtrace/tests/tools/exclude.sh
@@ -1,4 +1,3 @@
-# $FreeBSD$
# This file lists DTrace tests which are known to fail or hang/crash the
# system. They were pulled from the legacy DTrace test infrastructure in
diff --git a/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh b/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh
index 4f756f7eaf3a..b3663a91d9ef 100755
--- a/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh
+++ b/cddl/usr.sbin/dtrace/tests/tools/genmakefiles.sh
@@ -1,4 +1,3 @@
-# $FreeBSD$
usage()
{
@@ -60,8 +59,6 @@ WITH_CTF=YES
local makefile=$(mktemp)
cat <<__EOF__ > $makefile
-# \$FreeBSD$
-
#
# This Makefile was generated by \$srcdir${ORIGINDIR#${TOPDIR}}/genmakefiles.sh.
#
diff --git a/cddl/usr.sbin/dtrace/tests/tools/gentest.sh b/cddl/usr.sbin/dtrace/tests/tools/gentest.sh
index 6bad066e5419..5d8912ac29b0 100755
--- a/cddl/usr.sbin/dtrace/tests/tools/gentest.sh
+++ b/cddl/usr.sbin/dtrace/tests/tools/gentest.sh
@@ -1,4 +1,3 @@
-# $FreeBSD$
usage()
{
diff --git a/cddl/usr.sbin/dwatch/Makefile b/cddl/usr.sbin/dwatch/Makefile
index aa2873ec4681..e146e744e844 100644
--- a/cddl/usr.sbin/dwatch/Makefile
+++ b/cddl/usr.sbin/dwatch/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include <src.opts.mk>
diff --git a/cddl/usr.sbin/dwatch/dwatch b/cddl/usr.sbin/dwatch/dwatch
index 8d90d8173dfe..9adde7eb8d49 100755
--- a/cddl/usr.sbin/dwatch/dwatch
+++ b/cddl/usr.sbin/dwatch/dwatch
@@ -27,7 +27,6 @@
############################################################ IDENT(1)
#
# $Title: Watch processes as they trigger a particular DTrace probe $
-# $FreeBSD$
#
############################################################ CONFIGURATION
diff --git a/cddl/usr.sbin/dwatch/dwatch.1 b/cddl/usr.sbin/dwatch/dwatch.1
index d5595a530c0e..28b604d43c5d 100644
--- a/cddl/usr.sbin/dwatch/dwatch.1
+++ b/cddl/usr.sbin/dwatch/dwatch.1
@@ -22,8 +22,6 @@
.\" ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
-.\" $FreeBSD$
-.\"
.Dd February 9, 2018
.Dt DWATCH 1
.Os
@@ -68,7 +66,7 @@ utility uses
.Xr dtrace 1
to display process info when a given DTrace probe point is triggered.
Only the root user or users with
-.Xr sudo 8
+.Xr sudo 8 Pq Pa ports/security/sudo
access can run this command.
.Pp
.Nm
diff --git a/cddl/usr.sbin/dwatch/examples/Makefile b/cddl/usr.sbin/dwatch/examples/Makefile
index 344d67d27ec8..185f57d8cfe2 100644
--- a/cddl/usr.sbin/dwatch/examples/Makefile
+++ b/cddl/usr.sbin/dwatch/examples/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
PACKAGE= dwatch
FILESDIR= ${SHAREDIR}/examples/dwatch
diff --git a/cddl/usr.sbin/dwatch/examples/profile_template b/cddl/usr.sbin/dwatch/examples/profile_template
index 8bb3acfed2fb..c5b357c3f946 100644
--- a/cddl/usr.sbin/dwatch/examples/profile_template
+++ b/cddl/usr.sbin/dwatch/examples/profile_template
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) profile for XXX entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/Makefile b/cddl/usr.sbin/dwatch/libexec/Makefile
index 581556eeebd0..e8df567eb205 100644
--- a/cddl/usr.sbin/dwatch/libexec/Makefile
+++ b/cddl/usr.sbin/dwatch/libexec/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
PACKAGE= dwatch
FILESDIR= ${LIBEXECDIR}/dwatch
@@ -22,6 +21,7 @@ FILES= chmod \
vop_rename \
vop_symlink
+LINKMODE= ${SHAREMODE}
LINKS= ${LIBEXECDIR}/dwatch/chmod ${LIBEXECDIR}/dwatch/fchmodat
LINKS+= ${LIBEXECDIR}/dwatch/chmod ${LIBEXECDIR}/dwatch/lchmod
LINKS+= ${LIBEXECDIR}/dwatch/io ${LIBEXECDIR}/dwatch/io-done
diff --git a/cddl/usr.sbin/dwatch/libexec/chmod b/cddl/usr.sbin/dwatch/libexec/chmod
index d131109a0d66..6ec7140613e6 100644
--- a/cddl/usr.sbin/dwatch/libexec/chmod
+++ b/cddl/usr.sbin/dwatch/libexec/chmod
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for [l]chmod(2), fchmodat(2), or similar entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/errno b/cddl/usr.sbin/dwatch/libexec/errno
index 42fce4ab8faa..d899906a1313 100644
--- a/cddl/usr.sbin/dwatch/libexec/errno
+++ b/cddl/usr.sbin/dwatch/libexec/errno
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for syscall errno logging $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/io b/cddl/usr.sbin/dwatch/libexec/io
index 26c58593ead3..6aafb624c820 100644
--- a/cddl/usr.sbin/dwatch/libexec/io
+++ b/cddl/usr.sbin/dwatch/libexec/io
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for dtrace_io(4) $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/ip b/cddl/usr.sbin/dwatch/libexec/ip
index 8de385f568bf..9032e37dc043 100644
--- a/cddl/usr.sbin/dwatch/libexec/ip
+++ b/cddl/usr.sbin/dwatch/libexec/ip
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for dtrace_ip(4) $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/kill b/cddl/usr.sbin/dwatch/libexec/kill
index c30e951381c3..06960d11f8da 100644
--- a/cddl/usr.sbin/dwatch/libexec/kill
+++ b/cddl/usr.sbin/dwatch/libexec/kill
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for kill(2) [or similar] entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/nanosleep b/cddl/usr.sbin/dwatch/libexec/nanosleep
index acc4cf352af7..d645d8a2a026 100644
--- a/cddl/usr.sbin/dwatch/libexec/nanosleep
+++ b/cddl/usr.sbin/dwatch/libexec/nanosleep
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for nanosleep(2) [or similar] entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/open b/cddl/usr.sbin/dwatch/libexec/open
index 5185a97aca03..849f8865c55d 100644
--- a/cddl/usr.sbin/dwatch/libexec/open
+++ b/cddl/usr.sbin/dwatch/libexec/open
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for open[at](2) [or similar] entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/proc b/cddl/usr.sbin/dwatch/libexec/proc
index 0f67394a84d5..02d4d9d1fb8d 100644
--- a/cddl/usr.sbin/dwatch/libexec/proc
+++ b/cddl/usr.sbin/dwatch/libexec/proc
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for dtrace_proc(4) activity $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/rw b/cddl/usr.sbin/dwatch/libexec/rw
index 32aa58c34f15..6e726c54d8f7 100644
--- a/cddl/usr.sbin/dwatch/libexec/rw
+++ b/cddl/usr.sbin/dwatch/libexec/rw
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for read(2), write(2), or similar entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/sched b/cddl/usr.sbin/dwatch/libexec/sched
index acbe47d92989..2058f199f40a 100644
--- a/cddl/usr.sbin/dwatch/libexec/sched
+++ b/cddl/usr.sbin/dwatch/libexec/sched
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for dtrace_sched(4) $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/sendrecv b/cddl/usr.sbin/dwatch/libexec/sendrecv
index 7227e41b5731..05ac339dfa05 100644
--- a/cddl/usr.sbin/dwatch/libexec/sendrecv
+++ b/cddl/usr.sbin/dwatch/libexec/sendrecv
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for send(2)/recv(2) $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/systop b/cddl/usr.sbin/dwatch/libexec/systop
index b5a29354eee9..7408e41ffffb 100644
--- a/cddl/usr.sbin/dwatch/libexec/systop
+++ b/cddl/usr.sbin/dwatch/libexec/systop
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) profile for top-like syscall $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/tcp b/cddl/usr.sbin/dwatch/libexec/tcp
index 344cdb4ee6e8..a97cde17ef51 100644
--- a/cddl/usr.sbin/dwatch/libexec/tcp
+++ b/cddl/usr.sbin/dwatch/libexec/tcp
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for dtrace_tcp(4) connections $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/udp b/cddl/usr.sbin/dwatch/libexec/udp
index 1f896a71805d..048f0c9a4102 100644
--- a/cddl/usr.sbin/dwatch/libexec/udp
+++ b/cddl/usr.sbin/dwatch/libexec/udp
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for dtrace_udp(4) $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/udplite b/cddl/usr.sbin/dwatch/libexec/udplite
index 093c0857f865..44f55de146fe 100644
--- a/cddl/usr.sbin/dwatch/libexec/udplite
+++ b/cddl/usr.sbin/dwatch/libexec/udplite
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for dtrace_udplite(4) $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/vop_create b/cddl/usr.sbin/dwatch/libexec/vop_create
index 3c544815b758..d36812a4a0d8 100644
--- a/cddl/usr.sbin/dwatch/libexec/vop_create
+++ b/cddl/usr.sbin/dwatch/libexec/vop_create
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for VOP_CREATE(9) [or similar] entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/vop_readdir b/cddl/usr.sbin/dwatch/libexec/vop_readdir
index 8114bae6527a..6a07b98973f4 100644
--- a/cddl/usr.sbin/dwatch/libexec/vop_readdir
+++ b/cddl/usr.sbin/dwatch/libexec/vop_readdir
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for VOP_READDIR(9) [or similar] entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/vop_rename b/cddl/usr.sbin/dwatch/libexec/vop_rename
index a9dbf16e73fa..8eca72505558 100644
--- a/cddl/usr.sbin/dwatch/libexec/vop_rename
+++ b/cddl/usr.sbin/dwatch/libexec/vop_rename
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for VOP_RENAME(9) [or similar] entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/dwatch/libexec/vop_symlink b/cddl/usr.sbin/dwatch/libexec/vop_symlink
index ca75d350af47..dbf7702b2629 100644
--- a/cddl/usr.sbin/dwatch/libexec/vop_symlink
+++ b/cddl/usr.sbin/dwatch/libexec/vop_symlink
@@ -4,7 +4,6 @@
#
# $Title: dwatch(8) module for VOP_SYMLINK(9) [or similar] entry $
# $Copyright: 2014-2018 Devin Teske. All rights reserved. $
-# $FreeBSD$
#
############################################################ DESCRIPTION
#
diff --git a/cddl/usr.sbin/lockstat/Makefile b/cddl/usr.sbin/lockstat/Makefile
index a4bec42df367..e0e3f40ccda9 100644
--- a/cddl/usr.sbin/lockstat/Makefile
+++ b/cddl/usr.sbin/lockstat/Makefile
@@ -1,4 +1,5 @@
-# $FreeBSD$
+
+.include <src.opts.mk>
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/cmd/lockstat
@@ -26,6 +27,11 @@ CFLAGS+= -I${SRCTOP}/sys/cddl/compat/opensolaris \
-I${SRCTOP}/sys
CFLAGS+= -DHAVE_ISSETUGID
+.if ${MK_DTRACE_ASAN} != "no"
+CFLAGS+= -fsanitize=address -fsanitize=undefined
+LDFLAGS+= -fsanitize=address -fsanitize=undefined
+.endif
+
CFLAGS+= -DNEED_ERRLOC -g
#YFLAGS+= -d
diff --git a/cddl/usr.sbin/lockstat/Makefile.depend b/cddl/usr.sbin/lockstat/Makefile.depend
index 04b96e83f1c7..2df10f761ad0 100644
--- a/cddl/usr.sbin/lockstat/Makefile.depend
+++ b/cddl/usr.sbin/lockstat/Makefile.depend
@@ -1,25 +1,16 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
- cddl/lib/libctf \
cddl/lib/libdtrace \
- gnu/lib/csu \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libcxxrt \
lib/libelf \
- lib/libkvm \
lib/libproc \
- lib/libprocstat \
lib/librt \
lib/librtld_db \
- lib/libthr \
- lib/libutil \
- lib/libz \
.include <dirdeps.mk>
diff --git a/cddl/usr.sbin/plockstat/Makefile b/cddl/usr.sbin/plockstat/Makefile
index 22610870c846..e83fae8f305c 100644
--- a/cddl/usr.sbin/plockstat/Makefile
+++ b/cddl/usr.sbin/plockstat/Makefile
@@ -1,4 +1,5 @@
-# $FreeBSD$
+
+.include <src.opts.mk>
.PATH: ${SRCTOP}/cddl/contrib/opensolaris/cmd/plockstat
@@ -26,6 +27,11 @@ CFLAGS+= -I${SRCTOP}/sys/cddl/compat/opensolaris \
-I${SRCTOP}/sys
CFLAGS+= -DHAVE_ISSETUGID
+.if ${MK_DTRACE_ASAN} != "no"
+CFLAGS+= -fsanitize=address -fsanitize=undefined
+LDFLAGS+= -fsanitize=address -fsanitize=undefined
+.endif
+
LIBADD= dtrace proc
.include <bsd.prog.mk>
diff --git a/cddl/usr.sbin/plockstat/Makefile.depend b/cddl/usr.sbin/plockstat/Makefile.depend
index c37ef4acf01e..22b6f0fded18 100644
--- a/cddl/usr.sbin/plockstat/Makefile.depend
+++ b/cddl/usr.sbin/plockstat/Makefile.depend
@@ -1,24 +1,15 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
- cddl/lib/libctf \
cddl/lib/libdtrace \
- gnu/lib/csu \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libcxxrt \
lib/libelf \
- lib/libkvm \
lib/libproc \
- lib/libprocstat \
lib/librtld_db \
- lib/libthr \
- lib/libutil \
- lib/libz \
.include <dirdeps.mk>
diff --git a/cddl/usr.sbin/plockstat/plockstat.1 b/cddl/usr.sbin/plockstat/plockstat.1
index d02c962771b4..264d01b89df2 100644
--- a/cddl/usr.sbin/plockstat/plockstat.1
+++ b/cddl/usr.sbin/plockstat/plockstat.1
@@ -26,8 +26,6 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $FreeBSD$
-.\"
.Dd September 13, 2010
.Dt PLOCKSTAT 1
.Os
diff --git a/cddl/usr.sbin/tests/Makefile b/cddl/usr.sbin/tests/Makefile
index 3b3078f8612a..b8996030aafc 100644
--- a/cddl/usr.sbin/tests/Makefile
+++ b/cddl/usr.sbin/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/tests
KYUAFILE= yes
diff --git a/cddl/usr.sbin/tests/Makefile.depend b/cddl/usr.sbin/tests/Makefile.depend
index f80275d86ab1..11aba52f82cf 100644
--- a/cddl/usr.sbin/tests/Makefile.depend
+++ b/cddl/usr.sbin/tests/Makefile.depend
@@ -1,4 +1,3 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/zdb/Makefile b/cddl/usr.sbin/zdb/Makefile
index efd8c746128f..744db789772c 100644
--- a/cddl/usr.sbin/zdb/Makefile
+++ b/cddl/usr.sbin/zdb/Makefile
@@ -1,10 +1,10 @@
-# $FreeBSD$
ZFSTOP= ${SRCTOP}/sys/contrib/openzfs
.PATH: ${ZFSTOP}/cmd/zdb
.PATH: ${ZFSTOP}/man/man8
+PACKAGE= zfs
PROG= zdb
MAN= zdb.8
INCS= zdb.h
@@ -23,7 +23,7 @@ CFLAGS+= \
-include ${ZFSTOP}/include/os/freebsd/spl/sys/ccompile.h \
-DHAVE_ISSETUGID
-LIBADD= nvpair umem uutil zfs spl avl zutil zpool
+LIBADD= nvpair umem uutil zfs spl avl zutil zpool crypto
CFLAGS.gcc+= -fms-extensions
# Since there are many asserts in this program, it makes no sense to compile
diff --git a/cddl/usr.sbin/zdb/Makefile.depend b/cddl/usr.sbin/zdb/Makefile.depend
index dfb2563fa7d1..d9ae0ff3c82e 100644
--- a/cddl/usr.sbin/zdb/Makefile.depend
+++ b/cddl/usr.sbin/zdb/Makefile.depend
@@ -1,28 +1,20 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libavl \
cddl/lib/libnvpair \
+ cddl/lib/libspl \
cddl/lib/libumem \
cddl/lib/libuutil \
cddl/lib/libzfs \
- cddl/lib/libzfs_core \
cddl/lib/libzpool \
- gnu/lib/csu \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libexpat \
- lib/libgeom \
- lib/libmd \
- lib/libsbuf \
- lib/libthr \
- lib/libutil \
- lib/libz \
- lib/msun \
+ secure/lib/libcrypto \
.include <dirdeps.mk>
diff --git a/cddl/usr.sbin/zfsd/Makefile b/cddl/usr.sbin/zfsd/Makefile
index 88eb9220a8cc..93426c0320af 100644
--- a/cddl/usr.sbin/zfsd/Makefile
+++ b/cddl/usr.sbin/zfsd/Makefile
@@ -1,9 +1,9 @@
-# $FreeBSD$
.include <src.opts.mk>
.include "Makefile.common"
+PACKAGE= zfs
PROG_CXX= zfsd
MAN= zfsd.8
diff --git a/cddl/usr.sbin/zfsd/Makefile.common b/cddl/usr.sbin/zfsd/Makefile.common
index 5e9257d7b37e..1755031fee72 100644
--- a/cddl/usr.sbin/zfsd/Makefile.common
+++ b/cddl/usr.sbin/zfsd/Makefile.common
@@ -1,4 +1,3 @@
-# $FreeBSD$
SRCS= callout.cc \
case_file.cc \
@@ -24,7 +23,7 @@ CFLAGS+= -include ${SRCTOP}/sys/contrib/openzfs/include/os/freebsd/spl/sys/ccomp
CFLAGS+= -I${SRCTOP}/cddl/usr.sbin
# use issetugid(2)
-CFLAGS+= -D_MACHINE_FLOAT_H_ -DHAVE_ISSETUGID
+CFLAGS+= -DHAVE_ISSETUGID
LIBADD+= devdctl zfs util geom bsdxml sbuf nvpair avl uutil zutil
diff --git a/cddl/usr.sbin/zfsd/Makefile.depend b/cddl/usr.sbin/zfsd/Makefile.depend
index 023a4456ec68..4b9049efecdc 100644
--- a/cddl/usr.sbin/zfsd/Makefile.depend
+++ b/cddl/usr.sbin/zfsd/Makefile.depend
@@ -1,14 +1,11 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
cddl/lib/libavl \
cddl/lib/libnvpair \
- cddl/lib/libumem \
cddl/lib/libuutil \
cddl/lib/libzfs \
- cddl/lib/libzfs_core \
- gnu/lib/csu \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
@@ -19,11 +16,8 @@ DIRDEPS = \
lib/libdevdctl \
lib/libexpat \
lib/libgeom \
- lib/libmd \
lib/libsbuf \
- lib/libthr \
lib/libutil \
- lib/libz \
lib/msun \
diff --git a/cddl/usr.sbin/zfsd/callout.cc b/cddl/usr.sbin/zfsd/callout.cc
index 3e5cd5779559..c141e6550f41 100644
--- a/cddl/usr.sbin/zfsd/callout.cc
+++ b/cddl/usr.sbin/zfsd/callout.cc
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/callout.h b/cddl/usr.sbin/zfsd/callout.h
index d6b83bcfe5f5..69a4cf123162 100644
--- a/cddl/usr.sbin/zfsd/callout.h
+++ b/cddl/usr.sbin/zfsd/callout.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/case_file.cc b/cddl/usr.sbin/zfsd/case_file.cc
index 8da711fc10cb..3728913b646b 100644
--- a/cddl/usr.sbin/zfsd/case_file.cc
+++ b/cddl/usr.sbin/zfsd/case_file.cc
@@ -73,9 +73,6 @@
#include "zfsd.h"
#include "zfsd_exception.h"
#include "zpool_list.h"
-
-__FBSDID("$FreeBSD$");
-
/*============================ Namespace Control =============================*/
using std::hex;
using std::ifstream;
@@ -116,6 +113,26 @@ CaseFile::Find(Guid poolGUID, Guid vdevGUID)
return (NULL);
}
+void
+CaseFile::Find(Guid poolGUID, Guid vdevGUID, CaseFileList &cases)
+{
+ for (CaseFileList::iterator curCase = s_activeCases.begin();
+ curCase != s_activeCases.end(); curCase++) {
+ if (((*curCase)->PoolGUID() != poolGUID &&
+ Guid::InvalidGuid() != poolGUID) ||
+ (*curCase)->VdevGUID() != vdevGUID)
+ continue;
+
+ /*
+ * We can have multiple cases for spare vdevs
+ */
+ cases.push_back(*curCase);
+ if (!(*curCase)->IsSpare()) {
+ return;
+ }
+ }
+}
+
CaseFile *
CaseFile::Find(const string &physPath)
{
@@ -217,6 +234,12 @@ CaseFile::PurgeAll()
}
+int
+CaseFile::IsSpare()
+{
+ return (m_is_spare);
+}
+
//- CaseFile Public Methods ----------------------------------------------------
bool
CaseFile::RefreshVdevState()
@@ -240,6 +263,7 @@ CaseFile::ReEvaluate(const string &devPath, const string &physPath, Vdev *vdev)
{
ZpoolList zpl(ZpoolList::ZpoolByGUID, &m_poolGUID);
zpool_handle_t *pool(zpl.empty() ? NULL : zpl.front());
+ int flags = ZFS_ONLINE_CHECKREMOVE | ZFS_ONLINE_UNSPARE;
if (pool == NULL || !RefreshVdevState()) {
/*
@@ -280,9 +304,10 @@ CaseFile::ReEvaluate(const string &devPath, const string &physPath, Vdev *vdev)
|| vdev->PoolGUID() == Guid::InvalidGuid())
&& vdev->GUID() == m_vdevGUID) {
+ if (IsSpare())
+ flags |= ZFS_ONLINE_SPARE;
if (zpool_vdev_online(pool, vdev->GUIDString().c_str(),
- ZFS_ONLINE_CHECKREMOVE | ZFS_ONLINE_UNSPARE,
- &m_vdevState) != 0) {
+ flags, &m_vdevState) != 0) {
syslog(LOG_ERR,
"Failed to online vdev(%s/%s:%s): %s: %s\n",
zpool_get_name(pool), vdev->GUIDString().c_str(),
@@ -360,7 +385,7 @@ CaseFile::ReEvaluate(const ZfsEvent &event)
{
bool consumed(false);
- if (event.Value("type") == "misc.fs.zfs.vdev_remove") {
+ if (event.Value("type") == "sysevent.fs.zfs.vdev_remove") {
/*
* The Vdev we represent has been removed from the
* configuration. This case is no longer of value.
@@ -368,12 +393,12 @@ CaseFile::ReEvaluate(const ZfsEvent &event)
Close();
return (/*consumed*/true);
- } else if (event.Value("type") == "misc.fs.zfs.pool_destroy") {
+ } else if (event.Value("type") == "sysevent.fs.zfs.pool_destroy") {
/* This Pool has been destroyed. Discard the case */
Close();
return (/*consumed*/true);
- } else if (event.Value("type") == "misc.fs.zfs.config_sync") {
+ } else if (event.Value("type") == "sysevent.fs.zfs.config_sync") {
RefreshVdevState();
if (VdevState() < VDEV_STATE_HEALTHY)
consumed = ActivateSpare();
@@ -490,8 +515,7 @@ bool
CaseFile::ActivateSpare() {
nvlist_t *config, *nvroot, *parent_config;
nvlist_t **spares;
- char *devPath, *vdev_type;
- const char *poolname;
+ const char *devPath, *poolname, *vdev_type;
u_int nspares, i;
int error;
@@ -518,7 +542,7 @@ CaseFile::ActivateSpare() {
parent_config = find_parent(config, nvroot, m_vdevGUID);
if (parent_config != NULL) {
- char *parent_type;
+ const char *parent_type;
/*
* Don't activate spares for members of a "replacing" vdev.
@@ -791,7 +815,8 @@ CaseFile::CaseFile(const Vdev &vdev)
: m_poolGUID(vdev.PoolGUID()),
m_vdevGUID(vdev.GUID()),
m_vdevState(vdev.State()),
- m_vdevPhysPath(vdev.PhysicalPath())
+ m_vdevPhysPath(vdev.PhysicalPath()),
+ m_is_spare(vdev.IsSpare())
{
stringstream guidString;
diff --git a/cddl/usr.sbin/zfsd/case_file.h b/cddl/usr.sbin/zfsd/case_file.h
index b4dc2dee5d96..e6c7010af234 100644
--- a/cddl/usr.sbin/zfsd/case_file.h
+++ b/cddl/usr.sbin/zfsd/case_file.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
@@ -99,6 +97,19 @@ public:
static CaseFile *Find(DevdCtl::Guid poolGUID, DevdCtl::Guid vdevGUID);
/**
+ * \brief Find multiple CaseFile objects by a vdev's pool/vdev
+ * GUID tuple (special case for spare vdevs)
+ *
+ * \param poolGUID Pool GUID for the vdev of the CaseFile to find.
+ * If InvalidGuid, then only match the vdev GUID
+ * instead of both pool and vdev GUIDs.
+ * \param vdevGUID Vdev GUID for the vdev of the CaseFile to find.
+ * \param caseList List of cases associated with the vdev.
+ */
+ static void Find(DevdCtl::Guid poolGUID, DevdCtl::Guid vdevGUID,
+ CaseFileList &caseList);
+
+ /**
* \brief Find a CaseFile object by a vdev's current/last known
* physical path.
*
@@ -219,6 +230,11 @@ public:
*/
bool ShouldFault() const;
+ /**
+ * \brief If this vdev is spare
+ */
+ int IsSpare();
+
protected:
enum {
/**
@@ -384,6 +400,7 @@ protected:
string m_poolGUIDString;
string m_vdevGUIDString;
string m_vdevPhysPath;
+ int m_is_spare;
/**
* \brief Callout activated when a grace period
diff --git a/cddl/usr.sbin/zfsd/tests/Makefile b/cddl/usr.sbin/zfsd/tests/Makefile
index 1b776b217776..a4613e4cb1e8 100644
--- a/cddl/usr.sbin/zfsd/tests/Makefile
+++ b/cddl/usr.sbin/zfsd/tests/Makefile
@@ -1,4 +1,3 @@
-# $FreeBSD$
.include "${.CURDIR}/../Makefile.common"
.PATH: ${.CURDIR:H}
diff --git a/cddl/usr.sbin/zfsd/tests/libmocks.c b/cddl/usr.sbin/zfsd/tests/libmocks.c
index e3c90a46920f..64eb02b1d480 100644
--- a/cddl/usr.sbin/zfsd/tests/libmocks.c
+++ b/cddl/usr.sbin/zfsd/tests/libmocks.c
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Alan Somers (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
#include <stdio.h>
diff --git a/cddl/usr.sbin/zfsd/tests/libmocks.h b/cddl/usr.sbin/zfsd/tests/libmocks.h
index 130f4389f70a..ffa2f0673e1d 100644
--- a/cddl/usr.sbin/zfsd/tests/libmocks.h
+++ b/cddl/usr.sbin/zfsd/tests/libmocks.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Alan Somers (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
#ifndef _LIBMOCKS_H_
diff --git a/cddl/usr.sbin/zfsd/tests/zfsd_unittest.cc b/cddl/usr.sbin/zfsd/tests/zfsd_unittest.cc
index e2833170f9ac..caeb077a3de8 100644
--- a/cddl/usr.sbin/zfsd/tests/zfsd_unittest.cc
+++ b/cddl/usr.sbin/zfsd/tests/zfsd_unittest.cc
@@ -62,9 +62,6 @@
#include <zfsd/zpool_list.h>
#include "libmocks.h"
-
-__FBSDID("$FreeBSD$");
-
/*================================== Macros ==================================*/
#define NUM_ELEMENTS(x) (sizeof(x) / sizeof(*x))
@@ -400,7 +397,7 @@ TEST_F(ZfsEventTest, ProcessPoolEventGetsCalled)
{
string evString("!system=ZFS "
"subsystem=ZFS "
- "type=misc.fs.zfs.vdev_remove "
+ "type=sysevent.fs.zfs.vdev_remove "
"pool_name=foo "
"pool_guid=9756779504028057996 "
"vdev_guid=1631193447431603339 "
@@ -515,7 +512,7 @@ TEST_F(CaseFileTest, PoolDestroy)
"pool_guid=456 "
"subsystem=ZFS "
"timestamp=1348867914 "
- "type=misc.fs.zfs.pool_destroy ");
+ "type=sysevent.fs.zfs.pool_destroy ");
m_event = Event::CreateEvent(*m_eventFactory, evString);
ZfsEvent *zfs_event = static_cast<ZfsEvent*>(m_event);
EXPECT_CALL(*m_caseFile, Close());
@@ -685,7 +682,7 @@ string ReEvaluateByGuidTest::s_evString(
"pool_name=foo "
"subsystem=ZFS "
"timestamp=1360620391 "
- "type=misc.fs.zfs.config_sync");
+ "type=sysevent.fs.zfs.config_sync");
/*
@@ -769,3 +766,40 @@ TEST_F(ReEvaluateByGuidTest, ReEvaluateByGuid_five)
delete CaseFile4;
delete CaseFile5;
}
+
+/*
+ * Test VdevIterator
+ */
+class VdevIteratorTest : public ::testing::Test
+{
+};
+
+bool VdevIteratorTestCB(Vdev &vdev, void *cbArg) {
+ return (false);
+}
+
+/*
+ * VdevIterator::Next should not crash when run on a pool that has a previously
+ * removed vdev. Regression for
+ * https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=273663
+ */
+TEST_F(VdevIteratorTest, VdevRemoval)
+{
+ nvlist_t* poolConfig, *rootVdev;
+
+ ASSERT_EQ(0, nvlist_alloc(&rootVdev, NV_UNIQUE_NAME, 0));
+ ASSERT_EQ(0, nvlist_add_uint64(rootVdev, ZPOOL_CONFIG_GUID, 0x5678));
+ /*
+ * Note: pools with previously-removed top-level VDEVs will contain a
+ * TLV in their labels that has 0 children.
+ */
+ ASSERT_EQ(0, nvlist_add_nvlist_array(rootVdev, ZPOOL_CONFIG_CHILDREN,
+ NULL, 0));
+ ASSERT_EQ(0, nvlist_alloc(&poolConfig, NV_UNIQUE_NAME, 0));
+ ASSERT_EQ(0, nvlist_add_uint64(poolConfig,
+ ZPOOL_CONFIG_POOL_GUID, 0x1234));
+ ASSERT_EQ(0, nvlist_add_nvlist(poolConfig, ZPOOL_CONFIG_VDEV_TREE,
+ rootVdev));
+
+ VdevIterator(poolConfig).Each(VdevIteratorTestCB, NULL);
+}
diff --git a/cddl/usr.sbin/zfsd/tests/zfsd_unittest.supp b/cddl/usr.sbin/zfsd/tests/zfsd_unittest.supp
index 138ef6907e62..377ca1e10746 100644
--- a/cddl/usr.sbin/zfsd/tests/zfsd_unittest.supp
+++ b/cddl/usr.sbin/zfsd/tests/zfsd_unittest.supp
@@ -29,7 +29,6 @@
#
# Authors: Alan Somers (Spectra Logic Corporation)
#
-# $FreeBSD$
# This is a valgrind suppression file used for running zfsd_unittest with
diff --git a/cddl/usr.sbin/zfsd/vdev.cc b/cddl/usr.sbin/zfsd/vdev.cc
index 508af8cda925..1a37340fb76e 100644
--- a/cddl/usr.sbin/zfsd/vdev.cc
+++ b/cddl/usr.sbin/zfsd/vdev.cc
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
@@ -65,8 +63,6 @@
#include "zfsd.h"
#include "zfsd_exception.h"
#include "zpool_list.h"
-
-__FBSDID("$FreeBSD$");
/*============================ Namespace Control =============================*/
using std::string;
using std::stringstream;
@@ -336,7 +332,7 @@ Vdev::Name(zpool_handle_t *zhp, bool verbose) const
string
Vdev::Path() const
{
- char *path(NULL);
+ const char *path(NULL);
if ((m_config != NULL)
&& (nvlist_lookup_string(m_config, ZPOOL_CONFIG_PATH, &path) == 0))
@@ -348,7 +344,7 @@ Vdev::Path() const
string
Vdev::PhysicalPath() const
{
- char *path(NULL);
+ const char *path(NULL);
if ((m_config != NULL) && (nvlist_lookup_string(m_config,
ZPOOL_CONFIG_PHYS_PATH, &path) == 0))
diff --git a/cddl/usr.sbin/zfsd/vdev.h b/cddl/usr.sbin/zfsd/vdev.h
index 322efc8f4e53..ace5d5a009fa 100644
--- a/cddl/usr.sbin/zfsd/vdev.h
+++ b/cddl/usr.sbin/zfsd/vdev.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/vdev_iterator.cc b/cddl/usr.sbin/zfsd/vdev_iterator.cc
index b5a4f22c1c60..e9283108ed3c 100644
--- a/cddl/usr.sbin/zfsd/vdev_iterator.cc
+++ b/cddl/usr.sbin/zfsd/vdev_iterator.cc
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
@@ -78,8 +76,10 @@ VdevIterator::Reset()
{
nvlist_t *rootVdev;
nvlist **cache_child;
+ nvlist **spare_child;
int result;
uint_t cache_children;
+ uint_t spare_children;
result = nvlist_lookup_nvlist(m_poolConfig,
ZPOOL_CONFIG_VDEV_TREE,
@@ -95,6 +95,13 @@ VdevIterator::Reset()
if (result == 0)
for (uint_t c = 0; c < cache_children; c++)
m_vdevQueue.push_back(cache_child[c]);
+ result = nvlist_lookup_nvlist_array(rootVdev,
+ ZPOOL_CONFIG_SPARES,
+ &spare_child,
+ &spare_children);
+ if (result == 0)
+ for (uint_t c = 0; c < spare_children; c++)
+ m_vdevQueue.push_back(spare_child[c]);
}
nvlist_t *
@@ -102,10 +109,7 @@ VdevIterator::Next()
{
nvlist_t *vdevConfig;
- if (m_vdevQueue.empty())
- return (NULL);
-
- for (;;) {
+ for (vdevConfig = NULL; !m_vdevQueue.empty();) {
nvlist_t **vdevChildren;
int result;
u_int numChildren;
diff --git a/cddl/usr.sbin/zfsd/vdev_iterator.h b/cddl/usr.sbin/zfsd/vdev_iterator.h
index 435582ec1f84..439f987ba6e1 100644
--- a/cddl/usr.sbin/zfsd/vdev_iterator.h
+++ b/cddl/usr.sbin/zfsd/vdev_iterator.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/zfsd.8 b/cddl/usr.sbin/zfsd/zfsd.8
index ce7550b891a3..75a3333e6f9e 100644
--- a/cddl/usr.sbin/zfsd/zfsd.8
+++ b/cddl/usr.sbin/zfsd/zfsd.8
@@ -23,8 +23,6 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $FreeBSD$
-.\"
.Dd April 18, 2020
.Dt ZFSD 8
.Os
diff --git a/cddl/usr.sbin/zfsd/zfsd.cc b/cddl/usr.sbin/zfsd/zfsd.cc
index 876cca836e9e..210cc4b85a44 100644
--- a/cddl/usr.sbin/zfsd/zfsd.cc
+++ b/cddl/usr.sbin/zfsd/zfsd.cc
@@ -74,9 +74,6 @@
#include "zfsd.h"
#include "zfsd_exception.h"
#include "zpool_list.h"
-
-__FBSDID("$FreeBSD$");
-
/*================================== Macros ==================================*/
#define NUM_ELEMENTS(x) (sizeof(x) / sizeof(*x))
@@ -248,7 +245,7 @@ ZfsDaemon::BuildCaseFiles()
snprintf(evString, 160, "!system=ZFS subsystem=ZFS "
- "type=misc.fs.zfs.config_sync sub_type=synthesized "
+ "type=sysevent.fs.zfs.config_sync sub_type=synthesized "
"pool_name=%s pool_guid=%" PRIu64 "\n", poolname, poolGUID);
event = Event::CreateEvent(GetFactory(), string(evString));
if (event != NULL) {
@@ -276,7 +273,7 @@ ZfsDaemon::RescanSystem()
result = geom_gettree(&mesh);
if (result != 0) {
syslog(LOG_ERR, "ZfsDaemon::RescanSystem: "
- "geom_gettree faild with error %d\n", result);
+ "geom_gettree failed with error %d\n", result);
return;
}
diff --git a/cddl/usr.sbin/zfsd/zfsd.h b/cddl/usr.sbin/zfsd/zfsd.h
index 7b4019c7ae10..8c7c63a7c9c4 100644
--- a/cddl/usr.sbin/zfsd/zfsd.h
+++ b/cddl/usr.sbin/zfsd/zfsd.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/zfsd_event.cc b/cddl/usr.sbin/zfsd/zfsd_event.cc
index 688e7c0354a2..7a19b95abeed 100644
--- a/cddl/usr.sbin/zfsd/zfsd_event.cc
+++ b/cddl/usr.sbin/zfsd/zfsd_event.cc
@@ -68,8 +68,6 @@
#include "zfsd.h"
#include "zfsd_exception.h"
#include "zpool_list.h"
-
-__FBSDID("$FreeBSD$");
/*============================ Namespace Control =============================*/
using DevdCtl::Event;
using DevdCtl::Guid;
@@ -229,7 +227,9 @@ bool
GeomEvent::OnlineByLabel(const string &devPath, const string& physPath,
nvlist_t *devConfig)
{
+ bool ret = false;
try {
+ CaseFileList case_list;
/*
* A device with ZFS label information has been
* inserted. If it matches a device for which we
@@ -238,10 +238,12 @@ GeomEvent::OnlineByLabel(const string &devPath, const string& physPath,
syslog(LOG_INFO, "Interrogating VDEV label for %s\n",
devPath.c_str());
Vdev vdev(devConfig);
- CaseFile *caseFile(CaseFile::Find(vdev.PoolGUID(),
- vdev.GUID()));
- if (caseFile != NULL)
- return (caseFile->ReEvaluate(devPath, physPath, &vdev));
+ CaseFile::Find(vdev.PoolGUID(),vdev.GUID(), case_list);
+ for (CaseFileList::iterator curr = case_list.begin();
+ curr != case_list.end(); curr++) {
+ ret |= (*curr)->ReEvaluate(devPath, physPath, &vdev);
+ }
+ return (ret);
} catch (ZfsdException &exp) {
string context("GeomEvent::OnlineByLabel: " + devPath + ": ");
@@ -249,7 +251,7 @@ GeomEvent::OnlineByLabel(const string &devPath, const string& physPath,
exp.GetString().insert(0, context);
exp.Log();
}
- return (false);
+ return (ret);
}
@@ -281,7 +283,7 @@ ZfsEvent::Process() const
}
/* On config syncs, replay any queued events first. */
- if (Value("type").find("misc.fs.zfs.config_sync") == 0) {
+ if (Value("type").find("sysevent.fs.zfs.config_sync") == 0) {
/*
* Even if saved events are unconsumed the second time
* around, drop them. Any events that still can't be
@@ -292,7 +294,7 @@ ZfsEvent::Process() const
CaseFile::ReEvaluateByGuid(PoolGUID(), *this);
}
- if (Value("type").find("misc.fs.zfs.") == 0) {
+ if (Value("type").find("sysevent.fs.zfs.") == 0) {
/* Configuration changes, resilver events, etc. */
ProcessPoolEvent();
return (false);
@@ -405,7 +407,7 @@ ZfsEvent::ProcessPoolEvent() const
bool degradedDevice(false);
/* The pool is destroyed. Discard any open cases */
- if (Value("type") == "misc.fs.zfs.pool_destroy") {
+ if (Value("type") == "sysevent.fs.zfs.pool_destroy") {
Log(LOG_INFO);
CaseFile::ReEvaluateByGuid(PoolGUID(), *this);
return;
@@ -420,7 +422,7 @@ ZfsEvent::ProcessPoolEvent() const
Log(LOG_INFO);
caseFile->ReEvaluate(*this);
}
- else if (Value("type") == "misc.fs.zfs.resilver_finish")
+ else if (Value("type") == "sysevent.fs.zfs.resilver_finish")
{
/*
* It's possible to get a resilver_finish event with no
@@ -431,7 +433,7 @@ ZfsEvent::ProcessPoolEvent() const
CleanupSpares();
}
- if (Value("type") == "misc.fs.zfs.vdev_remove"
+ if (Value("type") == "sysevent.fs.zfs.vdev_remove"
&& degradedDevice == false) {
/* See if any other cases can make use of this device. */
diff --git a/cddl/usr.sbin/zfsd/zfsd_event.h b/cddl/usr.sbin/zfsd/zfsd_event.h
index fd3f9f7c5200..6398cb3c0c13 100644
--- a/cddl/usr.sbin/zfsd/zfsd_event.h
+++ b/cddl/usr.sbin/zfsd/zfsd_event.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/zfsd_exception.cc b/cddl/usr.sbin/zfsd/zfsd_exception.cc
index 7ebb74ca8c6a..d5b3cab24f02 100644
--- a/cddl/usr.sbin/zfsd/zfsd_exception.cc
+++ b/cddl/usr.sbin/zfsd/zfsd_exception.cc
@@ -52,8 +52,6 @@
#include "vdev.h"
#include "zfsd_exception.h"
-
-__FBSDID("$FreeBSD$");
/*============================ Namespace Control =============================*/
using std::endl;
using std::string;
@@ -106,7 +104,7 @@ ZfsdException::Log() const
output << "Pool ";
- char *poolName;
+ const char *poolName;
if (nvlist_lookup_string(m_poolConfig, ZPOOL_CONFIG_POOL_NAME,
&poolName) == 0)
output << poolName;
diff --git a/cddl/usr.sbin/zfsd/zfsd_exception.h b/cddl/usr.sbin/zfsd/zfsd_exception.h
index 5170b2d0dbb1..6cb182e7223b 100644
--- a/cddl/usr.sbin/zfsd/zfsd_exception.h
+++ b/cddl/usr.sbin/zfsd/zfsd_exception.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/zfsd_main.cc b/cddl/usr.sbin/zfsd/zfsd_main.cc
index f090631e21f2..cc9ce6044384 100644
--- a/cddl/usr.sbin/zfsd/zfsd_main.cc
+++ b/cddl/usr.sbin/zfsd/zfsd_main.cc
@@ -55,9 +55,6 @@
#include "vdev_iterator.h"
#include "zfsd.h"
-
-__FBSDID("$FreeBSD$");
-
/*=============================== Program Main ===============================*/
static void
usage()
diff --git a/cddl/usr.sbin/zfsd/zpool_list.cc b/cddl/usr.sbin/zfsd/zpool_list.cc
index 82c35736df13..65612ca0591c 100644
--- a/cddl/usr.sbin/zfsd/zpool_list.cc
+++ b/cddl/usr.sbin/zfsd/zpool_list.cc
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
diff --git a/cddl/usr.sbin/zfsd/zpool_list.h b/cddl/usr.sbin/zfsd/zpool_list.h
index 6ee30892aedd..3043d35731eb 100644
--- a/cddl/usr.sbin/zfsd/zpool_list.h
+++ b/cddl/usr.sbin/zfsd/zpool_list.h
@@ -28,8 +28,6 @@
* POSSIBILITY OF SUCH DAMAGES.
*
* Authors: Justin T. Gibbs (Spectra Logic Corporation)
- *
- * $FreeBSD$
*/
/**
@@ -95,7 +93,7 @@ public:
static PoolFilter_t ZpoolByName;
/**
- * \brief ZpoolList contructor
+ * \brief ZpoolList constructor
*
* \param filter The filter function to use when constructing
* the ZpoolList. This may be one of the static
diff --git a/cddl/usr.sbin/zhack/Makefile b/cddl/usr.sbin/zhack/Makefile
index ffac0785d18d..b2fa0e98b7e5 100644
--- a/cddl/usr.sbin/zhack/Makefile
+++ b/cddl/usr.sbin/zhack/Makefile
@@ -1,7 +1,7 @@
-# $FreeBSD$
.PATH: ${SRCTOP}/sys/contrib/openzfs/cmd
+PACKAGE= zfs
PROG= zhack
MAN=
diff --git a/cddl/usr.sbin/zhack/Makefile.depend b/cddl/usr.sbin/zhack/Makefile.depend
index dfb2563fa7d1..6e162364b929 100644
--- a/cddl/usr.sbin/zhack/Makefile.depend
+++ b/cddl/usr.sbin/zhack/Makefile.depend
@@ -1,28 +1,16 @@
-# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
- cddl/lib/libavl \
cddl/lib/libnvpair \
- cddl/lib/libumem \
- cddl/lib/libuutil \
+ cddl/lib/libspl \
cddl/lib/libzfs \
- cddl/lib/libzfs_core \
cddl/lib/libzpool \
- gnu/lib/csu \
+ cddl/lib/libzutil \
include \
include/xlocale \
lib/${CSU_DIR} \
lib/libc \
lib/libcompiler_rt \
- lib/libexpat \
- lib/libgeom \
- lib/libmd \
- lib/libsbuf \
- lib/libthr \
- lib/libutil \
- lib/libz \
- lib/msun \
.include <dirdeps.mk>