summaryrefslogtreecommitdiffstats
path: root/cddl
diff options
context:
space:
mode:
Diffstat (limited to 'cddl')
-rw-r--r--cddl/contrib/opensolaris/cmd/lockstat/lockstat.18
-rw-r--r--cddl/contrib/opensolaris/cmd/lockstat/lockstat.c42
-rw-r--r--cddl/contrib/opensolaris/cmd/zdb/zdb.c14
-rw-r--r--cddl/contrib/opensolaris/cmd/zfs/zfs_main.c41
-rw-r--r--cddl/contrib/opensolaris/cmd/ztest/ztest.c19
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h18
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c50
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.h4
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c20
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_pragma.c8
-rw-r--r--cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c5
-rw-r--r--cddl/lib/drti/Makefile.depend1
-rw-r--r--cddl/lib/libavl/Makefile.depend1
-rw-r--r--cddl/lib/libctf/Makefile.depend1
-rw-r--r--cddl/lib/libdtrace/Makefile.depend1
-rw-r--r--cddl/lib/libnvpair/Makefile.depend1
-rw-r--r--cddl/lib/libumem/Makefile.depend1
-rw-r--r--cddl/lib/libuutil/Makefile.depend1
-rw-r--r--cddl/lib/libzfs/Makefile.depend1
-rw-r--r--cddl/lib/libzfs_core/Makefile.depend1
-rw-r--r--cddl/lib/libzpool/Makefile.depend1
-rw-r--r--cddl/sbin/zfs/Makefile.depend1
-rw-r--r--cddl/sbin/zpool/Makefile.depend1
-rw-r--r--cddl/usr.bin/ctfconvert/Makefile.depend1
-rw-r--r--cddl/usr.bin/ctfdump/Makefile.depend1
-rw-r--r--cddl/usr.bin/ctfmerge/Makefile.depend1
-rw-r--r--cddl/usr.bin/sgsmsg/Makefile.depend1
-rw-r--r--cddl/usr.bin/zinject/Makefile.depend1
-rw-r--r--cddl/usr.bin/zstreamdump/Makefile.depend1
-rw-r--r--cddl/usr.bin/ztest/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtrace/Makefile.depend1
-rw-r--r--cddl/usr.sbin/dtruss/Makefile.depend1
-rw-r--r--cddl/usr.sbin/lockstat/Makefile.depend1
-rw-r--r--cddl/usr.sbin/zdb/Makefile.depend1
-rw-r--r--cddl/usr.sbin/zhack/Makefile.depend1
35 files changed, 197 insertions, 56 deletions
diff --git a/cddl/contrib/opensolaris/cmd/lockstat/lockstat.1 b/cddl/contrib/opensolaris/cmd/lockstat/lockstat.1
index a725c8b..1aa73cc 100644
--- a/cddl/contrib/opensolaris/cmd/lockstat/lockstat.1
+++ b/cddl/contrib/opensolaris/cmd/lockstat/lockstat.1
@@ -21,7 +21,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd October 8, 2014
+.Dd May 24, 2015
.Dt LOCKSTAT 1
.Os
.Sh NAME
@@ -29,7 +29,7 @@
.Nd report kernel lock and profiling statistics
.Sh SYNOPSIS
.Nm
-.Op Fl ACEHI
+.Op Fl ACEHIV
.Op Fl e Ar event-list
.Op Fl i Ar rate
.Op Fl b | t | h | s Ar depth
@@ -90,6 +90,10 @@ to
is restricted to super-user by default.
.Sh OPTIONS
The following options are supported:
+.Bl -tag -width indent
+.It Fl V
+Print the D program used to gather the requested data.
+.El
.Ss Event Selection
If no event selection options are specified, the default is
.Fl C .
diff --git a/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c b/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c
index ad512c1..5c71160 100644
--- a/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c
+++ b/cddl/contrib/opensolaris/cmd/lockstat/lockstat.c
@@ -157,14 +157,22 @@ static ls_event_info_t g_event_info[LS_MAX_EVENTS] = {
"lockstat:::rw-block", "arg2 != 0 && arg3 == 1" },
{ 'C', "Lock", "R/W reader blocked by write wanted", "nsec",
"lockstat:::rw-block", "arg2 != 0 && arg3 == 0 && arg4" },
- { 'C', "Lock", "Unknown event (type 8)", "units" },
- { 'C', "Lock", "Unknown event (type 9)", "units" },
- { 'C', "Lock", "Unknown event (type 10)", "units" },
- { 'C', "Lock", "Unknown event (type 11)", "units" },
- { 'C', "Lock", "Unknown event (type 12)", "units" },
- { 'C', "Lock", "Unknown event (type 13)", "units" },
- { 'C', "Lock", "Unknown event (type 14)", "units" },
- { 'C', "Lock", "Unknown event (type 15)", "units" },
+ { 'C', "Lock", "R/W writer spin on writer", "nsec",
+ "lockstat:::rw-spin", "arg2 == 0 && arg3 == 1" },
+ { 'C', "Lock", "R/W writer spin on readers", "nsec",
+ "lockstat:::rw-spin", "arg2 == 0 && arg3 == 0 && arg4" },
+ { 'C', "Lock", "R/W reader spin on writer", "nsec",
+ "lockstat:::rw-spin", "arg2 != 0 && arg3 == 1" },
+ { 'C', "Lock", "R/W reader spin on write wanted", "nsec",
+ "lockstat:::rw-spin", "arg2 != 0 && arg3 == 0 && arg4" },
+ { 'C', "Lock", "SX exclusive block", "nsec",
+ "lockstat:::sx-block", "arg2 == 0" },
+ { 'C', "Lock", "SX shared block", "nsec",
+ "lockstat:::sx-block", "arg2 != 0" },
+ { 'C', "Lock", "SX exclusive spin", "nsec",
+ "lockstat:::sx-spin", "arg2 == 0" },
+ { 'C', "Lock", "SX shared spin", "nsec",
+ "lockstat:::sx-spin", "arg2 != 0" },
{ 'C', "Lock", "Unknown event (type 16)", "units" },
{ 'C', "Lock", "Unknown event (type 17)", "units" },
{ 'C', "Lock", "Unknown event (type 18)", "units" },
@@ -188,13 +196,17 @@ static ls_event_info_t g_event_info[LS_MAX_EVENTS] = {
"lockstat:::spin-release", NULL,
"lockstat:::spin-acquire" },
{ 'H', "Lock", "R/W writer hold", "nsec",
- "lockstat:::rw-release", "arg1 == 0",
- "lockstat:::rw-acquire" },
+ "lockstat::rw_wunlock:rw-release", NULL,
+ "lockstat::rw_wlock:rw-acquire" },
{ 'H', "Lock", "R/W reader hold", "nsec",
- "lockstat:::rw-release", "arg1 != 0",
- "lockstat:::rw-acquire" },
- { 'H', "Lock", "Unknown event (type 36)", "units" },
- { 'H', "Lock", "Unknown event (type 37)", "units" },
+ "lockstat::rw_runlock:rw-release", NULL,
+ "lockstat::rw_rlock:rw-acquire" },
+ { 'H', "Lock", "SX shared hold", "nsec",
+ "lockstat::sx_sunlock:sx-release", NULL,
+ "lockstat::sx_slock:sx-acquire" },
+ { 'H', "Lock", "SX exclusive hold", "nsec",
+ "lockstat::sx_xunlock:sx-release", NULL,
+ "lockstat::sx_xlock:sx-acquire" },
{ 'H', "Lock", "Unknown event (type 38)", "units" },
{ 'H', "Lock", "Unknown event (type 39)", "units" },
{ 'H', "Lock", "Unknown event (type 40)", "units" },
@@ -299,6 +311,8 @@ usage(void)
{
(void) fprintf(stderr,
"Usage: lockstat [options] command [args]\n"
+ "\nGeneral options:\n\n"
+ " -V print the corresponding D program\n"
"\nEvent selection options:\n\n"
" -C watch contention events [on by default]\n"
" -E watch error events [off by default]\n"
diff --git a/cddl/contrib/opensolaris/cmd/zdb/zdb.c b/cddl/contrib/opensolaris/cmd/zdb/zdb.c
index 34912cd..45b6dbd 100644
--- a/cddl/contrib/opensolaris/cmd/zdb/zdb.c
+++ b/cddl/contrib/opensolaris/cmd/zdb/zdb.c
@@ -90,10 +90,10 @@ uint8_t dump_opt[256];
typedef void object_viewer_t(objset_t *, uint64_t, void *data, size_t size);
extern void dump_intent_log(zilog_t *);
-uint64_t *zopt_object = NULL;
-int zopt_objects = 0;
-libzfs_handle_t *g_zfs;
-uint64_t max_inflight = 1000;
+static uint64_t *zopt_object = NULL;
+static int zopt_objects = 0;
+static libzfs_handle_t *g_zfs;
+static uint64_t max_inflight = 1000;
/*
* These libumem hooks provide a reasonable set of defaults for the allocator's
@@ -1488,16 +1488,14 @@ dump_deadlist(dsl_deadlist_t *dl)
dle = AVL_NEXT(&dl->dl_tree, dle)) {
if (dump_opt['d'] >= 5) {
char buf[128];
- (void) snprintf(buf, sizeof (buf), "mintxg %llu -> ",
- (longlong_t)dle->dle_mintxg,
+ (void) snprintf(buf, sizeof (buf), "mintxg %llu -> "
+ "obj %llu", (longlong_t)dle->dle_mintxg,
(longlong_t)dle->dle_bpobj.bpo_object);
-
dump_bpobj(&dle->dle_bpobj, buf, 0);
} else {
(void) printf("mintxg %llu -> obj %llu\n",
(longlong_t)dle->dle_mintxg,
(longlong_t)dle->dle_bpobj.bpo_object);
-
}
}
}
diff --git a/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c b/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c
index d7c702b..389b248 100644
--- a/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c
+++ b/cddl/contrib/opensolaris/cmd/zfs/zfs_main.c
@@ -593,6 +593,17 @@ finish_progress(char *done)
}
/*
+ * Check if the dataset is mountable and should be automatically mounted.
+ */
+static boolean_t
+should_auto_mount(zfs_handle_t *zhp)
+{
+ if (!zfs_prop_valid_for_type(ZFS_PROP_CANMOUNT, zfs_get_type(zhp)))
+ return (B_FALSE);
+ return (zfs_prop_get_int(zhp, ZFS_PROP_CANMOUNT) == ZFS_CANMOUNT_ON);
+}
+
+/*
* zfs clone [-p] [-o prop=value] ... <snap> <fs | vol>
*
* Given an existing dataset, create a writable copy whose initial contents
@@ -677,9 +688,22 @@ zfs_do_clone(int argc, char **argv)
clone = zfs_open(g_zfs, argv[1], ZFS_TYPE_DATASET);
if (clone != NULL) {
- if (zfs_get_type(clone) != ZFS_TYPE_VOLUME)
- if ((ret = zfs_mount(clone, NULL, 0)) == 0)
- ret = zfs_share(clone);
+ /*
+ * If the user doesn't want the dataset
+ * automatically mounted, then skip the mount/share
+ * step.
+ */
+ if (should_auto_mount(clone)) {
+ if ((ret = zfs_mount(clone, NULL, 0)) != 0) {
+ (void) fprintf(stderr, gettext("clone "
+ "successfully created, "
+ "but not mounted\n"));
+ } else if ((ret = zfs_share(clone)) != 0) {
+ (void) fprintf(stderr, gettext("clone "
+ "successfully created, "
+ "but not shared\n"));
+ }
+ }
zfs_close(clone);
}
}
@@ -728,7 +752,6 @@ zfs_do_create(int argc, char **argv)
int ret = 1;
nvlist_t *props;
uint64_t intval;
- int canmount = ZFS_CANMOUNT_OFF;
if (nvlist_alloc(&props, NV_UNIQUE_NAME, 0) != 0)
nomem();
@@ -868,19 +891,15 @@ zfs_do_create(int argc, char **argv)
goto error;
ret = 0;
- /*
- * if the user doesn't want the dataset automatically mounted,
- * then skip the mount/share step
- */
- if (zfs_prop_valid_for_type(ZFS_PROP_CANMOUNT, type))
- canmount = zfs_prop_get_int(zhp, ZFS_PROP_CANMOUNT);
/*
* Mount and/or share the new filesystem as appropriate. We provide a
* verbose error message to let the user know that their filesystem was
* in fact created, even if we failed to mount or share it.
+ * If the user doesn't want the dataset automatically mounted,
+ * then skip the mount/share step altogether.
*/
- if (!nomount && canmount == ZFS_CANMOUNT_ON) {
+ if (!nomount && should_auto_mount(zhp)) {
if (zfs_mount(zhp, NULL, 0) != 0) {
(void) fprintf(stderr, gettext("filesystem "
"successfully created, but not mounted\n"));
diff --git a/cddl/contrib/opensolaris/cmd/ztest/ztest.c b/cddl/contrib/opensolaris/cmd/ztest/ztest.c
index ab69154..0695834 100644
--- a/cddl/contrib/opensolaris/cmd/ztest/ztest.c
+++ b/cddl/contrib/opensolaris/cmd/ztest/ztest.c
@@ -20,7 +20,7 @@
*/
/*
* Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
- * Copyright (c) 2011, 2014 by Delphix. All rights reserved.
+ * Copyright (c) 2011, 2015 by Delphix. All rights reserved.
* Copyright 2011 Nexenta Systems, Inc. All rights reserved.
* Copyright (c) 2012 Martin Matuska <mm@FreeBSD.org>. All rights reserved.
* Copyright (c) 2013 Steven Hartland. All rights reserved.
@@ -969,21 +969,6 @@ ztest_random_spa_version(uint64_t initial_version)
return (version);
}
-/*
- * Find the largest ashift used
- */
-static uint64_t
-ztest_spa_get_ashift() {
- uint64_t i;
- uint64_t ashift = SPA_MINBLOCKSHIFT;
- vdev_t *rvd = ztest_spa->spa_root_vdev;
-
- for (i = 0; i < rvd->vdev_children; i++) {
- ashift = MAX(ashift, rvd->vdev_child[i]->vdev_ashift);
- }
- return (ashift);
-}
-
static int
ztest_random_blocksize(void)
{
@@ -995,7 +980,7 @@ ztest_random_blocksize(void)
int maxbs = SPA_OLD_MAXBLOCKSHIFT;
if (spa_maxblocksize(ztest_spa) == SPA_MAXBLOCKSIZE)
maxbs = 20;
- block_shift = ztest_random(maxbs - ztest_spa_get_ashift() + 1);
+ block_shift = ztest_random(maxbs - ztest_spa->spa_max_ashift + 1);
return (1 << (SPA_MINBLOCKSHIFT + block_shift));
}
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h
index 51bed72..36cc539 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_impl.h
@@ -156,6 +156,21 @@ typedef struct dt_module {
#define DT_DM_KERNEL 0x2 /* module is associated with a kernel object */
#define DT_DM_PRIMARY 0x4 /* module is a krtld primary kernel object */
+#ifdef __FreeBSD__
+/*
+ * A representation of a FreeBSD kernel module, used when checking module
+ * dependencies. This differs from dt_module_t, which refers to a KLD in the
+ * case of kernel probes. Since modules can be identified regardless of whether
+ * they've been compiled into the kernel, we use them to identify DTrace
+ * modules.
+ */
+typedef struct dt_kmodule {
+ struct dt_kmodule *dkm_next; /* hash table entry */
+ char *dkm_name; /* string name of module */
+ dt_module_t *dkm_module; /* corresponding KLD module */
+} dt_kmodule_t;
+#endif
+
typedef struct dt_provmod {
char *dp_name; /* name of provider module */
struct dt_provmod *dp_next; /* next module */
@@ -235,6 +250,9 @@ struct dtrace_hdl {
dt_idhash_t *dt_tls; /* hash table of thread-local identifiers */
dt_list_t dt_modlist; /* linked list of dt_module_t's */
dt_module_t **dt_mods; /* hash table of dt_module_t's */
+#ifdef __FreeBSD__
+ dt_kmodule_t **dt_kmods; /* hash table of dt_kmodule_t's */
+#endif
uint_t dt_modbuckets; /* number of module hash buckets */
uint_t dt_nmods; /* number of modules in hash and list */
dt_provmod_t *dt_provmod; /* linked list of provider modules */
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c
index b3fe516..77f9223 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.c
@@ -37,6 +37,7 @@
#else
#include <sys/param.h>
#include <sys/linker.h>
+#include <sys/module.h>
#include <sys/stat.h>
#endif
@@ -542,6 +543,22 @@ dt_module_lookup_by_ctf(dtrace_hdl_t *dtp, ctf_file_t *ctfp)
return (ctfp ? ctf_getspecific(ctfp) : NULL);
}
+#ifdef __FreeBSD__
+dt_kmodule_t *
+dt_kmodule_lookup(dtrace_hdl_t *dtp, const char *name)
+{
+ uint_t h = dt_strtab_hash(name, NULL) % dtp->dt_modbuckets;
+ dt_kmodule_t *dkmp;
+
+ for (dkmp = dtp->dt_kmods[h]; dkmp != NULL; dkmp = dkmp->dkm_next) {
+ if (strcmp(dkmp->dkm_name, name) == 0)
+ return (dkmp);
+ }
+
+ return (NULL);
+}
+#endif
+
static int
dt_module_load_sect(dtrace_hdl_t *dtp, dt_module_t *dmp, ctf_sect_t *ctsp)
{
@@ -1124,6 +1141,12 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
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;
@@ -1270,6 +1293,33 @@ dt_module_update(dtrace_hdl_t *dtp, struct kld_file_stat *k_stat)
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)) {
+ if (modstat(modid, &ms) != 0) {
+ dt_dprintf("modstat failed for id %d in %s: %s\n",
+ modid, k_stat->name, strerror(errno));
+ continue;
+ }
+ if (dt_kmodule_lookup(dtp, ms.name) != NULL)
+ continue;
+
+ dkmp = malloc(sizeof (*dkmp));
+ if (dkmp == NULL) {
+ dt_dprintf("failed to allocate memory\n");
+ dt_module_destroy(dtp, dmp);
+ return;
+ }
+
+ h = dt_strtab_hash(ms.name, NULL) % dtp->dt_modbuckets;
+ dkmp->dkm_next = dtp->dt_kmods[h];
+ dkmp->dkm_name = strdup(ms.name);
+ 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_module.h b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.h
index d103e02..6db16cc 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.h
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_module.h
@@ -44,6 +44,10 @@ extern void dt_module_destroy(dtrace_hdl_t *, dt_module_t *);
extern dt_module_t *dt_module_lookup_by_name(dtrace_hdl_t *, const char *);
extern dt_module_t *dt_module_lookup_by_ctf(dtrace_hdl_t *, ctf_file_t *);
+#ifdef __FreeBSD__
+extern dt_kmodule_t *dt_kmodule_lookup(dtrace_hdl_t *, const char *);
+#endif
+
extern int dt_module_hasctf(dtrace_hdl_t *, dt_module_t *);
extern ctf_file_t *dt_module_getctf(dtrace_hdl_t *, dt_module_t *);
extern dt_ident_t *dt_module_extern(dtrace_hdl_t *, dt_module_t *,
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c
index 80e4be9..ac0524b 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c
@@ -1178,6 +1178,9 @@ alloc:
#endif
dtp->dt_modbuckets = _dtrace_strbuckets;
dtp->dt_mods = calloc(dtp->dt_modbuckets, sizeof (dt_module_t *));
+#ifdef __FreeBSD__
+ dtp->dt_kmods = calloc(dtp->dt_modbuckets, sizeof (dt_module_t *));
+#endif
dtp->dt_provbuckets = _dtrace_strbuckets;
dtp->dt_provs = calloc(dtp->dt_provbuckets, sizeof (dt_provider_t *));
dt_proc_hash_create(dtp);
@@ -1199,6 +1202,7 @@ alloc:
if (dtp->dt_mods == NULL || dtp->dt_provs == NULL ||
dtp->dt_procs == NULL || dtp->dt_ld_path == NULL ||
#ifdef __FreeBSD__
+ dtp->dt_kmods == NULL ||
dtp->dt_objcopy_path == NULL ||
#endif
dtp->dt_cpp_path == NULL || dtp->dt_cpp_argv == NULL)
@@ -1621,6 +1625,10 @@ dtrace_close(dtrace_hdl_t *dtp)
dtrace_prog_t *pgp;
dt_xlator_t *dxp;
dt_dirpath_t *dirp;
+#ifdef __FreeBSD__
+ dt_kmodule_t *dkm;
+ uint_t h;
+#endif
int i;
if (dtp->dt_procs != NULL)
@@ -1648,6 +1656,15 @@ dtrace_close(dtrace_hdl_t *dtp)
if (dtp->dt_tls != NULL)
dt_idhash_destroy(dtp->dt_tls);
+#ifdef __FreeBSD__
+ for (h = 0; h < dtp->dt_modbuckets; h++)
+ while ((dkm = dtp->dt_kmods[h]) != NULL) {
+ dtp->dt_kmods[h] = dkm->dkm_next;
+ free(dkm->dkm_name);
+ free(dkm);
+ }
+#endif
+
while ((dmp = dt_list_next(&dtp->dt_modlist)) != NULL)
dt_module_destroy(dtp, dmp);
@@ -1697,6 +1714,9 @@ dtrace_close(dtrace_hdl_t *dtp)
#endif
free(dtp->dt_mods);
+#ifdef __FreeBSD__
+ free(dtp->dt_kmods);
+#endif
free(dtp->dt_provs);
free(dtp);
}
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_pragma.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_pragma.c
index bd0d708..550a436 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_pragma.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_pragma.c
@@ -278,6 +278,14 @@ dt_pragma_depends(const char *prname, dt_node_t *cnp)
} else if (strcmp(cnp->dn_string, "module") == 0) {
dt_module_t *mp = dt_module_lookup_by_name(dtp, nnp->dn_string);
found = mp != NULL && dt_module_getctf(dtp, mp) != NULL;
+#ifdef __FreeBSD__
+ if (!found) {
+ dt_kmodule_t *dkmp = dt_kmodule_lookup(dtp,
+ nnp->dn_string);
+ found = dkmp != NULL &&
+ dt_module_getctf(dtp, dkmp->dkm_module) != NULL;
+ }
+#endif
} else if (strcmp(cnp->dn_string, "library") == 0) {
if (yypcb->pcb_cflags & DTRACE_C_CTL) {
assert(dtp->dt_filetag != NULL);
diff --git a/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c b/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c
index c4e9ada..0987024 100644
--- a/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c
+++ b/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c
@@ -23,6 +23,7 @@
* Copyright 2015 Nexenta Systems, Inc. All rights reserved.
* Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013 by Delphix. All rights reserved.
+ * Copyright 2015 RackTop Systems.
*/
/*
@@ -1094,11 +1095,7 @@ zpool_open_func(void *arg)
}
(void) close(fd);
-
rn->rn_config = config;
- if (config != NULL) {
- assert(rn->rn_nozpool == B_FALSE);
- }
}
/*
diff --git a/cddl/lib/drti/Makefile.depend b/cddl/lib/drti/Makefile.depend
index 2c564fe..422dbea 100644
--- a/cddl/lib/drti/Makefile.depend
+++ b/cddl/lib/drti/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libavl/Makefile.depend b/cddl/lib/libavl/Makefile.depend
index c9d74dc..3699b06 100644
--- a/cddl/lib/libavl/Makefile.depend
+++ b/cddl/lib/libavl/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libctf/Makefile.depend b/cddl/lib/libctf/Makefile.depend
index b1a0bae..4b536f7 100644
--- a/cddl/lib/libctf/Makefile.depend
+++ b/cddl/lib/libctf/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libdtrace/Makefile.depend b/cddl/lib/libdtrace/Makefile.depend
index 411b469..124d5c7 100644
--- a/cddl/lib/libdtrace/Makefile.depend
+++ b/cddl/lib/libdtrace/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libnvpair/Makefile.depend b/cddl/lib/libnvpair/Makefile.depend
index a83fb20..3dce64a 100644
--- a/cddl/lib/libnvpair/Makefile.depend
+++ b/cddl/lib/libnvpair/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libumem/Makefile.depend b/cddl/lib/libumem/Makefile.depend
index c9d74dc..3699b06 100644
--- a/cddl/lib/libumem/Makefile.depend
+++ b/cddl/lib/libumem/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libuutil/Makefile.depend b/cddl/lib/libuutil/Makefile.depend
index 593d407..dde2d60 100644
--- a/cddl/lib/libuutil/Makefile.depend
+++ b/cddl/lib/libuutil/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libzfs/Makefile.depend b/cddl/lib/libzfs/Makefile.depend
index 3380eff..8c2b34b 100644
--- a/cddl/lib/libzfs/Makefile.depend
+++ b/cddl/lib/libzfs/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libzfs_core/Makefile.depend b/cddl/lib/libzfs_core/Makefile.depend
index 3abceb8..9e7fae2 100644
--- a/cddl/lib/libzfs_core/Makefile.depend
+++ b/cddl/lib/libzfs_core/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/lib/libzpool/Makefile.depend b/cddl/lib/libzpool/Makefile.depend
index 667f0fd..cb67e22 100644
--- a/cddl/lib/libzpool/Makefile.depend
+++ b/cddl/lib/libzpool/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/sbin/zfs/Makefile.depend b/cddl/sbin/zfs/Makefile.depend
index 2648cea..03bb95d 100644
--- a/cddl/sbin/zfs/Makefile.depend
+++ b/cddl/sbin/zfs/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/sbin/zpool/Makefile.depend b/cddl/sbin/zpool/Makefile.depend
index 80ee84f..08245ad 100644
--- a/cddl/sbin/zpool/Makefile.depend
+++ b/cddl/sbin/zpool/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.bin/ctfconvert/Makefile.depend b/cddl/usr.bin/ctfconvert/Makefile.depend
index 6a7ea61..f479cfc 100644
--- a/cddl/usr.bin/ctfconvert/Makefile.depend
+++ b/cddl/usr.bin/ctfconvert/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DEP_RELDIR := ${_PARSEDIR:S,${SRCTOP}/,,}
diff --git a/cddl/usr.bin/ctfdump/Makefile.depend b/cddl/usr.bin/ctfdump/Makefile.depend
index 2dd7922..6b3e8f7 100644
--- a/cddl/usr.bin/ctfdump/Makefile.depend
+++ b/cddl/usr.bin/ctfdump/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DEP_RELDIR := ${_PARSEDIR:S,${SRCTOP}/,,}
diff --git a/cddl/usr.bin/ctfmerge/Makefile.depend b/cddl/usr.bin/ctfmerge/Makefile.depend
index 6a7ea61..f479cfc 100644
--- a/cddl/usr.bin/ctfmerge/Makefile.depend
+++ b/cddl/usr.bin/ctfmerge/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DEP_RELDIR := ${_PARSEDIR:S,${SRCTOP}/,,}
diff --git a/cddl/usr.bin/sgsmsg/Makefile.depend b/cddl/usr.bin/sgsmsg/Makefile.depend
index 7e64306..b767569 100644
--- a/cddl/usr.bin/sgsmsg/Makefile.depend
+++ b/cddl/usr.bin/sgsmsg/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.bin/zinject/Makefile.depend b/cddl/usr.bin/zinject/Makefile.depend
index 1e6ee39..deb1256 100644
--- a/cddl/usr.bin/zinject/Makefile.depend
+++ b/cddl/usr.bin/zinject/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.bin/zstreamdump/Makefile.depend b/cddl/usr.bin/zstreamdump/Makefile.depend
index 7f2f2a4..138e88b 100644
--- a/cddl/usr.bin/zstreamdump/Makefile.depend
+++ b/cddl/usr.bin/zstreamdump/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.bin/ztest/Makefile.depend b/cddl/usr.bin/ztest/Makefile.depend
index 1e6ee39..deb1256 100644
--- a/cddl/usr.bin/ztest/Makefile.depend
+++ b/cddl/usr.bin/ztest/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/dtrace/Makefile.depend b/cddl/usr.sbin/dtrace/Makefile.depend
index 516fe67..2efd35c 100644
--- a/cddl/usr.sbin/dtrace/Makefile.depend
+++ b/cddl/usr.sbin/dtrace/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DEP_RELDIR := ${_PARSEDIR:S,${SRCTOP}/,,}
diff --git a/cddl/usr.sbin/dtruss/Makefile.depend b/cddl/usr.sbin/dtruss/Makefile.depend
index 57b7e10..d14a02b 100644
--- a/cddl/usr.sbin/dtruss/Makefile.depend
+++ b/cddl/usr.sbin/dtruss/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DEP_RELDIR := ${_PARSEDIR:S,${SRCTOP}/,,}
diff --git a/cddl/usr.sbin/lockstat/Makefile.depend b/cddl/usr.sbin/lockstat/Makefile.depend
index 08502fb..70f0672 100644
--- a/cddl/usr.sbin/lockstat/Makefile.depend
+++ b/cddl/usr.sbin/lockstat/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/zdb/Makefile.depend b/cddl/usr.sbin/zdb/Makefile.depend
index 1e6ee39..deb1256 100644
--- a/cddl/usr.sbin/zdb/Makefile.depend
+++ b/cddl/usr.sbin/zdb/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
diff --git a/cddl/usr.sbin/zhack/Makefile.depend b/cddl/usr.sbin/zhack/Makefile.depend
index 1e6ee39..deb1256 100644
--- a/cddl/usr.sbin/zhack/Makefile.depend
+++ b/cddl/usr.sbin/zhack/Makefile.depend
@@ -1,3 +1,4 @@
+# $FreeBSD$
# Autogenerated - do NOT edit!
DIRDEPS = \
OpenPOWER on IntegriCloud